From 32e183108ae521955e93fcd8b55fef19b501c289 Mon Sep 17 00:00:00 2001 From: Zygo Blaxell Date: Sun, 1 Mar 2009 20:47:42 -0500 Subject: [PATCH] ftp://ftp.zenez.com/pub/SCO/skunkware/src/x11/savers/xscreensaver-2.16-src.tar.gz -rw-r--r-- 1 zblaxell zblaxell 753590 Jun 2 2001 xscreensaver-2.16-src.tar.gz 138a4faae4898675887a27f608eb359d70aadbc1 xscreensaver-2.16-src.tar.gz --- INSTALL | 183 + Makefile.in | 76 + README | 367 ++ README.VMS | 57 + README.debugging | 141 + README.skunkware | 23 + config.guess | 693 +++ config.h-vms | 251 + config.h.in | 267 ++ config.sub | 927 ++++ configure | 6052 +++++++++++++++++++++++++ configure-98 | 5 + configure-ancilla | 14 + configure-skunkware | 6 + configure-skunkware.00 | 5 + configure.in | 1401 ++++++ driver/.gdbinit | 25 + driver/Makefile.in | 305 ++ driver/README | 6 + driver/XScreenSaver.ad.in | 426 ++ driver/compile_axp.com | 15 + driver/compile_decc.com | 15 + driver/demo.c | 1019 +++++ driver/dialogs-Xaw.c | 311 ++ driver/dialogs-Xm.c | 701 +++ driver/dialogs.xd | 569 +++ driver/kpasswd.c | 180 + driver/link_axp.com | 15 + driver/link_decc.com | 15 + driver/lock.c | 735 +++ driver/passwd.c | 240 + driver/stderr.c | 451 ++ driver/subprocs.c | 1139 +++++ driver/timers.c | 633 +++ driver/vms-getpwnam.c | 132 + driver/vms-hpwd.c | 75 + driver/vms-pwd.h | 48 + driver/vms-validate.c | 75 + driver/vms_axp.opt | 5 + driver/vms_axp_12.opt | 5 + driver/vms_decc.opt | 5 + driver/vms_decc_12.opt | 5 + driver/windows.c | 1148 +++++ driver/xscreensaver-command.c | 260 ++ driver/xscreensaver-command.man | 132 + driver/xscreensaver.c | 1137 +++++ driver/xscreensaver.h | 376 ++ driver/xscreensaver.man | 853 ++++ driver/xset.c | 236 + hacks/.gdbinit | 4 + hacks/Makefile.in | 1257 +++++ hacks/README | 6 + hacks/ant.c | 1094 +++++ hacks/attraction.c | 666 +++ hacks/attraction.man | 178 + hacks/blitspin.c | 365 ++ hacks/blitspin.man | 106 + hacks/bouboule.c | 841 ++++ hacks/bouboule.man | 76 + hacks/braid.c | 434 ++ hacks/braid.man | 65 + hacks/bubbles-default.c | 151 + hacks/bubbles.c | 1321 ++++++ hacks/bubbles.h | 214 + hacks/bubbles.man | 142 + hacks/compile_axp.com | 66 + hacks/compile_decc.com | 66 + hacks/coral.c | 257 ++ hacks/cynosure.c | 390 ++ hacks/decayscreen.c | 212 + hacks/decayscreen.man | 86 + hacks/deco.c | 152 + hacks/deco.man | 72 + hacks/drift.c | 630 +++ hacks/drift.man | 75 + hacks/fadeplot.c | 177 + hacks/flag.c | 597 +++ hacks/flag.man | 88 + hacks/flame.c | 409 ++ hacks/flame.man | 70 + hacks/forest.c | 211 + hacks/forest.man | 63 + hacks/galaxy.c | 469 ++ hacks/galaxy.man | 83 + hacks/glx/Makefile.in | 365 ++ hacks/glx/README | 10 + hacks/glx/buildlwo.c | 101 + hacks/glx/buildlwo.h | 24 + hacks/glx/cage.c | 452 ++ hacks/glx/e_textures.h | 1478 ++++++ hacks/glx/gears.c | 518 +++ hacks/glx/moebius.c | 711 +++ hacks/glx/morph3d.c | 890 ++++ hacks/glx/pipeobjs.c | 3267 +++++++++++++ hacks/glx/pipes.c | 1036 +++++ hacks/glx/rubik.c | 1812 ++++++++ hacks/glx/s1_1.c | 1057 +++++ hacks/glx/s1_2.c | 1057 +++++ hacks/glx/s1_3.c | 1057 +++++ hacks/glx/s1_4.c | 1057 +++++ hacks/glx/s1_5.c | 1057 +++++ hacks/glx/s1_6.c | 1057 +++++ hacks/glx/s1_b.c | 537 +++ hacks/glx/sproingies.c | 827 ++++ hacks/glx/sproingiewrap.c | 244 + hacks/glx/stairs.c | 495 ++ hacks/glx/superquadrics.c | 778 ++++ hacks/glx/xlock-gl.c | 180 + hacks/goop.c | 534 +++ hacks/goop.man | 81 + hacks/grav.c | 322 ++ hacks/grav.man | 74 + hacks/greynetic.c | 182 + hacks/greynetic.man | 52 + hacks/halo.c | 450 ++ hacks/halo.man | 80 + hacks/helix.c | 303 ++ hacks/helix.man | 63 + hacks/hopalong.c | 260 ++ hacks/hopalong.man | 78 + hacks/hypercube.c | 328 ++ hacks/hypercube.man | 93 + hacks/ifs.c | 478 ++ hacks/ifs.man | 59 + hacks/images/bob.xbm | 43 + hacks/images/bubbles/blood.pov | 24 + hacks/images/bubbles/blood1.xpm | 74 + hacks/images/bubbles/blood10.xpm | 257 ++ hacks/images/bubbles/blood11.xpm | 269 ++ hacks/images/bubbles/blood2.xpm | 100 + hacks/images/bubbles/blood3.xpm | 122 + hacks/images/bubbles/blood4.xpm | 171 + hacks/images/bubbles/blood5.xpm | 201 + hacks/images/bubbles/blood6.xpm | 220 + hacks/images/bubbles/blood7.xpm | 228 + hacks/images/bubbles/blood8.xpm | 241 + hacks/images/bubbles/blood9.xpm | 247 + hacks/images/bubbles/blue.pov | 22 + hacks/images/bubbles/blue1.xpm | 63 + hacks/images/bubbles/blue10.xpm | 240 + hacks/images/bubbles/blue11.xpm | 254 ++ hacks/images/bubbles/blue2.xpm | 89 + hacks/images/bubbles/blue3.xpm | 103 + hacks/images/bubbles/blue4.xpm | 157 + hacks/images/bubbles/blue5.xpm | 170 + hacks/images/bubbles/blue6.xpm | 195 + hacks/images/bubbles/blue7.xpm | 212 + hacks/images/bubbles/blue8.xpm | 219 + hacks/images/bubbles/blue9.xpm | 227 + hacks/images/bubbles/glass.pov | 27 + hacks/images/bubbles/glass1.xpm | 78 + hacks/images/bubbles/glass10.xpm | 256 ++ hacks/images/bubbles/glass11.xpm | 268 ++ hacks/images/bubbles/glass2.xpm | 94 + hacks/images/bubbles/glass3.xpm | 111 + hacks/images/bubbles/glass4.xpm | 178 + hacks/images/bubbles/glass5.xpm | 195 + hacks/images/bubbles/glass6.xpm | 218 + hacks/images/bubbles/glass7.xpm | 230 + hacks/images/bubbles/glass8.xpm | 240 + hacks/images/bubbles/glass9.xpm | 245 + hacks/images/bubbles/jade.pov | 24 + hacks/images/bubbles/jade1.xpm | 75 + hacks/images/bubbles/jade10.xpm | 259 ++ hacks/images/bubbles/jade11.xpm | 271 ++ hacks/images/bubbles/jade2.xpm | 95 + hacks/images/bubbles/jade3.xpm | 114 + hacks/images/bubbles/jade4.xpm | 170 + hacks/images/bubbles/jade5.xpm | 200 + hacks/images/bubbles/jade6.xpm | 222 + hacks/images/bubbles/jade7.xpm | 232 + hacks/images/bubbles/jade8.xpm | 240 + hacks/images/bubbles/jade9.xpm | 248 + hacks/images/noseguy/nose-f1.xbm | 38 + hacks/images/noseguy/nose-f1.xpm | 74 + hacks/images/noseguy/nose-f2.xbm | 38 + hacks/images/noseguy/nose-f2.xpm | 74 + hacks/images/noseguy/nose-f3.xbm | 38 + hacks/images/noseguy/nose-f3.xpm | 74 + hacks/images/noseguy/nose-f4.xbm | 38 + hacks/images/noseguy/nose-f4.xpm | 73 + hacks/images/noseguy/nose-l1.xbm | 38 + hacks/images/noseguy/nose-l1.xpm | 74 + hacks/images/noseguy/nose-l2.xbm | 38 + hacks/images/noseguy/nose-l2.xpm | 74 + hacks/images/noseguy/nose-r1.xbm | 38 + hacks/images/noseguy/nose-r1.xpm | 74 + hacks/images/noseguy/nose-r2.xbm | 38 + hacks/images/noseguy/nose-r2.xpm | 74 + hacks/images/puzzle/puzzle.xbm | 1614 +++++++ hacks/images/puzzle/puzzle_a_e_f.xbm | 77 + hacks/images/puzzle/puzzle_a_e_h.xbm | 77 + hacks/images/puzzle/puzzle_a_f.xbm | 96 + hacks/images/puzzle/puzzle_a_h.xbm | 96 + hacks/images/puzzle/puzzle_a_n_f.xbm | 91 + hacks/images/puzzle/puzzle_a_n_h.xbm | 91 + hacks/images/puzzle/puzzle_a_ne_f.xbm | 79 + hacks/images/puzzle/puzzle_a_ne_h.xbm | 79 + hacks/images/puzzle/puzzle_a_nw_f.xbm | 73 + hacks/images/puzzle/puzzle_a_nw_h.xbm | 73 + hacks/images/puzzle/puzzle_a_s_f.xbm | 91 + hacks/images/puzzle/puzzle_a_s_h.xbm | 91 + hacks/images/puzzle/puzzle_a_se_f.xbm | 73 + hacks/images/puzzle/puzzle_a_se_h.xbm | 73 + hacks/images/puzzle/puzzle_a_sw_f.xbm | 73 + hacks/images/puzzle/puzzle_a_sw_h.xbm | 73 + hacks/images/puzzle/puzzle_a_w_f.xbm | 77 + hacks/images/puzzle/puzzle_a_w_h.xbm | 77 + hacks/images/puzzle/puzzle_b_e_f.xbm | 95 + hacks/images/puzzle/puzzle_b_e_h.xbm | 95 + hacks/images/puzzle/puzzle_b_f.xbm | 95 + hacks/images/puzzle/puzzle_b_h.xbm | 95 + hacks/images/puzzle/puzzle_b_n_f.xbm | 79 + hacks/images/puzzle/puzzle_b_n_h.xbm | 79 + hacks/images/puzzle/puzzle_b_ne_f.xbm | 79 + hacks/images/puzzle/puzzle_b_ne_h.xbm | 79 + hacks/images/puzzle/puzzle_b_nw_f.xbm | 79 + hacks/images/puzzle/puzzle_b_nw_h.xbm | 79 + hacks/images/puzzle/puzzle_b_s_f.xbm | 79 + hacks/images/puzzle/puzzle_b_s_h.xbm | 79 + hacks/images/puzzle/puzzle_b_se_f.xbm | 79 + hacks/images/puzzle/puzzle_b_se_h.xbm | 79 + hacks/images/puzzle/puzzle_b_sw_f.xbm | 79 + hacks/images/puzzle/puzzle_b_sw_h.xbm | 79 + hacks/images/puzzle/puzzle_b_w_f.xbm | 95 + hacks/images/puzzle/puzzle_b_w_h.xbm | 95 + hacks/images/som.xbm | 1685 +++++++ hacks/imsmap.c | 502 ++ hacks/imsmap.man | 66 + hacks/julia.c | 420 ++ hacks/julia.man | 83 + hacks/kaleidescope.c | 464 ++ hacks/kaleidescope.man | 85 + hacks/laser.c | 319 ++ hacks/laser.man | 64 + hacks/lightning.c | 580 +++ hacks/lightning.man | 58 + hacks/link_axp.com | 109 + hacks/link_decc.com | 109 + hacks/lisa.c | 485 ++ hacks/lisa.man | 67 + hacks/lissie.c | 284 ++ hacks/lmorph.c | 508 +++ hacks/lmorph.man | 54 + hacks/maze.c | 1522 +++++++ hacks/maze.man | 134 + hacks/moire.c | 193 + hacks/moire.man | 64 + hacks/moire2.c | 278 ++ hacks/mountain.c | 235 + hacks/munch.c | 256 ++ hacks/munch.man | 133 + hacks/noseguy.c | 720 +++ hacks/noseguy.man | 74 + hacks/pedal.c | 380 ++ hacks/pedal.man | 62 + hacks/penrose.c | 1285 ++++++ hacks/penrose.man | 93 + hacks/puzzle.c | 579 +++ hacks/puzzle.man | 74 + hacks/pyro.c | 248 + hacks/pyro.man | 60 + hacks/qix.c | 510 +++ hacks/qix.man | 129 + hacks/rd-bomb.c | 514 +++ hacks/rd-bomb.man | 98 + hacks/rocks.c | 533 +++ hacks/rocks.man | 86 + hacks/rorschach.c | 138 + hacks/rorschach.man | 75 + hacks/rotor.c | 348 ++ hacks/screenhack.c | 325 ++ hacks/screenhack.h | 98 + hacks/sierpinski.c | 184 + hacks/sierpinski.man | 65 + hacks/slidescreen.c | 362 ++ hacks/slidescreen.man | 92 + hacks/slip.c | 301 ++ hacks/slip.man | 93 + hacks/sphere.c | 246 + hacks/sphere.man | 58 + hacks/spiral.c | 300 ++ hacks/spiral.man | 67 + hacks/starfish.c | 535 +++ hacks/starfish.man | 89 + hacks/strange.c | 404 ++ hacks/strange.man | 58 + hacks/swirl.c | 1456 ++++++ hacks/swirl.man | 64 + hacks/triangle.c | 362 ++ hacks/vidwhacker | 264 ++ hacks/vines.c | 142 + hacks/vines.man | 62 + hacks/vms_axp.opt | 4 + hacks/vms_axp_12.opt | 4 + hacks/vms_decc.opt | 4 + hacks/vms_decc_12.opt | 4 + hacks/worm.c | 441 ++ hacks/xjack.c | 361 ++ hacks/xjack.man | 51 + hacks/xlock.h | 192 + hacks/xlockmore.c | 356 ++ hacks/xlockmore.h | 152 + hacks/xlockmoreI.h | 104 + hacks/xlyap.c | 1973 ++++++++ hacks/xlyap.c.00 | 1965 ++++++++ hacks/xlyap.man | 237 + hacks/xroger-hack.c | 102 + hacks/xroger.man | 52 + hacks/xscreensaver-sgigl.c | 256 ++ install-sh | 250 + makevms.com | 57 + screenblank.txt | 46 + setup.com | 72 + utils/Makefile.in | 190 + utils/README | 6 + utils/ad2c | 38 + utils/alpha.c | 177 + utils/alpha.h | 32 + utils/colors.c | 685 +++ utils/colors.h | 140 + utils/compile_axp.com | 20 + utils/compile_decc.com | 20 + utils/erase.c | 397 ++ utils/erase.h | 15 + utils/fade.c | 621 +++ utils/fade.h | 21 + utils/grabscreen.c | 722 +++ utils/grabscreen.h | 27 + utils/hsv.c | 81 + utils/hsv.h | 27 + utils/overlay.c | 126 + utils/resources.c | 214 + utils/resources.h | 24 + utils/sgivideo.c | 502 ++ utils/sgivideo.h | 18 + utils/spline.c | 321 ++ utils/spline.h | 60 + utils/usleep.c | 58 + utils/usleep.h | 20 + utils/utils.h | 22 + utils/version.h | 2 + utils/visual.c | 465 ++ utils/visual.h | 27 + utils/vms-gtod.c | 31 + utils/vms-gtod.h | 85 + utils/vms-strdup.c | 25 + utils/vroot.h | 126 + utils/xmu.c | 168 + utils/xmu.h | 14 + utils/xroger.c | 134 + utils/yarandom.c | 114 + utils/yarandom.h | 52 + xscreensaver.lsm | 28 + xscreensaver.lsm.sh | 53 + 355 files changed, 103263 insertions(+) create mode 100644 INSTALL create mode 100644 Makefile.in create mode 100644 README create mode 100644 README.VMS create mode 100644 README.debugging create mode 100644 README.skunkware create mode 100755 config.guess create mode 100644 config.h-vms create mode 100644 config.h.in create mode 100755 config.sub create mode 100755 configure create mode 100755 configure-98 create mode 100755 configure-ancilla create mode 100755 configure-skunkware create mode 100755 configure-skunkware.00 create mode 100644 configure.in create mode 100644 driver/.gdbinit create mode 100644 driver/Makefile.in create mode 100644 driver/README create mode 100644 driver/XScreenSaver.ad.in create mode 100644 driver/compile_axp.com create mode 100644 driver/compile_decc.com create mode 100644 driver/demo.c create mode 100644 driver/dialogs-Xaw.c create mode 100644 driver/dialogs-Xm.c create mode 100644 driver/dialogs.xd create mode 100644 driver/kpasswd.c create mode 100644 driver/link_axp.com create mode 100644 driver/link_decc.com create mode 100644 driver/lock.c create mode 100644 driver/passwd.c create mode 100644 driver/stderr.c create mode 100644 driver/subprocs.c create mode 100644 driver/timers.c create mode 100644 driver/vms-getpwnam.c create mode 100644 driver/vms-hpwd.c create mode 100644 driver/vms-pwd.h create mode 100644 driver/vms-validate.c create mode 100644 driver/vms_axp.opt create mode 100644 driver/vms_axp_12.opt create mode 100644 driver/vms_decc.opt create mode 100644 driver/vms_decc_12.opt create mode 100644 driver/windows.c create mode 100644 driver/xscreensaver-command.c create mode 100644 driver/xscreensaver-command.man create mode 100644 driver/xscreensaver.c create mode 100644 driver/xscreensaver.h create mode 100644 driver/xscreensaver.man create mode 100644 driver/xset.c create mode 100644 hacks/.gdbinit create mode 100644 hacks/Makefile.in create mode 100644 hacks/README create mode 100644 hacks/ant.c create mode 100644 hacks/attraction.c create mode 100644 hacks/attraction.man create mode 100644 hacks/blitspin.c create mode 100644 hacks/blitspin.man create mode 100644 hacks/bouboule.c create mode 100644 hacks/bouboule.man create mode 100644 hacks/braid.c create mode 100644 hacks/braid.man create mode 100644 hacks/bubbles-default.c create mode 100644 hacks/bubbles.c create mode 100644 hacks/bubbles.h create mode 100644 hacks/bubbles.man create mode 100644 hacks/compile_axp.com create mode 100644 hacks/compile_decc.com create mode 100644 hacks/coral.c create mode 100644 hacks/cynosure.c create mode 100644 hacks/decayscreen.c create mode 100644 hacks/decayscreen.man create mode 100644 hacks/deco.c create mode 100644 hacks/deco.man create mode 100644 hacks/drift.c create mode 100644 hacks/drift.man create mode 100644 hacks/fadeplot.c create mode 100644 hacks/flag.c create mode 100644 hacks/flag.man create mode 100644 hacks/flame.c create mode 100644 hacks/flame.man create mode 100644 hacks/forest.c create mode 100644 hacks/forest.man create mode 100644 hacks/galaxy.c create mode 100644 hacks/galaxy.man create mode 100644 hacks/glx/Makefile.in create mode 100644 hacks/glx/README create mode 100644 hacks/glx/buildlwo.c create mode 100644 hacks/glx/buildlwo.h create mode 100644 hacks/glx/cage.c create mode 100644 hacks/glx/e_textures.h create mode 100644 hacks/glx/gears.c create mode 100644 hacks/glx/moebius.c create mode 100644 hacks/glx/morph3d.c create mode 100644 hacks/glx/pipeobjs.c create mode 100644 hacks/glx/pipes.c create mode 100644 hacks/glx/rubik.c create mode 100644 hacks/glx/s1_1.c create mode 100644 hacks/glx/s1_2.c create mode 100644 hacks/glx/s1_3.c create mode 100644 hacks/glx/s1_4.c create mode 100644 hacks/glx/s1_5.c create mode 100644 hacks/glx/s1_6.c create mode 100644 hacks/glx/s1_b.c create mode 100644 hacks/glx/sproingies.c create mode 100644 hacks/glx/sproingiewrap.c create mode 100644 hacks/glx/stairs.c create mode 100644 hacks/glx/superquadrics.c create mode 100644 hacks/glx/xlock-gl.c create mode 100644 hacks/goop.c create mode 100644 hacks/goop.man create mode 100644 hacks/grav.c create mode 100644 hacks/grav.man create mode 100644 hacks/greynetic.c create mode 100644 hacks/greynetic.man create mode 100644 hacks/halo.c create mode 100644 hacks/halo.man create mode 100644 hacks/helix.c create mode 100644 hacks/helix.man create mode 100644 hacks/hopalong.c create mode 100644 hacks/hopalong.man create mode 100644 hacks/hypercube.c create mode 100644 hacks/hypercube.man create mode 100644 hacks/ifs.c create mode 100644 hacks/ifs.man create mode 100644 hacks/images/bob.xbm create mode 100644 hacks/images/bubbles/blood.pov create mode 100644 hacks/images/bubbles/blood1.xpm create mode 100644 hacks/images/bubbles/blood10.xpm create mode 100644 hacks/images/bubbles/blood11.xpm create mode 100644 hacks/images/bubbles/blood2.xpm create mode 100644 hacks/images/bubbles/blood3.xpm create mode 100644 hacks/images/bubbles/blood4.xpm create mode 100644 hacks/images/bubbles/blood5.xpm create mode 100644 hacks/images/bubbles/blood6.xpm create mode 100644 hacks/images/bubbles/blood7.xpm create mode 100644 hacks/images/bubbles/blood8.xpm create mode 100644 hacks/images/bubbles/blood9.xpm create mode 100644 hacks/images/bubbles/blue.pov create mode 100644 hacks/images/bubbles/blue1.xpm create mode 100644 hacks/images/bubbles/blue10.xpm create mode 100644 hacks/images/bubbles/blue11.xpm create mode 100644 hacks/images/bubbles/blue2.xpm create mode 100644 hacks/images/bubbles/blue3.xpm create mode 100644 hacks/images/bubbles/blue4.xpm create mode 100644 hacks/images/bubbles/blue5.xpm create mode 100644 hacks/images/bubbles/blue6.xpm create mode 100644 hacks/images/bubbles/blue7.xpm create mode 100644 hacks/images/bubbles/blue8.xpm create mode 100644 hacks/images/bubbles/blue9.xpm create mode 100644 hacks/images/bubbles/glass.pov create mode 100644 hacks/images/bubbles/glass1.xpm create mode 100644 hacks/images/bubbles/glass10.xpm create mode 100644 hacks/images/bubbles/glass11.xpm create mode 100644 hacks/images/bubbles/glass2.xpm create mode 100644 hacks/images/bubbles/glass3.xpm create mode 100644 hacks/images/bubbles/glass4.xpm create mode 100644 hacks/images/bubbles/glass5.xpm create mode 100644 hacks/images/bubbles/glass6.xpm create mode 100644 hacks/images/bubbles/glass7.xpm create mode 100644 hacks/images/bubbles/glass8.xpm create mode 100644 hacks/images/bubbles/glass9.xpm create mode 100644 hacks/images/bubbles/jade.pov create mode 100644 hacks/images/bubbles/jade1.xpm create mode 100644 hacks/images/bubbles/jade10.xpm create mode 100644 hacks/images/bubbles/jade11.xpm create mode 100644 hacks/images/bubbles/jade2.xpm create mode 100644 hacks/images/bubbles/jade3.xpm create mode 100644 hacks/images/bubbles/jade4.xpm create mode 100644 hacks/images/bubbles/jade5.xpm create mode 100644 hacks/images/bubbles/jade6.xpm create mode 100644 hacks/images/bubbles/jade7.xpm create mode 100644 hacks/images/bubbles/jade8.xpm create mode 100644 hacks/images/bubbles/jade9.xpm create mode 100644 hacks/images/noseguy/nose-f1.xbm create mode 100644 hacks/images/noseguy/nose-f1.xpm create mode 100644 hacks/images/noseguy/nose-f2.xbm create mode 100644 hacks/images/noseguy/nose-f2.xpm create mode 100644 hacks/images/noseguy/nose-f3.xbm create mode 100644 hacks/images/noseguy/nose-f3.xpm create mode 100644 hacks/images/noseguy/nose-f4.xbm create mode 100644 hacks/images/noseguy/nose-f4.xpm create mode 100644 hacks/images/noseguy/nose-l1.xbm create mode 100644 hacks/images/noseguy/nose-l1.xpm create mode 100644 hacks/images/noseguy/nose-l2.xbm create mode 100644 hacks/images/noseguy/nose-l2.xpm create mode 100644 hacks/images/noseguy/nose-r1.xbm create mode 100644 hacks/images/noseguy/nose-r1.xpm create mode 100644 hacks/images/noseguy/nose-r2.xbm create mode 100644 hacks/images/noseguy/nose-r2.xpm create mode 100644 hacks/images/puzzle/puzzle.xbm create mode 100644 hacks/images/puzzle/puzzle_a_e_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_e_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_n_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_n_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_ne_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_ne_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_nw_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_nw_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_s_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_s_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_se_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_se_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_sw_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_sw_h.xbm create mode 100644 hacks/images/puzzle/puzzle_a_w_f.xbm create mode 100644 hacks/images/puzzle/puzzle_a_w_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_e_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_e_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_n_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_n_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_ne_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_ne_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_nw_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_nw_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_s_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_s_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_se_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_se_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_sw_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_sw_h.xbm create mode 100644 hacks/images/puzzle/puzzle_b_w_f.xbm create mode 100644 hacks/images/puzzle/puzzle_b_w_h.xbm create mode 100644 hacks/images/som.xbm create mode 100644 hacks/imsmap.c create mode 100644 hacks/imsmap.man create mode 100644 hacks/julia.c create mode 100644 hacks/julia.man create mode 100644 hacks/kaleidescope.c create mode 100644 hacks/kaleidescope.man create mode 100644 hacks/laser.c create mode 100644 hacks/laser.man create mode 100644 hacks/lightning.c create mode 100644 hacks/lightning.man create mode 100644 hacks/link_axp.com create mode 100644 hacks/link_decc.com create mode 100644 hacks/lisa.c create mode 100644 hacks/lisa.man create mode 100644 hacks/lissie.c create mode 100644 hacks/lmorph.c create mode 100644 hacks/lmorph.man create mode 100644 hacks/maze.c create mode 100644 hacks/maze.man create mode 100644 hacks/moire.c create mode 100644 hacks/moire.man create mode 100644 hacks/moire2.c create mode 100644 hacks/mountain.c create mode 100644 hacks/munch.c create mode 100644 hacks/munch.man create mode 100644 hacks/noseguy.c create mode 100644 hacks/noseguy.man create mode 100644 hacks/pedal.c create mode 100644 hacks/pedal.man create mode 100644 hacks/penrose.c create mode 100644 hacks/penrose.man create mode 100644 hacks/puzzle.c create mode 100644 hacks/puzzle.man create mode 100644 hacks/pyro.c create mode 100644 hacks/pyro.man create mode 100644 hacks/qix.c create mode 100644 hacks/qix.man create mode 100644 hacks/rd-bomb.c create mode 100644 hacks/rd-bomb.man create mode 100644 hacks/rocks.c create mode 100644 hacks/rocks.man create mode 100644 hacks/rorschach.c create mode 100644 hacks/rorschach.man create mode 100644 hacks/rotor.c create mode 100644 hacks/screenhack.c create mode 100644 hacks/screenhack.h create mode 100644 hacks/sierpinski.c create mode 100644 hacks/sierpinski.man create mode 100644 hacks/slidescreen.c create mode 100644 hacks/slidescreen.man create mode 100644 hacks/slip.c create mode 100644 hacks/slip.man create mode 100644 hacks/sphere.c create mode 100644 hacks/sphere.man create mode 100644 hacks/spiral.c create mode 100644 hacks/spiral.man create mode 100644 hacks/starfish.c create mode 100644 hacks/starfish.man create mode 100644 hacks/strange.c create mode 100644 hacks/strange.man create mode 100644 hacks/swirl.c create mode 100644 hacks/swirl.man create mode 100644 hacks/triangle.c create mode 100755 hacks/vidwhacker create mode 100644 hacks/vines.c create mode 100644 hacks/vines.man create mode 100644 hacks/vms_axp.opt create mode 100644 hacks/vms_axp_12.opt create mode 100644 hacks/vms_decc.opt create mode 100644 hacks/vms_decc_12.opt create mode 100644 hacks/worm.c create mode 100644 hacks/xjack.c create mode 100644 hacks/xjack.man create mode 100644 hacks/xlock.h create mode 100644 hacks/xlockmore.c create mode 100644 hacks/xlockmore.h create mode 100644 hacks/xlockmoreI.h create mode 100644 hacks/xlyap.c create mode 100644 hacks/xlyap.c.00 create mode 100644 hacks/xlyap.man create mode 100644 hacks/xroger-hack.c create mode 100644 hacks/xroger.man create mode 100644 hacks/xscreensaver-sgigl.c create mode 100755 install-sh create mode 100644 makevms.com create mode 100644 screenblank.txt create mode 100644 setup.com create mode 100644 utils/Makefile.in create mode 100644 utils/README create mode 100755 utils/ad2c create mode 100644 utils/alpha.c create mode 100644 utils/alpha.h create mode 100644 utils/colors.c create mode 100644 utils/colors.h create mode 100644 utils/compile_axp.com create mode 100644 utils/compile_decc.com create mode 100644 utils/erase.c create mode 100644 utils/erase.h create mode 100644 utils/fade.c create mode 100644 utils/fade.h create mode 100644 utils/grabscreen.c create mode 100644 utils/grabscreen.h create mode 100644 utils/hsv.c create mode 100644 utils/hsv.h create mode 100644 utils/overlay.c create mode 100644 utils/resources.c create mode 100644 utils/resources.h create mode 100644 utils/sgivideo.c create mode 100644 utils/sgivideo.h create mode 100644 utils/spline.c create mode 100644 utils/spline.h create mode 100644 utils/usleep.c create mode 100644 utils/usleep.h create mode 100644 utils/utils.h create mode 100644 utils/version.h create mode 100644 utils/visual.c create mode 100644 utils/visual.h create mode 100644 utils/vms-gtod.c create mode 100644 utils/vms-gtod.h create mode 100644 utils/vms-strdup.c create mode 100644 utils/vroot.h create mode 100644 utils/xmu.c create mode 100644 utils/xmu.h create mode 100644 utils/xroger.c create mode 100644 utils/yarandom.c create mode 100644 utils/yarandom.h create mode 100644 xscreensaver.lsm create mode 100755 xscreensaver.lsm.sh diff --git a/INSTALL b/INSTALL new file mode 100644 index 00000000..50dbe439 --- /dev/null +++ b/INSTALL @@ -0,0 +1,183 @@ +Basic Installation +================== + + These are generic installation instructions. + + The `configure' shell script attempts to guess correct values for +various system-dependent variables used during compilation. It uses +those values to create a `Makefile' in each directory of the package. +It may also create one or more `.h' files containing system-dependent +definitions. Finally, it creates a shell script `config.status' that +you can run in the future to recreate the current configuration, a file +`config.cache' that saves the results of its tests to speed up +reconfiguring, and a file `config.log' containing compiler output +(useful mainly for debugging `configure'). + + If you need to do unusual things to compile the package, please try +to figure out how `configure' could check whether to do them, and mail +diffs or instructions to the address given in the `README' so they can +be considered for the next release. If at some point `config.cache' +contains results you don't want to keep, you may remove or edit it. + + The file `configure.in' is used to create `configure' by a program +called `autoconf'. You only need `configure.in' if you want to change +it or regenerate `configure' using a newer version of `autoconf'. + +The simplest way to compile this package is: + + 1. `cd' to the directory containing the package's source code and type + `./configure' to configure the package for your system. If you're + using `csh' on an old version of System V, you might need to type + `sh ./configure' instead to prevent `csh' from trying to execute + `configure' itself. + + Running `configure' takes awhile. While running, it prints some + messages telling which features it is checking for. + + 2. Type `make' to compile the package. + + 3. Optionally, type `make check' to run any self-tests that come with + the package. + + 4. Type `make install' to install the programs and any data files and + documentation. + + 5. You can remove the program binaries and object files from the + source code directory by typing `make clean'. To also remove the + files that `configure' created (so you can compile the package for + a different kind of computer), type `make distclean'. There is + also a `make maintainer-clean' target, but that is intended mainly + for the package's developers. If you use it, you may have to get + all sorts of other programs in order to regenerate files that came + with the distribution. + +Compilers and Options +===================== + + Some systems require unusual options for compilation or linking that +the `configure' script does not know about. You can give `configure' +initial values for variables by setting them in the environment. Using +a Bourne-compatible shell, you can do that on the command line like +this: + CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure + +Or on systems that have the `env' program, you can do it like this: + env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure + +Compiling For Multiple Architectures +==================================== + + You can compile the package for more than one kind of computer at the +same time, by placing the object files for each architecture in their +own directory. To do this, you must use a version of `make' that +supports the `VPATH' variable, such as GNU `make'. `cd' to the +directory where you want the object files and executables to go and run +the `configure' script. `configure' automatically checks for the +source code in the directory that `configure' is in and in `..'. + + If you have to use a `make' that does not supports the `VPATH' +variable, you have to compile the package for one architecture at a time +in the source code directory. After you have installed the package for +one architecture, use `make distclean' before reconfiguring for another +architecture. + +Installation Names +================== + + By default, `make install' will install the package's files in +`/usr/local/bin', `/usr/local/man', etc. You can specify an +installation prefix other than `/usr/local' by giving `configure' the +option `--prefix=PATH'. + + You can specify separate installation prefixes for +architecture-specific files and architecture-independent files. If you +give `configure' the option `--exec-prefix=PATH', the package will use +PATH as the prefix for installing programs and libraries. +Documentation and other data files will still use the regular prefix. + + In addition, if you use an unusual directory layout you can give +options like `--bindir=PATH' to specify different values for particular +kinds of files. Run `configure --help' for a list of the directories +you can set and what kinds of files go in them. + + If the package supports it, you can cause programs to be installed +with an extra prefix or suffix on their names by giving `configure' the +option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. + +Optional Features +================= + + Some packages pay attention to `--enable-FEATURE' options to +`configure', where FEATURE indicates an optional part of the package. +They may also pay attention to `--with-PACKAGE' options, where PACKAGE +is something like `gnu-as' or `x' (for the X Window System). The +`README' should mention any `--enable-' and `--with-' options that the +package recognizes. + + For packages that use the X Window System, `configure' can usually +find the X include and library files automatically, but if it doesn't, +you can use the `configure' options `--x-includes=DIR' and +`--x-libraries=DIR' to specify their locations. + +Specifying the System Type +========================== + + There may be some features `configure' can not figure out +automatically, but needs to determine by the type of host the package +will run on. Usually `configure' can figure that out, but if it prints +a message saying it can not guess the host type, give it the +`--host=TYPE' option. TYPE can either be a short name for the system +type, such as `sun4', or a canonical name with three fields: + CPU-COMPANY-SYSTEM + +See the file `config.sub' for the possible values of each field. If +`config.sub' isn't included in this package, then this package doesn't +need to know the host type. + + If you are building compiler tools for cross-compiling, you can also +use the `--target=TYPE' option to select the type of system they will +produce code for and the `--build=TYPE' option to select the type of +system on which you are compiling the package. + +Sharing Defaults +================ + + If you want to set default values for `configure' scripts to share, +you can create a site shell script called `config.site' that gives +default values for variables like `CC', `cache_file', and `prefix'. +`configure' looks for `PREFIX/share/config.site' if it exists, then +`PREFIX/etc/config.site' if it exists. Or, you can set the +`CONFIG_SITE' environment variable to the location of the site script. +A warning: not all `configure' scripts look for a site script. + +Operation Controls +================== + + `configure' recognizes the following options to control how it +operates. + +`--cache-file=FILE' + Use and save the results of the tests in FILE instead of + `./config.cache'. Set FILE to `/dev/null' to disable caching, for + debugging `configure'. + +`--help' + Print a summary of the options to `configure', and exit. + +`--quiet' +`--silent' +`-q' + Do not print messages saying which checks are being made. To + suppress all normal output, redirect it to `/dev/null' (any error + messages will still be shown). + +`--srcdir=DIR' + Look for the package's source code in directory DIR. Usually + `configure' can determine that directory automatically. + +`--version' + Print the version of Autoconf used to generate the `configure' + script, and exit. + +`configure' also accepts some other, not widely useful, options. + diff --git a/Makefile.in b/Makefile.in new file mode 100644 index 00000000..4985d506 --- /dev/null +++ b/Makefile.in @@ -0,0 +1,76 @@ +# Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# the `../configure' script generates `Makefile' from this file. + +@SET_MAKE@ +srcdir = @srcdir@ +VPATH = @srcdir@ + +SHELL = /bin/sh +SUBDIRS = utils driver hacks hacks/glx +TARFILES = README README.VMS README.debugging INSTALL xscreensaver.lsm \ + configure configure.in Makefile.in config.h.in \ + config.h-vms install-sh setup.com config.guess \ + config.sub makevms.com screenblank.txt \ + xscreensaver.lsm.sh +TAR = gtar +COMPRESS = gzip --verbose --best +COMPRESS_EXT = gz +# COMPRESS = compress +# COMPRESS_EXT = Z + +MAKE_SUBDIR = for dir in $(SUBDIRS) ; do ( cd $$dir ; $(MAKE) $@ ) ; done + +all:: + @$(MAKE_SUBDIR) +install: + @$(MAKE_SUBDIR) +install-program: + @$(MAKE_SUBDIR) +install-man: + @$(MAKE_SUBDIR) +install-strip: + @$(MAKE_SUBDIR) +uninstall: + @$(MAKE_SUBDIR) +uninstall-program: + @$(MAKE_SUBDIR) +uninstall-man: + @$(MAKE_SUBDIR) +depend: + @$(MAKE_SUBDIR) +distdepend: + @$(MAKE_SUBDIR) +TAGS: tags +tags: + @$(MAKE_SUBDIR) +clean: + @$(MAKE_SUBDIR) +distclean: clean + -rm -f config.h Makefile config.status config.cache config.log *~ "#"* + @$(MAKE_SUBDIR) + +dist: tar + +# This really makes me sick... +tar: + @$(MAKE) distdepend ; \ + sh config.status ; \ + sh xscreensaver.lsm.sh > xscreensaver.lsm.$$$$ ; \ + mv xscreensaver.lsm.$$$$ xscreensaver.lsm ; \ + NAME=`sed -n \ + 's/[^0-9]*\([0-9]\.[0-9][0-9]*\).*/xscreensaver-\1/p' utils/version.h` ; \ + rm -f $$NAME ; ln -s . $$NAME ; \ + FILES= ; \ + for subdir in $(SUBDIRS) ; do \ + d=`pwd` ; \ + cd $$subdir ; \ + FILES="$$FILES `$(MAKE) echo_tarfiles \ + | grep -v '^.*make\[' \ + | sed \"s|^|$$subdir/|g;s| | $$subdir/|g\" \ + ` "; \ + cd $$d ; done ; \ + echo creating tar file $${NAME}.tar.$(COMPRESS_EXT)... ; \ + $(TAR) -vchf - \ + `echo $(TARFILES) $$FILES | sed "s|^|$$NAME/|g; s| | $$NAME/|g" ` \ + | $(COMPRESS) > $${NAME}.tar.$(COMPRESS_EXT) ; \ + rm $$NAME diff --git a/README b/README new file mode 100644 index 00000000..021b9f11 --- /dev/null +++ b/README @@ -0,0 +1,367 @@ + + XScreenSaver + + a screen saver and locker for the X window system + by Jamie Zawinski + +To build on Unix: + + - ./configure + - make + - make install + +The `configure' shell script will attempt to figure out which options are +appropriate for your system, and will create config.h and the various +Makefiles for you. Run `configure --help' to see how to override these +choices, or to specify things like the default installation directory. +The file `INSTALL' gives a general overview of use of these sorts of +configure scripts (those generated by the GNU autoconf system.) +The most important hint is probably this: + + ./configure --includedir=/opt/Motif/include --libdir=/opt/Motif/lib + +To build on VMS, see README.VMS. + +If you think you've found a bug, please let me know; but first, read +the enlosed `README.debugging' file to find out what kind of information +would be most helpful to include in your bug report. + + ============ + +The xscreensaver program waits until the keyboard and mouse have been idle +for a period, and then runs a graphics demo chosen at random. It turns off +as soon as there is any mouse or keyboard activity. + +The purpose of xscreensaver is to display pretty pictures on your screen +when it is not in use, in keeping with the philosophy that unattended +monitors should always be doing something interesting, just like they do +in the movies. + +However, xscreensaver can also be used as a screen locker, to prevent +others from using your terminal while your are away. + +The benefit that this program has over the combination of the xlock and +xautolock programs is the ease with which new graphics hacks can be +installed: you don't need to recompile this program to add a new display +mode, you just change some resource settings. Any program which can be +invoked in such a way that it draws on the root window of the screen can +now be used as a screensaver without modification. The programs that +are being run as screensavers don't need to have any special knowledge +about what it means to be a screensaver. + +The XIDLE, MIT-SCREEN-SAVER, and/or SGI SCREEN_SAVER server extensions +will be used if you have them. + +The dialog boxes (for locking and demo-mode) look best using Motif, but +can be configured to use Athena widgets instead. + +Also included are several graphics hacks for use as screensavers. There's +nothing magic about these: they're just programs that draw on the root +window, which are pointed at by the screensaver's default resource settings. + + qix - My own implementation of this, with many more options + than you would have thought qix could have. + helix - Generates spirally "stringart" patterns. + pedal - Draws a different kind of spirally pattern. + rorschach - Random inkblot patterns. + attraction - A bouncing ball demo, or a qix-like demo, or a wild + color-cycling thing, with some odd rules. + greynetic - Random colored/stippled rectangles. + rocks - Flying through an asteroid field. + blitspin - Rotate a bitmap using bitblts. + imsmap - Generates random maps or cloud formations. + hypercube - 2d projection of a hypercube rotating on all four axes. + slidescreen - Divides the screen into a grid and plays a 16-puzzle on it. + decayscreen - A melting effect. + puzzle - Turns the screen into a jigsaw puzzle and shuffles it. + halo - Random circular patterns. + pyro - Fireworks. Looks a lot like the version in xlock. + hopalong - Fractals. I snarfed this code from xlock. + flame - Fractals. Also from xlock. + noseguy - A guy with a big nose wanders around the screen saying + things. I snarfed this code from xnlock. + maze - This is the X maze demo modified to take a -root option + so that it works with xscreensaver. + lmorph - morphing line drawings. + bubbles - condensation forms on your monitor, then pops. + deco - Generates Brady-Bunch-era wall paneling. + moire - Circular interference patterns. + moire2 - More moire. + kaleidescope - Groovy, man. + swirl - Swirly color-cycling patterns. + bouboule - Spinning bubbles on a transparent ball. + braid - Draws random color-cycling braids around a circle. + drift - Drifting recursive fractal cosmic flames. + vines - Small, curvy geometric patterns. + galaxy - Spinning, colliding galaxies. + grav - Orbital simulation and/or cloud chamber. + ifs - Spinning, colliding iterated-function-system shapes. + julia - Animated rendition of the Julia set. + laser - Moving radiating lines. + lightning - Crackling fractal lightning bolts. + penrose - Quasiperiodic tilings. + sierpinski - two-dimensional Sierpinski triangle. + slip - Sucks your desktop through a jet engine. + spiral - Circular color-cycling interference patterns. + strange - Animating strange attractors. + flag - A waving flag of an arbitrary bitmap or text. + sphere - Draws a bunch of shaded spheres. + forest - grows a fractal forest. + lisa - draws animated full-loop lisajous figures. + lissie - another lisajous path. + goop - Squishy transparent oil-and-bubble images + starfish - Radially-symmetric throbbing colormap-hacking blobs. + munch - The classic 1962-vintage "munching squares" hack. + rd-bomb - Reaction-diffusion fractals. + coral - Simulation of coral growth, sort of. + fadeplot - Draws a swimming ribbon. + mountain - Generates mountains on a square grid. + triangle - Generates mountains on a triangular grid. + worm - Draws wiggly worms. + rotor - Draws a rotating spiral pattern. + ant - A cellular automaton. + xjack - Simulates a schizophrenic typist. + xlyap - Calculates and displays Lyapunov exponents. + gears - Draws interlocking rotating gears (GLX only.) + morph3d - Draws shiny shape-changing 3d forms (GLX only.) + superquadrics - More shiny shape-changing 3d forms (GLX only.) + pipes - Generates a field of intertwined plumbing (GLX only.) + rubik - Solves a Rubik's Cube (GLX only.) + sproingies - Marble Madness meets Q-Bert (GLX only.) + stairs - Draws Escher's infinite staircase (GLX only.) + cage - Draws Escher's impossible cage (GLX only.) + moebius - Draws Escher's Moebius Strip II (GLX only.) + +All of these will pop up their own window unless given that -root option. +See their man pages for more details. + +Other reasonable things to use as screensavers, if you have them, are + + xdaliclock -root -builtin2 - melting digital clock + xswarm -r 2>&- - swimming sperm + xwave -root - random 3d graphs + xbouncebits - bounce arbitrary bitmaps around + ico -r -p8 -faces -sleep 1 - it's dull, but it's there + xv -root file.gif -quit - they don't all have to animate! + xsplinefun - bouncing splines + xfishtank -c black -d -r 1 - fish (use version 2.0 or later) + xmountains -b - very realistic generated mountains + xtacy -root - various eye candy + xearth -wait 0 -timewarp 400 - the earth as seen from space + /usr/demos/bin/bongo - an SGI GL demo + /usr/demos/bin/ep -S - another: the stunning ElectroPaint. + (Compile hacks/xscreensaver-sgigl.c + to use these with xscreensaver.) + +You can get most of these from the contrib directory on ftp.x.org. If you +know of (or write) any other interesting programs that can be used as +screensavers, please let me know! + +The latest version of xscreensaver is always available on the web at +http://people.netscape.com/jwz/xscreensaver/. + + -- Jamie Zawinski + + +Changes since 2.15: Made `flag' able to do XPM images. + New look for the xscreensaver logo (`xroger'). + Fixed compilation error on Suns with adjunct passwords. + Got multi-architecture builds working again. + Some configure tweaks for building on HPUX and Solaris. + Fixed bug in decayscreen. + Fixed typo i passwd.c. + Made `cynosure' not die when colormap is full. +Changes since 2.14: Added `cynosure' hack. + Added `moire2' hack. + Tweaked `erase.c' some more. + Made unfading a bit smoother. + Added `vidwhacker' hack (not installed by default.) + Added `stairs' hack. + Split `escher' into `cage' and `moebius', as per + xlockmore. + Changed subprocess handling to use sigaction() instead + of signal() if it's available (this is necessary for + SCO but should work fine on other systems too.) + Various other tweaks. +Changes since 2.13: Better fix for the Motif drag-and-die lossage. + Put in some kludges to work around a LessTif bug. + XScreenSaver is known to work with LessTif 0.82 now. + Made fading work on high-end SGI video hardware. + Fixed another SGI-specific bug in screen grabbing; + will the madness never cease? + Fixed another crash in `xlyap'. +Changes since 2.12: Made `decayscreen' do directions other than down. + Improved `puzzle'. + Fixed a crash in `xlyap'. + Added CDE info to the man page, removed `cde.txt'. + Configure tweaks for Zippy. + Turned off the signal handling in `bubbles' because + it was sometimes failing to die. + Added `hacks/xscreensaver-sgigl.c' to make it possible + to run SGI's ElectroPaint hack (/usr/demos/bin/ep) + with xscreensaver. Finally! + Fixed a buffer overrun in the locking code that some + wily, malicious cracker must have slipped in. + Disabled Motif drag-and-drool in the dialog box + buttons, since it's broken in some old versions of + Motif. +Changes since 2.11: Added `README.debugging'. + Added `puzzle' hack. + Added `xlyap' hack. + Added "default-n" as a visual name, so that one can + have -install on by default, but turn it off for + certain poorly-behaved hacks (like xv.) + Added support for grabbing frames of external video + (on SGI) to the screen-grabbing hacks (decayscreen, + slidescreen, slip, blitspin, and puzzle.) + Improved look of tiles in `slidescreen'; fixed its + color allocation problem. +Changes since 2.10: Tweaked `blitspin', added it to the default list. + Added `lissie', `mountain', `triangle', `worm', + `rotor', and `ant' from xlockmore. + Updated `sierpinski', `galaxy', and `lisa'. + Thickened the lines in `braid' and `lmorph'. + Updated VMS makefiles. + Renamed `fract' to `vines'. + Added `xjack' hack. + Made a few more hacks use erase.c, and added a few + more wipe styles. + Fixed compilation problem with Sun's version of OpenGL. + Added ability to use sigaction() instead of signal() + to work around a SCO kernel bug. +Changes since 2.09: Fixed colormap bugs in `rd-bomb'; sped up `coral'. + Configure tweaks for *BSD. +Changes since 2.07: New hacks `rd-bomb' and `coral'. + New version of `maze' with some new algorithms. + New colorized version of `rocks'. + Fixed a bug in qix on 64-bit machines. + Fixed a bug in the -time option. + Fixed a bug in configure related to LessTif. +Changes since 2.06: Minor header tweaks in windows.c and flag.c. + Made multi-architecture (VPATH) builds work properly. + Merged new GL stuff from xlockmore (rubik, morph3d.) + Fixed intermittent crashes in `imsmap' and `munch'. + Added `fadeplot' hack from xlockmore. +Changes since 2.05: Merged in VMS support from Patrick Moreau. +Changes since 2.04: Fixed a MIT-SCREEN-SAVER-related crash, and tweaked + configure to detect the extra-random -Xss library. +Changes since 2.03: HP configure tweaks. Detect and warn about LessTif. + Fixed low-color behavior of `goop', `pyro', `starfish', + `greynetic', `flame', `halo', and `moire'. +Changes since 2.02: Fixed flicker in `pipes'. Fixed 3d in `bouboule'. + Added `munch' hack. + Added basic dependencies to the Makefile.in files. +Changes since 2.01: Fixes for compiling with the MIT saver extension. + Made the yow/fortune program be a configure option. + Various configure tweaks. +Changes since 2.00: Added `goop' and `starfish' hacks. + Added colomap cycling to `halo'. + Made `attraction' use the new colormap allocator. + Added better $PATH diagnostics. + There was a bug in frand! Color selection should be + much improved now. +Changes since 1.34: Converted to use `configure' instead of `imake'. + ANSI C is now required. + Added Kerberos locking support, from Nat Lanza. + Made the stderr text use overlay planes, if possible. + Reworked the xlockmore compatibility stuff again. + Added `gears', `superquadrics', `escher', `pipes', + and `sproingies' hacks (depend on OpenGL.) +Changes since 1.33: Fixed some bugs, made fading be a little smoother. +Changes since 1.32: Made it work with multi-headed displays. + Generalized sub-process management (Unix sucks!) + Added interactive mouse frobbing to Julia. + Added (untested) support for HPUX shadow passwords. + Made normal non-shadow passwords be checked if the + shadow passwords aren't accessible for some reason. +Changes since 1.31: Removed *colorPrograms and *monoPrograms resources: + made it possible to specify the desired visual on a + per-hack basis. + Cleaned up / restructured the driver: no more globals. + Made the Motif and Athena dialogs share more code. + Probably fixed some Athena colormap-installation bugs. + Fixed screen grabbing (cmap) on SGI 12-bit PseudoColor. + Fixed divide-by-zero in bright random colormaps. + Added an improved version of xlock's `flag' hack. + Made unfading work better, and not flicker on SGIs. + Added `sphere', `forest', `lisa' hacks from xlockmore. + Added (untested) support for SunOS Adjunct passwords. +Changes since 1.30: Improved colors and colormap cycling of many hacks. + Cleaned up xlockmore compatibility layer. + Made `blitspin' able to grab an image off the screen. + Ported `swirl' and `bouboule' hacks from xlockmore. + Made the driver more careful about not leaving bits on + the screen, or allowing other windows to raise + themselves: it now re-blanks the screen every so often. + Added `-time' option to `xscreensaver-command'. + Improved SGI screen-grabbing some more: now it can grab + TrueColor screens into PseudoColor windows and have the + colors still come out semi-reasonably. +Changes since 1.29: Made `slidescreen' and `decayscreen' work better on + SGIs when windows of different visuals are present, by + using the XReadDisplay() extension to get a true 24-bit + image out of the frame buffer. + Made `noseguy' be in color, if compiled with XPM. + Ported `braid', `drift', `fract', `galaxy', `grav', + `ifs', `julia', `laser', `lightning', `penrose', + `sierpinski', `slip', `spiral', and `strange' hacks + from xlockmore. + Merged `hopalong' hack with a more recent version. + Added `cde.txt'. +Changes since 1.27: Added `deco', `moire', and `kaleidescope' hacks. + Merged in support for non-Motif locking and demo mode. + Made `blitspin' and `bubbles' work in TrueColor. + Fixed a stupid bug I introduced in `imsmap'. + Added `poly' and `gravity' options to `qix'. +Changes since 1.26: Added support for SGI SCREEN_SAVER extension. + Made `fade' and `unfade' work on 8-bit SGIs. + Made the dialog boxes more Motify. + Added `bubbles' hack. +Changes since 1.25: Added `lmorph' hack. + Added viscosity and mouse-control to attraction. + Fixed possible bad color choices in qix and attraction. + Added ramp-mode to halo. + Added a new RNG, which is faster and more portable + than using the RNG in libc. + Made locking work on SCO. + Various other minor tweaks that I don't remember. +Changes since 1.24: Made it capture the stdout/stderr of its subprocesses + and present them on the screensaver window itself. + Made demo mode work correctly with non-default visuals + and color maps, instead of always using the defaults. + Added -visual argument to all included screenhacks. + Support for the R6 MIT-SCREEN-SAVER server extension. + Made the demo mode list scroll properly. + Added `pedal' hack. +Changes since 1.23: Fixed some private-colormap oddities in slidescreen, + decayscreen, and xroger. Fixed apparent conservation- + of-mass problem in pyro; made the shrapnel round. +Changes since 1.22: Minor tweaks for IRIX5; fixed locking race condition. +Changes since 1.21: Minor tweaks for X11R6. + Fixes for non-default visuals. +Changes since 1.20: Fixed bug in color blitspin; added default image. + Added diagnostics to noseguy. Fixed off-by-one + error in flame. Added some missing casts. +Changes since 1.18: Added `flame' hack. + Fixed a minor Motif dialog text field bug. + Fixed yet another XPointer-not-defined-in-R4 bug. +Changes since 1.17: Added support for shadow password files. + Fixed some Motif-related locking bugs. + Added diagnostics when locking is disabled. + Made blitspin able to use the XPM library. + Added `decayscreen' hack. +Changes since 1.16: Added `halo' hack. +Changes since 1.15: Portability fixes. +Changes since 1.14: Broke the driver up into more source files. + Moved the hacks into their own directory. + Made all `time' parameters accept the 00:00:00 syntax, + so that even the parameters which are normally read as + minutes can be specified in seconds. + Added colormap cycling to `imsmap'. + Made hyper work with K&R compilers. +Changes since 1.13: Added `orbit' option to `attraction' hack. + Added `lock-timeout' option. + Cleaned up options of `maze' hack. +Changes since 1.8: Added demo mode, and locking. + Added `maze' hack. + Added `norotate' option to `rocks' hack. diff --git a/README.VMS b/README.VMS new file mode 100644 index 00000000..d1903443 --- /dev/null +++ b/README.VMS @@ -0,0 +1,57 @@ +OpenVMS port of Xscreensavser version 2.10 October 1997 +========================================== + +Xscreensaver distribution can be found in 3 subdirectories: + +[.DRIVER] The Xscreensaver and Xscreensaver-command programs. +[.HACKS] Graphic demos ,can be run either through the xscreensaver program + or standalone. +[.UTILS] A small libraries of various utilities. + +This port has been tested with VAX VMS 6.1 (compiled with DEC 5 5.0 and +Motif 1.2) and AXP VMS 6.2 (compiled with DEC C 5.0 and Motif 1.2-4). + +To rebuild, you need to rebuild [.UTILS] directory first and create the +object library (look at the end of COMPILE*.COM procedure). + +You can now build the [.HACKS] directory and the [.DRIVER] directory. + +A one-step build is now available via the MAKEVMS.COM script. + +WARNING : before building [.HACKS], you may need to correct some of the +DECwindows bitmap files. Some files are bogus !! (they have a long line of +null chars at the end). These files are under +SYS$COMMON:[DECW$INCLUDE.BITMAPS] directory: + +STIPPLE.XBM +HLINES2.XBM +LIGHT_GRAY.XBM +ROOT_WEAVES.XBM +VLINES2.XBM + +These files are all used by Greynetic demo. + +Nota: link procedure automagically select appropriate X and Motif Libraries +(X11R4/Motif 1.1 - X11R5/Motif 1.2). + +The SETUP.COM procedure gives you a definition of all DCL foreign command +symbols needed to run Xscreensaver and all the graphic hacks. You need to +modify this procedure if you install these programs in another directory tree. + +You can easily add new graphic demos without recompiling Xscreensaver. You just +need to add them in resource file XSCREENSAVER.DAT. This file (originally +present in [.DRIVER] directory ) can be installed under your SYS$LOGIN +directory for a per-user customization basis. You can also install it under +the system-wide user resource directory SYS$COMMON:[DECW$DEFAULT.USER] +(with (W:RE) protections). The new graphics hack must be run in root-window +mode to be accepted by Xscreensaver. + +The graphic demos are spawn into subprocess created by the system() call (in +the Unix version the execvp() call is used). + +The VMS passord checking programs were picked up in the Xlock distribution. + +Enjoy, + +Patrick MOREAU - CENA/Athis-Mons - FRANCE (pmoreau@cena.dgac.fr) + (moreau_p@decus.decus.fr) diff --git a/README.debugging b/README.debugging new file mode 100644 index 00000000..cf147893 --- /dev/null +++ b/README.debugging @@ -0,0 +1,141 @@ + + XScreenSaver + + a handy guide for creating useful bug reports + + -------- + + It's hard to imagine, but sometimes, xscreensaver has bugs. This + document gives some hints for isolating them; the more information + you can give me about the problem, the better the odds that I'll be + able to fix it. But, if you don't have time to go through these + steps, report the bug anyway -- even vague bug reports can be + better than no bug report at all. + -------- + +STEP ZERO: + + What are you doing here? Go read README, and then the man page. + +STEP ZERO, PART TWO: + + Do you have the most recent version? Go make sure. + http://people.netscape.com/jwz/xscreensaver/ + +BUILDING: + + If you get an error running the `configure' script, the first thing + you should try is deleting the `config.cache' file, and running again. + If that doesn't fix it, the information I'll need to see to make + sense of the problem is the following: + + * everything printed to stderr/stdout when you first ran + ./configure; + + * the contents of the `config.log' file. + + Make sure you blow away the config.cache file before regenerating + this info, or else the `config.log' file will be mostly empty/useless. + + Experience seems to show that the most common configure problem is + that sites have gcc installed, but installed improperly. The + configure script will always try to use gcc in preference to another + compiler if gcc exists, so if gcc exists but is broken, it won't + work. Your options are: + + * get someone to fix the gcc installation; + + * rearrange your $PATH so that the broken gcc is not on it; + + * or pass $CC in the environment, like so: + csh: setenv CC cc ; ./configure + sh: CC=cc ; ./configure + + After doing this, you'll need to nuke `config.cache'. + + If you get errors about not being able to find Motif or Athena (the + Xm/ or Xaw/ header files), and you can't find them on your system, + then your system is horked and your vendor is lame. Perhaps the + problem is that you don't have some kind of ``development option'' + installed. Xt/ and Xaw/ (Athena) are free and available on all + systems; Xm/ (Motif) is available on all commercial systems except + SunOS 4.x and some early releases of Solaris. + +RUNNING: + + For runtime errors, it's important to keep in mind that there are + two parts to xscreensaver: there is the screensaver driver process + (the part that detects idleness, deals with locking, and launches + the demos); and there are the demos themselves (independent programs + that draw pretty pictures.) + + * Compile with `make CFLAGS=-g'. + + * What platform are you running on? What does the included + `./config.guess' shell script print? + + * Is the problem in the driver, or in the graphics hacks? + + * If the problem is in the driver, was the driver built using + Motif, or Athena? Which version? + + * If the problem is in one (or more) of the hacks, which ones? + If you're not sure, try + + xscreensaver-command -demo + + to go through the list of them and see which work and which + don't. + + * Does the problem occur when running that hack by hand, in + its own window? + + * Does the problem occur when running that hack by hand, on + the root window (the `-root' option)? + + * IMPORTANT: What visual are you using? Send the output of + the `xdpyinfo' command. + + * Does the problem go away if you give the program a different + `-visual' argument? (For example, `-visual pseudocolor' or + `-visual truecolor'.) + + * IMPORTANT: What exactly goes wrong? No, I don't know what + you mean by "crash". Does it print an "X Error" and exit? + Does it dump core? Does it go into a loop? + + * If it dumps core, what does the core file say? Run the + program under a debugger, and show me the stack trace. + (If you don't know how to do that, that's ok.) + + * If it gets an X error, where did it come from? Run the + program under a debugger; set a breakpoint on `exit'; + start the program with the `-sync' command-line option; + and show me the stack trace when it stops. + + If the problem is with the xscreensaver process itself, or if you + can't figure out which demo is causing the problem, or if you can't + reproduce the problem in isolation, then you will need to turn on + and examine the debugging output of the driver process. + + * Start `xscreensaver' with the command-line arguments + + -verbose -xrm '*captureStderr:false' -xrm '*captureStdout:false' + + This will cause it to write a lot of debugging info to the + stdout and stderr of the xscreensaver process (the -verbose + argument turns on the diagnostics; the remaining arguments + prevent the data from being displayed on the screensaver + window as well. + + * If the problem is intermittent, you might want to capture the + log information to a file and examine it later. + + * Hackers only: If you're feeling adventurous enough to run gdb + on the xscreensaver driver process itself, make sure you've + read the commentary at the top of xscreensaver.c. + +----------------------------------------------------------------------------- + http://people.netscape.com/jwz/xscreensaver/ + Jamie Zawinski +----------------------------------------------------------------------------- diff --git a/README.skunkware b/README.skunkware new file mode 100644 index 00000000..ba348ec4 --- /dev/null +++ b/README.skunkware @@ -0,0 +1,23 @@ +xscreensaver 2.16 from jwz@netscape.com + +Read the README for information on where to get it, what it does, etc. + +The copyright notices are in the individual .c files + +I have made no changes to this. The script configure-skunkware +was run to call configure with appropriate parameters. + +Configuration notes: + - This is configured as a screensaver, not as a screen locker. + - It assumes that XScreenSaver.ad has been installed in + an appropriate app-defaults directory + - The OpenGL 3D hacks are compiled, the libraries must be + in a directory on LD_LIBRARY_PATH + +Also note that at least on OpenServer 5.0.0, the hack "moire2" causes +the X server to dump core (after running out of memory). You might +want to disable that one. + +Tom Kelly +tom@ancilla.toronto.on.ca + diff --git a/config.guess b/config.guess new file mode 100755 index 00000000..e9e44559 --- /dev/null +++ b/config.guess @@ -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 . +# 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 + + 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 + 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 </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' /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 . + # 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 + 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 < +# include +#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 + 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/config.h-vms b/config.h-vms new file mode 100644 index 00000000..d91ebfc4 --- /dev/null +++ b/config.h-vms @@ -0,0 +1,251 @@ +/* This is a config.h file that has been pregenerated (from config.h.in) + * with settings that are correct for VMS. + */ + + + +/* config.h.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. + * + * 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. + */ + +/* ************************************************************************* + CONFIGURING SERVER EXTENSIONS + ************************************************************************* */ + +/* Define this if you have the XReadDisplay extension (I think this is an + SGI-only thing; it's in .) A couple of + the screenhacks will take advantage of this if it's available. + */ +#undef HAVE_READ_DISPLAY_EXTENSION + +/* Define this if you have the XHPDisableReset function (an HP only thing.) + */ +#undef HAVE_XHPDISABLERESET + +/* First, some background: there are three distinct server extensions which + * are useful to a screen saver program: they are XIDLE, MIT-SCREEN-SAVER, + * and SCREEN_SAVER. + * + * The XIDLE extension resides in .../contrib/extensions/xidle/ on the X11R5 + * contrib tape. This extension lets the client get accurate idle-time + * information from the X server in a potentially more reliable way than by + * simply watching for keyboard and mouse activity. However, the XIDLE + * extension has apparently not been ported to X11R6. + * + * The SCREEN_SAVER extension is found (as far as I know) only in the SGI + * X server, and it exists in all releases since (at least) Irix 5. The + * relevant header file is /usr/include/X11/extensions/XScreenSaver.h. + * + * The similarly-named MIT-SCREEN-SAVER extension came into existence long + * after the SGI SCREEN_SAVER extension was already in use, and resides in + * .../contrib/extensions/screensaver/ on the X11R6 contrib tape. It is + * also found in certain recent X servers built in to NCD X terminals. + * + * The MIT extension does basically the same thing that the XIDLE extension + * does, but there are two things wrong with it: first, because of the way + * the extension was designed, the `fade' option to XScreenSaver will be + * uglier: just before the screen fades out, there will be an unattractive + * flicker to black, because this extension blanks the screen *before* + * telling us that it is time to do so. Second, this extension is known to + * be buggy; on the systems I use, it works, but some people have reported + * X server crashes as a result of using it. XScreenSaver uses this + * extension rather conservatively, because when I tried to use any of its + * more complicated features, I could get it to crash the server at the + * drop of a hat. + * + * In short, the MIT-SCREEN-SAVER extension is a piece of junk. The older + * SGI SCREEN_SAVER extension works great, as does XIDLE. It would be nice + * If those two existed on more systems, that is, would be adopted by the + * X Consortium in favor of their inferior "not-invented-here" entry. + */ + +/* Define this if you have the XIDLE extension installed. If you have the + * XIDLE extension, this is recommended. (You have this extension if the + * file /usr/include/X11/extensions/xidle.h exists.) Turning on this flag + * lets XScreenSaver work better with servers which support this extension; + * but it will still work with servers which do not suport it, so it's a good + * idea to compile in support for it if you can. + */ +#undef HAVE_XIDLE_EXTENSION + +/* Define this if you have the MIT-SCREEN-SAVER extension installed. See the + * caveats about this extension, above. (It's available if the file + * /usr/include/X11/extensions/scrnsaver.h exists.) + */ +#undef HAVE_MIT_SAVER_EXTENSION + +/* Define this if you have the SGI SCREEN_SAVER extension. This is standard + * on Irix systems, and not available elsewhere. + */ +#undef HAVE_SGI_SAVER_EXTENSION + + + +/* ************************************************************************* + CONFIGURING GRAPHICS TOOLKITS + ************************************************************************* */ + +/* Define this if you have Motif. + */ +#define HAVE_MOTIF + +/* Define this if you don't have Motif, but you have Athena (-Xaw). + */ +#undef HAVE_ATHENA + +/* Define this if you have Athena, and the version you have includes the + * XawViewportSetCoordinates function in Viewport.h (some old versions of + * the library didn't have this function.) + */ +#undef HAVE_XawViewportSetCoordinates + +/* Define this if you have the XPM library installed. Some of the demos can + * make use of this if it is available. + */ +#undef HAVE_XPM + +/* Define this if you have the Xmu library. This is standard part of X, and + * if your vendor doesn't ship it, you should report that as a bug. + */ +#define HAVE_XMU + +/* Define this if you have OpenGL. Some of the demos require it, so if you + * don't have it, then those particular demos won't be built. (This won't + * affect the screen saver as a whole.) + */ +#undef HAVE_GL + +/* Define this if you have GL, but it's the MesaGL variant. (The libraries + have different names.) (HAVE_GL should be defined too.) + */ +#undef HAVE_MESA_GL + +/* Some screenhacks like to run an external program to generate random pieces + of text; set this to the one you like ("yow" and "fortune" are the most + likely prospects.) Note that this is just the default; X resources can + be used to override it. + */ +#define ZIPPY_PROGRAM "fortune" + + + +/* ************************************************************************* + CONFIGURING PASSWORD AUTHENTICATION + ************************************************************************* */ + +/* Define this to remove the option of locking the screen at all. + */ +#undef NO_LOCKING + +/* Define this if you want to use Kerberos authentication to lock/unlock the + * screen instead of your local password. This currently uses Kerberos V4, + * but a V5 server with V4 compatibility will work. WARNING: DO NOT USE AFS + * string-to-key passwords with this option. This option currently *only* + * works with standard Kerberos des_string_to_key. If your password is an + * AFS password and not a kerberos password, it will not authenticate + * properly. See the comments in driver/kpasswd.c for more information if you + * need it. + */ +#undef HAVE_KERBEROS + + +/* Define this if your system uses `shadow' passwords, that is, the passwords + * live in /etc/shadow instead of /etc/passwd, and one reads them with + * getspnam() instead of getpwnam(). (Note that SCO systems do some random + * other thing; others might as well. See the ifdefs in driver/passwd.c if + * you're having trouble related to reading passwords.) + */ +#undef HAVE_SHADOW_PASSWD + +/* Define this if your system is Digital or SCO Unix with so-called ``Enhanced + Security'', that is, the passwords live in /tcb/files/auth// + instead of in /etc/passwd, and one reads them with getprpwnam() instead + of getpwnam(). + */ +#undef HAVE_ENHANCED_PASSWD + +/* Define this if your system is Solaris with ``adjunct'' passwords (this is + the version where one gets at the passwords with getpwanam() instead of + getpwnam().) I haven't tested this one, let me know if it works. + */ +#undef HAVE_ADJUNCT_PASSWD + +/* Define this if you are running HPUX with so-called ``Secure Passwords'' + (if you have /usr/include/hpsecurity.h, you probably have this.) I + haven't tested this one, let me know if it works. + */ +#undef HAVE_HPUX_PASSWD + + +/* ************************************************************************* + OTHER C ENVIRONMENT JUNK + ************************************************************************* */ + +/* Define this to void* if you're using X11R4 or earlier. */ +#undef XPointer + +/* Define if you have the nice function. */ +#undef HAVE_NICE + +/* Define if you have the setpriority function. */ +#undef HAVE_SETPRIORITY + +/* Define to empty if the keyword does not work. */ +#undef const + +/* Define if you have that is POSIX.1 compatible. */ +#undef HAVE_SYS_WAIT_H + +/* Define as __inline if that's what the C compiler calls it. */ +#undef inline + +/* Define to `int' if doesn't define. */ +#undef mode_t + +/* Define to `int' if doesn't define. */ +#undef pid_t + +/* Define as the return type of signal handlers (int or void). */ +#define RETSIGTYPE void + +/* Define to `unsigned' if doesn't define. */ +#undef size_t + +/* Define if you have the ANSI C header files. */ +#define STDC_HEADERS + +/* Define if you can safely include both and . */ +#undef TIME_WITH_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 putenv function. */ +#undef HAVE_PUTENV + +/* Define if you have the select function. */ +#undef HAVE_SELECT + +/* Define if you have the getcwd function. */ +#undef HAVE_GETCWD + +/* Define if you have the getcwd function. */ +#undef HAVE_GETWD + +/* Define if you have the uname function. */ +#undef HAVE_UNAME + +/* Define if you have the fcntl function. */ +#undef HAVE_FCNTL + +/* Define if you have the header file. */ +#undef HAVE_UNISTD_H diff --git a/config.h.in b/config.h.in new file mode 100644 index 00000000..f8aed556 --- /dev/null +++ b/config.h.in @@ -0,0 +1,267 @@ +/* config.h.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. + * + * 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. + */ + + +/* ************************************************************************* + CONFIGURING SERVER EXTENSIONS + ************************************************************************* */ + +/* Define this if you have the XReadDisplay extension (I think this is an + SGI-only thing; it's in .) A few of the + screenhacks will take advantage of this if it's available. + */ +#undef HAVE_READ_DISPLAY_EXTENSION + +/* Define this if you have the Iris Video Library (dmedia/vl.h on SGI.) + A few of the screenhacks will take advantage of this if it's available. + */ +#undef HAVE_SGI_VIDEO + +/* Define this if you have the XHPDisableReset function (an HP only thing.) + */ +#undef HAVE_XHPDISABLERESET + +/* First, some background: there are three distinct server extensions which + * are useful to a screen saver program: they are XIDLE, MIT-SCREEN-SAVER, + * and SCREEN_SAVER. + * + * The XIDLE extension resides in .../contrib/extensions/xidle/ on the X11R5 + * contrib tape. This extension lets the client get accurate idle-time + * information from the X server in a potentially more reliable way than by + * simply watching for keyboard and mouse activity. However, the XIDLE + * extension has apparently not been ported to X11R6. + * + * The SCREEN_SAVER extension is found (as far as I know) only in the SGI + * X server, and it exists in all releases since (at least) Irix 5. The + * relevant header file is /usr/include/X11/extensions/XScreenSaver.h. + * + * The similarly-named MIT-SCREEN-SAVER extension came into existence long + * after the SGI SCREEN_SAVER extension was already in use, and resides in + * .../contrib/extensions/screensaver/ on the X11R6 contrib tape. It is + * also found in certain recent X servers built in to NCD X terminals. + * + * The MIT extension does basically the same thing that the XIDLE extension + * does, but there are two things wrong with it: first, because of the way + * the extension was designed, the `fade' option to XScreenSaver will be + * uglier: just before the screen fades out, there will be an unattractive + * flicker to black, because this extension blanks the screen *before* + * telling us that it is time to do so. Second, this extension is known to + * be buggy; on the systems I use, it works, but some people have reported + * X server crashes as a result of using it. XScreenSaver uses this + * extension rather conservatively, because when I tried to use any of its + * more complicated features, I could get it to crash the server at the + * drop of a hat. + * + * In short, the MIT-SCREEN-SAVER extension is a piece of junk. The older + * SGI SCREEN_SAVER extension works great, as does XIDLE. It would be nice + * If those two existed on more systems, that is, would be adopted by the + * X Consortium in favor of their inferior "not-invented-here" entry. + */ + +/* Define this if you have the XIDLE extension installed. If you have the + * XIDLE extension, this is recommended. (You have this extension if the + * file /usr/include/X11/extensions/xidle.h exists.) Turning on this flag + * lets XScreenSaver work better with servers which support this extension; + * but it will still work with servers which do not suport it, so it's a good + * idea to compile in support for it if you can. + */ +#undef HAVE_XIDLE_EXTENSION + +/* Define this if you have the MIT-SCREEN-SAVER extension installed. See the + * caveats about this extension, above. (It's available if the file + * /usr/include/X11/extensions/scrnsaver.h exists.) + */ +#undef HAVE_MIT_SAVER_EXTENSION + +/* Define this if you have the SGI SCREEN_SAVER extension. This is standard + * on Irix systems, and not available elsewhere. + */ +#undef HAVE_SGI_SAVER_EXTENSION + +/* Define this if you have the SGI-VIDEO-CONTROL extension. This is standard + * on Irix systems, and not available elsewhere. + */ +#undef HAVE_SGI_VC_EXTENSION + + +/* ************************************************************************* + CONFIGURING GRAPHICS TOOLKITS + ************************************************************************* */ + +/* Define this if you have Motif. + */ +#undef HAVE_MOTIF + +/* Define this if you don't have Motif, but you have Athena (-Xaw). + */ +#undef HAVE_ATHENA + +/* Define this if you have Athena, and the version you have includes the + * XawViewportSetCoordinates function in Viewport.h (some old versions of + * the library didn't have this function.) + */ +#undef HAVE_XawViewportSetCoordinates + +/* Define this if you have the XPM library installed. Some of the demos can + * make use of this if it is available. + */ +#undef HAVE_XPM + +/* Define this if you have the Xmu library. This is standard part of X, and + * if your vendor doesn't ship it, you should report that as a bug. + */ +#undef HAVE_XMU + +/* Define this if you have OpenGL. Some of the demos require it, so if you + * don't have it, then those particular demos won't be built. (This won't + * affect the screen saver as a whole.) + */ +#undef HAVE_GL + +/* Define this if you have GL, but it's the MesaGL variant. (The libraries + have different names.) (HAVE_GL should be defined too.) + */ +#undef HAVE_MESA_GL + +/* Define this if you have the X Shared Memory Extension. + */ +#undef HAVE_XSHM_EXTENSION + +/* Some screenhacks like to run an external program to generate random pieces + of text; set this to the one you like ("yow" and "fortune" are the most + likely prospects.) Note that this is just the default; X resources can + be used to override it. + */ +#define ZIPPY_PROGRAM "fortune" + + + +/* ************************************************************************* + CONFIGURING PASSWORD AUTHENTICATION + ************************************************************************* */ + +/* Define this to remove the option of locking the screen at all. + */ +#undef NO_LOCKING + +/* Define this if you want to use Kerberos authentication to lock/unlock the + * screen instead of your local password. This currently uses Kerberos V4, + * but a V5 server with V4 compatibility will work. WARNING: DO NOT USE AFS + * string-to-key passwords with this option. This option currently *only* + * works with standard Kerberos des_string_to_key. If your password is an + * AFS password and not a kerberos password, it will not authenticate + * properly. See the comments in driver/kpasswd.c for more information if you + * need it. + */ +#undef HAVE_KERBEROS + + +/* Define this if your system uses `shadow' passwords, that is, the passwords + * live in /etc/shadow instead of /etc/passwd, and one reads them with + * getspnam() instead of getpwnam(). (Note that SCO systems do some random + * other thing; others might as well. See the ifdefs in driver/passwd.c if + * you're having trouble related to reading passwords.) + */ +#undef HAVE_SHADOW_PASSWD + +/* Define this if your system is Digital or SCO Unix with so-called ``Enhanced + Security'', that is, the passwords live in /tcb/files/auth// + instead of in /etc/passwd, and one reads them with getprpwnam() instead + of getpwnam(). + */ +#undef HAVE_ENHANCED_PASSWD + +/* Define this if your system is Solaris with ``adjunct'' passwords (this is + the version where one gets at the passwords with getpwanam() instead of + getpwnam().) I haven't tested this one, let me know if it works. + */ +#undef HAVE_ADJUNCT_PASSWD + +/* Define this if you are running HPUX with so-called ``Secure Passwords'' + (if you have /usr/include/hpsecurity.h, you probably have this.) I + haven't tested this one, let me know if it works. + */ +#undef HAVE_HPUX_PASSWD + + +/* ************************************************************************* + OTHER C ENVIRONMENT JUNK + ************************************************************************* */ + +/* Define this to void* if you're using X11R4 or earlier. */ +#undef XPointer + +/* Define if you have the nice function. */ +#undef HAVE_NICE + +/* Define if you have the setpriority function. */ +#undef HAVE_SETPRIORITY + +/* Define to empty if the keyword does not work. */ +#undef const + +/* Define if you have that is POSIX.1 compatible. */ +#undef HAVE_SYS_WAIT_H + +/* Define as __inline if that's what the C compiler calls it. */ +#undef inline + +/* Define to `int' if doesn't define. */ +#undef mode_t + +/* Define to `int' if doesn't define. */ +#undef pid_t + +/* Define as the return type of signal handlers (int or void). */ +#undef RETSIGTYPE + +/* Define to `unsigned' if 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 and . */ +#undef TIME_WITH_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 putenv function. */ +#undef HAVE_PUTENV + +/* Define if you have the select function. */ +#undef HAVE_SELECT + +/* Define if you have the getcwd function. */ +#undef HAVE_GETCWD + +/* Define if you have the getcwd function. */ +#undef HAVE_GETWD + +/* Define if you have the uname function. */ +#undef HAVE_UNAME + +/* Define if you have the fcntl function. */ +#undef HAVE_FCNTL + +/* Define if you have the sigaction function. */ +#undef HAVE_SIGACTION + +/* Define if you have the header file. */ +#undef HAVE_UNISTD_H + +/* Define to use sigaction() instead of signal() for SIGCHLD-related activity. + This is necessary at least on SCO OpenServer 5, due to a Unix kernel bug. + */ +#undef USE_SIGACTION diff --git a/config.sub b/config.sub new file mode 100755 index 00000000..04325249 --- /dev/null +++ b/config.sub @@ -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/configure b/configure new file mode 100755 index 00000000..d5831435 --- /dev/null +++ b/configure @@ -0,0 +1,6052 @@ +#! /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 + +Installation options: + + --enable-subdir=DIR Put the demo programs in a subdirectory of \`bindir', + instead of putting them in bindir itself. You can + specify the name of the subdirectory. For example, + --exec-prefix=/usr/local/bin --enable-subdir=demos + would put xscreensaver in /usr/local/bin/, and would + put the demos in /usr/local/bin/demos/. Note that if + you do this, you must make sure that the directory + is on your \$PATH before xscreensaver is started: the + directory name is not hardcoded into the program. + This merely sets the default installation location. + + --disable-subdir Just put the demos in \`bindir' (this is the default.) +" +ac_help="$ac_help + --with-x use the X Window System" +ac_help="$ac_help + +Server options: + + --with-sgi-ext Include support for the SGI SCREEN_SAVER + server extension, if possible (this is the default). + --without-sgi-ext Do not compile in support for this extension." +ac_help="$ac_help + --with-mit-ext Include support for the MIT-SCREEN-SAVER + server extension, if possible (this is the default). + --without-mit-ext Do not compile in support for this extension." +ac_help="$ac_help + --with-xidle-ext Include support for the XIDLE server extension, + if possible (this is the default). + --without-xidle-ext Do not compile in support for this extension." +ac_help="$ac_help + --with-xshm-ext Include support for the XSHM (Shared Memory) server + extension, if possible (this is the default). + --without-xshm-ext Do not compile in support for this extension." +ac_help="$ac_help + --with-sgivc-ext Include support for the SGI-VIDEO-CONTROL server + extension, if possible (this is the default). + --without-sgivc-ext Do not compile in support for this extension." +ac_help="$ac_help + +Toolkit options: + + --with-motif Use the Motif toolkit for the user interface, + if possible (this is the default). + --without-motif Do not use Motif." +ac_help="$ac_help + --with-athena Use the Athena toolkit for the user interface, if + possible (this is the default if Motif isn't used.) + --without-athena Do not use Athena." +ac_help="$ac_help + +Demo options: + + --with-xpm Include support for XPM files in some demos, + if possible (this is the default). + --without-xpm Do not compile in support for XPM files." +ac_help="$ac_help + --with-gl Build those demos which depend on OpenGL, + if possible (this is the default). + --without-gl Do not build the OpenGL demos." +ac_help="$ac_help + --with-readdisplay Include support for the XReadDisplay server + extension if possible (this is the default). + --without-readdisplay Do not compile in support for this extension." +ac_help="$ac_help + --with-sgivideo Include support for SGI's Iris Video Library + if possible (this is the default). + --without-sgivideo Do not compile in support for this library." +ac_help="$ac_help + --with-zippy=PROGRAM Some demos are able to run an external program and + display its text; this names the program to use by + default (though it can be overridden with X + resources.) If you don't specify this, the default + is to use \"yow\" from the Emacs distribution (if you + have it) or else to use \"fortune\"." +ac_help="$ac_help + +Locking options: + + --enable-locking Compile in support for locking the display + (this is the default.) + --disable-locking Do not allow locking at all." +ac_help="$ac_help + + --with-kerberos Include support for Kerberos authentication, + if possible (this is the default.) + --without-kerberos Do not compile in support for Kerberos." +ac_help="$ac_help + --with-shadow Include support for shadow password authentication, + if possible (this is the default, if no Kerberos.) + --without-shadow Do not compile in support for shadow passwords. +" + +# 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=driver/subprocs.c + +# 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:645: 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 + + +# 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:669: 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:698: 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:746: 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 <&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:780: 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:785: 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 <&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:809: 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 + + +if test -z "$GCC"; then + echo $ac_n "checking how to request ANSI compilation""... $ac_c" 1>&6 +echo "configure:839: checking how to request ANSI compilation" >&5 + case "$host" in + *-hpux*) + echo "$ac_t""HPUX: adding -Ae" 1>&6 + CC="$CC -Ae" + ;; + *-aix*) + echo "$ac_t""AIX: adding -qlanglvl=ansi -qhalt=e" 1>&6 + CC="$CC -qlanglvl=ansi -qhalt=e" + ;; + *) + echo "$ac_t""no idea" 1>&6 + ;; + esac +fi + + +echo $ac_n "checking whether the compiler works on ANSI C""... $ac_c" 1>&6 +echo "configure:857: checking whether the compiler works on ANSI C" >&5 +if test "$cross_compiling" = yes; then + { echo "configure: error: Couldn't build even a trivial ANSI C program: check CC." 1>&2; exit 1; } +else + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + echo "$ac_t""yes" 1>&6 +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + echo "$ac_t""no" 1>&6 + { echo "configure: error: Couldn't build even a trivial ANSI C program: check CC." 1>&2; exit 1; } +fi +rm -fr conftest* +fi + + +case "$host" in + *-irix*) + if test -n "$GCC"; then + echo "$ac_t""Turning on gcc compiler warnings." 1>&6 + CC="$CC -Wall -Wstrict-prototypes -Wnested-externs -Wno-format" + else + # not gcc + echo "$ac_t""Turning on SGI compiler warnings." 1>&6 + CC="$CC -fullwarn -use_readonly_const -rdata_shared -g3" + fi + ;; +esac + + +echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 +echo "configure:895: 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 < +Syntax Error +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:916: \"$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 < +Syntax Error +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:933: \"$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 + +# 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:966: 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:1016: 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 + + +echo $ac_n "checking for working const""... $ac_c" 1>&6 +echo "configure:1044: 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 <j = 5; +} +{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; +} + +; return 0; } +EOF +if { (eval echo configure:1098: \"$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 inline""... $ac_c" 1>&6 +echo "configure:1119: 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 <&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 <&6 +echo "configure:1160: 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 < +#include +#include +#include +EOF +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1173: \"$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 +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 +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 < +#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:1240: \"$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 whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 +echo "configure:1264: 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 < +#include +#include +int main() { +struct tm *tp; +; return 0; } +EOF +if { (eval echo configure:1278: \"$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 for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 +echo "configure:1299: checking for sys/wait.h that is POSIX.1 compatible" >&5 +if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#ifndef WEXITSTATUS +#define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8) +#endif +#ifndef WIFEXITED +#define WIFEXITED(stat_val) (((stat_val) & 255) == 0) +#endif +int main() { +int s; +wait (&s); +s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; +; return 0; } +EOF +if { (eval echo configure:1320: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_header_sys_wait_h=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_header_sys_wait_h=no +fi +rm -f conftest* +fi + +echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6 +if test $ac_cv_header_sys_wait_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_SYS_WAIT_H 1 +EOF + +fi + +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:1345: 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 < +#include <$ac_hdr> +int main() { +DIR *dirp = 0; +; return 0; } +EOF +if { (eval echo configure:1358: \"$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 <&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:1383: 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 <&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:1424: 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 <&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 + + +echo $ac_n "checking for mode_t""... $ac_c" 1>&6 +echo "configure:1467: 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 < +#if STDC_HEADERS +#include +#include +#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 pid_t""... $ac_c" 1>&6 +echo "configure:1500: 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 < +#if STDC_HEADERS +#include +#include +#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:1533: 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 < +#if STDC_HEADERS +#include +#include +#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 return type of signal handlers""... $ac_c" 1>&6 +echo "configure:1566: checking return type of signal handlers" >&5 +if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#ifdef signal +#undef signal +#endif +#ifdef __cplusplus +extern "C" void (*signal (int, void (*)(int)))(int); +#else +void (*signal ()) (); +#endif + +int main() { +int i; +; return 0; } +EOF +if { (eval echo configure:1588: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_type_signal=void +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_type_signal=int +fi +rm -f conftest* +fi + +echo "$ac_t""$ac_cv_type_signal" 1>&6 +cat >> confdefs.h <&6 +echo "configure:1608: 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 < + #include +int main() { +struct timeval tv; gettimeofday(&tv); +; return 0; } +EOF +if { (eval echo configure:1621: \"$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* + cat > conftest.$ac_ext < + #include +int main() { +struct timeval tv; struct timezone tzp; + gettimeofday(&tv, &tzp); +; return 0; } +EOF +if { (eval echo configure:1638: \"$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* + 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 = 1 ; then + cat >> confdefs.h <<\EOF +#define HAVE_GETTIMEOFDAY 1 +EOF + + echo "$ac_t""one argument" 1>&6 +elif 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 +else + echo "$ac_t""unknown" 1>&6 +fi + + +for ac_func in select fcntl uname nice setpriority getcwd getwd putenv +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:1678: 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 < +/* 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:1706: \"$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 <&6 +fi +done + +for ac_func in sigaction +do +echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +echo "configure:1733: 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 < +/* 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:1761: \"$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 <&6 +fi +done + + +for ac_hdr in unistd.h +do +ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 +echo "configure:1790: 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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1800: \"$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 <&6 +fi +done + + + + +# Check whether --enable-subdir or --disable-subdir was given. +if test "${enable_subdir+set}" = set; then + enableval="$enable_subdir" + enable_subdir="$enableval" +else + enable_subdir=no +fi + +if test x"$enable_subdir" = xno; then + HACKDIR='$(bindir)' +elif test x"$enable_subdir" = xyes -o x"$enable_subdir" = x ; then + echo "error: must be a subdirectory name: --enable-subdir=$enable_subdir" + exit 1 +else + HACKDIR='$(bindir)/'$enable_subdir +fi + + +# 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:1852: 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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:1919: \"$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 <&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:2101: checking whether -R must be followed by a space" >&5 + ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" + cat > conftest.$ac_ext <&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 <&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:2166: 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 <&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:2207: 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 <&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:2255: 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 < +/* 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:2283: \"$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:2304: 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 <&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:2353: 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 < +/* 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:2381: \"$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:2402: 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 <&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:2445: 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 < +/* 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:2473: \"$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:2494: 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 <&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:2537: 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 < +/* 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:2565: \"$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:2586: 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 <&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:2638: 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 <&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 + + +# Try and find the app-defaults directory. +# It sucks that autoconf doesn't do this already... +# + + + + + + + + + echo $ac_n "checking for X app-defaults directory""... $ac_c" 1>&6 +echo "configure:2694: 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 \ + /usr/X11/lib/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/app-defaults \ + /usr/lib/X11R5/app-defaults \ + /usr/lib/X11R4/app-defaults \ + \ + /usr/local/X11/lib/app-defaults \ + /usr/local/X11R6/lib/app-defaults \ + /usr/local/X11R5/lib/app-defaults \ + /usr/local/X11R4/lib/app-defaults \ + \ + /usr/local/lib/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/local/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/openwin/lib/app-defaults \ + /usr/openwin/lib/X11/app-defaults \ + /usr/openwin/share/lib/app-defaults \ + /usr/openwin/share/lib/X11/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 + + 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 + + +# Like AC_CHECK_HEADER, but it uses the already-computed -I directories. +# + + +# Like AC_EGREP_HEADER, but it uses the already-computed -I directories. +# + + +# Like AC_TRY_COMPILE, but it uses the already-computed -I directories. +# + + + +# Like AC_CHECK_LIB, but it uses the already-computed -I and -L directories. +# Use this sparingly; it probably doesn't work very well on X programs. +# + + +# Like AC_TRY_RUN, but it uses the already-computed -I directories. +# (But not the -L directories!) +# + + + + + + +# check for the HP XHPDisableReset server extension headers. +# + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "XHPDisableReset" >/dev/null 2>&1; then + rm -rf conftest* + cat >> confdefs.h <<\EOF +#define HAVE_XHPDISABLERESET 1 +EOF + + SAVER_LIBS="-lXhp11 $SAVER_LIBS" +fi +rm -f conftest* + + CPPFLAGS="$ac_save_CPPFLAGS" + + +# Check for the availability of the XPointer typedef, and define it otherwise. +# +echo $ac_n "checking for XPointer""... $ac_c" 1>&6 +echo "configure:2842: checking for XPointer" >&5 +if eval "test \"`echo '$''{'ac_cv_xpointer'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +int main() { +XPointer foo = (XPointer) 0; +; return 0; } +EOF +if { (eval echo configure:2860: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_xpointer=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_xpointer=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_xpointer" 1>&6 +if test $ac_cv_xpointer != yes; then + cat >> confdefs.h <<\EOF +#define XPointer char* +EOF + +fi + + +case "$host" in + *-hpux*) + # Thanks for not making xmkmf find this by default, you losers. + if test -d /usr/lib/Motif1.2 ; then + X_CFLAGS="-I/usr/include/Motif1.2 $X_CFLAGS" + X_LIBS="-L/usr/lib/Motif1.2 $X_LIBS" + elif test -d /usr/lib/Motif1.1 ; then + X_CFLAGS="-I/usr/include/Motif1.1 $X_CFLAGS" + X_LIBS="-L/usr/lib/Motif1.1 $X_LIBS" + fi + + # This too. You losers. + if test -d /usr/contrib/X11R6/include ; then + X_CFLAGS="-I/usr/contrib/X11R6/include $X_CFLAGS" + X_LIBS="-L/usr/contrib/X11R6/lib $X_LIBS" + elif test -d /usr/contrib/X11R5/include ; then + X_CFLAGS="-I/usr/contrib/X11R5/include $X_CFLAGS" + X_LIBS="-L/usr/contrib/X11R5/lib $X_LIBS" + fi + + ;; + *-solaris*) + # Same to you, pinheads. (Is this really the standard location now? + # What happened to the joke that this kind of thing went in /opt?) + if test -f /usr/dt/include/Xm/Xm.h ; then + X_CFLAGS="$X_CFLAGS -I/usr/dt/include" + X_LIBS="$X_LIBS -L/usr/dt/lib -R:/usr/dt/lib" + + # Some versions of Slowlaris Motif require -lgen. But not all. Why? + echo $ac_n "checking for regcmp in -lgen""... $ac_c" 1>&6 +echo "configure:2912: checking for regcmp in -lgen" >&5 +ac_lib_var=`echo gen'_'regcmp | 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="-lgen $LIBS" +cat > conftest.$ac_ext <&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_LIBS="$X_LIBS -lgen" +else + echo "$ac_t""no" 1>&6 +fi + + fi + ;; +esac + + + +# Check for Xmu (some fucked up vendors don't ship it...) +# +have_xmu=no + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/Xmu/Error.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/Xmu/Error.h""... $ac_c" 1>&6 +echo "configure:2968: checking for X11/Xmu/Error.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:2978: \"$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 + have_xmu=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +if test $have_xmu = no ; then + XMU_SRCS='$(UTILS_SRC)/xmu.c' + XMU_OBJS='$(UTILS_BIN)/xmu.o' +else + XMU_SRCS='' + XMU_OBJS='' + SAVER_LIBS="-lXmu $SAVER_LIBS" + HACK_LIBS="-lXmu $HACK_LIBS" + cat >> confdefs.h <<\EOF +#define HAVE_XMU 1 +EOF + +fi + + +# See comp.windows.x FAQ question 124 about _get_wmShellWidgetClass on 4.1.x. +# The right fix is to get OpenWindows 3.0 patches 100512-02 and 100573-03. +# +if test $have_xmu = yes ; then + case "$host" in + *-sunos4*) + echo $ac_n "checking for the SunOS 4.1.x _get_wmShellWidgetClass bug""... $ac_c" 1>&6 +echo "configure:3022: checking for the SunOS 4.1.x _get_wmShellWidgetClass bug" >&5 +if eval "test \"`echo '$''{'ac_cv_sunos_xmu_bug'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + # Note: this trick never works! (Generally.) + # We're only getting away with using AC_TRY_LINK + # with X libraries because we know it's SunOS. + LDFLAGS="$LDFLAGS -lXmu -lXt -lX11 -lXext -lm" + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_cv_sunos_xmu_bug=no +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_sunos_xmu_bug=yes +fi +rm -f conftest* + LDFLAGS="$ac_save_LDFLAGS" +fi + +echo "$ac_t""$ac_cv_sunos_xmu_bug" 1>&6 + if test $ac_cv_sunos_xmu_bug = yes ; then + echo $ac_n "checking whether the compiler understands -static""... $ac_c" 1>&6 +echo "configure:3058: checking whether the compiler understands -static" >&5 +if eval "test \"`echo '$''{'ac_cv_ld_static'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -static" + cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest; then + rm -rf conftest* + ac_cv_ld_static=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_ld_static=no +fi +rm -f conftest* + LDFLAGS="$ac_save_LDFLAGS" +fi + +echo "$ac_t""$ac_cv_ld_static" 1>&6 + if test $ac_cv_ld_static = yes ; then + LDFLAGS="$LDFLAGS -static" + else + LDFLAGS="$LDFLAGS -Bstatic" + fi + fi + ;; + esac +fi + + +# Check for the SGI SCREEN_SAVER server extension header. +# +have_sgi=no +with_sgi_req=unspecified +# Check whether --with-sgi-ext or --without-sgi-ext was given. +if test "${with_sgi_ext+set}" = set; then + withval="$with_sgi_ext" + with_sgi="$withval"; with_sgi_req="$withval" +else + with_sgi=yes +fi + +if test $with_sgi = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/XScreenSaver.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/XScreenSaver.h""... $ac_c" 1>&6 +echo "configure:3118: checking for X11/extensions/XScreenSaver.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3128: \"$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 + have_sgi=yes + cat >> confdefs.h <<\EOF +#define HAVE_SGI_SAVER_EXTENSION 1 +EOF + +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + +elif test $with_sgi != no; then + echo "error: must be yes or no: --with-sgi-ext=$with_sgi" + exit 1 +fi + +# Check for the MIT-SCREEN-SAVER server extension header, +# unless the SGI extension has already been found. +# +have_mit=no +with_mit_req=unspecified +# Check whether --with-mit-ext or --without-mit-ext was given. +if test "${with_mit_ext+set}" = set; then + withval="$with_mit_ext" + with_mit="$withval"; with_mit_req="$withval" +else + with_mit=yes +fi + +if test $have_sgi != yes; then + if test $with_mit = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/scrnsaver.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/scrnsaver.h""... $ac_c" 1>&6 +echo "configure:3183: checking for X11/extensions/scrnsaver.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3193: \"$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 + have_mit=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + + # Now check to see if it's really in the library; XF86Free-3.3 ships + # scrnsaver.h, but doesn't include the code in libXext.a, the idiots! + # + if test $have_mit = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + echo $ac_n "checking for XScreenSaverRegister in -lXext""... $ac_c" 1>&6 +echo "configure:3237: checking for XScreenSaverRegister in -lXext" >&5 +ac_lib_var=`echo Xext'_'XScreenSaverRegister | 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="-lXext -lm $LIBS" +cat > conftest.$ac_ext <&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 + ac_tr_lib=HAVE_LIB`echo Xext | sed -e 's/[^a-zA-Z0-9_]/_/g' \ + -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` + cat >> confdefs.h <&6 +have_mit=no +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + LDFLAGS="$ac_save_LDFLAGS" + + if test $have_mit = no; then + # Fuck! Looks like XF86Free-3.3 actually puts it in XExExt instead + # of in Xext. Thank you master, may I have another. + + ac_save_CPPFLAGS="$CPPFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + echo $ac_n "checking for XScreenSaverRegister in -lXExExt""... $ac_c" 1>&6 +echo "configure:3307: checking for XScreenSaverRegister in -lXExExt" >&5 +ac_lib_var=`echo XExExt'_'XScreenSaverRegister | 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="-lXExExt -lX11 -lXext -lm $LIBS" +cat > conftest.$ac_ext <&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 + have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXExExt" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + LDFLAGS="$ac_save_LDFLAGS" + fi + + if test $have_mit = no; then + # Double fuck! Looks like some versions of XFree86 (whichever version + # it is that comes with RedHat Linux 2.0 -- I can't find a version + # number) put this garbage in Xss instead of Xext. Thank you master, + # may I have another. + + ac_save_CPPFLAGS="$CPPFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + echo $ac_n "checking for XScreenSaverRegister in -lXss""... $ac_c" 1>&6 +echo "configure:3372: checking for XScreenSaverRegister in -lXss" >&5 +ac_lib_var=`echo Xss'_'XScreenSaverRegister | 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="-lXss -lX11 -lXext -lm $LIBS" +cat > conftest.$ac_ext <&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 + have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXss" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + LDFLAGS="$ac_save_LDFLAGS" + fi + + if test $have_mit = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_MIT_SAVER_EXTENSION 1 +EOF + + fi + + fi + + elif test $with_mit != no; then + echo "error: must be yes or no: --with-mit-ext=$with_mit" + exit 1 + fi +fi + + +# Check for the XIDLE server extension header. +# +have_xidle=no +with_xidle_req=unspecified +# Check whether --with-xidle-ext or --without-xidle-ext was given. +if test "${with_xidle_ext+set}" = set; then + withval="$with_xidle_ext" + with_xidle="$withval"; with_xidle_req="$withval" +else + with_xidle=yes +fi + +if test $with_xidle = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/xidle.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/xidle.h""... $ac_c" 1>&6 +echo "configure:3452: checking for X11/extensions/xidle.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3462: \"$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 + have_xidle=yes + cat >> confdefs.h <<\EOF +#define HAVE_XIDLE_EXTENSION 1 +EOF + +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +elif test $with_xidle != no; then + echo "error: must be yes or no: --with-xidle-ext=$with_xidle" + exit 1 +fi + + +# Check for the XSHM server extension header. +# +have_xshm=no +with_xshm_req=unspecified +# Check whether --with-xshm-ext or --without-xshm-ext was given. +if test "${with_xshm_ext+set}" = set; then + withval="$with_xshm_ext" + with_xshm="$withval"; with_xshm_req="$withval" +else + with_xshm=yes +fi + +if test $with_xshm = yes; then + + # first check for Xshm.h. + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/XShm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/XShm.h""... $ac_c" 1>&6 +echo "configure:3517: checking for X11/extensions/XShm.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3527: \"$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 + have_xshm=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + + # if that succeeded, then check for sys/ipc.h. + if test $have_xshm = yes; then + have_xshm=no + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "sys/ipc.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for sys/ipc.h""... $ac_c" 1>&6 +echo "configure:3561: checking for sys/ipc.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3571: \"$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 + have_xshm=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + fi + + # if that succeeded, then check for sys/shm.h. + if test $have_xshm = yes; then + have_xshm=no + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "sys/shm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for sys/shm.h""... $ac_c" 1>&6 +echo "configure:3606: checking for sys/shm.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3616: \"$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 + have_xshm=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + fi + + # if that succeeded, then we've really got it. + if test $have_xshm = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_XSHM_EXTENSION 1 +EOF + + fi + +elif test $with_xshm != no; then + echo "error: must be yes or no: --with-xshm-ext=$with_xshm" + exit 1 +fi + + +# Check for the SGI-VIDEO-CONTROL server extension header. +# +have_sgivc=no +with_sgivc_req=unspecified +# Check whether --with-sgivc-ext or --without-sgivc-ext was given. +if test "${with_sgivc_ext+set}" = set; then + withval="$with_sgivc_ext" + with_sgivc="$withval"; with_sgivc_req="$withval" +else + with_sgivc=yes +fi + +if test $with_sgivc = yes; then + + # first check for XSGIvc.h + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/XSGIvc.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/XSGIvc.h""... $ac_c" 1>&6 +echo "configure:3677: checking for X11/extensions/XSGIvc.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3687: \"$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 + have_sgivc=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + + # if that succeeded, then check for the -lXsgivc + if test $have_sgivc = yes; then + have_sgivc=no + + ac_save_CPPFLAGS="$CPPFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + echo $ac_n "checking for XSGIvcQueryGammaMap in -lXsgivc""... $ac_c" 1>&6 +echo "configure:3730: checking for XSGIvcQueryGammaMap in -lXsgivc" >&5 +ac_lib_var=`echo Xsgivc'_'XSGIvcQueryGammaMap | 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="-lXsgivc -lXext -lX11 $LIBS" +cat > conftest.$ac_ext <&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 + have_sgivc=yes; SAVER_LIBS="$SAVER_LIBS -lXsgivc" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + LDFLAGS="$ac_save_LDFLAGS" + fi + + # if that succeeded, then we've really got it. + if test $have_sgivc = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_SGI_VC_EXTENSION 1 +EOF + + fi + +elif test $with_sgivc != no; then + echo "error: must be yes or no: --with-sgivc-ext=$with_sgivc" + exit 1 +fi + + + + + + + + +# Check for Motif and Athena --with and --without arguments. +# +have_motif=no +have_athena=no +with_motif_req=unspecified +with_athena_req=unspecified + +# Check whether --with-motif or --without-motif was given. +if test "${with_motif+set}" = set; then + withval="$with_motif" + with_motif="$withval"; with_motif_req="$withval" +else + with_motif=no +fi + + +# Check whether --with-athena or --without-athena was given. +if test "${with_athena+set}" = set; then + withval="$with_athena" + with_athena="$withval"; with_athena_req="$withval" +else + with_athena=no +fi + + +if test $with_motif != yes -a $with_motif != no ; then + echo "error: must be yes or no: --with-motif=$with_motif" + exit 1 +fi + +if test $with_athena != yes -a $with_athena != no ; then + echo "error: must be yes or no: --with-athena=$with_athena" + exit 1 +fi + + +# Saying --without-motif is the same as saying --with-athena. +if test $with_motif_req = no ; then + with_athena_req=yes + with_athena=yes +fi + +# Saying --without-athena is the same as saying --with-motif. +if test $with_athena_req = no ; then + with_motif_req=yes + with_motif=yes +fi + +# Check for Motif and Athena headers. + +check_motif() { + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6 +echo "configure:3852: checking for Xm/Xm.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3862: \"$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 + have_motif=yes + cat >> confdefs.h <<\EOF +#define HAVE_MOTIF 1 +EOF + + SAVER_LIBS="-lXm $SAVER_LIBS" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +} + +check_athena() { + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/Xaw/Dialog.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/Xaw/Dialog.h""... $ac_c" 1>&6 +echo "configure:3900: checking for X11/Xaw/Dialog.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:3910: \"$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 + have_athena=yes + cat >> confdefs.h <<\EOF +#define HAVE_ATHENA 1 +EOF + + SAVER_LIBS="-lXaw $SAVER_LIBS" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +} + + +# If they asked for both motif and athena, check motif then athena. +# If they asked for only motif, check motif then athena. +# If they asked for only athena, check athena then motif. +# If they asked for neither, check motif then athena. + +proselytize_motif=yes +if test $with_motif = yes; then + # asked for both, or for motif only + check_motif + if test $have_motif = yes; then + with_athena=no + with_athena_req=no + else + check_athena + fi + +elif test $with_athena = yes; then + # asked for athena only + check_athena + if test $have_athena = yes; then + with_motif=no + proselytize_motif=no + else + check_motif + fi + +else + # asked for neither + check_motif + if test $have_motif = yes; then + with_athena=no + else + check_athena + fi + +fi + +if test $have_motif = yes; then + proselytize_motif=no +fi + +# If we have Athena, check whether it's a version that includes +# XawViewportSetCoordinates in Viewport.h (R3 (or R4?) don't.) +if test $have_athena = yes ; then + echo $ac_n "checking for XawViewportSetCoordinates in Viewport.h""... $ac_c" 1>&6 +echo "configure:3985: checking for XawViewportSetCoordinates in Viewport.h" >&5 +if eval "test \"`echo '$''{'ac_cv_have_XawViewportSetCoordinates'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + ac_cv_have_XawViewportSetCoordinates=no + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "XawViewportSetCoordinates" >/dev/null 2>&1; then + rm -rf conftest* + ac_cv_have_XawViewportSetCoordinates=yes +fi +rm -f conftest* + + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_have_XawViewportSetCoordinates" 1>&6 + if test $ac_cv_have_XawViewportSetCoordinates = yes ; then + cat >> confdefs.h <<\EOF +#define HAVE_XawViewportSetCoordinates 1 +EOF + + fi +fi + + +# If we have Motif, check whether it's really LessTif. +# +have_lesstif=no +if test $have_motif = yes ; then + echo $ac_n "checking whether Motif is really LessTif""... $ac_c" 1>&6 +echo "configure:4026: checking whether Motif is really LessTif" >&5 +if eval "test \"`echo '$''{'ac_cv_have_lesstif'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +int main() { +long vers = LesstifVersion; +; return 0; } +EOF +if { (eval echo configure:4044: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_have_lesstif=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_have_lesstif=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_have_lesstif" 1>&6 + have_lesstif=$ac_cv_have_lesstif +fi + +# don't cache this +unset ac_cv_good_lesstif + +good_lesstif=no +if test $have_lesstif = yes ; then + # It must be at least "GNU Lesstif 0.82". + # #### If you change this, also sync the warning message lower down. + echo $ac_n "checking whether LessTif is of a recent enough vintage""... $ac_c" 1>&6 +echo "configure:4069: checking whether LessTif is of a recent enough vintage" >&5 +if eval "test \"`echo '$''{'ac_cv_good_lesstif'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test "$cross_compiling" = yes; then + # cross compiling? Make an ass out of umption. + ac_cv_good_lesstif=yes +else + cat > conftest.$ac_ext < + int main() { exit(LesstifVersion < 82); } +EOF +if { (eval echo configure:4089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null +then + ac_cv_good_lesstif=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -fr conftest* + ac_cv_good_lesstif=no +fi +rm -fr conftest* +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_good_lesstif" 1>&6 + good_lesstif=$ac_cv_good_lesstif +fi + + +# check for XPM header. +# +have_xpm=no +with_xpm_req=unspecified +# Check whether --with-xpm or --without-xpm was given. +if test "${with_xpm+set}" = set; then + withval="$with_xpm" + with_xpm="$withval"; with_xpm_req="$withval" +else + with_xpm=yes +fi + +if test $with_xpm = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/xpm.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/xpm.h""... $ac_c" 1>&6 +echo "configure:4130: checking for X11/xpm.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4140: \"$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 + have_xpm=yes + cat >> confdefs.h <<\EOF +#define HAVE_XPM 1 +EOF + + XPM_LIBS="-lXpm" +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +elif test $with_xpm != no; then + echo "error: must be yes or no: --with-xpm=$with_xpm" + exit 1 +fi + + +# check for the GL header +# +have_gl=no +with_gl_req=unspecified +# Check whether --with-gl or --without-gl was given. +if test "${with_gl+set}" = set; then + withval="$with_gl" + with_gl="$withval"; with_gl_req="$withval" +else + with_gl=yes +fi + + +if test $with_gl = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "GL/gl.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for GL/gl.h""... $ac_c" 1>&6 +echo "configure:4195: checking for GL/gl.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4205: \"$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 + have_gl=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + if test $have_gl = yes ; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "GL/glx.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for GL/glx.h""... $ac_c" 1>&6 +echo "configure:4236: checking for GL/glx.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4246: \"$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 + have_gl=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + fi + + # If we have the headers, try and figure out which vendor it's from. + # + if test $have_gl = yes ; then + + cat >> confdefs.h <<\EOF +#define HAVE_GL 1 +EOF + + have_mesa_gl=no + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +EOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + egrep "Mesa" >/dev/null 2>&1; then + rm -rf conftest* + have_mesa_gl=yes +fi +rm -f conftest* + + CPPFLAGS="$ac_save_CPPFLAGS" + if test $have_mesa_gl = no ; then + GL_LIBS="-lGL -lGLU" + else + cat >> confdefs.h <<\EOF +#define HAVE_MESA_GL 1 +EOF + + GL_LIBS="-lMesaGL -lMesaGLU" + fi + fi + +elif test $with_gl != no; then + echo "error: must be yes or no: --with-gl=$with_gl" + exit 1 +fi + + +# check for SGI XReadDisplay server extension header. +# +have_readdisplay=no +with_readdisplay_req=unspecified +# Check whether --with-readdisplay or --without-readdisplay was given. +if test "${with_readdisplay+set}" = set; then + withval="$with_readdisplay" + with_readdisplay="$withval"; with_readdisplay_req="$withval" +else + with_readdisplay=yes +fi + +if test $with_readdisplay = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "X11/extensions/readdisplay.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for X11/extensions/readdisplay.h""... $ac_c" 1>&6 +echo "configure:4336: checking for X11/extensions/readdisplay.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4346: \"$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_READ_DISPLAY_EXTENSION 1 +EOF + +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" +elif test $with_readdisplay != no; then + echo "error: must be yes or no: --with-readdisplay=$with_readdisplay" + exit 1 +fi + + +# check for SGI's Iris Video Library header. +# +have_sgivideo=no +with_sgivideo_req=unspecified +# Check whether --with-sgivideo or --without-sgivideo was given. +if test "${with_sgivideo+set}" = set; then + withval="$with_sgivideo" + with_sgivideo="$withval"; with_sgivideo_req="$withval" +else + with_sgivideo=yes +fi + +if test $with_sgivideo = yes; then + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + ac_safe=`echo "dmedia/vl.h" | sed 'y%./+-%__p_%'` +echo $ac_n "checking for dmedia/vl.h""... $ac_c" 1>&6 +echo "configure:4398: checking for dmedia/vl.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 +ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +{ (eval echo configure:4408: \"$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 + have_sgivideo=yes +else + echo "$ac_t""no" 1>&6 +fi + + CPPFLAGS="$ac_save_CPPFLAGS" + if test $have_sgivideo = yes; then + have_sgivideo=no + echo $ac_n "checking for vlOpenVideo in -lvl""... $ac_c" 1>&6 +echo "configure:4433: checking for vlOpenVideo in -lvl" >&5 +ac_lib_var=`echo vl'_'vlOpenVideo | 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="-lvl $LIBS" +cat > conftest.$ac_ext <&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 + have_sgivideo=yes +else + echo "$ac_t""no" 1>&6 +fi + + if test $have_sgivideo = yes; then + SGI_VIDEO_OBJS="$(UTILS_BIN)/sgivideo.o" + SGI_VIDEO_LIBS="-lvl" + cat >> confdefs.h <<\EOF +#define HAVE_SGI_VIDEO 1 +EOF + + fi + fi +elif test $with_sgivideo != no; then + echo "error: must be yes or no: --with-sgivideo=$with_sgivideo" + exit 1 +fi + + + +# Try to find a program to generate random text. +# +# Zippy is funnier than the idiocy generally spat out by `fortune', +# so try to find that, by invoking Emacs and asking it where its +# libexec directory is ("yow" lives in there.) +# +# If that doesn't work, see if fortune, zippy, or yow are on $PATH, +# and if so, use them. +# +# If that doesn't work, look in /usr/games, and if it's there, use +# the full pathname. +# +with_zippy_req="" +# Check whether --with-zippy or --without-zippy was given. +if test "${with_zippy+set}" = set; then + withval="$with_zippy" + with_zippy_req="$withval"; with_zippy="$withval" +else + with_zippy_req="$withval"; with_zippy="$withval" +fi + + +if test "$with_zippy" = no || test "$with_zippy" = yes ; then + with_zippy="" + with_zippy_req="" +fi + +if test -n "$with_zippy_req" ; then + ac_cv_zippy_program="" + case "$with_zippy_req" in + /*) + echo $ac_n "checking for $with_zippy_req""... $ac_c" 1>&6 +echo "configure:4520: checking for $with_zippy_req" >&5 + if test -x "$with_zippy_req" ; then + echo "$ac_t""yes" 1>&6 + else + echo "$ac_t""no" 1>&6 + with_zippy="" + fi + ;; + *) + # don't cache + unset ac_cv_path_zip2 + # Extract the first word of "$with_zippy_req", so it can be a program name with args. +set dummy $with_zippy_req; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:4534: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_zip2'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$zip2" in + /*) + ac_cv_path_zip2="$zip2" # 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_zip2="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + ;; +esac +fi +zip2="$ac_cv_path_zip2" +if test -n "$zip2"; then + echo "$ac_t""$zip2" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + + if test "$zip2" = ""; then + with_zippy="" + fi + ;; + esac + ac_cv_zippy_program="$with_zippy" + +elif test -n "$ac_cv_zippy_program"; then + echo "$ac_t""checking for zippy... (cached) $ac_cv_zippy_program" 1>&6 +fi + +if test ! -n "$ac_cv_zippy_program"; then + + for ac_prog in emacs +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:4580: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_emacs_exe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$emacs_exe"; then + ac_cv_prog_emacs_exe="$emacs_exe" # 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_emacs_exe="$ac_prog" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +emacs_exe="$ac_cv_prog_emacs_exe" +if test -n "$emacs_exe"; then + echo "$ac_t""$emacs_exe" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$emacs_exe" && break +done + + for ac_prog in xemacs +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:4613: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_xemacs_exe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$xemacs_exe"; then + ac_cv_prog_xemacs_exe="$xemacs_exe" # 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_xemacs_exe="$ac_prog" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +xemacs_exe="$ac_cv_prog_xemacs_exe" +if test -n "$xemacs_exe"; then + echo "$ac_t""$xemacs_exe" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$xemacs_exe" && break +done + + + ac_cv_zippy_program="" + eargs='-batch -q -nw --eval' + + if test -n "$emacs_exe" ; then + echo $ac_n "checking for emacs yow""... $ac_c" 1>&6 +echo "configure:4647: checking for emacs yow" >&5 + # + # get emacs to tell us where the libexec directory is. + # + dir=`$emacs_exe $eargs '(princ (concat exec-directory "\n"))' \ + 2>/dev/null | tail -1` + dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'` + # + # try running libexec/yow and see if it exits without error. + # + if test x"$dir" != x -a -x $dir/yow ; then + if $dir/yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/yow" + echo "$ac_t""$ac_cv_zippy_program" 1>&6 + else + echo "$ac_t""no" 1>&6 + fi + fi + fi + + if test -z "$ac_cv_zippy_program" ; then + echo $ac_n "checking for xemacs yow""... $ac_c" 1>&6 +echo "configure:4669: checking for xemacs yow" >&5 + if test -n "$xemacs_exe" ; then + # + # get xemacs to tell us where the libexec directory is. + # + dir=`$xemacs_exe $eargs '(princ (concat exec-directory "\n"))' \ + 2>/dev/null | tail -1` + dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'` + # + # try running libexec/yow and see if it exits without error. + # + if test x"$dir" != x -a -x $dir/yow ; then + if $dir/yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/yow" + echo "$ac_t""$ac_cv_zippy_program" 1>&6 + else + # + # in some xemacs installations, the pathname of the yow.lines file + # isn't hardcoded into the yow executable, and must be passed on + # the command line. See if it's in libexec/../etc/. + + # M4 sucks!! + + dir_up=`echo "$dir" | sed 's@/[^/]*$@@'` + + + yow="yow -f $dir_up/etc/yow.lines" + if $dir/$yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/$yow" + echo "$ac_t""$ac_cv_zippy_program" 1>&6 + else + echo "$ac_t""no" 1>&6 + fi + fi + fi + fi + fi + + # if that didn't work, try for some other programs... + if test -z "$ac_cv_zippy_program" ; then + fortune='' + for ac_prog in fortune zippy yow +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:4715: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_fortune'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + if test -n "$fortune"; then + ac_cv_prog_fortune="$fortune" # 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_fortune="$ac_prog" + break + fi + done + IFS="$ac_save_ifs" +fi +fi +fortune="$ac_cv_prog_fortune" +if test -n "$fortune"; then + echo "$ac_t""$fortune" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$fortune" && break +done + + # if that didn't work, try for those programs in /usr/games... + if test -z "$fortune" ; then + for ac_prog in fortune zippy yow +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:4750: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_path_fortune'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + case "$fortune" in + /*) + ac_cv_path_fortune="$fortune" # Let the user override the test with a path. + ;; + *) + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" + for ac_dir in /usr/games:/usr/local/games$ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_path_fortune="$ac_dir/$ac_word" + break + fi + done + IFS="$ac_save_ifs" + ;; +esac +fi +fortune="$ac_cv_path_fortune" +if test -n "$fortune"; then + echo "$ac_t""$fortune" 1>&6 +else + echo "$ac_t""no" 1>&6 +fi + +test -n "$fortune" && break +done +test -n "$fortune" || fortune="fortune" + + fi + fi +fi + +if test -z "$ac_cv_zippy_program" ; then + ac_cv_zippy_program=fortune +fi + +cat >> confdefs.h <&6 +echo "configure:4829: checking for Kerberos" >&5 +if eval "test \"`echo '$''{'ac_cv_kerberos'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < +int main() { + +; return 0; } +EOF +if { (eval echo configure:4847: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_kerberos=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_kerberos=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_kerberos" 1>&6 + if test $ac_cv_kerberos = yes ; then + have_kerberos=yes + cat >> confdefs.h <<\EOF +#define HAVE_KERBEROS 1 +EOF + + PASSWD_LIBS="$PASSWD_LIBS -lkrb -ldes -lnsl -lsocket" + fi + elif test $with_kerberos != no; then + echo "error: must be yes or no: --with-kerberos=$with_kerberos" + exit 1 + fi + + # Next, check for the nine billion variants of shadow passwords... + + passwd_cruft_done=no + # Check whether --with-shadow or --without-shadow was given. +if test "${with_shadow+set}" = set; then + withval="$with_shadow" + with_shadow="$withval"; with_shadow_req="$withval" +else + with_shadow=yes +fi + + if test $with_shadow = no; then + passwd_cruft_done=yes + elif test $with_shadow != yes; then + echo "error: must be yes or no: --with-shadow=$with_shadow" + exit 1 + fi + + + # Sun's "adjunct" passwords. + # + if test $passwd_cruft_done = no ; then + echo $ac_n "checking for Sun-style shadow passwords""... $ac_c" 1>&6 +echo "configure:4897: checking for Sun-style shadow passwords" >&5 +if eval "test \"`echo '$''{'ac_cv_sun_adjunct'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < + #include + #include + #include + #include + #include +int main() { +struct passwd_adjunct *p = getpwanam("nobody"); + const char *pw = p->pwa_passwd; +; return 0; } +EOF +if { (eval echo configure:4921: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_sun_adjunct=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_sun_adjunct=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_sun_adjunct" 1>&6 + if test $ac_cv_sun_adjunct = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + cat >> confdefs.h <<\EOF +#define HAVE_ADJUNCT_PASSWD 1 +EOF + + fi + fi + + # DEC and SCO so-called "enhanced" security. + # + if test $passwd_cruft_done = no ; then + echo $ac_n "checking for DEC-style shadow passwords""... $ac_c" 1>&6 +echo "configure:4950: checking for DEC-style shadow passwords" >&5 +if eval "test \"`echo '$''{'ac_cv_enhanced_passwd'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < + #include + #include + #include + #include + #include +int main() { +struct pr_passwd *p; + const char *pw; + set_auth_parameters(0, 0); + check_auth_parameters(); + p = getprpwnam("nobody"); + pw = p->ufld.fd_encrypt; +; return 0; } +EOF +if { (eval echo configure:4978: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_enhanced_passwd=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_enhanced_passwd=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_enhanced_passwd" 1>&6 + if test $ac_cv_enhanced_passwd = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + cat >> confdefs.h <<\EOF +#define HAVE_ENHANCED_PASSWD 1 +EOF + + + # On SCO, getprpwnam() is in -lprot (which uses nap() from -lx) + # (I'm told it needs -lcurses too, but I don't understand why.) + echo $ac_n "checking for getprpwnam in -lprot""... $ac_c" 1>&6 +echo "configure:5004: checking for getprpwnam in -lprot" >&5 +ac_lib_var=`echo prot'_'getprpwnam | 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="-lprot -lx $LIBS" +cat > conftest.$ac_ext <&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 + PASSWD_LIBS="$PASSWD_LIBS -lprot -lcurses -lx" +else + echo "$ac_t""no" 1>&6 +# On DEC, getprpwnam() is in -lsecurity + echo $ac_n "checking for getprpwnam in -lsecurity""... $ac_c" 1>&6 +echo "configure:5043: checking for getprpwnam in -lsecurity" >&5 +ac_lib_var=`echo security'_'getprpwnam | 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="-lsecurity $LIBS" +cat > conftest.$ac_ext <&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 + PASSWD_LIBS="$PASSWD_LIBS -lsecurity" +else + echo "$ac_t""no" 1>&6 +fi + +fi + + fi + fi + + # HP's entry in the "Not Invented Here" Sweepstakes. + # + if test $passwd_cruft_done = no ; then + echo $ac_n "checking for HP-style shadow passwords""... $ac_c" 1>&6 +echo "configure:5091: checking for HP-style shadow passwords" >&5 +if eval "test \"`echo '$''{'ac_cv_hpux_passwd'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < + #include + #include + #include + #include + #include +int main() { +struct s_passwd *p = getspwnam("nobody"); + const char *pw = p->pw_passwd; +; return 0; } +EOF +if { (eval echo configure:5115: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_hpux_passwd=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_hpux_passwd=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_hpux_passwd" 1>&6 + if test $ac_cv_hpux_passwd = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + cat >> confdefs.h <<\EOF +#define HAVE_HPUX_PASSWD 1 +EOF + + + # on HPUX, bigcrypt is in -lsec + echo $ac_n "checking for bigcrypt in -lsec""... $ac_c" 1>&6 +echo "configure:5140: checking for bigcrypt in -lsec" >&5 +ac_lib_var=`echo sec'_'bigcrypt | 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="-lsec $LIBS" +cat > conftest.$ac_ext <&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 + PASSWD_LIBS="$PASSWD_LIBS -lsec" +else + echo "$ac_t""no" 1>&6 +fi + + fi + fi + + # Traditional (ha!) shadow passwords. + # + if test $passwd_cruft_done = no ; then + echo $ac_n "checking for generic shadow passwords""... $ac_c" 1>&6 +echo "configure:5186: checking for generic shadow passwords" >&5 +if eval "test \"`echo '$''{'ac_cv_shadow'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + cat > conftest.$ac_ext < + #include + #include + #include + #include +int main() { +struct spwd *p = getspnam("nobody"); + const char *pw = p->sp_pwdp; +; return 0; } +EOF +if { (eval echo configure:5209: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_shadow=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + ac_cv_shadow=no +fi +rm -f conftest* + CPPFLAGS="$ac_save_CPPFLAGS" +fi + +echo "$ac_t""$ac_cv_shadow" 1>&6 + if test $ac_cv_shadow = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + cat >> confdefs.h <<\EOF +#define HAVE_SHADOW_PASSWD 1 +EOF + + + # On some systems (UnixWare 2.1), getspnam() is in -lgen instead of -lc. + have_getspnam=no + echo $ac_n "checking for getspnam in -lc""... $ac_c" 1>&6 +echo "configure:5235: checking for getspnam in -lc" >&5 +ac_lib_var=`echo c'_'getspnam | 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="-lc $LIBS" +cat > conftest.$ac_ext <&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 + have_getspnam=yes +else + echo "$ac_t""no" 1>&6 +fi + + if test $have_getspnam = no ; then + echo $ac_n "checking for getspnam in -lgen""... $ac_c" 1>&6 +echo "configure:5276: checking for getspnam in -lgen" >&5 +ac_lib_var=`echo gen'_'getspnam | 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="-lgen $LIBS" +cat > conftest.$ac_ext <&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 + have_getspnam=yes; PASSWD_LIBS="$PASSWD_LIBS -lgen" +else + echo "$ac_t""no" 1>&6 +fi + + fi + fi + fi + + # On some systems (UnixWare 2.1), crypt() is in -lcrypt instead of -lc. + have_crypt=no + echo $ac_n "checking for crypt in -lc""... $ac_c" 1>&6 +echo "configure:5322: checking for crypt in -lc" >&5 +ac_lib_var=`echo c'_'crypt | 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="-lc $LIBS" +cat > conftest.$ac_ext <&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 + have_crypt=yes +else + echo "$ac_t""no" 1>&6 +fi + + if test $have_crypt = no ; then + echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 +echo "configure:5363: checking for crypt in -lcrypt" >&5 +ac_lib_var=`echo crypt'_'crypt | 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="-lcrypt $LIBS" +cat > conftest.$ac_ext <&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 + have_crypt=yes; PASSWD_LIBS="$PASSWD_LIBS -lcrypt" +else + echo "$ac_t""no" 1>&6 +fi + + fi + + + # Most of the above shadow mechanisms will have set need_setuid to yes, + # if they were found. But, on some systems, we need setuid even when + # using plain old vanilla passwords. + # + if test $need_setuid = no ; then + case "$host" in + *-hpux* | *-aix* | *-netbsd* | *-freebsd* | *-openbsd* ) + need_setuid=yes + ;; + esac + fi + +elif test $enable_locking = no; then + cat >> confdefs.h <<\EOF +#define NO_LOCKING 1 +EOF + +else + echo "error: must be yes or no: --enable-locking=$enable_locking" + exit 1 +fi + + + +if test \! -z "$includedir" ; then + INCLUDES="-I$includedir" +fi + +if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" +fi + + +##### should have options to override the DEPEND crap, I guess... +DEPEND=makedepend +DEPEND_FLAGS= +DEPEND_DEFINES= + + + +# Done testing things -- now substitute in some stuff for the Makefiles. +# +if test $have_motif = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_MOTIF 1 +EOF + + DIALOG_SRCS='$(MOTIF_SRCS)' + DIALOG_OBJS='$(MOTIF_OBJS)' +elif test $have_athena = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_ATHENA 1 +EOF + + DIALOG_SRCS='$(ATHENA_SRCS)' + DIALOG_OBJS='$(ATHENA_OBJS)' +else + DIALOG_SRCS='' + DIALOG_OBJS='' +fi + +if test $have_kerberos = yes; then + PASSWD_SRCS='$(KERBEROS_SRCS)' + PASSWD_OBJS='$(KERBEROS_OBJS)' +else + PASSWD_SRCS='$(PWENT_SRCS)' + PASSWD_OBJS='$(PWENT_OBJS)' +fi + +if test $enable_locking = yes; then + LOCK_SRCS='$(LOCK_SRCS_1) $(PASSWD_SRCS)' + LOCK_OBJS='$(LOCK_OBJS_1) $(PASSWD_OBJS)' +else + LOCK_SRCS='' + LOCK_OBJS='' +fi + +if test $need_setuid = yes; then + NEED_SETUID=yes + INSTALL_SETUID='$(INSTALL) $(SUID_FLAGS)' +else + NEED_SETUID=no + INSTALL_SETUID='$(INSTALL_PROGRAM)' +fi + +tab=' ' +if test $have_gl = yes; then + GL_EXES='$(GL_EXES)' + GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}' \' + GL_KLUDGE_2=${tab} +else + GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}'\n' + GL_KLUDGE_2='!'${tab} +fi + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +# Print some warnings before emitting the Makefiles. +# +warning=no +warnsep=' #################################################################' +warnpre() { + if test $warning = no ; then + echo '' ; echo "$warnsep" ; echo '' + warning=yes + fi +} + +warn() { + warnpre + if test $warning = long ; then echo '' ; fi + warning=yes + echo " Warning: $@" +} + +warnL() { + was=$warning + warnpre + warning=yes + if test $was != no ; then echo '' ; fi + echo " Warning: $@" +} + +warn2() { + echo " $@" + warning=long +} + +if test $with_sgi_req = yes -a $have_sgi = no ; then + warn 'The SGI saver extension was requested, but was not found.' +fi + +if test $with_mit_req = yes -a $have_mit = no ; then + warn 'The MIT saver extension was requested, but was not found.' +fi + +if test $with_xidle_req = yes -a $have_xidle = no ; then + warn 'The XIdle extension was requested, but was not found.' +fi + +if test $with_xshm_req = yes -a $have_xshm = no ; then + warn 'The XSHM extension was requested, but was not found.' +fi + +if test $with_sgivc_req = yes -a $have_sgivc = no ; then + warn 'The SGI-VIDEO-CONTROL extension was requested, but was not found.' +fi + +if test $have_motif = no -a $have_athena = no ; then + warnL "Neither Motif nor Athena widgets seem to be available;" + warn2 "one or the other is required." + proselytize_motif=no + +elif test $with_motif_req = yes -a $have_motif = no ; then + warnL "Use of Motif was requested, but it wasn't found;" + warn2 "Athena will be used instead." + +elif test $with_athena_req = yes -a $have_athena = no ; then + warnL "Use of Athena was requested, but it wasn't found;" + warn2 "Motif will be used instead." +fi + +if test $have_motif = yes -a $have_lesstif = yes ; then + if test $good_lesstif != yes ; then + warnL "Motif is being used, but it appears to actually be" + warn2 "LessTif, and the version number is less than 0.82!" + warn2 "Such old versions of LessTif are too buggy to use" + warn2 "with XScreenSaver; it is strongly recommended that" + warn2 "you upgrade! See ." + fi +fi + +if test $proselytize_motif = yes ; then + warnL "Athena widgets are being used instead of Motif." + warn2 "XScreenSaver looks much better with Motif, and has" + warn2 "a few extra features as well. Wouldn't you rather" + warn2 "be using Motif? It is shipped by every commercial" + warn2 "Unix vendor; and there is a free implementation" + warn2 "available as well: see ." +fi + +if test $with_xpm_req = yes -a $have_xpm = no ; then + warn 'Use of XPM was requested, but it was not found.' +fi + +if test $with_gl_req = yes -a $have_gl = no ; then + warn 'Use of GL was requested, but it was not found.' +fi + +if test $with_readdisplay_req = yes -a $have_readdisplay = no ; then + warn 'Use of XReadDisplay was requested, but it was not found.' +fi + +if test $with_sgivideo_req = yes -a $have_sgivideo = no ; then + warn 'Use of the Iris Video Library was requested, but it was not found.' +fi + +if test $with_kerberos_req = yes -a $have_kerberos = no ; then + warn 'Use of Kerberos was requested, but it was not found.' +fi + +if test $with_shadow_req = yes -a $have_shadow = no ; then + warn 'Use of shadow passwords was requested, but they were not found.' +fi + +if test -n "$with_zippy_req"; then + if test "$with_zippy_req" != "$ac_cv_zippy_program" ; then + warnL "$with_zippy_req was requested as the Zippy program," + warn2 "but was not found. The default will be used instead." + fi +fi + +if test $warning != no; then + echo '' ; echo "$warnsep" ; echo '' +fi + + +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 </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 + utils/Makefile + driver/Makefile + hacks/Makefile + hacks/glx/Makefile + driver/XScreenSaver.ad config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +EOF +cat >> $CONFIG_STATUS < 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%@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%@zip2@%$zip2%g +s%@emacs_exe@%$emacs_exe%g +s%@xemacs_exe@%$xemacs_exe%g +s%@fortune@%$fortune%g +s%@INCLUDES@%$INCLUDES%g +s%@SAVER_LIBS@%$SAVER_LIBS%g +s%@HACK_LIBS@%$HACK_LIBS%g +s%@XPM_LIBS@%$XPM_LIBS%g +s%@GL_LIBS@%$GL_LIBS%g +s%@PASSWD_LIBS@%$PASSWD_LIBS%g +s%@INSTALL_SETUID@%$INSTALL_SETUID%g +s%@NEED_SETUID@%$NEED_SETUID%g +s%@SGI_VIDEO_OBJS@%$SGI_VIDEO_OBJS%g +s%@SGI_VIDEO_LIBS@%$SGI_VIDEO_LIBS%g +s%@DIALOG_SRCS@%$DIALOG_SRCS%g +s%@DIALOG_OBJS@%$DIALOG_OBJS%g +s%@PASSWD_SRCS@%$PASSWD_SRCS%g +s%@PASSWD_OBJS@%$PASSWD_OBJS%g +s%@XMU_SRCS@%$XMU_SRCS%g +s%@XMU_OBJS@%$XMU_OBJS%g +s%@LOCK_SRCS@%$LOCK_SRCS%g +s%@LOCK_OBJS@%$LOCK_OBJS%g +s%@GL_EXES@%$GL_EXES%g +s%@GL_KLUDGE_1@%$GL_KLUDGE_1%g +s%@GL_KLUDGE_2@%$GL_KLUDGE_2%g +s%@HACKDIR@%$HACKDIR%g +s%@APPDEFAULTS@%$APPDEFAULTS%g +s%@DEPEND@%$DEPEND%g +s%@DEPEND_FLAGS@%$DEPEND_FLAGS%g +s%@DEPEND_DEFINES@%$DEPEND_DEFINES%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 <> $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 <> $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 <> $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 <> $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/configure-98 b/configure-98 new file mode 100755 index 00000000..97357538 --- /dev/null +++ b/configure-98 @@ -0,0 +1,5 @@ +CFLAGS="-b elf -I/usr/local/include" +LDFLAGS="-b elf -L/usr/local/lib" +CPPFLAGS="-I/usr/local/include" +export CFLAGS LDFLAGS CPPFLAGS +./configure --prefix=/skunk98/usr/local --exec-prefix=/skunk98/usr/local --without-sgi-ext -without-mit-ext --with-motif --with-xpm --disable-locking --without-shadow --without-kerberos diff --git a/configure-ancilla b/configure-ancilla new file mode 100755 index 00000000..a2b5bffe --- /dev/null +++ b/configure-ancilla @@ -0,0 +1,14 @@ +#!/bin/ksh +#x=`whence gcc` +#if [ -z "$x" ]; then +# echo "MUST USE gcc" +# exit 1 +#fi +#CFLAGS="-b elf -I/u/include -DDEBUG -DUSE_SIGACTION -g" +#CFLAGS="-b elf -I/u/include -DUSE_SIGACTION" +CFLAGS="-b elf -I/u/include" +#LDFLAGS="-b elf -L/u/lib -g" +LDFLAGS="-b elf -L/u/lib" +CPPFLAGS="-I/u/include" +export CFLAGS LDFLAGS CPPFLAGS +./configure --exec-prefix=/u --without-sgi-ext -without-mit-ext --with-motif --with-xpm --disable-locking --without-shadow --without-kerberos diff --git a/configure-skunkware b/configure-skunkware new file mode 100755 index 00000000..f0311b8b --- /dev/null +++ b/configure-skunkware @@ -0,0 +1,6 @@ +CC=cc +CFLAGS="-b elf -I/usr/local/include" +LDFLAGS="-b elf -L/usr/local/lib" +CPPFLAGS="-I/usr/local/include" +export CC CFLAGS LDFLAGS CPPFLAGS +./configure --prefix=/usr/local --exec-prefix=/usr/local --without-sgi-ext -without-mit-ext --with-motif --with-xpm --disable-locking --without-shadow --without-kerberos diff --git a/configure-skunkware.00 b/configure-skunkware.00 new file mode 100755 index 00000000..c905fcce --- /dev/null +++ b/configure-skunkware.00 @@ -0,0 +1,5 @@ +CFLAGS="-b elf -I/usr/local/include" +LDFLAGS="-b elf -L/usr/local/lib" +CPPFLAGS="-I/usr/local/include" +export CFLAGS LDFLAGS CPPFLAGS +./configure --prefix=/usr/local --exec-prefix=/usr/local --without-sgi-ext -without-mit-ext --with-motif --with-xpm --disable-locking --without-shadow --without-kerberos diff --git a/configure.in b/configure.in new file mode 100644 index 00000000..e614456e --- /dev/null +++ b/configure.in @@ -0,0 +1,1401 @@ +# configure.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# + +AC_INIT(driver/subprocs.c) +AC_CONFIG_HEADER(config.h) +AC_CANONICAL_HOST + +AC_PROG_CC + +if test -z "$GCC"; then + AC_MSG_CHECKING(how to request ANSI compilation) + case "$host" in + *-hpux*) + AC_MSG_RESULT(HPUX: adding -Ae) + CC="$CC -Ae" + ;; + *-aix*) + AC_MSG_RESULT(AIX: adding -qlanglvl=ansi -qhalt=e) + CC="$CC -qlanglvl=ansi -qhalt=e" + ;; + *) + AC_MSG_RESULT(no idea) + ;; + esac +fi + + +AC_MSG_CHECKING([whether the compiler works on ANSI C]) +AC_TRY_RUN([ main(int ac, char **av) { return 0; } ], + AC_MSG_RESULT(yes), + AC_MSG_RESULT(no) + AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.), + AC_MSG_ERROR(Couldn't build even a trivial ANSI C program: check CC.)) + +case "$host" in + *-irix*) + if test -n "$GCC"; then + AC_MSG_RESULT(Turning on gcc compiler warnings.) + CC="$CC -Wall -Wstrict-prototypes -Wnested-externs -Wno-format" + else + # not gcc + AC_MSG_RESULT(Turning on SGI compiler warnings.) + CC="$CC -fullwarn -use_readonly_const -rdata_shared -g3" + fi + ;; +esac + + +AC_PROG_CPP +AC_PROG_INSTALL +AC_PROG_MAKE_SET + +AC_C_CONST +AC_C_INLINE + +AC_HEADER_STDC +AC_HEADER_TIME +AC_HEADER_SYS_WAIT +AC_HEADER_DIRENT + +AC_TYPE_MODE_T +AC_TYPE_PID_T +AC_TYPE_SIZE_T +AC_TYPE_SIGNAL + +AC_MSG_CHECKING(how to call gettimeofday) +AC_CACHE_VAL(ac_cv_gettimeofday_args, + [AC_TRY_COMPILE([#include + #include ], + [struct timeval tv; gettimeofday(&tv);], + [ac_gettimeofday_args=1], + [AC_TRY_COMPILE([#include + #include ], + [struct timeval tv; struct timezone tzp; + gettimeofday(&tv, &tzp);], + [ac_gettimeofday_args=2], + [ac_gettimeofday_args=0])]) + ac_cv_gettimeofday_args=$ac_gettimeofday_args]) +ac_gettimeofday_args=$ac_cv_gettimeofday_args +if test $ac_gettimeofday_args = 1 ; then + AC_DEFINE(HAVE_GETTIMEOFDAY) + AC_MSG_RESULT(one argument) +elif test $ac_gettimeofday_args = 2 ; then + AC_DEFINE(HAVE_GETTIMEOFDAY) + AC_DEFINE(GETTIMEOFDAY_TWO_ARGS) + AC_MSG_RESULT(two arguments) +else + AC_MSG_RESULT(unknown) +fi + + +AC_CHECK_FUNCS(select fcntl uname nice setpriority getcwd getwd putenv) +AC_CHECK_FUNCS(sigaction) + +AC_CHECK_HEADERS(unistd.h) + +dnl /usr/local/src/ssh-1.2.17/putenv.c -- AC_REPLACE_FUNCS(putenv) + + +AC_ARG_ENABLE(subdir,[ +Installation options: + + --enable-subdir=DIR Put the demo programs in a subdirectory of \`bindir', + instead of putting them in bindir itself. You can + specify the name of the subdirectory. For example, + --exec-prefix=/usr/local/bin --enable-subdir=demos + would put xscreensaver in /usr/local/bin/, and would + put the demos in /usr/local/bin/demos/. Note that if + you do this, you must make sure that the directory + is on your \$PATH before xscreensaver is started: the + directory name is not hardcoded into the program. + This merely sets the default installation location. + + --disable-subdir Just put the demos in \`bindir' (this is the default.) +], + [enable_subdir="$enableval"],[enable_subdir=no]) +if test x"$enable_subdir" = xno; then + HACKDIR='$(bindir)' +elif test x"$enable_subdir" = xyes -o x"$enable_subdir" = x ; then + echo "error: must be a subdirectory name: --enable-subdir=$enable_subdir" + exit 1 +else + HACKDIR='$(bindir)/'$enable_subdir +fi + + +AC_PATH_XTRA + +# Try and find the app-defaults directory. +# It sucks that autoconf doesn't do this already... +# +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 \ + /usr/X11/lib/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/app-defaults \ + /usr/lib/X11R5/app-defaults \ + /usr/lib/X11R4/app-defaults \ + \ + /usr/local/X11/lib/app-defaults \ + /usr/local/X11R6/lib/app-defaults \ + /usr/local/X11R5/lib/app-defaults \ + /usr/local/X11R4/lib/app-defaults \ + \ + /usr/local/lib/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/local/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/openwin/lib/app-defaults \ + /usr/openwin/lib/X11/app-defaults \ + /usr/openwin/share/lib/app-defaults \ + /usr/openwin/share/lib/X11/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 +]) + + +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 + + +# Like AC_CHECK_HEADER, but it uses the already-computed -I directories. +# +AC_DEFUN(AC_CHECK_X_HEADER, [ + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + AC_CHECK_HEADER([$1], [$2]) + CPPFLAGS="$ac_save_CPPFLAGS"]) + +# Like AC_EGREP_HEADER, but it uses the already-computed -I directories. +# +AC_DEFUN(AC_EGREP_X_HEADER, [ + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + AC_EGREP_HEADER([$1], [$2], [$3], [$4]) + CPPFLAGS="$ac_save_CPPFLAGS"]) + +# Like AC_TRY_COMPILE, but it uses the already-computed -I directories. +# +AC_DEFUN(AC_TRY_X_COMPILE, [ + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + AC_TRY_COMPILE([$1], [$2], [$3], [$4]) + CPPFLAGS="$ac_save_CPPFLAGS"]) + + +# Like AC_CHECK_LIB, but it uses the already-computed -I and -L directories. +# Use this sparingly; it probably doesn't work very well on X programs. +# +AC_DEFUN(AC_CHECK_X_LIB, [ + ac_save_CPPFLAGS="$CPPFLAGS" + ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + AC_CHECK_LIB([$1], [$2], [$3], [$4], [$5]) + CPPFLAGS="$ac_save_CPPFLAGS" + LDFLAGS="$ac_save_LDFLAGS"]) + +# Like AC_TRY_RUN, but it uses the already-computed -I directories. +# (But not the -L directories!) +# +AC_DEFUN(AC_TRY_X_RUN, [ + ac_save_CPPFLAGS="$CPPFLAGS" + if test \! -z "$includedir" ; then + CPPFLAGS="$CPPFLAGS -I$includedir" + fi + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + AC_TRY_RUN([$1], [$2], [$3], [$4]) + CPPFLAGS="$ac_save_CPPFLAGS"]) + + + + + +# check for the HP XHPDisableReset server extension headers. +# +AC_EGREP_X_HEADER(XHPDisableReset, X11/XHPlib.h, + [AC_DEFINE(HAVE_XHPDISABLERESET) + SAVER_LIBS="-lXhp11 $SAVER_LIBS"]) + + +# Check for the availability of the XPointer typedef, and define it otherwise. +# +AC_CACHE_CHECK([for XPointer], ac_cv_xpointer, + [AC_TRY_X_COMPILE([#include ], + [XPointer foo = (XPointer) 0;], + [ac_cv_xpointer=yes], + [ac_cv_xpointer=no])]) +if test $ac_cv_xpointer != yes; then + AC_DEFINE(XPointer,[char*]) +fi + + +case "$host" in + *-hpux*) + # Thanks for not making xmkmf find this by default, you losers. + if test -d /usr/lib/Motif1.2 ; then + X_CFLAGS="-I/usr/include/Motif1.2 $X_CFLAGS" + X_LIBS="-L/usr/lib/Motif1.2 $X_LIBS" + elif test -d /usr/lib/Motif1.1 ; then + X_CFLAGS="-I/usr/include/Motif1.1 $X_CFLAGS" + X_LIBS="-L/usr/lib/Motif1.1 $X_LIBS" + fi + + # This too. You losers. + if test -d /usr/contrib/X11R6/include ; then + X_CFLAGS="-I/usr/contrib/X11R6/include $X_CFLAGS" + X_LIBS="-L/usr/contrib/X11R6/lib $X_LIBS" + elif test -d /usr/X11R6/include ; then + X_CFLAGS="-I/usr/X11R6/include $X_CFLAGS" + X_LIBS="-L/usr/X11R6/lib $X_LIBS" + elif test -d /usr/contrib/X11R5/include ; then + X_CFLAGS="-I/usr/contrib/X11R5/include $X_CFLAGS" + X_LIBS="-L/usr/contrib/X11R5/lib $X_LIBS" + elif test -d /usr/X11R5/include ; then + X_CFLAGS="-I/usr/X11R5/include $X_CFLAGS" + X_LIBS="-L/usr/X11R5/lib $X_LIBS" + fi + + ;; + *-solaris*) + # Same to you, pinheads. (Is this really the standard location now? + # What happened to the joke that this kind of thing went in /opt?) + # cthomp says "answer: CDE (Common Disorganized Environment)" + if test -f /usr/dt/include/Xm/Xm.h ; then + X_CFLAGS="$X_CFLAGS -I/usr/dt/include" + X_LIBS="$X_LIBS -L/usr/dt/lib -R:/usr/dt/lib" + + # Some versions of Slowlaris Motif require -lgen. But not all. Why? + AC_CHECK_LIB(gen, regcmp, [X_LIBS="$X_LIBS -lgen"]) + fi + ;; +esac + + + +# Check for Xmu (some fucked up vendors don't ship it...) +# +have_xmu=no +AC_CHECK_X_HEADER(X11/Xmu/Error.h, [have_xmu=yes]) +if test $have_xmu = no ; then + XMU_SRCS='$(UTILS_SRC)/xmu.c' + XMU_OBJS='$(UTILS_BIN)/xmu.o' +else + XMU_SRCS='' + XMU_OBJS='' + SAVER_LIBS="-lXmu $SAVER_LIBS" + HACK_LIBS="-lXmu $HACK_LIBS" + AC_DEFINE(HAVE_XMU) +fi + + +# See comp.windows.x FAQ question 124 about _get_wmShellWidgetClass on 4.1.x. +# The right fix is to get OpenWindows 3.0 patches 100512-02 and 100573-03. +# +if test $have_xmu = yes ; then + case "$host" in + *-sunos4*) + AC_CACHE_CHECK([for the SunOS 4.1.x _get_wmShellWidgetClass bug], + ac_cv_sunos_xmu_bug, + [ac_save_LDFLAGS="$LDFLAGS" + if test \! -z "$x_libraries" ; then + LDFLAGS="$LDFLAGS -L$x_libraries" + fi + # Note: this trick never works! (Generally.) + # We're only getting away with using AC_TRY_LINK + # with X libraries because we know it's SunOS. + LDFLAGS="$LDFLAGS -lXmu -lXt -lX11 -lXext -lm" + AC_TRY_LINK(,, + [ac_cv_sunos_xmu_bug=no], + [ac_cv_sunos_xmu_bug=yes]) + LDFLAGS="$ac_save_LDFLAGS"]) + if test $ac_cv_sunos_xmu_bug = yes ; then + AC_CACHE_CHECK([whether the compiler understands -static], + ac_cv_ld_static, + [ac_save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -static" + AC_TRY_LINK(,,[ac_cv_ld_static=yes],[ac_cv_ld_static=no]) + LDFLAGS="$ac_save_LDFLAGS"]) + if test $ac_cv_ld_static = yes ; then + LDFLAGS="$LDFLAGS -static" + else + LDFLAGS="$LDFLAGS -Bstatic" + fi + fi + ;; + esac +fi + + +# Check for the SGI SCREEN_SAVER server extension header. +# +have_sgi=no +with_sgi_req=unspecified +AC_ARG_WITH(sgi-ext,[ +Server options: + + --with-sgi-ext Include support for the SGI SCREEN_SAVER + server extension, if possible (this is the default). + --without-sgi-ext Do not compile in support for this extension.], + [with_sgi="$withval"; with_sgi_req="$withval"],[with_sgi=yes]) +if test $with_sgi = yes; then + AC_CHECK_X_HEADER(X11/extensions/XScreenSaver.h, + [have_sgi=yes + AC_DEFINE(HAVE_SGI_SAVER_EXTENSION)]) + +elif test $with_sgi != no; then + echo "error: must be yes or no: --with-sgi-ext=$with_sgi" + exit 1 +fi + +# Check for the MIT-SCREEN-SAVER server extension header, +# unless the SGI extension has already been found. +# +have_mit=no +with_mit_req=unspecified +AC_ARG_WITH(mit-ext, +[ --with-mit-ext Include support for the MIT-SCREEN-SAVER + server extension, if possible (this is the default). + --without-mit-ext Do not compile in support for this extension.], + [with_mit="$withval"; with_mit_req="$withval"],[with_mit=yes]) +if test $have_sgi != yes; then + if test $with_mit = yes; then + AC_CHECK_X_HEADER(X11/extensions/scrnsaver.h, [have_mit=yes]) + + # Now check to see if it's really in the library; XF86Free-3.3 ships + # scrnsaver.h, but doesn't include the code in libXext.a, the idiots! + # + if test $have_mit = yes; then + AC_CHECK_X_LIB(Xext, XScreenSaverRegister, [], [have_mit=no], -lm) + + if test $have_mit = no; then + # Fuck! Looks like XF86Free-3.3 actually puts it in XExExt instead + # of in Xext. Thank you master, may I have another. + AC_CHECK_X_LIB(XExExt, XScreenSaverRegister, + [have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXExExt"], + [], -lX11 -lXext -lm) + fi + + if test $have_mit = no; then + # Double fuck! Looks like some versions of XFree86 (whichever version + # it is that comes with RedHat Linux 2.0 -- I can't find a version + # number) put this garbage in Xss instead of Xext. Thank you master, + # may I have another. + AC_CHECK_X_LIB(Xss, XScreenSaverRegister, + [have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXss"], + [], -lX11 -lXext -lm) + fi + + if test $have_mit = yes; then + AC_DEFINE(HAVE_MIT_SAVER_EXTENSION) + fi + + fi + + elif test $with_mit != no; then + echo "error: must be yes or no: --with-mit-ext=$with_mit" + exit 1 + fi +fi + + +# Check for the XIDLE server extension header. +# +have_xidle=no +with_xidle_req=unspecified +AC_ARG_WITH(xidle-ext, +[ --with-xidle-ext Include support for the XIDLE server extension, + if possible (this is the default). + --without-xidle-ext Do not compile in support for this extension.], + [with_xidle="$withval"; with_xidle_req="$withval"],[with_xidle=yes]) +if test $with_xidle = yes; then + AC_CHECK_X_HEADER(X11/extensions/xidle.h, + [have_xidle=yes + AC_DEFINE(HAVE_XIDLE_EXTENSION)]) +elif test $with_xidle != no; then + echo "error: must be yes or no: --with-xidle-ext=$with_xidle" + exit 1 +fi + + +# Check for the XSHM server extension header. +# +have_xshm=no +with_xshm_req=unspecified +AC_ARG_WITH(xshm-ext, +[ --with-xshm-ext Include support for the XSHM (Shared Memory) server + extension, if possible (this is the default). + --without-xshm-ext Do not compile in support for this extension.], + [with_xshm="$withval"; with_xshm_req="$withval"],[with_xshm=yes]) +if test $with_xshm = yes; then + + # first check for Xshm.h. + AC_CHECK_X_HEADER(X11/extensions/XShm.h, [have_xshm=yes]) + + # if that succeeded, then check for sys/ipc.h. + if test $have_xshm = yes; then + have_xshm=no + AC_CHECK_X_HEADER(sys/ipc.h, [have_xshm=yes]) + fi + + # if that succeeded, then check for sys/shm.h. + if test $have_xshm = yes; then + have_xshm=no + AC_CHECK_X_HEADER(sys/shm.h, [have_xshm=yes]) + fi + + # if that succeeded, then we've really got it. + if test $have_xshm = yes; then + AC_DEFINE(HAVE_XSHM_EXTENSION) + fi + +elif test $with_xshm != no; then + echo "error: must be yes or no: --with-xshm-ext=$with_xshm" + exit 1 +fi + + +# Check for the SGI-VIDEO-CONTROL server extension header. +# +have_sgivc=no +with_sgivc_req=unspecified +AC_ARG_WITH(sgivc-ext, +[ --with-sgivc-ext Include support for the SGI-VIDEO-CONTROL server + extension, if possible (this is the default). + --without-sgivc-ext Do not compile in support for this extension.], + [with_sgivc="$withval"; with_sgivc_req="$withval"],[with_sgivc=yes]) +if test $with_sgivc = yes; then + + # first check for XSGIvc.h + AC_CHECK_X_HEADER(X11/extensions/XSGIvc.h, [have_sgivc=yes]) + + # if that succeeded, then check for the -lXsgivc + if test $have_sgivc = yes; then + have_sgivc=no + AC_CHECK_X_LIB(Xsgivc, XSGIvcQueryGammaMap, + [have_sgivc=yes; SAVER_LIBS="$SAVER_LIBS -lXsgivc"], [], + -lXext -lX11) + fi + + # if that succeeded, then we've really got it. + if test $have_sgivc = yes; then + AC_DEFINE(HAVE_SGI_VC_EXTENSION) + fi + +elif test $with_sgivc != no; then + echo "error: must be yes or no: --with-sgivc-ext=$with_sgivc" + exit 1 +fi + + + + + + + + +# Check for Motif and Athena --with and --without arguments. +# +have_motif=no +have_athena=no +with_motif_req=unspecified +with_athena_req=unspecified + +AC_ARG_WITH(motif,[ +Toolkit options: + + --with-motif Use the Motif toolkit for the user interface, + if possible (this is the default). + --without-motif Do not use Motif.], + [with_motif="$withval"; with_motif_req="$withval"],[with_motif=no]) + +AC_ARG_WITH(athena, +[ --with-athena Use the Athena toolkit for the user interface, if + possible (this is the default if Motif isn't used.) + --without-athena Do not use Athena.], + [with_athena="$withval"; with_athena_req="$withval"],[with_athena=no]) + +if test $with_motif != yes -a $with_motif != no ; then + echo "error: must be yes or no: --with-motif=$with_motif" + exit 1 +fi + +if test $with_athena != yes -a $with_athena != no ; then + echo "error: must be yes or no: --with-athena=$with_athena" + exit 1 +fi + + +# Saying --without-motif is the same as saying --with-athena. +if test $with_motif_req = no ; then + with_athena_req=yes + with_athena=yes +fi + +# Saying --without-athena is the same as saying --with-motif. +if test $with_athena_req = no ; then + with_motif_req=yes + with_motif=yes +fi + +# Check for Motif and Athena headers. + +check_motif() { + AC_CHECK_X_HEADER(Xm/Xm.h, + [have_motif=yes + AC_DEFINE(HAVE_MOTIF) + SAVER_LIBS="-lXm $SAVER_LIBS"]) +} + +check_athena() { + AC_CHECK_X_HEADER(X11/Xaw/Dialog.h, + [have_athena=yes + AC_DEFINE(HAVE_ATHENA) + SAVER_LIBS="-lXaw $SAVER_LIBS"]) +} + + +# If they asked for both motif and athena, check motif then athena. +# If they asked for only motif, check motif then athena. +# If they asked for only athena, check athena then motif. +# If they asked for neither, check motif then athena. + +proselytize_motif=yes +if test $with_motif = yes; then + # asked for both, or for motif only + check_motif + if test $have_motif = yes; then + with_athena=no + with_athena_req=no + else + check_athena + fi + +elif test $with_athena = yes; then + # asked for athena only + check_athena + if test $have_athena = yes; then + with_motif=no + proselytize_motif=no + else + check_motif + fi + +else + # asked for neither + check_motif + if test $have_motif = yes; then + with_athena=no + else + check_athena + fi + +fi + +if test $have_motif = yes; then + proselytize_motif=no +fi + +# If we have Athena, check whether it's a version that includes +# XawViewportSetCoordinates in Viewport.h (R3 (or R4?) don't.) +if test $have_athena = yes ; then + AC_CACHE_CHECK([for XawViewportSetCoordinates in Viewport.h], + ac_cv_have_XawViewportSetCoordinates, + [ac_cv_have_XawViewportSetCoordinates=no + AC_EGREP_X_HEADER(XawViewportSetCoordinates, + X11/Xaw/Viewport.h, + ac_cv_have_XawViewportSetCoordinates=yes)]) + if test $ac_cv_have_XawViewportSetCoordinates = yes ; then + AC_DEFINE(HAVE_XawViewportSetCoordinates) + fi +fi + + +# If we have Motif, check whether it's really LessTif. +# +have_lesstif=no +if test $have_motif = yes ; then + AC_CACHE_CHECK([whether Motif is really LessTif], + ac_cv_have_lesstif, + [AC_TRY_X_COMPILE([#include ], + [long vers = LesstifVersion;], + [ac_cv_have_lesstif=yes], + [ac_cv_have_lesstif=no])]) + have_lesstif=$ac_cv_have_lesstif +fi + +# don't cache this +unset ac_cv_good_lesstif + +good_lesstif=no +if test $have_lesstif = yes ; then + # It must be at least "GNU Lesstif 0.82". + # #### If you change this, also sync the warning message lower down. + AC_CACHE_CHECK([whether LessTif is of a recent enough vintage], + ac_cv_good_lesstif, + [AC_TRY_X_RUN([#include + int main() { exit(LesstifVersion < 82); }], + [ac_cv_good_lesstif=yes], + [ac_cv_good_lesstif=no], + # cross compiling? Make an ass out of umption. + [ac_cv_good_lesstif=yes])]) + good_lesstif=$ac_cv_good_lesstif +fi + + +# check for XPM header. +# +have_xpm=no +with_xpm_req=unspecified +AC_ARG_WITH(xpm,[ +Demo options: + + --with-xpm Include support for XPM files in some demos, + if possible (this is the default). + --without-xpm Do not compile in support for XPM files.], + [with_xpm="$withval"; with_xpm_req="$withval"],[with_xpm=yes]) +if test $with_xpm = yes; then + AC_CHECK_X_HEADER(X11/xpm.h, + [have_xpm=yes + AC_DEFINE(HAVE_XPM) + XPM_LIBS="-lXpm"]) +elif test $with_xpm != no; then + echo "error: must be yes or no: --with-xpm=$with_xpm" + exit 1 +fi + + +# check for the GL header +# +have_gl=no +with_gl_req=unspecified +AC_ARG_WITH(gl, +[ --with-gl Build those demos which depend on OpenGL, + if possible (this is the default). + --without-gl Do not build the OpenGL demos.], + [with_gl="$withval"; with_gl_req="$withval"],[with_gl=yes]) + +if test $with_gl = yes; then + AC_CHECK_X_HEADER(GL/gl.h, have_gl=yes, have_gl=no) + if test $have_gl = yes ; then + AC_CHECK_X_HEADER(GL/glx.h, have_gl=yes, have_gl=no) + fi + + # If we have the headers, try and figure out which vendor it's from. + # + if test $have_gl = yes ; then + + AC_DEFINE(HAVE_GL) + have_mesa_gl=no + AC_EGREP_X_HEADER(Mesa, GL/glx.h, [have_mesa_gl=yes]) + if test $have_mesa_gl = no ; then + GL_LIBS="-lGL -lGLU" + else + AC_DEFINE(HAVE_MESA_GL) + GL_LIBS="-lMesaGL -lMesaGLU" + fi + fi + +elif test $with_gl != no; then + echo "error: must be yes or no: --with-gl=$with_gl" + exit 1 +fi + + +# check for SGI XReadDisplay server extension header. +# +have_readdisplay=no +with_readdisplay_req=unspecified +AC_ARG_WITH(readdisplay, +[ --with-readdisplay Include support for the XReadDisplay server + extension if possible (this is the default). + --without-readdisplay Do not compile in support for this extension.], + [with_readdisplay="$withval"; with_readdisplay_req="$withval"], + [with_readdisplay=yes]) +if test $with_readdisplay = yes; then + AC_CHECK_X_HEADER(X11/extensions/readdisplay.h, + AC_DEFINE(HAVE_READ_DISPLAY_EXTENSION)) +elif test $with_readdisplay != no; then + echo "error: must be yes or no: --with-readdisplay=$with_readdisplay" + exit 1 +fi + + +# check for SGI's Iris Video Library header. +# +have_sgivideo=no +with_sgivideo_req=unspecified +AC_ARG_WITH(sgivideo, +[ --with-sgivideo Include support for SGI's Iris Video Library + if possible (this is the default). + --without-sgivideo Do not compile in support for this library.], + [with_sgivideo="$withval"; with_sgivideo_req="$withval"], + [with_sgivideo=yes]) +if test $with_sgivideo = yes; then + AC_CHECK_X_HEADER(dmedia/vl.h, have_sgivideo=yes) + if test $have_sgivideo = yes; then + have_sgivideo=no + AC_CHECK_LIB(vl, vlOpenVideo, have_sgivideo=yes) + if test $have_sgivideo = yes; then + SGI_VIDEO_OBJS="$(UTILS_BIN)/sgivideo.o" + SGI_VIDEO_LIBS="-lvl" + AC_DEFINE(HAVE_SGI_VIDEO) + fi + fi +elif test $with_sgivideo != no; then + echo "error: must be yes or no: --with-sgivideo=$with_sgivideo" + exit 1 +fi + + + +# Try to find a program to generate random text. +# +# Zippy is funnier than the idiocy generally spat out by `fortune', +# so try to find that, by invoking Emacs and asking it where its +# libexec directory is ("yow" lives in there.) +# +# If that doesn't work, see if fortune, zippy, or yow are on $PATH, +# and if so, use them. +# +# If that doesn't work, look in /usr/games, and if it's there, use +# the full pathname. +# +with_zippy_req="" +AC_ARG_WITH(zippy, +[ --with-zippy=PROGRAM Some demos are able to run an external program and + display its text; this names the program to use by + default (though it can be overridden with X + resources.) If you don't specify this, the default + is to use \"yow\" from the Emacs distribution (if you + have it) or else to use \"fortune\".], + [ with_zippy_req="$withval"; with_zippy="$withval" ], + [ with_zippy_req="$withval"; with_zippy="$withval" ]) + +if test "$with_zippy" = no || test "$with_zippy" = yes ; then + with_zippy="" + with_zippy_req="" +fi + +if test -n "$with_zippy_req" ; then + ac_cv_zippy_program="" + case "$with_zippy_req" in + /*) + AC_MSG_CHECKING([for $with_zippy_req]) + if test -x "$with_zippy_req" ; then + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) + with_zippy="" + fi + ;; + *) + # don't cache + unset ac_cv_path_zip2 + AC_PATH_PROG(zip2, $with_zippy_req, []) + if test "$zip2" = ""; then + with_zippy="" + fi + ;; + esac + ac_cv_zippy_program="$with_zippy" + +elif test -n "$ac_cv_zippy_program"; then + AC_MSG_RESULT([checking for zippy... (cached) $ac_cv_zippy_program]) +fi + +if test ! -n "$ac_cv_zippy_program"; then + + AC_CHECK_PROGS(emacs_exe, emacs) + AC_CHECK_PROGS(xemacs_exe, xemacs) + + ac_cv_zippy_program="" + eargs='-batch -q -nw --eval' + + if test -n "$emacs_exe" ; then + AC_MSG_CHECKING([for emacs yow]) + # + # get emacs to tell us where the libexec directory is. + # + dir=`$emacs_exe $eargs '(princ (concat exec-directory "\n"))' \ + 2>/dev/null | tail -1` + dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'` + # + # try running libexec/yow and see if it exits without error. + # + if test x"$dir" != x -a -x $dir/yow ; then + if $dir/yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/yow" + AC_MSG_RESULT($ac_cv_zippy_program) + else + AC_MSG_RESULT(no) + fi + fi + fi + + if test -z "$ac_cv_zippy_program" ; then + AC_MSG_CHECKING([for xemacs yow]) + if test -n "$xemacs_exe" ; then + # + # get xemacs to tell us where the libexec directory is. + # + dir=`$xemacs_exe $eargs '(princ (concat exec-directory "\n"))' \ + 2>/dev/null | tail -1` + dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'` + # + # try running libexec/yow and see if it exits without error. + # + if test x"$dir" != x -a -x $dir/yow ; then + if $dir/yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/yow" + AC_MSG_RESULT($ac_cv_zippy_program) + else + # + # in some xemacs installations, the pathname of the yow.lines file + # isn't hardcoded into the yow executable, and must be passed on + # the command line. See if it's in libexec/../etc/. + + # M4 sucks!! + changequote(X,Y) + dir_up=`echo "$dir" | sed 's@/[^/]*$@@'` + changequote([,]) + + yow="yow -f $dir_up/etc/yow.lines" + if $dir/$yow >&- 2>&- ; then + ac_cv_zippy_program="$dir/$yow" + AC_MSG_RESULT($ac_cv_zippy_program) + else + AC_MSG_RESULT(no) + fi + fi + fi + fi + fi + + # if that didn't work, try for some other programs... + if test -z "$ac_cv_zippy_program" ; then + fortune='' + AC_CHECK_PROGS(fortune, [fortune zippy yow]) + # if that didn't work, try for those programs in /usr/games... + if test -z "$fortune" ; then + AC_PATH_PROGS(fortune, [fortune zippy yow], fortune, + /usr/games:/usr/local/games) + fi + fi +fi + +if test -z "$ac_cv_zippy_program" ; then + ac_cv_zippy_program=fortune +fi + +AC_DEFINE_UNQUOTED(ZIPPY_PROGRAM, "$ac_cv_zippy_program") + + + + +# Allow locking to be disabled at compile-time. +# +have_locking=yes +have_kerberos=no +with_kerberos_req=unspecified +have_shadow=no +with_shadow_req=unspecified +need_setuid=no + +AC_ARG_ENABLE(locking,[ +Locking options: + + --enable-locking Compile in support for locking the display + (this is the default.) + --disable-locking Do not allow locking at all.], + [enable_locking="$enableval"],[enable_locking=yes]) +if test $enable_locking = yes; then + + # Check for Kerberos. + # + AC_ARG_WITH(kerberos, [ + --with-kerberos Include support for Kerberos authentication, + if possible (this is the default.) + --without-kerberos Do not compile in support for Kerberos.], + [with_kerberos="$withval"; with_kerberos_req="$withval"],[with_kerberos=yes]) + if test $with_kerberos = yes; then + AC_CACHE_CHECK([for Kerberos], ac_cv_kerberos, + [AC_TRY_X_COMPILE([#include ],, + [ac_cv_kerberos=yes], + [ac_cv_kerberos=no])]) + if test $ac_cv_kerberos = yes ; then + have_kerberos=yes + AC_DEFINE(HAVE_KERBEROS) + PASSWD_LIBS="$PASSWD_LIBS -lkrb -ldes -lnsl -lsocket" + fi + elif test $with_kerberos != no; then + echo "error: must be yes or no: --with-kerberos=$with_kerberos" + exit 1 + fi + + # Next, check for the nine billion variants of shadow passwords... + + passwd_cruft_done=no + AC_ARG_WITH(shadow, +[ --with-shadow Include support for shadow password authentication, + if possible (this is the default, if no Kerberos.) + --without-shadow Do not compile in support for shadow passwords. +], + [with_shadow="$withval"; with_shadow_req="$withval"],[with_shadow=yes]) + if test $with_shadow = no; then + passwd_cruft_done=yes + elif test $with_shadow != yes; then + echo "error: must be yes or no: --with-shadow=$with_shadow" + exit 1 + fi + + + # Sun's "adjunct" passwords. + # + if test $passwd_cruft_done = no ; then + AC_CACHE_CHECK([for Sun-style shadow passwords], ac_cv_sun_adjunct, + [AC_TRY_X_COMPILE([#include + #include + #include + #include + #include + #include ], + [struct passwd_adjunct *p = getpwanam("nobody"); + const char *pw = p->pwa_passwd;], + [ac_cv_sun_adjunct=yes], + [ac_cv_sun_adjunct=no])]) + if test $ac_cv_sun_adjunct = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + AC_DEFINE(HAVE_ADJUNCT_PASSWD) + fi + fi + + # DEC and SCO so-called "enhanced" security. + # + if test $passwd_cruft_done = no ; then + AC_CACHE_CHECK([for DEC-style shadow passwords], ac_cv_enhanced_passwd, + [AC_TRY_X_COMPILE([#include + #include + #include + #include + #include + #include ], + [struct pr_passwd *p; + const char *pw; + set_auth_parameters(0, 0); + check_auth_parameters(); + p = getprpwnam("nobody"); + pw = p->ufld.fd_encrypt;], + [ac_cv_enhanced_passwd=yes], + [ac_cv_enhanced_passwd=no])]) + if test $ac_cv_enhanced_passwd = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + AC_DEFINE(HAVE_ENHANCED_PASSWD) + + # On SCO, getprpwnam() is in -lprot (which uses nap() from -lx) + # (I'm told it needs -lcurses too, but I don't understand why.) + AC_CHECK_LIB(prot, getprpwnam, + [PASSWD_LIBS="$PASSWD_LIBS -lprot -lcurses -lx"], + [# On DEC, getprpwnam() is in -lsecurity + AC_CHECK_LIB(security, getprpwnam, + [PASSWD_LIBS="$PASSWD_LIBS -lsecurity"])], + [-lx]) + fi + fi + + # HP's entry in the "Not Invented Here" Sweepstakes. + # + if test $passwd_cruft_done = no ; then + AC_CACHE_CHECK([for HP-style shadow passwords], ac_cv_hpux_passwd, + [AC_TRY_X_COMPILE([#include + #include + #include + #include + #include + #include ], + [struct s_passwd *p = getspwnam("nobody"); + const char *pw = p->pw_passwd;], + [ac_cv_hpux_passwd=yes], + [ac_cv_hpux_passwd=no])]) + if test $ac_cv_hpux_passwd = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + AC_DEFINE(HAVE_HPUX_PASSWD) + + # on HPUX, bigcrypt is in -lsec + AC_CHECK_LIB(sec, bigcrypt, [PASSWD_LIBS="$PASSWD_LIBS -lsec"]) + fi + fi + + # Traditional (ha!) shadow passwords. + # + if test $passwd_cruft_done = no ; then + AC_CACHE_CHECK([for generic shadow passwords], ac_cv_shadow, + [AC_TRY_X_COMPILE([#include + #include + #include + #include + #include ], + [struct spwd *p = getspnam("nobody"); + const char *pw = p->sp_pwdp;], + [ac_cv_shadow=yes], + [ac_cv_shadow=no])]) + if test $ac_cv_shadow = yes; then + have_shadow=yes + need_setuid=yes + passwd_cruft_done=yes + AC_DEFINE(HAVE_SHADOW_PASSWD) + + # On some systems (UnixWare 2.1), getspnam() is in -lgen instead of -lc. + have_getspnam=no + AC_CHECK_LIB(c, getspnam, [have_getspnam=yes]) + if test $have_getspnam = no ; then + AC_CHECK_LIB(gen, getspnam, + [have_getspnam=yes; PASSWD_LIBS="$PASSWD_LIBS -lgen"]) + fi + fi + fi + + # On some systems (UnixWare 2.1), crypt() is in -lcrypt instead of -lc. + have_crypt=no + AC_CHECK_LIB(c, crypt, [have_crypt=yes]) + if test $have_crypt = no ; then + AC_CHECK_LIB(crypt, crypt, + [have_crypt=yes; PASSWD_LIBS="$PASSWD_LIBS -lcrypt"]) + fi + + + # Most of the above shadow mechanisms will have set need_setuid to yes, + # if they were found. But, on some systems, we need setuid even when + # using plain old vanilla passwords. + # + if test $need_setuid = no ; then + case "$host" in + *-hpux* | *-aix* | *-netbsd* | *-freebsd* | *-openbsd* ) + need_setuid=yes + ;; + esac + fi + +elif test $enable_locking = no; then + AC_DEFINE(NO_LOCKING) +else + echo "error: must be yes or no: --enable-locking=$enable_locking" + exit 1 +fi + + + +if test \! -z "$includedir" ; then + INCLUDES="-I$includedir" +fi + +if test \! -z "$libdir" ; then + LDFLAGS="$LDFLAGS -L$libdir" +fi + + +##### should have options to override the DEPEND crap, I guess... +DEPEND=makedepend +DEPEND_FLAGS= +DEPEND_DEFINES= + + + +# Done testing things -- now substitute in some stuff for the Makefiles. +# +if test $have_motif = yes; then + AC_DEFINE(HAVE_MOTIF) + DIALOG_SRCS='$(MOTIF_SRCS)' + DIALOG_OBJS='$(MOTIF_OBJS)' +elif test $have_athena = yes; then + AC_DEFINE(HAVE_ATHENA) + DIALOG_SRCS='$(ATHENA_SRCS)' + DIALOG_OBJS='$(ATHENA_OBJS)' +else + DIALOG_SRCS='' + DIALOG_OBJS='' +fi + +if test $have_kerberos = yes; then + PASSWD_SRCS='$(KERBEROS_SRCS)' + PASSWD_OBJS='$(KERBEROS_OBJS)' +else + PASSWD_SRCS='$(PWENT_SRCS)' + PASSWD_OBJS='$(PWENT_OBJS)' +fi + +if test $enable_locking = yes; then + LOCK_SRCS='$(LOCK_SRCS_1) $(PASSWD_SRCS)' + LOCK_OBJS='$(LOCK_OBJS_1) $(PASSWD_OBJS)' +else + LOCK_SRCS='' + LOCK_OBJS='' +fi + +if test $need_setuid = yes; then + NEED_SETUID=yes + INSTALL_SETUID='$(INSTALL) $(SUID_FLAGS)' +else + NEED_SETUID=no + INSTALL_SETUID='$(INSTALL_PROGRAM)' +fi + +tab=' ' +if test $have_gl = yes; then + GL_EXES='$(GL_EXES)' + GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}' \' + GL_KLUDGE_2=${tab} +else + GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}'\n' + GL_KLUDGE_2='!'${tab} +fi + +AC_SUBST(INCLUDES) + +AC_SUBST(SAVER_LIBS) +AC_SUBST(HACK_LIBS) +AC_SUBST(XPM_LIBS) +AC_SUBST(GL_LIBS) +AC_SUBST(PASSWD_LIBS) +AC_SUBST(INSTALL_SETUID) +AC_SUBST(NEED_SETUID) +AC_SUBST(SGI_VIDEO_OBJS) +AC_SUBST(SGI_VIDEO_LIBS) + +AC_SUBST(DIALOG_SRCS) +AC_SUBST(DIALOG_OBJS) +AC_SUBST(PASSWD_SRCS) +AC_SUBST(PASSWD_OBJS) +AC_SUBST(XMU_SRCS) +AC_SUBST(XMU_OBJS) +AC_SUBST(LOCK_SRCS) +AC_SUBST(LOCK_OBJS) +AC_SUBST(GL_EXES) +AC_SUBST(GL_KLUDGE_1) +AC_SUBST(GL_KLUDGE_2) +AC_SUBST(HACKDIR) +AC_SUBST(APPDEFAULTS) + +AC_SUBST(DEPEND) +AC_SUBST(DEPEND_FLAGS) +AC_SUBST(DEPEND_DEFINES) + +# Print some warnings before emitting the Makefiles. +# +warning=no +warnsep=' #################################################################' +warnpre() { + if test $warning = no ; then + echo '' ; echo "$warnsep" ; echo '' + warning=yes + fi +} + +warn() { + warnpre + if test $warning = long ; then echo '' ; fi + warning=yes + echo " Warning: $@" +} + +warnL() { + was=$warning + warnpre + warning=yes + if test $was != no ; then echo '' ; fi + echo " Warning: $@" +} + +warn2() { + echo " $@" + warning=long +} + +if test $with_sgi_req = yes -a $have_sgi = no ; then + warn 'The SGI saver extension was requested, but was not found.' +fi + +if test $with_mit_req = yes -a $have_mit = no ; then + warn 'The MIT saver extension was requested, but was not found.' +fi + +if test $with_xidle_req = yes -a $have_xidle = no ; then + warn 'The XIdle extension was requested, but was not found.' +fi + +if test $with_xshm_req = yes -a $have_xshm = no ; then + warn 'The XSHM extension was requested, but was not found.' +fi + +if test $with_sgivc_req = yes -a $have_sgivc = no ; then + warn 'The SGI-VIDEO-CONTROL extension was requested, but was not found.' +fi + +if test $have_motif = no -a $have_athena = no ; then + warnL "Neither Motif nor Athena widgets seem to be available;" + warn2 "one or the other is required." + proselytize_motif=no + +elif test $with_motif_req = yes -a $have_motif = no ; then + warnL "Use of Motif was requested, but it wasn't found;" + warn2 "Athena will be used instead." + +elif test $with_athena_req = yes -a $have_athena = no ; then + warnL "Use of Athena was requested, but it wasn't found;" + warn2 "Motif will be used instead." +fi + +if test $have_motif = yes -a $have_lesstif = yes ; then + if test $good_lesstif != yes ; then + warnL "Motif is being used, but it appears to actually be" + warn2 "LessTif, and the version number is less than 0.82!" + warn2 "Such old versions of LessTif are too buggy to use" + warn2 "with XScreenSaver; it is strongly recommended that" + warn2 "you upgrade! See ." + fi +fi + +if test $proselytize_motif = yes ; then + warnL "Athena widgets are being used instead of Motif." + warn2 "XScreenSaver looks much better with Motif, and has" + warn2 "a few extra features as well. Wouldn't you rather" + warn2 "be using Motif? It is shipped by every commercial" + warn2 "Unix vendor; and there is a free implementation" + warn2 "available as well: see ." +fi + +if test $with_xpm_req = yes -a $have_xpm = no ; then + warn 'Use of XPM was requested, but it was not found.' +fi + +if test $with_gl_req = yes -a $have_gl = no ; then + warn 'Use of GL was requested, but it was not found.' +fi + +if test $with_readdisplay_req = yes -a $have_readdisplay = no ; then + warn 'Use of XReadDisplay was requested, but it was not found.' +fi + +if test $with_sgivideo_req = yes -a $have_sgivideo = no ; then + warn 'Use of the Iris Video Library was requested, but it was not found.' +fi + +if test $with_kerberos_req = yes -a $have_kerberos = no ; then + warn 'Use of Kerberos was requested, but it was not found.' +fi + +if test $with_shadow_req = yes -a $have_shadow = no ; then + warn 'Use of shadow passwords was requested, but they were not found.' +fi + +if test -n "$with_zippy_req"; then + if test "$with_zippy_req" != "$ac_cv_zippy_program" ; then + warnL "$with_zippy_req was requested as the Zippy program," + warn2 "but was not found. The default will be used instead." + fi +fi + +if test $warning != no; then + echo '' ; echo "$warnsep" ; echo '' +fi + + +AC_OUTPUT(Makefile + utils/Makefile + driver/Makefile + hacks/Makefile + hacks/glx/Makefile + driver/XScreenSaver.ad) diff --git a/driver/.gdbinit b/driver/.gdbinit new file mode 100644 index 00000000..cb7d98ab --- /dev/null +++ b/driver/.gdbinit @@ -0,0 +1,25 @@ +# If you're debugging xscreensaver and you are running a virtual root window +# manager, you'd better let the process handle these signals: it remaps the +# virtual root window when they arrive. If you don't do this, your window +# manager will be hosed. +# +# Also, gdb copes badly with breakpoints in functions that are called on the +# other side of a fork(). The Trace/BPT traps cause the spawned process to +# die. +# +#handle 1 pass nostop +#handle 3 pass nostop +#handle 4 pass nostop +#handle 6 pass nostop +#handle 7 pass nostop +#handle 8 pass nostop +#handle 9 pass nostop +#handle 10 pass nostop +#handle 11 pass nostop +#handle 12 pass nostop +#handle 13 pass nostop +#handle 15 pass nostop +#handle 19 pass nostop +b exit +set args -debug +#b purify_stop_here diff --git a/driver/Makefile.in b/driver/Makefile.in new file mode 100644 index 00000000..56b7f618 --- /dev/null +++ b/driver/Makefile.in @@ -0,0 +1,305 @@ +# driver/Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# the `../configure' script generates `driver/Makefile' from this file. + +@SET_MAKE@ +.SUFFIXES: +.SUFFIXES: .c .o + +srcdir = @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 = @DEFS@ +LIBS = @LIBS@ + +DEPEND = @DEPEND@ +DEPEND_FLAGS = @DEPEND_FLAGS@ +DEPEND_DEFINES = @DEPEND_DEFINES@ + +SHELL = /bin/sh +INSTALL = @INSTALL@ +SUID_FLAGS = -o root -m 4755 +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SETUID = @INSTALL_SETUID@ +INSTALL_DATA = @INSTALL_DATA@ + +X_CFLAGS = @X_CFLAGS@ +X_LIBS = @X_LIBS@ +X_PRE_LIBS = @X_PRE_LIBS@ +X_EXTRA_LIBS = @X_EXTRA_LIBS@ + +XLIBS = $(X_PRE_LIBS) -lX11 -lXext $(X_EXTRA_LIBS) + +AD_DIR = @APPDEFAULTS@ + +UTILS_SRC = $(srcdir)/../utils +UTILS_BIN = ../utils + +INCLUDES = -I. -I$(srcdir) -I$(srcdir)/.. -I$(UTILS_SRC) -I.. @INCLUDES@ + +PASSWD_LIBS = @PASSWD_LIBS@ +MOTIF_SRCS = dialogs-Xm.c +MOTIF_OBJS = dialogs-Xm.o + +ATHENA_SRCS = dialogs-Xaw.c +ATHENA_OBJS = dialogs-Xaw.o + +PWENT_SRCS = passwd.c +PWENT_OBJS = passwd.o + +KERBEROS_SRCS = kpasswd.c +KERBEROS_OBJS = kpasswd.o + +LOCK_SRCS_1 = lock.c +LOCK_OBJS_1 = lock.o + +DIALOG_SRCS = @DIALOG_SRCS@ +DIALOG_OBJS = @DIALOG_OBJS@ +PASSWD_SRCS = @PASSWD_SRCS@ +PASSWD_OBJS = @PASSWD_OBJS@ +LOCK_SRCS = @LOCK_SRCS@ +LOCK_OBJS = @LOCK_OBJS@ + +UTIL_SRCS = $(UTILS_SRC)/fade.c $(UTILS_SRC)/overlay.c \ + $(UTILS_SRC)/resources.c $(UTILS_SRC)/usleep.c \ + $(UTILS_SRC)/visual.c $(UTILS_SRC)/xroger.c \ + $(UTILS_SRC)/spline.c \ + $(UTILS_SRC)/yarandom.c @XMU_SRCS@ +UTIL_OBJS = $(UTILS_BIN)/fade.o $(UTILS_BIN)/overlay.o \ + $(UTILS_BIN)/resources.o $(UTILS_BIN)/usleep.o \ + $(UTILS_BIN)/visual.o $(UTILS_BIN)/xroger.o \ + $(UTILS_BIN)/spline.o \ + $(UTILS_BIN)/yarandom.o @XMU_OBJS@ + +SAVER_SRCS_1 = demo.c stderr.c subprocs.c timers.c windows.c \ + xscreensaver.c xset.c +SAVER_OBJS_1 = demo.o stderr.o subprocs.o timers.o windows.o \ + xscreensaver.o xset.o + +SAVER_SRCS = $(SAVER_SRCS_1) $(DIALOG_SRCS) $(LOCK_SRCS) $(UTIL_SRCS) +SAVER_OBJS = $(SAVER_OBJS_1) $(DIALOG_OBJS) $(LOCK_OBJS) $(UTIL_OBJS) +SAVER_LIBS = $(X_LIBS) @SAVER_LIBS@ -lXt $(XLIBS) $(PASSWD_LIBS) $(LIBS) + +CMD_SRCS = xscreensaver-command.c +CMD_OBJS = xscreensaver-command.o +CMD_LIBS = $(X_LIBS) $(XLIBS) $(LIBS) + +EXES = xscreensaver xscreensaver-command + +HDRS = XScreenSaver_ad.h xscreensaver.h +MEN = xscreensaver.man xscreensaver-command.man +EXTRAS = README Makefile.in XScreenSaver.ad.in dialogs.xd .gdbinit +VMSFILES = compile_axp.com compile_decc.com link_axp.com link_decc.com \ + vms-getpwnam.c vms-pwd.h vms-hpwd.c vms-validate.c \ + vms_axp.opt vms_axp_12.opt vms_decc.opt vms_decc_12.opt + +TARFILES = $(EXTRAS) $(VMSFILES) $(SAVER_SRCS_1) \ + $(MOTIF_SRCS) $(ATHENA_SRCS) $(PWENT_SRCS) $(KERBEROS_SRCS) \ + $(LOCK_SRCS_1) $(CMD_SRCS) $(HDRS) $(MEN) + + +all: $(EXES) + +install: install-program install-ad install-man +uninstall: uninstall-program uninstall-ad uninstall-man + +install-strip: + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' \ + INSTALL_SETUID='$(INSTALL_SETUID) -s' \ + install + +install-program: + @inst="$(INSTALL_PROGRAM)" ; \ + if [ @NEED_SETUID@ = yes ]; then \ + me="`whoami`" ; \ + if [ "$$me" = root ]; then \ + inst="$(INSTALL_SETUID)" ; \ + else \ + e=echo ; \ + $$e "" ;\ + $$e " Warning: xscreensaver has been compiled with support for shadow" ;\ + $$e " passwords. If your system actually uses shadow passwords," ;\ + $$e " then xscreensaver must be installed as a setuid root" ;\ + $$e " program in order for locking to work. To do this, you" ;\ + $$e " must run 'make install' as 'root', not as '$$me'." ;\ + $$e "" ;\ + $$e " For now, xscreensaver will be installed non-setuid, which" ;\ + $$e " means that locking might not work." ;\ + $$e "" ;\ + fi ; \ + fi ; \ + echo $$inst xscreensaver $(bindir)/xscreensaver ; \ + $$inst xscreensaver $(bindir)/xscreensaver + $(INSTALL_PROGRAM) xscreensaver-command $(bindir)/xscreensaver-command + +install-ad: + $(INSTALL_DATA) XScreenSaver.ad $(AD_DIR)/XScreenSaver + +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 $(bindir)/$$program ; \ + rm -f $(bindir)/$$program ; \ + done + +uninstall-ad: + rm -f $(AD_DIR)/XScreenSaver + +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) XScreenSaver_ad.h + +distclean: clean + -rm -f Makefile XScreenSaver.ad *~ "#"* + +# Adds all current dependencies to Makefile +depend: XScreenSaver_ad.h + $(DEPEND) -s '# DO NOT DELETE: updated by make depend' \ + $(DEPEND_FLAGS) -- \ + $(INCLUDES) $(DEFS) $(DEPEND_DEFINES) $(CFLAGS) $(X_CFLAGS) -- \ + $(SAVER_SRCS_1) $(CMD_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: update_ad_version XScreenSaver_ad.h + @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) -- \ + $(SAVER_SRCS_1) $(CMD_SRCS) | \ + ( \ + awk '/^# .*Makefile.in ---/,/^# DO .*distdepend/' < Makefile.in ; \ + sed -e 's@ \./@ @g;s@ /[^ ]*@@g;/^.*:$$/d' \ + -e 's@\.\./utils@$$(UTILS_SRC)@g' \ + -e 's@ \([^$$]\)@ $$(srcdir)/\1@g' \ + -e 's@$$.*\(XScreenSaver_ad\)@\1@g' \ + -e 's@ $$(srcdir)/\(.*config\.h\)@ \1@g' ; \ + echo '' \ + ) > /tmp/distdepend.$$$$ && \ + mv Makefile.in Makefile.in.bak && \ + mv /tmp/distdepend.$$$$ Makefile.in + +# Updates the version number in the app-defaults file to be in sync with +# the version number in version.h. This is so people can tell when they +# have a version skew between the app-defaults file and the executable. +update_ad_version:: + @S=XScreenSaver.ad.in ; \ + U=$(UTILS_SRC)/version.h ; \ + V=`sed -n 's/.*\([0-9][0-9]*\.[0-9]*\).*/\1/p' < $$U` ; \ + echo -n "Updating version number in $$S to $$V... " ; \ + T=/tmp/xs.$$$$ ; \ + sed "s/\(.*version \)[0-9][0-9]*\.[0-9]*\(.*\)/\1$$V\2/" \ + < $$S > $$T ; \ + if cmp -s $$S $$T ; then \ + echo "unchanged." ; \ + else \ + cat $$T > $$S ; \ + echo "done." ; \ + fi ; \ + rm $$T + + +TAGS: tags +tags: + find $(srcdir) -name '*.[chly]' -print | xargs etags -a + +echo_tarfiles: + @$(MAKE) XScreenSaver_ad.h 2>&1 >&- /dev/null + @echo $(TARFILES) + + +# 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)/fade.o: $(UTILS_SRC)/fade.c +$(UTILS_BIN)/overlay.o: $(UTILS_SRC)/overlay.c +$(UTILS_BIN)/resources.o: $(UTILS_SRC)/resources.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)/spline.o: $(UTILS_SRC)/spline.c +$(UTILS_BIN)/yarandom.o: $(UTILS_SRC)/yarandom.c + +$(UTIL_OBJS): + cd $(UTILS_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) $< + + +# How we build the default app-defaults file into the program. +# +XScreenSaver_ad.h: XScreenSaver.ad + $(SHELL) $(UTILS_SRC)/ad2c XScreenSaver.ad > $@ + +# The executables linked in this directory. +# +xscreensaver: $(SAVER_OBJS) + $(CC) $(LDFLAGS) -o $@ $(SAVER_OBJS) $(SAVER_LIBS) + +xscreensaver-command: $(CMD_OBJS) + $(CC) $(LDFLAGS) -o $@ $(CMD_OBJS) $(CMD_LIBS) + + +############################################################################## +# +# DO NOT DELETE: updated by make distdepend + +demo.o: ../config.h +demo.o: $(srcdir)/xscreensaver.h +demo.o: $(UTILS_SRC)/resources.h +stderr.o: ../config.h +stderr.o: $(srcdir)/xscreensaver.h +stderr.o: $(UTILS_SRC)/resources.h +stderr.o: $(UTILS_SRC)/visual.h +subprocs.o: ../config.h +subprocs.o: $(srcdir)/xscreensaver.h +subprocs.o: $(UTILS_SRC)/yarandom.h +timers.o: ../config.h +timers.o: $(srcdir)/xscreensaver.h +windows.o: ../config.h +windows.o: $(srcdir)/xscreensaver.h +windows.o: $(UTILS_SRC)/visual.h +windows.o: $(UTILS_SRC)/fade.h +xscreensaver.o: ../config.h +xscreensaver.o: $(srcdir)/xscreensaver.h +xscreensaver.o: $(UTILS_SRC)/version.h +xscreensaver.o: $(UTILS_SRC)/yarandom.h +xscreensaver.o: $(UTILS_SRC)/resources.h +xscreensaver.o: $(UTILS_SRC)/visual.h +xscreensaver.o: XScreenSaver_ad.h +xset.o: ../config.h +xset.o: $(srcdir)/xscreensaver.h +xscreensaver-command.o: ../config.h +xscreensaver-command.o: $(UTILS_SRC)/version.h + diff --git a/driver/README b/driver/README new file mode 100644 index 00000000..df64793b --- /dev/null +++ b/driver/README @@ -0,0 +1,6 @@ + +This directory contains the source for xscreensaver and xscreensaver-command, +the screensaver driver, and the program for externally controlling it. Some +stuff from the ../utils/ directory is used here as well. + +If you have compilation problems, check the parameters in ../config.h. diff --git a/driver/XScreenSaver.ad.in b/driver/XScreenSaver.ad.in new file mode 100644 index 00000000..72f79d4b --- /dev/null +++ b/driver/XScreenSaver.ad.in @@ -0,0 +1,426 @@ +! +! XScreenSaver +! +! a screen saver and locker for the X window system +! by Jamie Zawinski +! +! version 2.16 +! +! See "man xscreensaver" for more info. The latest version is always +! available at http://people.netscape.com/jwz/xscreensaver/ + +*timeout: 10 +*cycle: 10 +*lockTimeout: 0 +*passwdTimeout: 30 +*nice: 10 +*lock: False +*verbose: False +*fade: True +*unfade: False +*fadeSeconds: 3 +*fadeTicks: 20 + +*captureStderr: True +*captureStdout: True +*textForeground: Yellow +*textBackground: Black +*overlayStderr: True +*font: *-medium-r-*-140-*-m-* + +! Turning on "installColormap" interacts erratically with twm and tvtwm, +! but seems to work fine with mwm and olwm. Try it and see. If your +! screen turns some color other than black, the window manager is buggy, +! and you need to set this resource to False (or get a WM that works.) +! +*installColormap: True + + +! Any program which can draw on the root window will work as a screensaver. +! The following resource enumerates them. +! +! Programs are separated by newlines (specified in resource files with \n). +! Lines may be continued with a lone \ at the end of the line. +! +! Each line is an `sh' command. +! +! But, if the first word on the line is the name of a visual followed by a +! colon, then that visual will be used for the program, if it is available. +! If no such visual is available, then the program will be skipped. In +! this way, you can specify that you want certain programs to run only +! on color screens, and others only on mono screens, by making use of the +! magic visual names "color" and "mono". Likewise, if some hacks prefer +! colormaps, but others prefer 24-bit windows, that also can be arranged +! (in this case, by using "PseudoColor:" versus "TrueColor:".) +! +! All programs must be launched in such a way that they draw on the root +! window; they should not be spawned in the background with "&". If shell +! metacharacters are used, they must be understandable to `sh', not `csh' +! (the $SHELL variable is not consulted, for unfortunate but good reasons.) +! +! Be sure to check out Demo Mode: run the command `xscreensaver-command -demo' +! and it will cause the running XScreenSaver program to pop up a dialog box +! that lets you try out the following programs interactively. See the man +! pages for details. +! +*programs: qix -root -solid -delay 0 -segments 100 \n\ + attraction -root -mode balls \n\ + attraction -root -mode lines -points 3 -segments 200 \n\ + attraction -root -mode splines -segments 300 \n\ + attraction -root -mode lines -radius 300 \ + -orbit -vmult 0.5 \n\ + pyro -root \n\ + helix -root \n\ + pedal -root \n\ + rorschach -root -offset 7 \n\ + hopalong -root \n\ + greynetic -root \n\ + xroger -root \n\ + imsmap -root \n\ + slidescreen -root \n\ + decayscreen -root \n\ + puzzle -root \n\ + blitspin -root -grab \n\ + slip -root \n\ + hypercube -root \n\ + halo -root \n\ + maze -root \n\ + noseguy -root \n\ + flame -root \n\ + lmorph -root \n\ + deco -root \n\ + moire -root \n\ + moire2 -root \n\ + lightning -root \n\ + strange -root \n\ + spiral -root \n\ + laser -root \n\ + grav -root \n\ + grav -root -trail -decay \n\ + drift -root \n\ + ifs -root \n\ + julia -root \n\ + penrose -root \n\ + sierpinski -root \n\ + braid -root \n\ + galaxy -root \n\ + bouboule -root \n\ + swirl -root \n\ + flag -root \n\ + sphere -root \n\ + forest -root \n\ + lisa -root \n\ + lissie -root \n\ + goop -root \n\ + starfish -root \n\ + starfish -root -blob \n\ + munch -root \n\ + fadeplot -root \n\ + coral -root \n\ + mountain -root \n\ + triangle -root \n\ + worm -root \n\ + rotor -root \n\ + ant -root \n\ + vines -root \n\ + kaleidescope -root \n\ + xjack -root \n\ + xlyap -root -random \n\ + cynosure -root \n\ + \ + mono: rocks -root \n\ + color: rocks -root -fg darksalmon \n\ + \ + mono: qix -root -linear -count 5 -size 200 -spread 30 \ + -segments 75 -solid -xor \n\ + \ + color: attraction -root -mode polygons \n\ + color: attraction -root -mode filled-splines -segments 0 \n\ + color: attraction -root -glow -points 10 \n\ + color: bubbles -root \n\ + \ + color: rd-bomb -root \n\ + color: rd-bomb -root -speed 1 -size 0.1 \n\ + \ + PseudoColor: qix -root -count 4 -solid -transparent \n\ + PseudoColor: qix -root -count 5 -solid -transparent -linear \ + -segments 250 -size 100 \n\ +@GL_KLUDGE_1@ +@GL_KLUDGE_2@ gears -root \n\ +@GL_KLUDGE_2@ superquadrics -root \n\ +@GL_KLUDGE_2@ morph3d -root \n\ +@GL_KLUDGE_2@ cage -root \n\ +@GL_KLUDGE_2@ moebius -root \n\ +@GL_KLUDGE_2@ stairs -root \n\ +@GL_KLUDGE_2@ pipes -root \n\ +@GL_KLUDGE_2@ sproingies -root \n\ +@GL_KLUDGE_2@ rubik -root \n + + +! A few of the hacks require OpenGL, and will only be built if you have it. +! If your vendor doesn't provide real OpenGL, you might want to consider +! building MesaGL, which is a free implementation -- GL is way cool. +! +! Note that those hacks (gears, superquadratics, morph3d, cage, moebius, +! stairs, pipes, sproingies, and rubik) tend to work best on a visual *half* +! as deep as the depth of the screen, since that way, they can do +! double-buffering -- try it and see, but you will probably find that you +! should specify the deepest visual that is half as deep as the screen. +! +! For example, on a screen that supports both 24-bit TrueColor and 12-bit +! PseudoColor, the 12-bit visual will probably work best (this is true of +! base-model SGI Indys: the 0x29 visual is the one you want.) Oddly, on SGI +! O2s, (machines that have serious hardware support for GL) the 12-bit +! PseudoColor visual looks awful (you get a black and white, flickery image.) +! On these machines, the visual you want turns out to be 0x31 -- this is but +! one of the eight 15-bit TrueColor visuals (yes, 8, and yes, 15) that O2s +! provide. This is the only visual that works properly -- as far as xdpyinfo +! is concerned, all of the 15-bit TrueColor visuals are identical, but some +! flicker like mad, and some have deeply weird artifacts (hidden surfaces +! show through!) I suppose these other visuals must be tied to some arcane +! hardware feature... Your mileage, therefore, may vary dramatically. +! +! Some other programs that you might want to track down (these work as +! XScreenSaver helpers, but are not distributed with it): +! +! xdaliclock -root -builtin2 \n\ +! xswarm -r 2>&- \n\ +! xwave -root \n\ +! xbouncebits ... \n\ +! ico -r -faces -sleep 1 -obj ico \n\ +! xsplinefun \n\ +! xmountains -b -M \n\ +! color: xfishtank -c black -d -r 2 \n\ +! +! xtacy is ok, but it only works on the default visual. We can satisfy +! that constraint like so: +! +! default: xtacy -root -delay 100 -funky -number 3 \n\ +! default: xtacy -root -delay 100 -gravity \n\ +! default: xtacy -root -delay 100 -mixer \n\ +! default: xtacy -root -delay 100 -taffy -pal 4 \n\ +! +! To display a randomized slideshow of images, you can do something like this: +! +! default-n: xv -root -rmode 5 image-1.gif -quit +! default-n: xv -root -rmode 5 image-2.gif -quit +! default-n: xv -root -rmode 5 image-3.gif -quit +! ...and so on... +! +! Note that we've used "default-n" as the visual name, rather than just +! "default": this means "default visual, no install", that is, it's like +! specifying the command-line arguments "-visual default -no-install". +! This is necessary because, when XV is running in "-root" mode, it always +! assumes that the default visual and colormap are being used, rather than +! examining the window it is drawing on to see what visual and colormap it +! has. If we didn't force the default visual to be used, xv would get an +! X error. If we didn't force the default colormap to be installed, the +! colors would be all wrong. "default-i" may also be used as a visual name +! (meaning, "-visual default -install") but you probably won't ever need +! to use that. +! +! XEarth is nice, too: +! +! default-n: xearth -nostars -wait 0 -timewarp 400 -pos sunrel/38/-30 +! +! +! Some of the GL demos that SGI ships work with XScreenSaver; most don't. +! XScreenSaver includes a program (not built or installed by default) +! called "xscreensaver-sgigl". To use the SGI demos with XScreenSaver, +! build that program, and use it to launch the SGI demos. For example, +! on Irix 6.2, you can do this: +! +! xscreensaver-sgigl /usr/demos/bin/ep -S +! xscreensaver-sgigl /usr/demos/bin/bongo +! xscreensaver-sgigl /usr/demos/bin/atlantis +! +! On Irix 6.3, things have moved, so you need to do it like this: +! +! xscreensaver-sgigl /usr/sbin/ep -S +! +! You can also use the "ant" demo, but first you need to wrap a shell script +! around it that cds to its home directory, so that it can find its files; +! and also pass it the -S argument, to prevent it from forking. The "atlantis" +! hack *almost* works; but since it doesn't have an option to prevent it from +! forking, xscreensaver is unable to kill it, so when you come in the next +! morning, you'll find dozens of "atlantis" processes still running. +! +! +! Also, since these actually end up mapping their own windows instead of +! drawing on the XScreenSaver-provided root, when they are being run from +! demo-mode, you can't pop up the demo-mode dialog just by clicking the +! mouse: you must first type ESC to make the SGI programs exit. This sucks. +! Things should work properly when they are being run by xscreensaver in +! non-demo-mode, however. +! +! Basically, the SGI demo writers went out of their way to make my life hell. + + + +!============================================================================= +! +! You probably don't want to change anything after this point. +! +!============================================================================= + + +! Resources for the Motif dialog boxes: +! +*fontList: *-helvetica-medium-r-*-*-*-120-*-*-*-iso8859-1 +*demoDialog*label1.fontList: *-helvetica-medium-r-*-*-*-140-*-*-*-iso8859-1 +*passwdDialog*fontList: *-helvetica-medium-r-*-*-*-140-*-*-*-iso8859-1 +*XmList.fontList: *-courier-medium-r-*-*-*-120-*-*-*-iso8859-1 +*XmTextField.fontList: *-courier-medium-r-*-*-*-120-*-*-*-iso8859-1 +*passwdDialog.passwdText.fontList: *-courier-medium-r-*-*-*-120-*-*-*-iso8859-1 + +*XmDialogShell*foreground: black +*XmDialogShell*background: gray90 +*XmDialogShell*XmTextField.foreground: black +*XmDialogShell*XmTextField.background: white +*XmDialogShell*demoList.foreground: black +*XmDialogShell*demoList.background: white +*XmDialogShell*rogerLabel.foreground: red3 +*XmDialogShell*rogerLabel.background: white + +*XmDialogShell.title: XScreenSaver +*allowShellResize: True +*autoUnmanage: False + +! This doesn't work. Motif ignores it if there is a scroll-list! +*demoDialog.maxWidth: 600 + +*label1.labelString: XScreenSaver %s +*label1.label: XScreenSaver %s +*label2.labelString: Copyright © 1991-1998 by Jamie Zawinski +*label2.label: Copyright © 1991-1998 by Jamie Zawinski +*demoList.visibleItemCount: 10 +*demoList.automaticSelection: True +*next.labelString: Run Next +*prev.labelString: Run Previous +*edit.labelString: Edit Parameters +*done.labelString: Exit Demo Mode +*restart.labelString: Reinitialize + +*resourcesLabel.labelString: XScreenSaver Parameters + +*timeoutLabel.labelString: Saver Timeout +*cycleLabel.labelString: Cycle Timeout +*fadeSecondsLabel.labelString: Fade Duration +*fadeTicksLabel.labelString: Fade Ticks +*lockLabel.labelString: Lock Timeout +*passwdLabel.labelString: Password Timeout +*resourcesForm*XmTextField.columns: 8 + +*verboseToggle.labelString: Verbose +*cmapToggle.labelString: Install Colormap +*fadeToggle.labelString: Fade Colormap +*unfadeToggle.labelString: Unfade Colormap +*lockToggle.labelString: Require Password +*resourcesDone.labelString: Done +*resourcesCancel.labelString: Cancel + +*passwdDialog.title: Password +*passwdLabel1.labelString: XScreenSaver %s +*passwdLabel2.labelString: This display is locked. +*passwdLabel3.labelString: Please type %s's password to unlock it. +*passwdDone.labelString: Done +*passwdCancel.labelString: Cancel + +*passwdLabel1.alignment: ALIGNMENT_BEGINNING +*passwdLabel2.alignment: ALIGNMENT_BEGINNING +*passwdLabel3.alignment: ALIGNMENT_BEGINNING +*rogerLabel.width: 150 + +! Disable Motif drag-and-drop in dialog boxes. This is kind of pathetic, but +! in some older versions of Motif, most any attempt to drag cause immediate +! flaming death from above. This *should* rip the legs off that bug. +! +XScreenSaver*dragInitiatorProtocolStyle: DRAG_NONE +XScreenSaver*dragReceiverProtocolStyle: DRAG_NONE + + + +! Resources for the dialog boxes using the abominable Athena widgets: +! +*demo_dialog*font: *-helvetica-bold-r-*-*-*-120-*-*-*-iso8859-1 +*resources_dialog*font: *-helvetica-bold-r-*-*-*-120-*-*-*-iso8859-1 +*passwd_dialog*font: *-helvetica-bold-r-*-*-*-120-*-*-*-iso8859-1 +*demo_dialog*label1.font: *-helvetica-bold-r-*-*-*-140-*-*-*-iso8859-1 +*resources_dialog*label1.font: *-helvetica-bold-r-*-*-*-140-*-*-*-iso8859-1 +*demo_dialog*List.font: *-courier-medium-r-*-*-*-120-*-*-*-iso8859-1 + +! This is a hack to make the typed password invisible. +! Surely someone can do better than this... +*passwd_dialog*passwd_form.value*font: *nil* + +*demo_dialog*foreground: black +*demo_dialog*background: gray90 +*demo_dialog*List.background: white +*demo_dialog*Scrollbar.background: gray85 +*demo_dialog*Command.background: gray85 + +*resources_dialog*foreground: black +*resources_dialog*background: gray90 +*resources_dialog*Command.background: gray85 +*resources_dialog*Toggle.background: gray85 +*resources_dialog*Text*background: white + +*resources_dialog*Dialog.value.translations: #override\n\ + Return: beginning-of-line()\n + +*passwd_dialog*foreground: black +*passwd_dialog*background: gray90 +*passwd_dialog*Text*background: white + +*demo_dialog*viewport.width: 400 +*demo_dialog*viewport.height: 200 +*Form.borderWidth: 0 +*Box.borderWidth: 0 +*Label.borderWidth: 0 +*resources_dialog*Dialog.borderWidth: 0 + +*demo_dialog*next.label: Run Next +*demo_dialog*prev.label: Run Previous +*demo_dialog*edit.label: Edit Parameters +*demo_dialog*done.label: Exit Demo Mode +*demo_dialog*restart.label: Reinitialize + +*resources_dialog*timeout.label: Saver Timeout: +*resources_dialog*cycle.label: Cycle Timeout: +*resources_dialog*fade.label: Fade Duration: +*resources_dialog*ticks.label: Fade Ticks: +*resources_dialog*lockTime.label: Lock Timeout: +*resources_dialog*passwdTime.label: Password Timeout: + +*resources_dialog*label1.label: XScreenSaver Parameters +*resources_dialog*buttonbox.verbose.label: Verbose +*resources_dialog*buttonbox.cmap.label: Install Colormap +*resources_dialog*buttonbox.fade.label: Fade Colormap +*resources_dialog*buttonbox.unfade.label: Unfade Colormap +*resources_dialog*buttonbox.lock.label: Require Password +*resources_dialog*done.label: Done +*resources_dialog*cancel.label: Cancel + +*passwd_dialog*label1.label: XScreenSaver %s +*passwd_dialog*label2.label: This display is locked. +*passwd_dialog*label3.label: Please type %s's password to unlock it. +*passwd_dialog*ok.label: Done +*passwd_dialog*cancel.label: Cancel +*passwd_dialog*passwd_form*label.label: Enter password: +*passwd_dialog*Dialog.label: Enter password: +*passwd_dialog*passwd_form*Text.width: 200 +*passwd_dialog*roger.width: 150 +*passwd_dialog*roger.height: 150 +*passwd_dialog*roger.foreground: red3 +*passwd_dialog*roger.background: white +*passwd_dialog*roger.borderWidth: 1 + + +! You probably won't need to change these. They are only used if no server +! extension is in use. +! +*pointerPollTime: 5 +*initialDelay: 30 +*windowCreationTimeout: 30 + +*bourneShell: /bin/sh diff --git a/driver/compile_axp.com b/driver/compile_axp.com new file mode 100644 index 00000000..d6ed0e8a --- /dev/null +++ b/driver/compile_axp.com @@ -0,0 +1,15 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) DEMO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) DIALOGS-XM.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) LOCK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) PASSWD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) STDERR.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,NO_SETUID)/INCL=([],[-],[-.UTILS]) SUBPROCS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) TIMERS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) WINDOWS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) XSCREENSAVER-COMMAND.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,NO_SETUID)/INCL=([],[-],[-.UTILS]) XSCREENSAVER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) XSET.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-GETPWNAM.C +$!!! CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) GETPWUID.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-HPWD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-VALIDATE.C diff --git a/driver/compile_decc.com b/driver/compile_decc.com new file mode 100644 index 00000000..d6ed0e8a --- /dev/null +++ b/driver/compile_decc.com @@ -0,0 +1,15 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) DEMO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) DIALOGS-XM.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) LOCK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) PASSWD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) STDERR.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,NO_SETUID)/INCL=([],[-],[-.UTILS]) SUBPROCS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) TIMERS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) WINDOWS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) XSCREENSAVER-COMMAND.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,NO_SETUID)/INCL=([],[-],[-.UTILS]) XSCREENSAVER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) XSET.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-GETPWNAM.C +$!!! CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) GETPWUID.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-HPWD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-],[-.UTILS]) VMS-VALIDATE.C diff --git a/driver/demo.c b/driver/demo.c new file mode 100644 index 00000000..b13622e1 --- /dev/null +++ b/driver/demo.c @@ -0,0 +1,1019 @@ +/* demo.c --- implements the interactive demo-mode and options dialogs. + * xscreensaver, Copyright (c) 1993-1997 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include + +#ifdef DEBUG +# include /* just to get debug info for gdb... */ +# include +#endif + +#ifdef HAVE_MOTIF +# include +# include +# include +# include + +#else /* HAVE_ATHENA */ + /* Athena demo code contributed by Jon A. Christopher */ + /* Copyright 1997, with the same permissions as above. */ +# include +# include +# include +# include +# include +# include +# include +# include +# include +# include +#endif /* HAVE_ATHENA */ + +#include "xscreensaver.h" +#include "resources.h" /* for parse_time() */ +#include +#include +#include + +static void demo_mode_hack (saver_info *si, char *); +static void demo_mode_done (saver_info *si); + +extern Widget demo_dialog; +extern Widget label1; +extern Widget text_line; +extern Widget demo_form; +extern Widget demo_list; +extern Widget next, prev, done, restart, edit; + +extern Widget resources_dialog; +extern Widget resources_form; +extern Widget res_done, res_cancel; +extern Widget timeout_text, cycle_text, fade_text, ticks_text; +extern Widget lock_time_text, passwd_time_text; +extern Widget verbose_toggle, cmap_toggle, fade_toggle, unfade_toggle, + lock_toggle; + + +#ifdef HAVE_MOTIF + +# define set_toggle_button_state(toggle,state) \ + XmToggleButtonSetState ((toggle), (state), True) +# define set_text_string(text_widget,string) \ + XmTextSetString ((text_widget), (string)) +# define add_button_callback(button,cb,arg) \ + XtAddCallback ((button), XmNactivateCallback, (cb), (arg)) +# define add_toggle_callback(button,cb,arg) \ + XtAddCallback ((button), XmNvalueChangedCallback, (cb), (arg)) +# define add_text_callback add_toggle_callback + +#else /* HAVE_ATHENA */ + +# define set_toggle_button_state(toggle,state) \ + XtVaSetValues((toggle), XtNstate, (state), 0) +# define set_text_string(text_widget,string) \ + XtVaSetValues ((text_widget), XtNvalue, (string), 0) +# define add_button_callback(button,cb,arg) \ + XtAddCallback ((button), XtNcallback, (cb), (arg)) +# define add_toggle_callback add_button_callback +# define add_text_callback(b,c,a) ERROR! + +#endif /* HAVE_ATHENA */ + + +#define disable_widget(widget) \ + XtVaSetValues((widget), XtNsensitive, False, 0) + + +static char * +get_text_string (Widget text_widget) +{ +#ifdef HAVE_MOTIF + return XmTextGetString (text_widget); +#else /* HAVE_ATHENA */ + char *string = 0; + XtVaGetValues (text_widget, XtNvalue, &string, 0); + return string; +#endif /* HAVE_ATHENA */ +} + +static char * +get_label_string (Widget label_widget) +{ +#ifdef HAVE_MOTIF + char *label = 0; + XmString xm_label = 0; + XtVaGetValues (label_widget, XmNlabelString, &xm_label, 0); + if (!xm_label) + return 0; + XmStringGetLtoR (xm_label, XmSTRING_DEFAULT_CHARSET, &label); + return label; +#else /* HAVE_ATHENA */ + char *label = 0; + XtVaGetValues (label_widget, XtNlabel, &label, 0); + return (label ? strdup(label) : 0); +#endif /* HAVE_ATHENA */ +} + + +static void +set_label_string (Widget label_widget, char *string) +{ +#ifdef HAVE_MOTIF + XmString xm_string = XmStringCreate (string, XmSTRING_DEFAULT_CHARSET); + XtVaSetValues (label_widget, XmNlabelString, xm_string, 0); + XmStringFree (xm_string); +#else /* HAVE_ATHENA */ + XtVaSetValues (label_widget, XtNlabel, string, 0); +#endif /* HAVE_ATHENA */ +} + + +void +format_into_label (Widget label, const char *arg) +{ + char *text = get_label_string (label); + char *buf = (char *) malloc ((text ? strlen(text) : 100) + strlen(arg) + 10); + + if (!text || !strcmp (text, XtName (label))) + strcpy (buf, "ERROR: RESOURCES ARE NOT INSTALLED CORRECTLY"); + else + sprintf (buf, text, arg); + + set_label_string (label, buf); + free (buf); + XtFree (text); +} + + +void +steal_focus_and_colormap (Widget dialog) +{ + Display *dpy = XtDisplay (dialog); + Window window = XtWindow (dialog); + Colormap cmap = 0; + XSetInputFocus (dpy, window, RevertToParent, CurrentTime); + + XtVaGetValues (dialog, XtNcolormap, &cmap, 0); + if (cmap) + XInstallColormap (dpy, cmap); +} + +static void +raise_screenhack_dialog (void) +{ + XMapRaised (XtDisplay (demo_dialog), XtWindow (demo_dialog)); + if (resources_dialog) + XMapRaised (XtDisplay (resources_dialog), XtWindow (resources_dialog)); + steal_focus_and_colormap (resources_dialog ? resources_dialog : demo_dialog); +} + +static void +destroy_screenhack_dialogs (saver_info *si) +{ + saver_screen_info *ssi = si->default_screen; + + if (demo_dialog) XtDestroyWidget (demo_dialog); + if (resources_dialog) XtDestroyWidget (resources_dialog); + demo_dialog = resources_dialog = 0; + + if (ssi->demo_cmap && + ssi->demo_cmap != ssi->cmap && + ssi->demo_cmap != DefaultColormapOfScreen (ssi->screen)) + { + XFreeColormap (si->dpy, ssi->demo_cmap); + ssi->demo_cmap = 0; + } + + /* Since we installed our colormap to display the dialogs properly, put + the old one back, so that the screensaver_window is now displayed + properly. */ + if (ssi->cmap) + XInstallColormap (si->dpy, ssi->cmap); +} + +#ifdef HAVE_MOTIF + +static void +text_cb (Widget text_widget, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + char *line; + line = get_text_string (text_widget); + demo_mode_hack (si, line); +} + +#endif /* HAVE_MOTIF */ + + +static void +select_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + +#ifdef HAVE_ATHENA + XawListReturnStruct *item = (XawListReturnStruct*)call_data; + demo_mode_hack (si, item->string); +#else /* HAVE_MOTIF */ + XmListCallbackStruct *lcb = (XmListCallbackStruct *) call_data; + char *string = 0; + if (lcb->item) + XmStringGetLtoR (lcb->item, XmSTRING_DEFAULT_CHARSET, &string); + set_text_string (text_line, (string ? string : "")); + if (lcb->reason == XmCR_DEFAULT_ACTION && string) + demo_mode_hack (si, string); + if (string) + XtFree (string); +#endif /* HAVE_MOTIF */ + steal_focus_and_colormap (demo_dialog); +} + + +#if 0 /* configure does this now */ +#ifdef HAVE_ATHENA +# if !defined(_Viewport_h) + /* The R4 Athena libs don't have this function. I don't know the right + way to tell, but I note that the R5 version of Viewport.h defines + _XawViewport_h, while the R4 version defines _Viewport_h. So we'll + try and key off of that... */ +# define HAVE_XawViewportSetCoordinates +# endif +#endif /* HAVE_ATHENA */ +#endif /* 0 */ + + +/* Why this behavior isn't automatic in *either* toolkit, I'll never know. + */ +static void +ensure_selected_item_visible (Widget list) +{ +#ifdef HAVE_MOTIF + int *pos_list = 0; + int pos_count = 0; + if (XmListGetSelectedPos (list, &pos_list, &pos_count) && pos_count > 0) + { + int top = -2; + int visible = 0; + XtVaGetValues (list, + XmNtopItemPosition, &top, + XmNvisibleItemCount, &visible, + 0); + if (pos_list[0] >= top + visible) + { + int pos = pos_list[0] - visible + 1; + if (pos < 0) pos = 0; + XmListSetPos (list, pos); + } + else if (pos_list[0] < top) + { + XmListSetPos (list, pos_list[0]); + } + } + if (pos_list) + XtFree ((char *) pos_list); + +#else /* HAVE_ATHENA */ +# ifdef HAVE_XawViewportSetCoordinates + + int margin = 16; /* should be line height or something. */ + int count = 0; + int pos; + Dimension list_h = 0, vp_h = 0; + Dimension top_margin = 4; /* I don't know where this value comes from */ + Position vp_x = 0, vp_y = 0, current_y; + double cratio; + Widget viewport = XtParent(demo_list); + Widget sb = (viewport ? XtNameToWidget(viewport, "*vertical") : 0); + float sb_top = 0, sb_size = 0; + XawListReturnStruct *current = XawListShowCurrent(demo_list); + if (!current || !sb) return; + + XtVaGetValues(demo_list, + XtNnumberStrings, &count, + XtNheight, &list_h, + 0); + if (count < 2 || list_h < 10) return; + + XtVaGetValues(viewport, XtNheight, &vp_h, XtNx, &vp_x, XtNy, &vp_y, 0); + if (vp_h < 10) return; + + XtVaGetValues(sb, XtNtopOfThumb, &sb_top, XtNshown, &sb_size, 0); + if (sb_size <= 0) return; + + pos = current->list_index; + cratio = ((double) pos) / ((double) count); + current_y = (cratio * list_h); + + if (cratio < sb_top || + cratio > sb_top + sb_size) + { + if (cratio < sb_top) + current_y -= (vp_h - margin - margin); + else + current_y -= margin; + + if ((long)current_y >= (long) list_h) + current_y = (Position) ((long)list_h - (long)vp_h); + + if ((long)current_y < (long)top_margin) + current_y = (Position)top_margin; + + XawViewportSetCoordinates (viewport, vp_x, current_y); + } +# endif /* HAVE_XawViewportSetCoordinates */ +#endif /* HAVE_ATHENA */ +} + + +static void +next_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + +#ifdef HAVE_ATHENA + int cnt; + XawListReturnStruct *current = XawListShowCurrent(demo_list); + if (current->list_index == XAW_LIST_NONE) + XawListHighlight(demo_list,1); + else + { + XtVaGetValues(demo_list, + XtNnumberStrings, &cnt, + NULL); + if (current->list_index + 1 < cnt) + { + current->list_index++; + XawListHighlight(demo_list, current->list_index); + } + } + + ensure_selected_item_visible (demo_list); + current = XawListShowCurrent(demo_list); + demo_mode_hack (si, current->string); + +#else /* HAVE_MOTIF */ + + int *pos_list; + int pos_count; + if (! XmListGetSelectedPos (demo_list, &pos_list, &pos_count)) + { + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, 1, True); + } + else + { + int pos = pos_list[0] + 1; + if (pos > si->prefs.screenhacks_count) + pos = 1; + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, pos, True); + } + XtFree ((char *) pos_list); + ensure_selected_item_visible (demo_list); + demo_mode_hack (si, get_text_string (text_line)); + +#endif /* HAVE_MOTIF */ +} + + +static void +prev_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + +#ifdef HAVE_ATHENA + XawListReturnStruct *current=XawListShowCurrent(demo_list); + if (current->list_index == XAW_LIST_NONE) + XawListHighlight(demo_list,1); + else + { + if (current->list_index>=1) + { + current->list_index--; + XawListHighlight(demo_list, current->list_index); + } + } + + ensure_selected_item_visible (demo_list); + current = XawListShowCurrent(demo_list); + demo_mode_hack (si, current->string); + +#else /* HAVE_MOTIF */ + + int *pos_list; + int pos_count; + if (! XmListGetSelectedPos (demo_list, &pos_list, &pos_count)) + { + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, 0, True); + } + else + { + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, pos_list [0] - 1, True); + XtFree ((char *) pos_list); + } + ensure_selected_item_visible (demo_list); + demo_mode_hack (si, get_text_string (text_line)); + +#endif /* HAVE_MOTIF */ +} + + +static void pop_resources_dialog (saver_info *si); +static void make_resources_dialog (saver_info *si, Widget parent); + +static void +edit_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + saver_screen_info *ssi = si->default_screen; + Widget parent = ssi->toplevel_shell; + if (! resources_dialog) + make_resources_dialog (si, parent); + pop_resources_dialog (si); +} + +static void +done_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + demo_mode_done (si); +} + + +static void +restart_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + demo_mode_restart_process (si); +} + + +void +pop_up_dialog_box (Widget dialog, Widget form, int where) +{ + /* I'm sure this is the wrong way to pop up a dialog box, but I can't + figure out how else to do it. + + It's important that the screensaver dialogs not get decorated or + otherwise reparented by the window manager, because they need to be + children of the *real* root window, not the WM's virtual root, in + order for us to guarentee that they are visible above the screensaver + window itself. + */ + Arg av [100]; + int ac = 0; + Dimension sw, sh, x, y, w, h; + +#ifdef HAVE_ATHENA + XtRealizeWidget (dialog); +#else /* HAVE_MOTIF */ + /* Motif likes us to realize the *child* of the shell... */ + XtRealizeWidget (form); +#endif /* HAVE_MOTIF */ + + sw = WidthOfScreen (XtScreen (dialog)); + sh = HeightOfScreen (XtScreen (dialog)); + ac = 0; + XtSetArg (av [ac], XtNwidth, &w); ac++; + XtSetArg (av [ac], XtNheight, &h); ac++; + XtGetValues (form, av, ac); + +#ifdef DEBUG + if (where >= 69) + { + where -= 69; + sw = (sw * 7) / 12; + } +#endif + + switch (where) + { + case 0: /* center it in the top-right quadrant */ + x = (sw/2 + w) / 2 + (sw/2) - w; + y = (sh/2 + h) / 2 - h; + break; + case 1: /* center it in the bottom-right quadrant */ + x = (sw/2 + w) / 2 + (sw/2) - w; + y = (sh/2 + h) / 2 + (sh/2) - h; + break; + case 2: /* center it on the screen */ + x = (sw + w) / 2 - w; + y = (sh + h) / 2 - h; + break; + default: + abort (); + } + if (x + w > sw) x = sw - w; + if (y + h > sh) y = sh - h; + ac = 0; + XtSetArg (av [ac], XtNx, x); ac++; + XtSetArg (av [ac], XtNy, y); ac++; + XtSetArg (av [ac], XtNoverrideRedirect, True); ac++; + +#ifdef HAVE_MOTIF + XtSetArg (av [ac], XmNdefaultPosition, False); ac++; +#endif /* HAVE_MOTIF */ + + XtSetValues (dialog, av, ac); + XtSetValues (form, av, ac); + +#ifdef HAVE_ATHENA + XtPopup (dialog, XtGrabNone); +#else /* HAVE_MOTIF */ + XtManageChild (form); +#endif /* HAVE_MOTIF */ + + steal_focus_and_colormap (dialog); +} + + +static void +make_screenhack_dialog (saver_info *si) +{ + saver_screen_info *ssi = si->default_screen; + Widget parent = ssi->toplevel_shell; + char **hacks = si->prefs.screenhacks; + + if (ssi->demo_cmap && + ssi->demo_cmap != ssi->cmap && + ssi->demo_cmap != DefaultColormapOfScreen (ssi->screen)) + { + XFreeColormap (si->dpy, ssi->demo_cmap); + ssi->demo_cmap = 0; + } + + if (ssi->default_visual == DefaultVisualOfScreen (ssi->screen)) + ssi->demo_cmap = DefaultColormapOfScreen (ssi->screen); + else + ssi->demo_cmap = XCreateColormap (si->dpy, + RootWindowOfScreen (ssi->screen), + ssi->default_visual, AllocNone); + + create_demo_dialog (parent, ssi->default_visual, ssi->demo_cmap); + format_into_label (label1, si->version); + + add_button_callback (next, next_cb, (XtPointer) si); + add_button_callback (prev, prev_cb, (XtPointer) si); + add_button_callback (done, done_cb, (XtPointer) si); + add_button_callback (restart, restart_cb, (XtPointer) si); + add_button_callback (edit, edit_cb, (XtPointer) si); + +#ifdef HAVE_MOTIF + XtAddCallback (demo_list, XmNbrowseSelectionCallback, + select_cb, (XtPointer) si); + XtAddCallback (demo_list, XmNdefaultActionCallback, + select_cb, (XtPointer) si); + XtAddCallback (text_line, XmNactivateCallback, text_cb, (XtPointer) si); + + for (; *hacks; hacks++) + { + XmString xmstr = XmStringCreate (*hacks, XmSTRING_DEFAULT_CHARSET); + XmListAddItem (demo_list, xmstr, 0); + XmStringFree (xmstr); + } + + /* Cause the most-recently-run hack to be selected in the list. + Do some voodoo to make it be roughly centered in the list (really, + just make it not be within +/- 5 of the top/bottom if possible.) + */ + if (ssi->current_hack > 0) + { + int i = ssi->current_hack+1; + int top = i + 5; + int bot = i - 5; + if (bot < 1) bot = 1; + if (top > si->prefs.screenhacks_count) + top = si->prefs.screenhacks_count; + + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, bot, False); + ensure_selected_item_visible (demo_list); + + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, top, False); + ensure_selected_item_visible (demo_list); + + XmListDeselectAllItems(demo_list); /* LessTif lossage */ + XmListSelectPos (demo_list, i, False); + ensure_selected_item_visible (demo_list); + } + +#else /* HAVE_ATHENA */ + + XtVaSetValues (demo_list, + XtNlist, hacks, + XtNnumberStrings, si->prefs.screenhacks_count, + 0); + XtAddCallback (demo_list, XtNcallback, select_cb, si); + + /* #### still need to do the "select most-recently-run hack" + #### thing for Athena. + */ + +#endif /* HAVE_ATHENA */ + + pop_up_dialog_box(demo_dialog, demo_form, +#ifdef DEBUG + (si->prefs.debug_p ? 69 : 0) + +#endif + 0); +} + + +/* the Screensaver Parameters dialog */ + +static struct resources { + int timeout, cycle, secs, ticks, lock_time, passwd_time; + int verb, cmap, fade, unfade, lock_p; +} res; + + +static void +hack_time_cb (Display *dpy, char *line, int *store, Bool sec_p) +{ + if (*line) + { + int value; + value = parse_time (line, sec_p, True); + if (value < 0) + /*XBell (dpy, 0)*/; + else + *store = value; + } +} + +static void +res_sec_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + hack_time_cb (XtDisplay (button), get_text_string (button), + (int *) client_data, True); +} + +static void +res_min_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + hack_time_cb (XtDisplay (button), get_text_string (button), + (int *) client_data, False); +} + +static void +res_int_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + char *line = get_text_string (button); + int *store = (int *) client_data; + unsigned int value; + char c; + if (! *line) + ; + else if (sscanf (line, "%u%c", &value, &c) != 1) + XBell (XtDisplay (button), 0); + else + *store = value; +} + +static void +res_bool_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + int *store = (int *) client_data; +#ifdef HAVE_MOTIF + *store = ((XmToggleButtonCallbackStruct *) call_data)->set; +#else /* HAVE_ATHENA */ + Boolean state = FALSE; + XtVaGetValues (button, XtNstate, &state, NULL); + *store = state; +#endif /* HAVE_ATHENA */ +} + +static void +res_cancel_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + XtDestroyWidget (resources_dialog); + resources_dialog = 0; + raise_screenhack_dialog (); +} + + +static void +res_done_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + saver_info *si = (saver_info *) client_data; + saver_preferences *p = &si->prefs; + + res_cancel_cb (button, client_data, call_data); + +#ifdef HAVE_ATHENA + /* Check all text widgets, since we don't have callbacks for these. */ + res_min_cb (timeout_text, (XtPointer) &res.timeout, NULL); + res_min_cb (cycle_text, (XtPointer) &res.cycle, NULL); + res_sec_cb (fade_text, (XtPointer) &res.secs, NULL); + res_int_cb (ticks_text, (XtPointer) &res.ticks, NULL); + res_min_cb (lock_time_text, (XtPointer) &res.lock_time, NULL); + res_sec_cb (passwd_time_text, (XtPointer) &res.passwd_time, NULL); +#endif /* HAVE_ATHENA */ + + /* Throttle the timeouts to minimum sane values. */ + if (res.timeout < 5) res.timeout = 5; + if (res.cycle < 2) res.cycle = 2; + if (res.passwd_time < 10) res.passwd_time = 10; + + p->timeout = res.timeout * 1000; + p->cycle = res.cycle * 1000; + p->lock_timeout = res.lock_time * 1000; +#ifndef NO_LOCKING + p->passwd_timeout = res.passwd_time * 1000; +#endif + p->fade_seconds = res.secs; + p->fade_ticks = res.ticks; + p->verbose_p = res.verb; + p->install_cmap_p = res.cmap; + p->fade_p = res.fade; + p->unfade_p = res.unfade; + p->lock_p = res.lock_p; + +#ifdef DEBUG + if (p->debug_p && p->verbose_p) + fprintf (stderr, "%s: parameters changed:\n\ + timeout: %d\n\tcycle: %d\n\tlock: %d\n\tpasswd: %d\n\ + fade: %d\n\tfade: %d\n\tverbose: %d\n\tinstall: %d\n\ + fade: %d\n\tunfade: %d\n\tlock: %d\n", + progname, p->timeout, p->cycle, p->lock_timeout, +# ifdef NO_LOCKING + 0, +# else + p->passwd_timeout, +# endif + p->fade_seconds, p->fade_ticks, p->verbose_p, p->install_cmap_p, + p->fade_p, p->unfade_p, p->lock_p); +#endif /* DEBUG */ + +#if defined(HAVE_MIT_SAVER_EXTENSION) || defined(HAVE_SGI_SAVER_EXTENSION) + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + { + /* Need to set the server timeout to the new one the user has picked. + */ + int server_timeout, server_interval, prefer_blank, allow_exp; + XGetScreenSaver (si->dpy, &server_timeout, &server_interval, + &prefer_blank, &allow_exp); + if (server_timeout != (p->timeout / 1000)) + { + server_timeout = (p->timeout / 1000); + if (p->verbose_p) + fprintf (stderr, + "%s: configuring server for saver timeout of %d seconds.\n", + progname, server_timeout); + /* Leave all other parameters the same. */ + XSetScreenSaver (si->dpy, server_timeout, server_interval, + prefer_blank, allow_exp); + } + } +#endif /* HAVE_MIT_SAVER_EXTENSION || HAVE_SGI_SAVER_EXTENSION */ +} + + +static void +make_resources_dialog (saver_info *si, Widget parent) +{ + saver_screen_info *ssi = si->default_screen; + + if (ssi->demo_cmap && + ssi->demo_cmap != ssi->cmap && + ssi->demo_cmap != DefaultColormapOfScreen (ssi->screen)) + { + XFreeColormap (si->dpy, ssi->demo_cmap); + ssi->demo_cmap = 0; + } + + if (ssi->default_visual == DefaultVisualOfScreen (ssi->screen)) + ssi->demo_cmap = DefaultColormapOfScreen (ssi->screen); + else + ssi->demo_cmap = XCreateColormap (si->dpy, + RootWindowOfScreen (ssi->screen), + ssi->default_visual, AllocNone); + + create_resources_dialog (parent, ssi->default_visual, ssi->demo_cmap); + + add_button_callback (res_done, res_done_cb, (XtPointer) si); + add_button_callback (res_cancel, res_cancel_cb, (XtPointer) si); + +#define CB(widget,type,slot) \ + add_text_callback ((widget), (type), (XtPointer) (slot)) +#define CBT(widget,type,slot) \ + add_toggle_callback ((widget), (type), (XtPointer) (slot)) + +#ifdef HAVE_MOTIF + /* When using Athena widgets, we can't set callbacks for these, + so we'll check them all if "done" gets pressed. + */ + CB (timeout_text, res_min_cb, &res.timeout); + CB (cycle_text, res_min_cb, &res.cycle); + CB (fade_text, res_sec_cb, &res.secs); + CB (ticks_text, res_int_cb, &res.ticks); + CB (lock_time_text, res_min_cb, &res.lock_time); + CB (passwd_time_text, res_sec_cb, &res.passwd_time); +#endif /* HAVE_MOTIF */ + + CBT (verbose_toggle, res_bool_cb, &res.verb); + CBT (cmap_toggle, res_bool_cb, &res.cmap); + CBT (fade_toggle, res_bool_cb, &res.fade); + CBT (unfade_toggle, res_bool_cb, &res.unfade); + CBT (lock_toggle, res_bool_cb, &res.lock_p); +#undef CB +#undef CBT + + if (si->locking_disabled_p) + { + disable_widget (passwd_time_text); + disable_widget (lock_time_text); + disable_widget (lock_toggle); + } + if (CellsOfScreen (XtScreen (parent)) <= 2) + { + disable_widget (fade_text); + disable_widget (ticks_text); + disable_widget (cmap_toggle); + disable_widget (fade_toggle); + disable_widget (unfade_toggle); + } +} + + +static void +fmt_time (char *buf, unsigned int s, int min_p) +{ + unsigned int h = 0, m = 0; + if (s >= 60) + { + m += (s / 60); + s %= 60; + } + if (m >= 60) + { + h += (m / 60); + m %= 60; + } +/* + if (min_p && h == 0 && s == 0) + sprintf (buf, "%u", m); + else if (!min_p && h == 0 && m == 0) + sprintf (buf, "%u", s); + else + if (h == 0) + sprintf (buf, "%u:%02u", m, s); + else +*/ + sprintf (buf, "%u:%02u:%02u", h, m, s); +} + +static void +pop_resources_dialog (saver_info *si) +{ + saver_preferences *p = &si->prefs; + char buf [100]; + + res.timeout = p->timeout / 1000; + res.cycle = p->cycle / 1000; + res.lock_time = p->lock_timeout / 1000; +#ifndef NO_LOCKING + res.passwd_time = p->passwd_timeout / 1000; +#endif + res.secs = p->fade_seconds; + res.ticks = p->fade_ticks; + res.verb = p->verbose_p; + res.cmap = p->install_cmap_p; + res.fade = p->fade_p; + res.unfade = p->unfade_p; + res.lock_p = (p->lock_p && !si->locking_disabled_p); + + fmt_time (buf, res.timeout, 1); set_text_string (timeout_text, buf); + fmt_time (buf, res.cycle, 1); set_text_string (cycle_text, buf); + fmt_time (buf, res.lock_time, 1); set_text_string (lock_time_text, buf); + fmt_time (buf, res.passwd_time, 0); set_text_string (passwd_time_text, buf); + fmt_time (buf, res.secs, 0); set_text_string (fade_text, buf); + sprintf (buf, "%u", res.ticks); set_text_string (ticks_text, buf); + + set_toggle_button_state (verbose_toggle, res.verb); + set_toggle_button_state (cmap_toggle, res.cmap); + set_toggle_button_state (fade_toggle, res.fade); + set_toggle_button_state (unfade_toggle, res.unfade); + set_toggle_button_state (lock_toggle, res.lock_p); + + pop_up_dialog_box (resources_dialog, resources_form, +#ifdef DEBUG + (si->prefs.debug_p ? 69 : 0) + +#endif + 1); +} + + +/* The main demo-mode command loop. + */ + +void +demo_mode (saver_info *si) +{ + saver_preferences *p = &si->prefs; + si->dbox_up_p = True; + initialize_screensaver_window (si); + raise_window (si, True, False, False); + make_screenhack_dialog (si); + while (si->demo_mode_p) + { + XEvent event; + XtAppNextEvent (si->app, &event); + switch (event.xany.type) + { + case 0: /* synthetic "timeout" event */ + break; + + case ClientMessage: + handle_clientmessage (si, &event, False); + break; + + case CreateNotify: + if (!p->use_xidle_extension && + !p->use_mit_saver_extension && + !p->use_sgi_saver_extension) + { + start_notice_events_timer (si, event.xcreatewindow.window); +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: starting notice_events_timer for 0x%X (%lu)\n", + progname, + (unsigned int) event.xcreatewindow.window, + p->notice_events_timeout); +#endif /* DEBUG_TIMERS */ + } + break; + + case ButtonPress: + case ButtonRelease: + if (!XtWindowToWidget (si->dpy, event.xbutton.window)) + raise_screenhack_dialog (); + /* fall through */ + + default: +#ifdef HAVE_MIT_SAVER_EXTENSION + if (event.type == si->mit_saver_ext_event_number) + { + /* Get the "real" server window(s) out of the way as soon + as possible. */ + int i = 0; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->server_mit_saver_window && + window_exists_p (si->dpy, ssi->server_mit_saver_window)) + XUnmapWindow (si->dpy, ssi->server_mit_saver_window); + } + } + else +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + XtDispatchEvent (&event); + break; + } + } + destroy_screenhack_dialogs (si); + initialize_screensaver_window (si); + + si->demo_mode_p = True; /* kludge to inhibit unfade... */ + unblank_screen (si); + si->demo_mode_p = False; +} + +static void +demo_mode_hack (saver_info *si, char *hack) +{ + if (! si->demo_mode_p) abort (); + kill_screenhack (si); + if (! si->demo_hack) + blank_screen (si); + si->demo_hack = hack; + spawn_screenhack (si, False); + /* raise_screenhack_dialog(); */ +} + +static void +demo_mode_done (saver_info *si) +{ + kill_screenhack (si); + if (si->demo_hack) + unblank_screen (si); + si->demo_mode_p = False; + si->dbox_up_p = False; + si->demo_hack = 0; +} diff --git a/driver/dialogs-Xaw.c b/driver/dialogs-Xaw.c new file mode 100644 index 00000000..17938136 --- /dev/null +++ b/driver/dialogs-Xaw.c @@ -0,0 +1,311 @@ +/* dialogs-Xaw.c --- Athena widgets for demo, options, and password dialogs. + * xscreensaver, Copyright (c) 1997 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. + * + * Most of this code contributed by Jon A. Christopher + * Copyright 1997, with the same permissions as above. + */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include "visual.h" /* for visual_depth() */ + +Widget passwd_dialog; +Widget passwd_form; +Widget roger_label; +Widget passwd_label1; +Widget passwd_label3; +/*Widget passwd_text;*/ +/*Widget passwd_done;*/ +/*Widget passwd_cancel;*/ + +Widget resources_dialog; +Widget resources_form; +Widget timeout_text; +Widget cycle_text; +Widget fade_text; +Widget ticks_text; +Widget lock_time_text; +Widget passwd_time_text; +Widget verbose_toggle; +Widget cmap_toggle; +Widget fade_toggle; +Widget unfade_toggle; +Widget lock_toggle; +Widget res_done; +Widget res_cancel; + +Widget demo_dialog; +Widget demo_form; +Widget label1; +/*Widget label2;*/ +/*Widget text_area;*/ +Widget demo_list; +Widget text_line; +/*Widget vline;*/ +Widget next; +Widget prev; +Widget edit; +Widget done; +Widget restart; +/*Widget spacer;*/ + + +static Widget buttonbox, textbox, okbox; + + +void +create_passwd_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Widget box, passwd_label2; + int depth = visual_depth(XtScreen(parent), visual); + + passwd_dialog = + XtVaCreatePopupShell("passwd_dialog", transientShellWidgetClass, parent, + XtNtitle, NULL, + XtNoverrideRedirect, TRUE, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + box = XtVaCreateManagedWidget("box", formWidgetClass, passwd_dialog, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNtop, XtChainTop, + XtNbottom, XtChainBottom, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + roger_label = XtVaCreateManagedWidget("roger", labelWidgetClass, box, + XtNlabel, "", + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNtop, XtChainTop, + NULL); + + passwd_label1 = XtVaCreateManagedWidget("label1", labelWidgetClass, box, + XtNfromHoriz, roger_label, + XtNright, XtChainRight, + XtNtop, XtChainTop, + NULL); + passwd_label2 = XtVaCreateManagedWidget("label2", labelWidgetClass, box, + XtNfromHoriz, roger_label, + XtNright, XtChainRight, + XtNfromVert, passwd_label1, + NULL); + passwd_label3 = XtVaCreateManagedWidget("label3", labelWidgetClass, box, + XtNfromHoriz, roger_label, + XtNright, XtChainRight, + XtNfromVert, passwd_label2, + NULL); + + passwd_form = + XtVaCreateManagedWidget("passwd_form", dialogWidgetClass, box, + XtNfromHoriz, roger_label, + XtNright, XtChainRight, + XtNfromVert, passwd_label3, + NULL); +} + + +void +create_resources_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Widget rlabel; + int depth = visual_depth(XtScreen(parent), visual); + + resources_dialog = + XtVaCreatePopupShell("resources_dialog", transientShellWidgetClass, parent, + XtNtitle, NULL, + XtNoverrideRedirect, TRUE, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + resources_form = + XtVaCreateManagedWidget("resources_form", formWidgetClass, + resources_dialog, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + rlabel = XtVaCreateManagedWidget("label1", labelWidgetClass, resources_form, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNtop, XtChainTop, + NULL); + + textbox= + XtVaCreateManagedWidget("textbox", formWidgetClass, resources_form, + XtNleft, XtChainLeft, + XtNfromVert, rlabel, + NULL); + okbox= + XtVaCreateManagedWidget("textbox", boxWidgetClass, resources_form, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNfromVert, textbox, + XtNorientation, XtorientHorizontal, + NULL); + timeout_text= + XtVaCreateManagedWidget("timeout", dialogWidgetClass, textbox, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNtop, XtChainTop, + NULL); + cycle_text= + XtVaCreateManagedWidget("cycle", dialogWidgetClass, textbox, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNfromVert, timeout_text, + NULL); + fade_text= + XtVaCreateManagedWidget("fade", dialogWidgetClass, textbox, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNfromVert, cycle_text, + NULL); + + ticks_text = + XtVaCreateManagedWidget("ticks", dialogWidgetClass, textbox, + XtNtop, XtChainTop, + XtNright, XtChainRight, + XtNfromHoriz, timeout_text, + NULL); + + lock_time_text = + XtVaCreateManagedWidget("lockTime", dialogWidgetClass, textbox, + XtNfromVert, ticks_text, + XtNright, XtChainRight, + XtNfromHoriz, cycle_text, + NULL); + + passwd_time_text = + XtVaCreateManagedWidget("passwdTime", dialogWidgetClass, textbox, + XtNfromVert, lock_time_text, + XtNright, XtChainRight, + XtNfromHoriz, fade_text, + NULL); + + buttonbox= + XtVaCreateManagedWidget("buttonbox", boxWidgetClass, resources_form, + XtNfromVert, rlabel, + XtNfromHoriz, textbox, + XtNright, XtChainRight, + XtNorientation, XtorientVertical, + NULL); + verbose_toggle = + XtVaCreateManagedWidget("verbose", toggleWidgetClass, buttonbox, + NULL); + cmap_toggle = + XtVaCreateManagedWidget("cmap", toggleWidgetClass, buttonbox, + NULL); + fade_toggle = + XtVaCreateManagedWidget("fade", toggleWidgetClass, buttonbox, + NULL); + unfade_toggle = + XtVaCreateManagedWidget("unfade", toggleWidgetClass, buttonbox, + NULL); + lock_toggle = + XtVaCreateManagedWidget("lock", toggleWidgetClass, buttonbox, + NULL); + + + res_done = XtVaCreateManagedWidget("done", commandWidgetClass, okbox, + NULL); + res_cancel = XtVaCreateManagedWidget("cancel", commandWidgetClass, okbox, + NULL); +} + +void +create_demo_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Widget subform, box, viewport, label2; + int depth = visual_depth(XtScreen(parent), visual); + + demo_dialog = + XtVaCreatePopupShell("demo_dialog", transientShellWidgetClass, parent, + XtNtitle, NULL, + XtNoverrideRedirect, TRUE, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + demo_form = + XtVaCreateManagedWidget("demo_form", formWidgetClass, demo_dialog, + XtNvisual, visual, + XtNcolormap, colormap, + XtNdepth, depth, + NULL); + + label1 = XtVaCreateManagedWidget("label1", labelWidgetClass, demo_form, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNtop, XtChainTop, + NULL); + + label2 = XtVaCreateManagedWidget("label2", labelWidgetClass, demo_form, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNfromVert, label1, + NULL); + + subform= + XtVaCreateManagedWidget("subform", formWidgetClass, demo_form, + XtNleft, XtChainLeft, + XtNright, XtChainRight, + XtNfromVert, label2, + XtNbottom, XtChainBottom, + NULL); + viewport= + XtVaCreateManagedWidget("viewport", viewportWidgetClass, subform, + XtNallowVert, TRUE, + XtNallowHoriz, TRUE, + XtNforceBars, TRUE, + NULL); + + demo_list = XtVaCreateManagedWidget("demo_list", listWidgetClass, viewport, + XtNverticalList, TRUE, + XtNdefaultColumns, 1, + NULL); + box= + XtVaCreateManagedWidget("box", boxWidgetClass, demo_form, + XtNfromHoriz, subform, + XtNfromVert, label2, + XtNbottom, XtChainBottom, + XtNright, XtChainRight, + NULL); + prev = XtVaCreateManagedWidget("prev", commandWidgetClass, box, NULL); + next = XtVaCreateManagedWidget("next", commandWidgetClass, box, NULL); + edit = XtVaCreateManagedWidget("edit", commandWidgetClass, box, NULL); + restart = XtVaCreateManagedWidget("restart", commandWidgetClass, box, NULL); + done = XtVaCreateManagedWidget("done", commandWidgetClass, box, NULL); +} diff --git a/driver/dialogs-Xm.c b/driver/dialogs-Xm.c new file mode 100644 index 00000000..0daa7b35 --- /dev/null +++ b/driver/dialogs-Xm.c @@ -0,0 +1,701 @@ +/* dialogs-Xm.c --- Motif widgets for demo, options, and password dialogs. + * xscreensaver, Copyright (c) 1993-1997 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. + */ + +/* The code in this file started off its life as the output of XDesigner, + but I've since hacked it by hand... It's a mess, avert your eyes. + */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include + +#include "visual.h" /* for visual_depth() */ + +Widget passwd_dialog; +Widget passwd_form; +Widget roger_label; +Widget passwd_label1; +Widget passwd_label3; +Widget passwd_text; +Widget passwd_done; +Widget passwd_cancel; + +Widget resources_dialog; +Widget resources_form; +Widget timeout_text; +Widget cycle_text; +Widget fade_text; +Widget ticks_text; +Widget lock_time_text; +Widget passwd_time_text; +Widget verbose_toggle; +Widget cmap_toggle; +Widget fade_toggle; +Widget unfade_toggle; +Widget lock_toggle; +Widget res_done; +Widget res_cancel; + +Widget demo_dialog; +Widget demo_form; +Widget label1; +Widget label2; +Widget text_area; +Widget demo_list; +Widget text_line; +Widget vline; +Widget next; +Widget prev; +Widget edit; +Widget done; +Widget restart; +Widget spacer; + + +void +create_passwd_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Widget shell; + Widget form1; + Widget roger; + Widget dialog; + Widget form2; + Widget label1, label2, label3; + Widget text; + Widget ok, cancel; + Widget w; + Arg al[64]; + int ac = 0; + + ac = 0; + XtSetArg (al[ac], XmNvisual, visual); ac++; + XtSetArg (al[ac], XmNcolormap, colormap); ac++; + XtSetArg (al[ac], XmNdepth, visual_depth(XtScreen(parent), visual)); ac++; + + shell = XmCreateDialogShell (parent, "passwdDialog", al, ac); + + form1 = XmCreateForm (shell, "form", 0, 0); + + roger = XmCreateDrawnButton (form1, "rogerLabel", 0, 0); + + dialog = XmCreateSelectionBox (form1, "passwdForm", al, ac); + + form2 = XmCreateForm ( dialog, "form", 0, 0); + label1 = XmCreateLabel ( form2, "passwdLabel1", 0, 0); + label2 = XmCreateLabel ( form2, "passwdLabel2", 0, 0); + label3 = XmCreateLabel ( form2, "passwdLabel3", 0, 0); + + text = XmSelectionBoxGetChild (dialog, XmDIALOG_TEXT); + ok = XmSelectionBoxGetChild (dialog, XmDIALOG_OK_BUTTON); + cancel = XmSelectionBoxGetChild (dialog, XmDIALOG_CANCEL_BUTTON); + + w = XmSelectionBoxGetChild (dialog, XmDIALOG_LIST_LABEL); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (dialog, XmDIALOG_LIST); + if (w) XtUnmanageChild (XtParent(w)); + w = XmSelectionBoxGetChild (dialog, XmDIALOG_SELECTION_LABEL); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (dialog, XmDIALOG_SEPARATOR); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (dialog, XmDIALOG_APPLY_BUTTON); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (dialog, XmDIALOG_HELP_BUTTON); + if (w) XtUnmanageChild (w); + + XtVaSetValues(label1, + XmNtopAttachment, XmATTACH_FORM, + XmNleftAttachment, XmATTACH_FORM, + XmNrightAttachment, XmATTACH_FORM, + XmNbottomAttachment, XmATTACH_NONE, + 0); + XtVaSetValues(label2, + XmNtopAttachment, XmATTACH_WIDGET, + XmNtopWidget, label1, + XmNleftAttachment, XmATTACH_FORM, + XmNrightAttachment, XmATTACH_FORM, + XmNbottomAttachment, XmATTACH_NONE, + 0); + XtVaSetValues(label3, + XmNtopAttachment, XmATTACH_WIDGET, + XmNtopWidget, label2, + XmNleftAttachment, XmATTACH_FORM, + XmNrightAttachment, XmATTACH_FORM, + XmNbottomAttachment, XmATTACH_FORM, + 0); + + XtVaSetValues(roger, + XmNsensitive, FALSE, + XmNtopAttachment, XmATTACH_FORM, + XmNleftAttachment, XmATTACH_FORM, + XmNrightAttachment, XmATTACH_NONE, + XmNbottomAttachment, XmATTACH_FORM, + 0); + XtVaSetValues(dialog, + XmNtopAttachment, XmATTACH_FORM, + XmNleftAttachment, XmATTACH_WIDGET, + XmNleftWidget, roger, + XmNrightAttachment, XmATTACH_FORM, + XmNbottomAttachment, XmATTACH_FORM, + 0); + + XtManageChild(label1); + XtManageChild(label2); + XtManageChild(label3); + + XtManageChild(form2); + XtManageChild(text); + XtManageChild(ok); + XtManageChild(cancel); + + XtManageChild(roger); + XtManageChild(dialog); + + { + Dimension width = 0, height = 0; + XtRealizeWidget(form1); + XtVaGetValues(roger, XmNwidth, &width, XmNheight, &height, 0); + if (width == height) + ; + else if (width > height) + XtVaSetValues(roger, XmNwidth, width, XmNheight, width, 0); + else + XtVaSetValues(roger, XmNwidth, height, XmNheight, height, 0); + } + + passwd_dialog = shell; + passwd_form = form1; + roger_label = roger; + passwd_label1 = label1; + passwd_label3 = label3; + passwd_text = text; + passwd_done = ok; + passwd_cancel = cancel; +} + + + +void +create_resources_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Widget children[22]; /* Children to manage */ + Arg al[64]; /* Arg List */ + register int ac = 0; /* Arg Count */ + Widget widget12; + Widget widget13; + Widget widget14; + Widget widget15; + Widget widget16; + Widget widget17; + Widget widget18; + Widget widget48; + Widget widget29; + + Widget real_dialog; + Widget w; + + ac = 0; + XtSetArg (al[ac], XmNvisual, visual); ac++; + XtSetArg (al[ac], XmNcolormap, colormap); ac++; + XtSetArg (al[ac], XmNdepth, visual_depth(XtScreen(parent), visual)); ac++; + + real_dialog = XmCreatePromptDialog (parent, "resourcesForm", al, ac); + resources_dialog = XtParent(real_dialog); + + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_SEPARATOR); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_TEXT); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_SELECTION_LABEL); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_HELP_BUTTON); + if (w) XtUnmanageChild (w); + + ac = 0; + XtSetArg (al [ac], XmNtopAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNbottomAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNrightAttachment, XmATTACH_FORM); ac++; + resources_form = XmCreateForm (real_dialog, "form", al, ac); + XtManageChild (resources_form); + + ac = 0; + + widget12 = XmCreateLabel ( resources_form, "resourcesLabel", al, ac ); + widget13 = XmCreateSeparator ( resources_form, "separator", al, ac ); + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget14 = XmCreateLabel ( resources_form, "timeoutLabel", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget15 = XmCreateLabel ( resources_form, "cycleLabel", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget16 = XmCreateLabel ( resources_form, "fadeSecondsLabel", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget17 = XmCreateLabel ( resources_form, "fadeTicksLabel", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget18 = XmCreateLabel ( resources_form, "lockLabel", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_END); ac++; + widget48 = XmCreateLabel ( resources_form, "passwdLabel", al, ac ); + ac = 0; + timeout_text = XmCreateTextField ( resources_form, "timeoutText", al, ac ); + cycle_text = XmCreateTextField ( resources_form, "cycleText", al, ac ); + fade_text = XmCreateTextField ( resources_form, "fadeSecondsText", al, ac ); + ticks_text = XmCreateTextField ( resources_form, "fadeTicksText", al, ac ); + lock_time_text = XmCreateTextField ( resources_form, "passwdText", al, ac ); + passwd_time_text = XmCreateTextField ( resources_form, "lockText", al, ac ); + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_BEGINNING); ac++; + verbose_toggle = XmCreateToggleButton ( resources_form, "verboseToggle", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_BEGINNING); ac++; + cmap_toggle = XmCreateToggleButton ( resources_form, "cmapToggle", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_BEGINNING); ac++; + fade_toggle = XmCreateToggleButton ( resources_form, "fadeToggle", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_BEGINNING); ac++; + unfade_toggle = XmCreateToggleButton ( resources_form, "unfadeToggle", al, ac ); + ac = 0; + XtSetArg(al[ac], XmNalignment, XmALIGNMENT_BEGINNING); ac++; + lock_toggle = XmCreateToggleButton ( resources_form, "lockToggle", al, ac ); + ac = 0; + widget29 = XmCreateSeparator ( resources_form, "separator", al, ac ); + + res_done = XmSelectionBoxGetChild (real_dialog, XmDIALOG_OK_BUTTON); + res_cancel = XmSelectionBoxGetChild (real_dialog, XmDIALOG_CANCEL_BUTTON); + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 4); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetValues ( widget12,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, widget12); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 0); ac++; + XtSetValues ( widget13,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, widget13); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomWidget, timeout_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 20); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, timeout_text); ac++; + XtSetValues ( widget14,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 20); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, cycle_text); ac++; + XtSetValues ( widget15,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, fade_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, fade_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 20); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, fade_text); ac++; + XtSetValues ( widget16,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 20); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, ticks_text); ac++; + XtSetValues ( widget17,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 19); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, lock_time_text); ac++; + XtSetValues ( widget18,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, passwd_time_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, passwd_time_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 14); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetArg(al[ac], XmNrightWidget, passwd_time_text); ac++; + XtSetValues ( widget48,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, widget13); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 141); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( timeout_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 2); ac++; + XtSetArg(al[ac], XmNtopWidget, timeout_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, timeout_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( cycle_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 2); ac++; + XtSetArg(al[ac], XmNtopWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( fade_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 2); ac++; + XtSetArg(al[ac], XmNtopWidget, fade_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, fade_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( ticks_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 2); ac++; + XtSetArg(al[ac], XmNtopWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( lock_time_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_NONE); ac++; + XtSetValues ( passwd_time_text,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, widget13); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, timeout_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 20); ac++; + XtSetArg(al[ac], XmNleftWidget, timeout_text); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 20); ac++; + XtSetValues ( verbose_toggle,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, cycle_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, verbose_toggle); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 20); ac++; + XtSetValues ( cmap_toggle,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, fade_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, fade_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, cmap_toggle); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 20); ac++; + XtSetValues ( fade_toggle,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, ticks_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, fade_toggle); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 20); ac++; + XtSetValues ( unfade_toggle,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNbottomOffset, 0); ac++; + XtSetArg(al[ac], XmNbottomWidget, lock_time_text); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_OPPOSITE_WIDGET); ac++; + XtSetArg(al[ac], XmNleftOffset, 0); ac++; + XtSetArg(al[ac], XmNleftWidget, unfade_toggle); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 20); ac++; + XtSetValues ( lock_toggle,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 0); ac++; + XtSetArg(al[ac], XmNtopWidget, passwd_time_text); ac++; + + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNbottomOffset, 4); ac++; + + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetValues ( widget29,al, ac ); + ac = 0; + + + + ac = 0; + children[ac++] = widget12; + children[ac++] = widget13; + children[ac++] = widget14; + children[ac++] = widget15; + children[ac++] = widget16; + children[ac++] = widget17; + children[ac++] = widget18; + children[ac++] = widget48; + children[ac++] = timeout_text; + children[ac++] = cycle_text; + children[ac++] = fade_text; + children[ac++] = ticks_text; + children[ac++] = lock_time_text; + children[ac++] = passwd_time_text; + children[ac++] = verbose_toggle; + children[ac++] = cmap_toggle; + children[ac++] = fade_toggle; + children[ac++] = unfade_toggle; + children[ac++] = lock_toggle; + children[ac++] = widget29; + + XtManageChildren(children, ac); + ac = 0; + + resources_form = real_dialog; +} + + +void +create_demo_dialog(Widget parent, Visual *visual, Colormap colormap) +{ + Arg al[64]; /* Arg List */ + register int ac = 0; /* Arg Count */ + + Widget real_dialog; + Widget w; + + + ac = 0; + XtSetArg (al[ac], XmNvisual, visual); ac++; + XtSetArg (al[ac], XmNcolormap, colormap); ac++; + XtSetArg (al[ac], XmNdepth, visual_depth(XtScreen(parent), visual)); ac++; + + + real_dialog = XmCreatePromptDialog (parent, "demoForm", al, ac); + demo_dialog = XtParent(real_dialog); + + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_SEPARATOR); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_TEXT); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_SELECTION_LABEL); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_OK_BUTTON); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_CANCEL_BUTTON); + if (w) XtUnmanageChild (w); + w = XmSelectionBoxGetChild (real_dialog, XmDIALOG_HELP_BUTTON); + if (w) XtUnmanageChild (w); + + ac = 0; + XtSetArg (al [ac], XmNtopAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNbottomAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg (al [ac], XmNrightAttachment, XmATTACH_FORM); ac++; + demo_form = XmCreateForm (real_dialog, "form", al, ac); + XtManageChild (demo_form); + + label1 = XmCreateLabel ( demo_form, "label1", al, ac ); + label2 = XmCreateLabel ( demo_form, "label2", al, ac ); + demo_list = XmCreateScrolledList ( demo_form, "demoList", al, ac ); + text_area = XtParent ( demo_list ); + + ac = 0; + text_line = XmSelectionBoxGetChild (real_dialog, XmDIALOG_TEXT); + XtManageChild(text_line); + + /* #### ARRGH! This is apparently the only way to make hitting return in + the text field not *ALSO* activate the most-recently-selected button! + + This has the unfortunate side effect of making the buttons not be + keyboard-traversable, but that's less bad than not being able to try + out new switches by typing them into the text field. + + XmSelectionBox(3M) says in the "Additional Behavior" section: + KActivate: + Calls the activate callbacks for the button with + the keyboard focus. [... ] In a List widget or + single-line Text widget, the List or Text action + associated with KActivate is called before the + SelectionBox actions associated with KActivate." + + So they take it as a given that when running activateCallback on a single- + line Text widget, you'll also want to run activateCallback on whatever the + currently-focussed button is as well! Morons! Villains! Shitheads! + + (Perhaps there's some way to override XmSelectionBox's KActivate behavior. + I doubt it, but if there is, I don't know it.) + */ + ac = 0; + XtSetArg(al[ac], XmNtraversalOn, False); ac++; + + next = XmCreatePushButton ( real_dialog, "next", al, ac ); + prev = XmCreatePushButton ( real_dialog, "prev", al, ac ); + edit = XmCreatePushButton ( real_dialog, "edit", al, ac ); + done = XmCreatePushButton ( real_dialog, "done", al, ac ); + restart = XmCreatePushButton ( real_dialog, "restart", al, ac ); + XtManageChild(next); + XtManageChild(prev); + XtManageChild(edit); + XtManageChild(done); + XtManageChild(restart); + + ac = 0; + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNtopOffset, 5); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 4); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetValues ( label1,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, label1); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_NONE); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 4); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetValues ( label2,al, ac ); + ac = 0; + + XtSetArg(al[ac], XmNtopAttachment, XmATTACH_WIDGET); ac++; + XtSetArg(al[ac], XmNtopOffset, 4); ac++; + XtSetArg(al[ac], XmNtopWidget, label2); ac++; + XtSetArg(al[ac], XmNbottomAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNleftOffset, 4); ac++; + XtSetArg(al[ac], XmNrightAttachment, XmATTACH_FORM); ac++; + XtSetArg(al[ac], XmNrightOffset, 4); ac++; + XtSetValues ( text_area,al, ac ); + + XtManageChild(demo_list); + XtManageChild(label1); + XtManageChild(label2); + + demo_form = real_dialog; +} diff --git a/driver/dialogs.xd b/driver/dialogs.xd new file mode 100644 index 00000000..ad1f6da0 --- /dev/null +++ b/driver/dialogs.xd @@ -0,0 +1,569 @@ +module 'XScreenSaver' +applicationName = 'XScreenSaver'; +generateNameC = 'dialogs.c'; +generateNameUIL = ''; +generateNameResDB = 'dialogs.ad'; +generateUidFile = ''; +generateMask = 1507557; +useMask = 1; +value +object 'passwd_dialog' : XmDialogShell { + arguments { + name = 'passwdDialog'; + XmNtitle= 'XScreenSaver'; + XmNallowShellResize= true; + }; +object 'passwd_form' : XmForm { + arguments { + name = 'passwdForm'; + XmNautoUnmanage= false; + }; +object 'roger_label' : XmDrawnButton { + arguments { + name = 'rogerLabel'; + XmNwidth= 150; + }; +}; +object 'passwd_label1' : XmLabel { + arguments { + name = 'passwdLabel1'; + XmNlabelString= 'XScreenSaver %s'; + XmNalignment= 0; + }; +}; +object '' : XmLabel { + arguments { + name = 'passwdLabel2'; + XmNlabelString= 'This display is locked.'; + XmNalignment= 0; + }; +}; +object 'passwd_label3' : XmLabel { + arguments { + name = 'passwdLabel3'; + XmNlabelString= 'Please type %s\'s password to unlock it.'; + XmNalignment= 0; + }; +}; +object 'passwd_text' : XmTextField { + arguments { + name = 'passwdText'; + }; +}; +object '' : XmSeparator { + arguments { + }; +}; +object 'passwd_done' : XmPushButton { + arguments { + name = 'passwdDone'; + XmNlabelString= 'Done'; + }; +}; +object 'passwd_cancel' : XmPushButton { + arguments { + name = 'passwdCancel'; + XmNlabelString= 'Cancel'; + }; +}; + attachments { + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 1 0 4; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 3 1 4; + XmNbottomAttachment = 3 3 4; + XmNtopAttachment = 1 0 4; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 3 1 4; + XmNbottomAttachment = 3 4 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 1 0 30; + XmNleftAttachment = 3 1 4; + XmNbottomAttachment = 3 5 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 3 1 4; + XmNbottomAttachment = 3 6 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 1 0 0; + XmNleftAttachment = 3 1 0; + XmNbottomAttachment = 3 7 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 1 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 7 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 0 0 0; + }; + }; +}; +}; +object 'resources_dialog' : XmDialogShell { + arguments { + name = 'resourcesDialog'; + XmNtitle= 'XScreenSaver'; + XmNallowShellResize= true; + }; +object 'resources_form' : XmForm { + arguments { + name = 'resourcesForm'; + XmNautoUnmanage= false; + }; +object '' : XmLabel { + arguments { + name = 'resourcesLabel'; + XmNlabelString= 'XScreenSaver Parameters'; + }; +}; +object '' : XmSeparator { + arguments { + }; +}; +object '' : XmLabel { + arguments { + name = 'timeoutLabel'; + XmNlabelString= 'Timeout Minutes'; + XmNalignment= * 2; + }; +}; +object '' : XmLabel { + arguments { + name = 'cycleLabel'; + XmNlabelString= 'Cycle Seconds'; + XmNalignment= * 2; + }; +}; +object '' : XmLabel { + arguments { + name = 'fadeSecondsLabel'; + XmNlabelString= 'Fade Seconds'; + XmNalignment= * 2; + }; +}; +object '' : XmLabel { + arguments { + name = 'fadeTicksLabel'; + XmNlabelString= 'Fade Ticks'; + XmNalignment= * 2; + }; +}; +object '' : XmLabel { + arguments { + name = 'lockLabel'; + XmNlabelString= 'Lock Timeout'; + XmNalignment= * 2; + }; +}; +object '' : XmLabel { + arguments { + name = 'passwdLabel'; + XmNlabelString= 'Password Timeout'; + XmNalignment= * 2; + }; +}; +object 'timeout_text' : XmTextField { + arguments { + name = 'timeoutText'; + XmNcolumns= 5; + }; +}; +object 'cycle_text' : XmTextField { + arguments { + name = 'cycleText'; + XmNcolumns= 5; + }; +}; +object 'fade_text' : XmTextField { + arguments { + name = 'fadeSecondsText'; + XmNcolumns= 5; + }; +}; +object 'ticks_text' : XmTextField { + arguments { + name = 'fadeTicksText'; + XmNcolumns= 5; + }; +}; +object 'lock_time_text' : XmTextField { + arguments { + name = 'passwdText'; + XmNcolumns= 5; + }; +}; +object 'passwd_time_text' : XmTextField { + arguments { + name = 'lockText'; + XmNcolumns= 5; + }; +}; +object 'verbose_toggle' : XmToggleButton { + arguments { + name = 'verboseToggle'; + XmNlabelString= 'Verbose'; + XmNalignment= * 0; + }; +}; +object 'cmap_toggle' : XmToggleButton { + arguments { + name = 'cmapToggle'; + XmNlabelString= 'Install Colormap'; + XmNalignment= * 0; + }; +}; +object 'fade_toggle' : XmToggleButton { + arguments { + name = 'fadeToggle'; + XmNlabelString= 'Fade Colormap'; + XmNalignment= * 0; + }; +}; +object 'unfade_toggle' : XmToggleButton { + arguments { + name = 'unfadeToggle'; + XmNlabelString= 'Unfade Colormap'; + XmNalignment= * 0; + }; +}; +object 'lock_toggle' : XmToggleButton { + arguments { + name = 'lockToggle'; + XmNlabelString= 'Require Password'; + XmNalignment= * 0; + }; +}; +object '' : XmSeparator { + arguments { + }; +}; +object 'res_done' : XmPushButton { + arguments { + name = 'resourcesDone'; + XmNlabelString= 'Done'; + }; +}; +object 'res_cancel' : XmPushButton { + arguments { + name = 'resourcesCancel'; + XmNlabelString= 'Cancel'; + }; +}; + attachments { + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNtopAttachment = 1 0 4; + }; + attachment { + XmNrightAttachment = 1 0 0; + XmNleftAttachment = 1 0 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 1 4; + }; + attachment { + XmNrightAttachment = 3 9 4; + XmNleftAttachment = 1 0 20; + XmNbottomAttachment = 4 9; + XmNtopAttachment = 3 2 4; + }; + attachment { + XmNrightAttachment = 3 10 4; + XmNleftAttachment = 1 0 20; + XmNbottomAttachment = 4 10 0; + XmNtopAttachment = 4 10 0; + }; + attachment { + XmNrightAttachment = 3 11 4; + XmNleftAttachment = 1 0 20; + XmNbottomAttachment = 4 11 0; + XmNtopAttachment = 4 11 0; + }; + attachment { + XmNrightAttachment = 3 12 4; + XmNleftAttachment = 1 0 20; + XmNbottomAttachment = 4 12 0; + XmNtopAttachment = 4 12 0; + }; + attachment { + XmNrightAttachment = 3 13 4; + XmNleftAttachment = 1 0 19; + XmNbottomAttachment = 4 13 0; + XmNtopAttachment = 4 13 0; + }; + attachment { + XmNrightAttachment = 3 14 4; + XmNleftAttachment = 1 0 14; + XmNbottomAttachment = 4 14 0; + XmNtopAttachment = 4 14 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 1 0 141; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 2 4; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 4 9 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 9 2; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 4 10 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 10 2; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 4 11 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 11 2; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 4 12 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 12 2; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 4 13 0; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 13 4; + }; + attachment { + XmNrightAttachment = 1 0 20; + XmNleftAttachment = 3 9 20; + XmNbottomAttachment = 4 9 0; + XmNtopAttachment = 3 2 4; + }; + attachment { + XmNrightAttachment = 1 0 20; + XmNleftAttachment = 4 15 0; + XmNbottomAttachment = 4 10 0; + XmNtopAttachment = 4 10 0; + }; + attachment { + XmNrightAttachment = 1 0 20; + XmNleftAttachment = 4 16 0; + XmNbottomAttachment = 4 11 0; + XmNtopAttachment = 4 11 0; + }; + attachment { + XmNrightAttachment = 1 0 20; + XmNleftAttachment = 4 17 0; + XmNbottomAttachment = 4 12 0; + XmNtopAttachment = 4 12 0; + }; + attachment { + XmNrightAttachment = 1 0 20; + XmNleftAttachment = 4 18 0; + XmNbottomAttachment = 4 13 0; + XmNtopAttachment = 4 13 0; + }; + attachment { + XmNrightAttachment = 1 0; + XmNleftAttachment = 1 0; + XmNbottomAttachment = 3 21 4; + XmNtopAttachment = 3 14 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 21 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 0 0 0; + }; + }; +}; +}; +object 'demo_dialog' : XmDialogShell { + arguments { + name = 'demoDialog'; + XmNtitle= 'XScreenSaver'; + XmNmaxWidth= 500; + XmNallowShellResize= true; + }; +object 'demo_form' : XmForm { + arguments { + name = 'demoForm'; + XmNautoUnmanage= false; + }; +object 'label1' : XmLabel { + arguments { + name = 'label1'; + XmNlabelString= 'XScreenSaver %s'; + }; +}; +object 'label2' : XmLabel { + arguments { + name = 'label2'; + XmNlabelString= 'Copyright © 1991-1994 by Jamie Zawinski '; + }; +}; +object 'text_area' : XmScrolledList { + arguments { + name = 'textArea'; + }; +object '' : XmScrollBar { + arguments { + name = 'ListhScrollBar'; + }; +}; +object '' : XmScrollBar { + arguments { + name = 'ListvScrollBar'; + }; +}; +object 'demo_list' : XmList { + arguments { + name = 'demoList'; + XmNvisibleItemCount= 10; + XmNautomaticSelection= true; + XmNlistSizePolicy= 2; + }; +}; +}; +object 'text_line' : XmTextField { + arguments { + name = 'textLine'; + }; +}; +object 'vline' : XmSeparator { + arguments { + name = 'vline'; + }; +}; +object 'next' : XmPushButton { + arguments { + name = 'next'; + XmNlabelString= 'Run Next'; + }; +}; +object 'prev' : XmPushButton { + arguments { + name = 'prev'; + XmNlabelString= 'Run Previous'; + }; +}; +object 'edit' : XmPushButton { + arguments { + name = 'edit'; + XmNlabelString= 'Edit Parameters'; + }; +}; +object 'done' : XmPushButton { + arguments { + name = 'done'; + XmNlabelString= 'Exit Demo Mode'; + }; +}; +object 'restart' : XmPushButton { + arguments { + name = 'restart'; + XmNlabelString= 'Restart Screen Saver'; + }; +}; +object 'spacer' : XmLabel { + arguments { + name = 'spacer'; + XmNlabelString= * ' '; + }; +}; + attachments { + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 1 0 5; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 0 0 0; + XmNtopAttachment = 3 1 4; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 3 4 4; + XmNtopAttachment = 3 2 4; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 3 5 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 1 0 4; + XmNbottomAttachment = 3 6 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 1 0 3; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 0 0 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 6 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 4 6 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 7 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 4 7 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 8 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 4 8 0; + }; + attachment { + XmNrightAttachment = 0 0 0; + XmNleftAttachment = 3 9 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 4 9 0; + }; + attachment { + XmNrightAttachment = 1 0 4; + XmNleftAttachment = 3 10 4; + XmNbottomAttachment = 1 0 4; + XmNtopAttachment = 4 10 0; + }; + }; +}; +}; +end module; diff --git a/driver/kpasswd.c b/driver/kpasswd.c new file mode 100644 index 00000000..ee115213 --- /dev/null +++ b/driver/kpasswd.c @@ -0,0 +1,180 @@ +/* kpasswd.c --- verify kerberos passwords. + * written by Nat Lanza (magus@cs.cmu.edu) for + * xscreensaver, Copyright (c) 1993-1997 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#ifndef NO_LOCKING /* whole file */ + +#include +#ifdef HAVE_UNISTD_H +# include +#endif + +#include +#include +#include +#include +#include + +#if !defined(VMS) && !defined(HAVE_ADJUNCT_PASSWD) +# include +#endif + + +#ifdef __bsdi__ +# include +# if _BSDI_VERSION >= 199608 +# define BSD_AUTH +# endif +#endif /* __bsdi__ */ + +/* blargh */ +#undef Bool +#undef True +#undef False +#define Bool int +#define True 1 +#define False 0 + +/* The user information we need to store */ +static char realm[REALM_SZ]; +static char name[ANAME_SZ]; +static char inst[INST_SZ]; +static char *tk_file; + + +/* Called at startup to grab user, instance, and realm information + from the user's ticketfile (remember, name.inst@realm). Since we're + using tf_get_pname(), this should work even if your kerberos username + isn't the same as your local username. We grab the ticket at startup + time so that even if your ticketfile dies while the screen's locked + we'll still have the information to unlock it. + + Problems: the password dialog currently displays local username, so if + you have some non-standard name/instance when you run xscreensaver, + you'll need to remember what it was when unlocking, or else you lose. + + Also, we use des_string_to_key(), so if you have an AFS password + (encrypted with ka_StringToKey()), you'll lose. Get a kerberos password; + it isn't that hard. + + Like the original lock_init, we return false if something went wrong. + We don't use the arguments we're given, though. + */ +Bool +lock_init (int argc, char **argv) +{ + int k_errno; + + memset(name, 0, sizeof(name)); + memset(inst, 0, sizeof(inst)); + + /* find out where the user's keeping his tickets. + squirrel it away for later use. */ + tk_file = tkt_string(); + + /* open ticket file or die trying. */ + if ((k_errno = tf_init(tk_file, R_TKT_FIL))) { + return False; + } + + /* same with principal and instance names */ + if ((k_errno = tf_get_pname(name)) || + (k_errno = tf_get_pinst(inst))) { + return False; + } + + /* close the ticketfile to release the lock on it. */ + tf_close(); + + /* figure out what realm we're authenticated to. this ought + to be the local realm, but it pays to be sure. */ + if ((k_errno = krb_get_tf_realm(tk_file, realm))) { + return False; + } + + /* last-minute sanity check on what we got. */ + if ((strlen(name)+strlen(inst)+strlen(realm)+3) > + (REALM_SZ + ANAME_SZ + INST_SZ + 3)) { + return False; + } + + /* success */ + return True; +} + + +/* des_string_to_key() wants this. If C didn't suck, we could have an + anonymous function do this. Even a local one. But it does, so here + we are. Calling it ive_got_your_local_function_right_here_buddy() + would have been rude. + */ +static int +key_to_key(char *user, char *instance, char *realm, char *passwd, C_Block key) +{ + memcpy(key, passwd, sizeof(des_cblock)); + return (0); +} + +/* Called to see if the user's typed password is valid. We do this by asking + the kerberos server for a ticket and checking to see if it gave us one. + We need to move the ticketfile first, or otherwise we end up updating the + user's tkfile with new tickets. This would break services like zephyr that + like to stay authenticated, and it would screw with AFS authentication at + some sites. So, we do a quick, painful hack with a tmpfile. + */ +Bool +passwd_valid_p (const char *typed_passwd) +{ + C_Block mitkey; + Bool success; + char *newtkfile; + + /* temporarily switch to a new ticketfile. + I'm not using tmpnam() because it isn't entirely portable. + this could probably be fixed with autoconf. */ + newtkfile = malloc(80 * sizeof(char)); + memset(newtkfile, 0, sizeof(newtkfile)); + + sprintf(newtkfile, "/tmp/xscrn-%i", getpid()); + + krb_set_tkt_string(newtkfile); + + /* encrypt the typed password. if you have an AFS password instead + of a kerberos one, you lose *right here*. If you want to use AFS + passwords, you can use ka_StringToKey() instead. As always, ymmv. */ + des_string_to_key(typed_passwd, mitkey); + + if (krb_get_in_tkt(name, inst, realm, "krbtgt", realm, DEFAULT_TKT_LIFE, + key_to_key, NULL, mitkey) != 0) { + success = False; + } else { + success = True; + } + + /* quickly block out the tempfile and password to prevent snooping, + then restore the old ticketfile and cleean up a bit. */ + + dest_tkt(); + krb_set_tkt_string(tk_file); + free(newtkfile); + memset(mitkey, 0, sizeof(mitkey)); + + + /* Did we verify successfully? */ + return success; +} + +#endif /* NO_LOCKING -- whole file */ diff --git a/driver/link_axp.com b/driver/link_axp.com new file mode 100644 index 00000000..a1418927 --- /dev/null +++ b/driver/link_axp.com @@ -0,0 +1,15 @@ +$! We fisrt test the version of DECW/Motif ; if 1.2 we need to link with new +$! X11R5 libraries +$@sys$update:decw$get_image_version sys$share:decw$xlibshr.exe decw$version +$ if f$extract(4,3,decw$version).eqs."1.2" +$ then +$! DECW/Motif 1.2 : link with X11R5 libraries +$ link xscreensaver-command,vms_axp_12.opt/opt +$ link xscreensaver,demo,dialogs-xm,lock,passwd,stderr,subprocs,timers, - + windows,xset,vms-getpwnam,vms-hpwd,vms-validate,vms_axp_12.opt/opt +$ else +$! Else, link with X11R4 libraries +$ link xscreensaver-command,vms_axp.opt/opt +$ link xscreensaver,demo,dialogs-xm,lock,passwd,stderr,subprocs,timers, - + windows,xset,vms-getpwnam,vms-hpwd,vms-validate,vms_axp.opt/opt +$ endif diff --git a/driver/link_decc.com b/driver/link_decc.com new file mode 100644 index 00000000..d1de0d0a --- /dev/null +++ b/driver/link_decc.com @@ -0,0 +1,15 @@ +$! We fisrt test the version of DECW/Motif ; if 1.2 we need to link with new +$! X11R5 libraries +$@sys$update:decw$get_image_version sys$share:decw$xlibshr.exe decw$version +$ if f$extract(4,3,decw$version).eqs."1.2" +$ then +$! DECW/Motif 1.2 : link with X11R5 libraries +$ link xscreensaver-command,vms_decc_12.opt/opt +$ link xscreensaver,demo,dialogs-xm,lock,passwd,stderr,subprocs,timers, - + windows,xset,vms-getpwnam,vms-hpwd,vms-validate,vms_decc_12.opt/opt +$ else +$! Else, link with X11R4 libraries +$ link xscreensaver-command,vms_decc.opt/opt +$ link xscreensaver,demo,dialogs-xm,lock,passwd,stderr,subprocs,timers, - + windows,xset,vms-getpwnam,vms-hpwd,vms-validate,vms_decc.opt/opt +$ endif diff --git a/driver/lock.c b/driver/lock.c new file mode 100644 index 00000000..a79d2135 --- /dev/null +++ b/driver/lock.c @@ -0,0 +1,735 @@ +/* lock.c --- handling the password dialog for locking-mode. + * xscreensaver, Copyright (c) 1993-1997 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. + */ + +/* Athena locking code contributed by Jon A. Christopher */ +/* Copyright 1997, with the same permissions as above. */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#ifndef NO_LOCKING /* whole file */ + +#include +#include +#include "xscreensaver.h" + +#ifndef VMS +# include +#else /* VMS */ +extern char *getenv(const char *name); +extern int validate_user(char *name, char *password); +static char * user_vms; +#endif /* VMS */ + + +#ifdef HAVE_ATHENA + +# include +# include +# include +# include +# include + +static void passwd_done_cb (Widget, XtPointer, XtPointer); +static XtActionsRec actionsList[] = +{ + {"passwdentered", (XtActionProc) passwd_done_cb}, +}; + +static char Translations[] = +"\ +Return: passwdentered()\ +"; + +#else /* HAVE_MOTIF */ + +# include +# include +# include + +#endif /* HAVE_MOTIF */ + +extern Widget passwd_dialog; +extern Widget passwd_form; +extern Widget roger_label; +extern Widget passwd_label1; +extern Widget passwd_label3; +extern Widget passwd_cancel; + +#ifdef HAVE_MOTIF +extern Widget passwd_text; +extern Widget passwd_done; +#else /* HAVE_ATHENA */ +static Widget passwd_text = 0; /* gag... */ +static Widget passwd_done = 0; +#endif /* HAVE_ATHENA */ + + + +static enum { pw_read, pw_ok, pw_fail, pw_cancel, pw_time } passwd_state; +static char typed_passwd [80]; + + +#if defined(HAVE_ATHENA) || (XmVersion >= 1002) + /* The `destroy' bug apears to be fixed as of Motif 1.2.1, but + the `verify-callback' bug is still present. */ +# define DESTROY_WORKS +#endif + +static void +passwd_cancel_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + passwd_state = pw_cancel; +} + +static void +passwd_done_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + if (passwd_state != pw_read) return; /* already done */ +#ifndef VMS + +# ifdef HAVE_ATHENA + strncpy(typed_passwd, XawDialogGetValueString(passwd_form), + sizeof(typed_passwd)-1); + typed_passwd[sizeof(typed_passwd)-1] = 0; +# endif /* HAVE_ATHENA */ + if (passwd_valid_p (typed_passwd)) + passwd_state = pw_ok; + else + passwd_state = pw_fail; + +#else /* VMS */ + user_vms = getenv("USER"); + if (validate_user(user_vms,typed_passwd) == 1) + passwd_state = pw_ok; + else + passwd_state = pw_fail; +#endif /* VMS */ +} + +#if defined(HAVE_MOTIF) && defined(VERIFY_CALLBACK_WORKS) + + /* It looks to me like adding any modifyVerify callback causes + Motif 1.1.4 to free the the TextF_Value() twice. I can't see + the bug in the Motif source, but Purify complains, even if + check_passwd_cb() is a no-op. + + Update: Motif 1.2.1 also loses, but in a different way: it + writes beyond the end of a malloc'ed block in ModifyVerify(). + Probably this block is the text field's text. + */ + +static void +check_passwd_cb (Widget button, XtPointer client_data, XtPointer call_data) +{ + XmTextVerifyCallbackStruct *vcb = (XmTextVerifyCallbackStruct *) call_data; + + if (passwd_state != pw_read) + return; + else if (vcb->reason == XmCR_ACTIVATE) + { + passwd_done_cb (0, 0, 0); + } + else if (vcb->text->length > 1) /* don't allow "paste" operations */ + { + vcb->doit = False; + } + else if (vcb->text->ptr != 0) + { + int i; + int L = vcb->text->length; + if (L >= sizeof(typed_passwd)) + L = sizeof(typed_passwd)-1; + strncat (typed_passwd, vcb->text->ptr, L); + typed_passwd [vcb->endPos + L] = 0; + for (i = 0; i < vcb->text->length; i++) + vcb->text->ptr [i] = '*'; + } +} + +# else /* HAVE_ATHENA || !VERIFY_CALLBACK_WORKS */ + +static void keypress (Widget w, XEvent *event, String *av, Cardinal *ac); +static void backspace (Widget w, XEvent *event, String *av, Cardinal *ac); +static void kill_line (Widget w, XEvent *event, String *av, Cardinal *ac); +static void done (Widget w, XEvent *event, String *av, Cardinal *ac); + +static XtActionsRec actions[] = {{"keypress", keypress}, + {"backspace", backspace}, + {"kill_line", kill_line}, + {"done", done} + }; + +# ifdef HAVE_MOTIF +# if 0 /* oh fuck, why doesn't this work? */ +static char translations[] = "\ +BackSpace: backspace()\n\ +Delete: backspace()\n\ +CtrlH: backspace()\n\ +CtrlU: kill_line()\n\ +CtrlX: kill_line()\n\ +CtrlJ: done()\n\ +CtrlM: done()\n\ +: keypress()\n\ +"; +# else /* !0 */ +static char translations[] = ":keypress()"; +# endif /* !0 */ +# endif /* HAVE_MOTIF */ + + +static void +text_field_set_string (Widget widget, char *text, int position) +{ +#ifdef HAVE_MOTIF + XmTextFieldSetString (widget, text); + XmTextFieldSetInsertionPosition (widget, position); + +#else /* HAVE_ATHENA */ + char *buf; + int end_pos; + + XawTextBlock block; + block.firstPos = 0; + block.length = strlen (text); + block.ptr = text; + block.format = 0; + if (block.length == 0) + { + buf = XawDialogGetValueString(passwd_form); + if (buf) + end_pos = strlen(buf); + else + end_pos = -1; + } + XawTextReplace (widget, 0, end_pos, &block); + XawTextSetInsertionPoint (widget, position); +#endif /* HAVE_ATHENA */ +} + + +static void +keypress (Widget w, XEvent *event, String *argv, Cardinal *argc) +{ + int i, j; + char s [sizeof(typed_passwd)]; + int size = XLookupString ((XKeyEvent *) event, s, sizeof(s)-1, 0, 0); + if (size != 1) return; + + /* hack because I can't get translations to dance to my tune... */ + if (*s == '\010') { backspace (w, event, argv, argc); return; } + if (*s == '\177') { backspace (w, event, argv, argc); return; } + if (*s == '\025') { kill_line (w, event, argv, argc); return; } + if (*s == '\030') { kill_line (w, event, argv, argc); return; } + if (*s == '\012') { done (w, event, argv, argc); return; } + if (*s == '\015') { done (w, event, argv, argc); return; } + + i = j = strlen (typed_passwd); + + if (i >= (sizeof(typed_passwd)-1)) + { + XBell(XtDisplay(w), 0); + return; + } + + typed_passwd [i] = *s; + s [++i] = 0; + while (i--) + s [i] = '*'; + + text_field_set_string (passwd_text, s, j + 1); +} + +static void +backspace (Widget w, XEvent *event, String *argv, Cardinal *argc) +{ + char s [sizeof(typed_passwd)]; + int i = strlen (typed_passwd); + int j = i; + if (i == 0) + return; + typed_passwd [--i] = 0; + s [i] = 0; + while (i--) + s [i] = '*'; + + text_field_set_string (passwd_text, s, j + 1); +} + +static void +kill_line (Widget w, XEvent *event, String *argv, Cardinal *argc) +{ + memset (typed_passwd, 0, sizeof(typed_passwd)); + text_field_set_string (passwd_text, "", 0); +} + +static void +done (Widget w, XEvent *event, String *argv, Cardinal *argc) +{ + passwd_done_cb (w, 0, 0); +} + +#endif /* HAVE_ATHENA || !VERIFY_CALLBACK_WORKS */ + + +extern void skull (Display *, Window, GC, GC, int, int, int, int); + +static void +roger (Widget button, XtPointer client_data, XtPointer call_data) +{ + Display *dpy = XtDisplay (button); + Screen *screen = XtScreen (button); + Window window = XtWindow (button); + Arg av [10]; + int ac = 0; + XGCValues gcv; + Colormap cmap; + GC draw_gc, erase_gc; + unsigned int fg, bg; + int x, y, size; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + if (xgwa.width > xgwa.height) size = xgwa.height; + else size = xgwa.width; + if (size > 40) size -= 30; + x = (xgwa.width - size) / 2; + y = (xgwa.height - size) / 2; + XtSetArg (av [ac], XtNforeground, &fg); ac++; + XtSetArg (av [ac], XtNbackground, &bg); ac++; + XtGetValues (button, av, ac); + /* if it's black on white, swap it cause it looks better (hack hack) */ + if (fg == BlackPixelOfScreen (screen) && bg == WhitePixelOfScreen (screen)) + fg = WhitePixelOfScreen (screen), bg = BlackPixelOfScreen (screen); + gcv.foreground = bg; + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = fg; + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + XFillRectangle (dpy, window, erase_gc, 0, 0, xgwa.width, xgwa.height); + skull (dpy, window, draw_gc, erase_gc, x, y, size, size); + XFreeGC (dpy, draw_gc); + XFreeGC (dpy, erase_gc); +} + +static void +make_passwd_dialog (saver_info *si) +{ + char *username = 0; + saver_screen_info *ssi = si->default_screen; + Widget parent = ssi->toplevel_shell; + + if (ssi->demo_cmap && + ssi->demo_cmap != ssi->cmap && + ssi->demo_cmap != DefaultColormapOfScreen (ssi->screen)) + { + XFreeColormap (si->dpy, ssi->demo_cmap); + ssi->demo_cmap = 0; + } + + if (ssi->default_visual == DefaultVisualOfScreen (ssi->screen)) + ssi->demo_cmap = DefaultColormapOfScreen (ssi->screen); + else + ssi->demo_cmap = XCreateColormap (si->dpy, + RootWindowOfScreen (ssi->screen), + ssi->default_visual, AllocNone); + + create_passwd_dialog (parent, ssi->default_visual, ssi->demo_cmap); + +#ifdef HAVE_ATHENA + + XtVaSetValues(passwd_form, XtNvalue, typed_passwd, 0); + + XawDialogAddButton(passwd_form,"ok", passwd_done_cb, 0); + XawDialogAddButton(passwd_form,"cancel", passwd_cancel_cb, 0); + passwd_done = XtNameToWidget(passwd_form,"ok"); + passwd_text = XtNameToWidget(passwd_form,"value"); + + XtAppAddActions(XtWidgetToApplicationContext(passwd_text), + actionsList, XtNumber(actionsList)); + XtOverrideTranslations(passwd_text, XtParseTranslationTable(Translations)); + +#else /* HAVE_MOTIF */ + + XtAddCallback (passwd_done, XmNactivateCallback, passwd_done_cb, 0); + XtAddCallback (passwd_cancel, XmNactivateCallback, passwd_cancel_cb, 0); + XtAddCallback (roger_label, XmNexposeCallback, roger, 0); + +# ifdef VERIFY_CALLBACK_WORKS + XtAddCallback (passwd_text, XmNmodifyVerifyCallback, check_passwd_cb, 0); + XtAddCallback (passwd_text, XmNactivateCallback, check_passwd_cb, 0); +# else + XtAddCallback (passwd_text, XmNactivateCallback, passwd_done_cb, 0); + XtOverrideTranslations (passwd_text, XtParseTranslationTable (translations)); +# endif + +# if defined(HAVE_MOTIF) && (XmVersion >= 1002) + /* The focus stuff changed around; this didn't exist in 1.1.5. */ + XtVaSetValues (passwd_form, XmNinitialFocus, passwd_text, 0); +# endif + + /* Another random thing necessary in 1.2.1 but not 1.1.5... */ + XtVaSetValues (roger_label, XmNborderWidth, 2, 0); + +#endif /* HAVE_MOTIF */ + +#ifndef VMS + { + struct passwd *pw = getpwuid (getuid ()); + username = pw->pw_name; + } +#else /* VMS -- from "R.S.Niranjan" who says + that on OpenVMS 6.1, using `struct passwd' crashes... */ + username = getenv("USER"); +#endif /* VMS */ + + format_into_label (passwd_label1, si->version); + format_into_label (passwd_label3, (username ? username : "???")); +} + +static int passwd_idle_timer_tick = -1; +static XtIntervalId passwd_idle_id; + +static void +passwd_idle_timer (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + saver_preferences *p = &si->prefs; + + Display *dpy = XtDisplay (passwd_form); +#ifdef HAVE_ATHENA + Window window = XtWindow (passwd_form); +#else /* MOTIF */ + Window window = XtWindow (XtParent(passwd_done)); +#endif /* MOTIF */ + static Dimension x, y, d, s, ss; + static GC gc = 0; + int max = p->passwd_timeout / 1000; + + idle_timer ((XtPointer) si, id); + + if (passwd_idle_timer_tick == max) /* first time */ + { + XGCValues gcv; +#ifdef HAVE_MOTIF + unsigned long fg = 0, bg = 0, ts = 0, bs = 0; + Dimension w = 0, h = 0; + XtVaGetValues(XtParent(passwd_done), + XmNwidth, &w, + 0); + XtVaGetValues(passwd_done, + XmNheight, &h, + XmNy, &y, + XtNforeground, &fg, + XtNbackground, &bg, + XmNtopShadowColor, &ts, + XmNbottomShadowColor, &bs, + 0); + + if (ts != bg && ts != fg) + fg = ts; + if (bs != bg && bs != fg) + fg = bs; + + d = h / 2; + if (d & 1) d++; + + x = (w / 2); + + x -= d/2; + y += d/2; + +#else /* HAVE_ATHENA */ + + Arg av [100]; + int ac = 0; + unsigned long fg = 0, bg = 0; + XtSetArg (av [ac], XtNheight, &d); ac++; + XtGetValues (passwd_done, av, ac); + ac = 0; + XtSetArg (av [ac], XtNwidth, &x); ac++; + XtSetArg (av [ac], XtNheight, &y); ac++; + XtSetArg (av [ac], XtNforeground, &fg); ac++; + XtSetArg (av [ac], XtNbackground, &bg); ac++; + XtGetValues (passwd_form, av, ac); + x -= d; + y -= d; + d -= 4; + +#endif /* HAVE_ATHENA */ + + gcv.foreground = fg; + if (gc) XFreeGC (dpy, gc); + gc = XCreateGC (dpy, window, GCForeground, &gcv); + s = 360*64 / (passwd_idle_timer_tick - 1); + ss = 90*64; + XFillArc (dpy, window, gc, x, y, d, d, 0, 360*64); + XSetForeground (dpy, gc, bg); + x += 1; + y += 1; + d -= 2; + } + + if (--passwd_idle_timer_tick) + { + passwd_idle_id = XtAppAddTimeOut (si->app, 1000, passwd_idle_timer, + (XtPointer) si); + XFillArc (dpy, window, gc, x, y, d, d, ss, s); + ss += s; + } +} + + +#ifdef HAVE_ATHENA + +void +pop_up_athena_dialog_box (Widget parent, Widget focus, Widget dialog, + Widget form, int where) +{ + /* modified from demo.c */ + /* I'm sure this is the wrong way to pop up a dialog box, but I can't + figure out how else to do it. + + It's important that the screensaver dialogs not get decorated or + otherwise reparented by the window manager, because they need to be + children of the *real* root window, not the WM's virtual root, in + order for us to guarentee that they are visible above the screensaver + window itself. + */ + Arg av [100]; + int ac = 0; + Dimension sw, sh, x, y, w, h; + + XtRealizeWidget(dialog); + sw = WidthOfScreen (XtScreen (dialog)); + sh = HeightOfScreen (XtScreen (dialog)); + ac = 0; + XtSetArg (av [ac], XtNwidth, &w); ac++; + XtSetArg (av [ac], XtNheight, &h); ac++; + XtGetValues (form, av, ac); + switch (where) + { + case 0: /* center it in the top-right quadrant */ + x = (sw/2 + w) / 2 + (sw/2) - w; + y = (sh/2 + h) / 2 - h; + break; + case 1: /* center it in the bottom-right quadrant */ + x = (sw/2 + w) / 2 + (sw/2) - w; + y = (sh/2 + h) / 2 + (sh/2) - h; + break; + case 2: /* center it on the screen */ + x = (sw + w) / 2 - w; + y = (sh + h) / 2 - h; + break; + default: + abort (); + } + if (x + w > sw) x = sw - w; + if (y + h > sh) y = sh - h; + ac = 0; + XtVaSetValues(dialog, + XtNx, x, + XtNy, y, + NULL); + XtVaSetValues(form, + XtNx, x, + XtNy, y, + NULL); + XtPopup(dialog,XtGrabNone); + steal_focus_and_colormap (focus); +} + +static void +passwd_set_label (char *buf, int len) +{ + Widget label; + if (!passwd_text) + return; + label=XtNameToWidget(XtParent(passwd_text),"*label"); + XtVaSetValues(label, + XtNlabel, buf, + NULL); +} +#endif /* HAVE_ATHENA */ + +static Bool +pop_passwd_dialog (saver_info *si) +{ + saver_preferences *p = &si->prefs; + saver_screen_info *ssi = si->default_screen; + Widget parent = ssi->toplevel_shell; + Display *dpy = XtDisplay (passwd_dialog); + Window focus; + int revert_to; + int i; + + typed_passwd [0] = 0; + passwd_state = pw_read; + text_field_set_string (passwd_text, "", 0); + + /* In case one of the hacks has unmapped it temporarily... + Get that sucker on stage now! */ + for (i = 0; i < si->nscreens; i++) + XMapRaised(si->dpy, si->screens[i].screensaver_window); + + XGetInputFocus (dpy, &focus, &revert_to); +#if defined(HAVE_MOTIF) && !defined(DESTROY_WORKS) + /* This fucker blows up if we destroy the widget. I can't figure + out why. The second destroy phase dereferences freed memory... + So we just keep it around; but unrealizing or unmanaging it + doesn't work right either, so we hack the window directly. FMH. + */ + if (XtWindow (passwd_form)) + XMapRaised (dpy, XtWindow (passwd_dialog)); +#endif + +#ifdef HAVE_ATHENA + pop_up_athena_dialog_box (parent, passwd_text, passwd_dialog, + passwd_form, 2); +#else + pop_up_dialog_box (passwd_dialog, passwd_form, +#ifdef DEBUG + (si->prefs.debug_p ? 69 : 0) + +#endif + 2); + XtManageChild (passwd_form); +#endif + +#if defined(HAVE_MOTIF) && (XmVersion < 1002) + /* The focus stuff changed around; this causes problems in 1.2.1 + but is necessary in 1.1.5. */ + XmProcessTraversal (passwd_text, XmTRAVERSE_CURRENT); +#endif + + passwd_idle_timer_tick = p->passwd_timeout / 1000; + passwd_idle_id = XtAppAddTimeOut (si->app, 1000, passwd_idle_timer, + (XtPointer) si); + +#ifdef HAVE_ATHENA + if (roger_label) + roger(roger_label, 0, 0); +#endif /* HAVE_ATHENA */ + +#ifdef DEBUG + if (!si->prefs.debug_p) +#endif + XGrabServer (dpy); /* ############ DANGER! */ + + /* this call to ungrab used to be in main_loop() - see comment in + xscreensaver.c around line 857. */ + ungrab_keyboard_and_mouse (si->dpy); + + while (passwd_state == pw_read) + { + XEvent event; + XtAppNextEvent (si->app, &event); + /* wait for timer event */ + if (event.xany.type == 0 && passwd_idle_timer_tick == 0) + passwd_state = pw_time; + XtDispatchEvent (&event); + } + XUngrabServer (dpy); + XSync (dpy, False); /* ###### (danger over) */ + + if (passwd_state != pw_time) + XtRemoveTimeOut (passwd_idle_id); + + if (passwd_state != pw_ok) + { + char *lose; + switch (passwd_state) + { + case pw_time: lose = "Timed out!"; break; + case pw_fail: lose = "Sorry!"; break; + case pw_cancel: lose = 0; break; + default: abort (); + } +#ifdef HAVE_MOTIF + XmProcessTraversal (passwd_cancel, 0); /* turn off I-beam */ +#endif + if (lose) + { +#ifdef HAVE_ATHENA + /* show the message */ + passwd_set_label(lose,strlen(lose)+1); + + /* and clear the password line */ + memset(typed_passwd, 0, sizeof(typed_passwd)); + text_field_set_string (passwd_text, "", 0); +#else + text_field_set_string (passwd_text, lose, strlen (lose) + 1); +#endif + passwd_idle_timer_tick = 1; + passwd_idle_id = XtAppAddTimeOut (si->app, 3000, passwd_idle_timer, + (XtPointer) si); + while (1) + { + XEvent event; + XtAppNextEvent (si->app, &event); + if (event.xany.type == 0 && /* wait for timer event */ + passwd_idle_timer_tick == 0) + break; + XtDispatchEvent (&event); + } + } + } + memset (typed_passwd, 0, sizeof(typed_passwd)); + text_field_set_string (passwd_text, "", 0); + XtSetKeyboardFocus (parent, None); + +#ifdef DESTROY_WORKS + XtDestroyWidget (passwd_dialog); + passwd_dialog = 0; +#else + XUnmapWindow (XtDisplay (passwd_dialog), XtWindow (passwd_dialog)); +#endif + { + XErrorHandler old_handler = XSetErrorHandler (BadWindow_ehandler); + /* I don't understand why this doesn't refocus on the old selected + window when MWM is running in click-to-type mode. The value of + `focus' seems to be correct. */ + XSetInputFocus (dpy, focus, revert_to, CurrentTime); + XSync (dpy, False); + XSetErrorHandler (old_handler); + } + + /* Since we installed our colormap to display the dialog properly, put + the old one back, so that the screensaver_window is now displayed + properly. */ + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->cmap) + XInstallColormap (si->dpy, ssi->cmap); + } + + return (passwd_state == pw_ok ? True : False); +} + +Bool +unlock_p (saver_info *si) +{ + static Bool initted = False; + if (! initted) + { +#ifndef VERIFY_CALLBACK_WORKS + XtAppAddActions (si->app, actions, XtNumber (actions)); +#endif + passwd_dialog = 0; + initted = True; + } + if (! passwd_dialog) + make_passwd_dialog (si); + return pop_passwd_dialog (si); +} + +#endif /* !NO_LOCKING -- whole file */ diff --git a/driver/passwd.c b/driver/passwd.c new file mode 100644 index 00000000..b0a4b8ad --- /dev/null +++ b/driver/passwd.c @@ -0,0 +1,240 @@ +/* passwd.c --- verifying typed passwords with the OS. + * xscreensaver, Copyright (c) 1993-1998 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#ifndef NO_LOCKING /* whole file */ + +#include +#ifdef HAVE_UNISTD_H +# include +#endif + +#include +#include +#include +#ifndef VMS +# include +#else /* VMS */ +# include "vms-pwd.h" +#endif /* VMS */ + + +#ifdef __bsdi__ +# include +# if _BSDI_VERSION >= 199608 +# define BSD_AUTH +# endif +#endif /* __bsdi__ */ + + +#if defined(HAVE_SHADOW_PASSWD) /* passwds live in /etc/shadow */ + +# include +# define PWTYPE struct spwd * +# define PWPSLOT sp_pwdp +# define GETPW getspnam + +#elif defined(HAVE_ENHANCED_PASSWD) /* passwds live in /tcb/files/auth/ */ + /* M.Matsumoto */ +# include +# include + +# define PWTYPE struct pr_passwd * +# define PWPSLOT ufld.fd_encrypt +# define GETPW getprpwnam + +#elif defined(HAVE_ADJUNCT_PASSWD) + +# include +# include +# include + +# define PWTYPE struct passwd_adjunct * +# define PWPSLOT pwa_passwd +# define GETPW getpwanam + +#elif defined(HAVE_HPUX_PASSWD) + +# include +# include + +# define PWTYPE struct s_passwd * +# define PWPSLOT pw_passwd +# define GETPW getspwnam +# define crypt bigcrypt + +#endif + + +/* blargh */ +#undef Bool +#undef True +#undef False +#define Bool int +#define True 1 +#define False 0 + + +extern char *progname; + +static char *encrypted_root_passwd = 0; +static char *encrypted_user_passwd = 0; + +#ifdef VMS +# define ROOT "SYSTEM" +#else +# define ROOT "root" +#endif + + + +#ifndef VMS + +static char * +user_name (void) +{ + /* I think that just checking $USER here is not the best idea. */ + + const char *u = 0; + + /* It has been reported that getlogin() returns the wrong user id on some + very old SGI systems... And I've seen it return the string "rlogin" + sometimes! Screw it, using getpwuid() should be enough... + */ +/* u = (char *) getlogin (); + */ + + /* getlogin() fails if not attached to a terminal; in that case, use + getpwuid(). (Note that in this case, we're not doing shadow stuff, since + all we're interested in is the name, not the password. So that should + still work. Right?) */ + if (!u || !*u) + { + struct passwd *p = getpwuid (getuid ()); + u = (p ? p->pw_name : 0); + } + + return (u ? strdup(u) : 0); +} + +#else /* VMS */ + +static char * +user_name (void) +{ + char *u = getenv("USER"); + return (u ? strdup(u) : 0); +} + +#endif /* VMS */ + + +static Bool +passwd_known_p (const char *pw) +{ + return (pw && + pw[0] != '*' && /* This would be sensible... */ + strlen(pw) > 4); /* ...but this is what Solaris does. */ +} + + +static char * +get_encrypted_passwd(const char *user) +{ + if (user && *user) + { +#ifdef PWTYPE + { /* First check the shadow passwords. */ + PWTYPE p = GETPW((char *) user); + if (p && passwd_known_p (p->PWPSLOT)) + return strdup(p->PWPSLOT); + } +#endif + { /* Check non-shadow passwords too. */ + struct passwd *p = getpwnam(user); + if (p && passwd_known_p (p->pw_passwd)) + return strdup(p->pw_passwd); + } + } + + fprintf (stderr, "%s: couldn't get password of \"%s\"\n", + progname, (user ? user : "(null)")); + + return 0; +} + + + +/* This has to be called before we've changed our effective user ID, + because it might need priveleges to get at the encrypted passwords. + Returns false if we weren't able to get any passwords, and therefore, + locking isn't possible. (It will also have written to stderr.) + */ + +#ifndef VMS + +Bool +lock_init (int argc, char **argv) +{ + char *u; + +#ifdef HAVE_ENHANCED_PASSWD + set_auth_parameters(argc, argv); + check_auth_parameters(); +#endif /* HAVE_DEC_ENHANCED */ + + u = user_name(); + encrypted_user_passwd = get_encrypted_passwd(u); + encrypted_root_passwd = get_encrypted_passwd(ROOT); + if (u) free (u); + + if (encrypted_user_passwd) + return True; + else + return False; +} + + +/* This can be called at any time, and says whether the typed password + belongs to either the logged in user (real uid, not effective); or + to root. + */ +Bool +passwd_valid_p (const char *typed_passwd) +{ + char *s = 0; /* note that on some systems, crypt() may return null */ + + if (encrypted_user_passwd && + (s = (char *) crypt (typed_passwd, encrypted_user_passwd)) && + !strcmp (s, encrypted_user_passwd)) + return True; + + /* do not allow root to have a null password. */ + else if (typed_passwd[0] && + encrypted_root_passwd && + (s = (char *) crypt (typed_passwd, encrypted_root_passwd)) && + !strcmp (s, encrypted_root_passwd)) + return True; + + else + return False; +} + +#else /* VMS */ +Bool lock_init (int argc, char **argv) { return True; } +#endif /* VMS */ + + +#endif /* NO_LOCKING -- whole file */ diff --git a/driver/stderr.c b/driver/stderr.c new file mode 100644 index 00000000..d2d4cc7b --- /dev/null +++ b/driver/stderr.c @@ -0,0 +1,451 @@ +/* stderr.c --- capturing stdout/stderr output onto the screensaver window. + * xscreensaver, Copyright (c) 1991-1997 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. + */ + +/* stderr hackery - Why Unix Sucks, reason number 32767. + */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include + +#include +#include + +#ifdef HAVE_UNISTD_H +# include +#endif + +#ifdef HAVE_FCNTL +# include +#endif + +#include + +#include "xscreensaver.h" +#include "resources.h" +#include "visual.h" + +FILE *real_stderr = 0; +FILE *real_stdout = 0; + + +/* It's ok for these to be global, since they refer to the one and only + stderr stream, not to a particular screen or window or visual. + */ +static char stderr_buffer [4096]; +static char *stderr_tail = 0; +static time_t stderr_last_read = 0; + +static void make_stderr_overlay_window (saver_screen_info *); + + +void +reset_stderr (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + +#ifdef DEBUG + if (si->prefs.debug_p) + fprintf ((real_stderr ? real_stderr : stderr), + "%s: resetting stderr\n", progname); +#endif + + ssi->stderr_text_x = 0; + ssi->stderr_text_y = 0; + + if (ssi->stderr_gc) + XFreeGC (si->dpy, ssi->stderr_gc); + ssi->stderr_gc = 0; + + if (ssi->stderr_overlay_window) + XDestroyWindow(si->dpy, ssi->stderr_overlay_window); + ssi->stderr_overlay_window = 0; + + if (ssi->stderr_cmap) + XFreeColormap(si->dpy, ssi->stderr_cmap); + ssi->stderr_cmap = 0; +} + +void +clear_stderr (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + ssi->stderr_text_x = 0; + ssi->stderr_text_y = 0; + if (ssi->stderr_overlay_window) + XClearWindow (si->dpy, ssi->stderr_overlay_window); +} + + +static void +print_stderr_1 (saver_screen_info *ssi, char *string) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + Display *dpy = si->dpy; + Screen *screen = ssi->screen; + Window window = (ssi->stderr_overlay_window ? + ssi->stderr_overlay_window : + ssi->screensaver_window); + int h_border = 20; + int v_border = 20; + char *head = string; + char *tail; + + /* In verbose mode, copy it to stderr as well. */ + if (p->verbose_p) + fprintf (real_stderr, "%s", string); + + if (! ssi->stderr_font) + { + char *font_name = get_string_resource ("font", "Font"); + if (!font_name) font_name = "fixed"; + ssi->stderr_font = XLoadQueryFont (dpy, font_name); + if (! ssi->stderr_font) ssi->stderr_font = XLoadQueryFont (dpy, "fixed"); + ssi->stderr_line_height = (ssi->stderr_font->ascent + + ssi->stderr_font->descent); + } + + if (! ssi->stderr_gc) + { + XGCValues gcv; + Pixel fg, bg; + Colormap cmap = ssi->cmap; + + if (!ssi->stderr_overlay_window && + get_boolean_resource("overlayStderr", "Boolean")) + { + make_stderr_overlay_window (ssi); + if (ssi->stderr_overlay_window) + window = ssi->stderr_overlay_window; + if (ssi->stderr_cmap) + cmap = ssi->stderr_cmap; + } + + fg = get_pixel_resource ("textForeground", "Foreground", dpy, cmap); + bg = get_pixel_resource ("textBackground", "Background", dpy, cmap); + gcv.font = ssi->stderr_font->fid; + gcv.foreground = fg; + gcv.background = bg; + ssi->stderr_gc = XCreateGC (dpy, window, + (GCFont | GCForeground | GCBackground), + &gcv); + } + + + if (ssi->stderr_cmap) + XInstallColormap(si->dpy, ssi->stderr_cmap); + + for (tail = string; *tail; tail++) + { + if (*tail == '\n' || *tail == '\r') + { + int maxy = HeightOfScreen (screen) - v_border - v_border; + if (tail != head) + XDrawImageString (dpy, window, ssi->stderr_gc, + ssi->stderr_text_x + h_border, + ssi->stderr_text_y + v_border + + ssi->stderr_font->ascent, + head, tail - head); + ssi->stderr_text_x = 0; + ssi->stderr_text_y += ssi->stderr_line_height; + head = tail + 1; + if (*tail == '\r' && *head == '\n') + head++, tail++; + + if (ssi->stderr_text_y > maxy - ssi->stderr_line_height) + { +#if 0 + ssi->stderr_text_y = 0; +#else + int offset = ssi->stderr_line_height * 5; + XCopyArea (dpy, window, window, ssi->stderr_gc, + 0, v_border + offset, + WidthOfScreen (screen), + (HeightOfScreen (screen) - v_border - v_border + - offset), + 0, v_border); + XClearArea (dpy, window, + 0, HeightOfScreen (screen) - v_border - offset, + WidthOfScreen (screen), offset, False); + ssi->stderr_text_y -= offset; +#endif + } + } + } + if (tail != head) + { + int direction, ascent, descent; + XCharStruct overall; + XDrawImageString (dpy, window, ssi->stderr_gc, + ssi->stderr_text_x + h_border, + ssi->stderr_text_y + v_border + + ssi->stderr_font->ascent, + head, tail - head); + XTextExtents (ssi->stderr_font, tail, tail - head, + &direction, &ascent, &descent, &overall); + ssi->stderr_text_x += overall.width; + } +} + +static void +make_stderr_overlay_window (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + unsigned long transparent_pixel = 0; + Visual *visual = get_overlay_visual (ssi->screen, &transparent_pixel); + if (visual) + { + int depth = visual_depth (ssi->screen, visual); + XSetWindowAttributes attrs; + unsigned long attrmask; + +#ifdef DEBUG + if (si->prefs.debug_p) + fprintf(real_stderr, + "%s: using overlay visual 0x%0x for stderr text layer.\n", + progname, (int) XVisualIDFromVisual (visual)); +#endif /* DEBUG */ + + ssi->stderr_cmap = XCreateColormap(si->dpy, + RootWindowOfScreen(ssi->screen), + visual, AllocNone); + + attrmask = (CWColormap | CWBackPixel | CWBackingPixel | CWBorderPixel | + CWBackingStore | CWSaveUnder); + attrs.colormap = ssi->stderr_cmap; + attrs.background_pixel = transparent_pixel; + attrs.backing_pixel = transparent_pixel; + attrs.border_pixel = transparent_pixel; + attrs.backing_store = NotUseful; + attrs.save_under = False; + + ssi->stderr_overlay_window = + XCreateWindow(si->dpy, ssi->screensaver_window, 0, 0, + WidthOfScreen(ssi->screen), HeightOfScreen(ssi->screen), + 0, depth, InputOutput, visual, attrmask, &attrs); + XMapRaised(si->dpy, ssi->stderr_overlay_window); + } +} + + +static void +print_stderr (saver_info *si, char *string) +{ + saver_preferences *p = &si->prefs; + int i; + + /* In verbose mode, copy it to stderr as well. */ + if (p->verbose_p) + fprintf (real_stderr, "%s", string); + + for (i = 0; i < si->nscreens; i++) + print_stderr_1 (&si->screens[i], string); +} + + +static void +stderr_popup_timer_fn (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + char *s = stderr_buffer; + if (*s) + { + /* If too much data was printed, then something has gone haywire, + so truncate it. */ + char *trailer = "\n\n<< stderr diagnostics have been truncated >>\n\n"; + int max = sizeof (stderr_buffer) - strlen (trailer) - 5; + if (strlen (s) > max) + strcpy (s + max, trailer); + /* Now show the user. */ + print_stderr (si, s); + } + + stderr_tail = stderr_buffer; + si->stderr_popup_timer = 0; +} + + +static void +stderr_callback (XtPointer closure, int *fd, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + char *s; + int left; + int size; + int read_this_time = 0; + + if (stderr_tail == 0) + stderr_tail = stderr_buffer; + + left = ((sizeof (stderr_buffer) - 2) - (stderr_tail - stderr_buffer)); + + s = stderr_tail; + *s = 0; + + /* Read as much data from the fd as we can, up to our buffer size. */ + if (left > 0) + { + while ((size = read (*fd, (void *) s, left)) > 0) + { + left -= size; + s += size; + read_this_time += size; + } + *s = 0; + } + else + { + char buf2 [1024]; + /* The buffer is full; flush the rest of it. */ + while (read (*fd, (void *) buf2, sizeof (buf2)) > 0) + ; + } + + stderr_tail = s; + stderr_last_read = time ((time_t *) 0); + + /* Now we have read some data that we would like to put up in a dialog + box. But more data may still be coming in - so don't pop up the + dialog right now, but instead, start a timer that will pop it up + a second from now. Should more data come in in the meantime, we + will be called again, and will reset that timer again. So the + dialog will only pop up when a second has elapsed with no new data + being written to stderr. + + However, if the buffer is full (meaning lots of data has been written) + then we don't reset the timer. + */ + if (read_this_time > 0) + { + if (si->stderr_popup_timer) + XtRemoveTimeOut (si->stderr_popup_timer); + + si->stderr_popup_timer = + XtAppAddTimeOut (si->app, 1 * 1000, stderr_popup_timer_fn, + (XtPointer) si); + } +} + +void +initialize_stderr (saver_info *si) +{ + static Boolean done = False; + int fds [2]; + int in, out; + int new_stdout, new_stderr; + int stdout_fd = 1; + int stderr_fd = 2; + int flags = 0; + Boolean stderr_dialog_p, stdout_dialog_p; + + if (done) return; + done = True; + + real_stderr = stderr; + real_stdout = stdout; + + stderr_dialog_p = get_boolean_resource ("captureStderr", "Boolean"); + stdout_dialog_p = get_boolean_resource ("captureStdout", "Boolean"); + + if (!stderr_dialog_p && !stdout_dialog_p) + return; + + if (pipe (fds)) + { + perror ("error creating pipe:"); + return; + } + + in = fds [0]; + out = fds [1]; + +# ifdef HAVE_FCNTL + +# if defined(O_NONBLOCK) + flags = O_NONBLOCK; +# elif defined(O_NDELAY) + flags = O_NDELAY; +# else + ERROR!! neither O_NONBLOCK nor O_NDELAY are defined. +# endif + + /* Set both sides of the pipe to nonblocking - this is so that + our reads (in stderr_callback) will terminate, and so that + out writes (in the client programs) will silently fail when + the pipe is full, instead of hosing the program. */ + if (fcntl (in, F_SETFL, flags) != 0) + { + perror ("fcntl:"); + return; + } + if (fcntl (out, F_SETFL, flags) != 0) + { + perror ("fcntl:"); + return; + } + +# endif /* !HAVE_FCNTL */ + + if (stderr_dialog_p) + { + FILE *new_stderr_file; + new_stderr = dup (stderr_fd); + if (new_stderr < 0) + { + perror ("could not dup() a stderr:"); + return; + } + if (! (new_stderr_file = fdopen (new_stderr, "w"))) + { + perror ("could not fdopen() the new stderr:"); + return; + } + real_stderr = new_stderr_file; + + close (stderr_fd); + if (dup2 (out, stderr_fd) < 0) + { + perror ("could not dup() a new stderr:"); + return; + } + } + + if (stdout_dialog_p) + { + FILE *new_stdout_file; + new_stdout = dup (stdout_fd); + if (new_stdout < 0) + { + perror ("could not dup() a stdout:"); + return; + } + if (! (new_stdout_file = fdopen (new_stdout, "w"))) + { + perror ("could not fdopen() the new stdout:"); + return; + } + real_stdout = new_stdout_file; + + close (stdout_fd); + if (dup2 (out, stdout_fd) < 0) + { + perror ("could not dup() a new stdout:"); + return; + } + } + + XtAppAddInput (si->app, in, (XtPointer) XtInputReadMask, stderr_callback, + (XtPointer) si); +} diff --git a/driver/subprocs.c b/driver/subprocs.c new file mode 100644 index 00000000..9070b81b --- /dev/null +++ b/driver/subprocs.c @@ -0,0 +1,1139 @@ +/* subprocs.c --- choosing, spawning, and killing screenhacks. + * xscreensaver, Copyright (c) 1991, 1992, 1993, 1995, 1997, 1998 + * 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include + +#include /* not used for much... */ + +#ifndef ESRCH +#include +#endif + +#include /* sys/resource.h needs this for timeval */ + +#ifndef VMS + +# include /* for setpriority() and PRIO_PROCESS */ +# include /* for waitpid() and associated macros */ + +#else /* VMS */ + +# if __DECC_VER >= 50200000 +# include +# endif + +# include +# include /* for close */ +# include /* for getpid */ +# define pid_t int +# define fork vfork + +#endif /* VMS */ + +#include /* for the signal names */ + +#ifndef NO_SETUID +#include /* for getpwnam() and struct passwd */ +#include /* for getgrgid() and struct group */ +#endif /* NO_SETUID */ + +#if !defined(SIGCHLD) && defined(SIGCLD) +#define SIGCHLD SIGCLD +#endif + +#ifdef HAVE_PUTENV +extern int putenv (/* const char * */); /* getenv() is in stdlib.h... */ +#endif +extern int kill (pid_t, int); /* signal() is in sys/signal.h... */ + +/* This file doesn't need the Xt headers, so stub these types out... */ +#undef XtPointer +#define XtAppContext void* +#define XrmDatabase void* +#define XtIntervalId void* +#define XtPointer void* +#define Widget void* + +#include "xscreensaver.h" +#include "yarandom.h" + + +extern saver_info *global_si_kludge; /* I hate C so much... */ + +static void hack_environment (saver_screen_info *ssi); + + +static void +nice_subproc (int nice_level) +{ + if (nice_level == 0) + return; + +#if defined(HAVE_NICE) + { + int old_nice = nice (0); + int n = nice_level - old_nice; + errno = 0; + if (nice (n) == -1 && errno != 0) + { + char buf [512]; + sprintf (buf, "%s: nice(%d) failed", progname, n); + perror (buf); + } + } +#elif defined(HAVE_SETPRIORITY) && defined(PRIO_PROCESS) + if (setpriority (PRIO_PROCESS, getpid(), nice_level) != 0) + { + char buf [512]; + sprintf (buf, "%s: setpriority(PRIO_PROCESS, %lu, %d) failed", + progname, (unsigned long) getpid(), nice_level); + perror (buf); + } +#else + fprintf (stderr, + "%s: don't know how to change process priority on this system.\n", + progname); + +#endif +} + + +#ifndef VMS + +static void +exec_simple_command (const char *command) +{ + char *av[1024]; + int ac = 0; + char *token = strtok (strdup(command), " \t"); + while (token) + { + av[ac++] = token; + token = strtok(0, " \t"); + } + av[ac] = 0; + + execvp (av[0], av); /* shouldn't return. */ + + { + char buf [512]; + sprintf (buf, "%s: could not execute \"%s\"", progname, av[0]); + perror (buf); + + if (errno == ENOENT && + (token = getenv("PATH"))) + { +# ifndef PATH_MAX +# ifdef MAXPATHLEN +# define PATH_MAX MAXPATHLEN +# else +# define PATH_MAX 2048 +# endif +# endif + char path[PATH_MAX]; + fprintf (stderr, "\n"); + *path = 0; +# if defined(HAVE_GETCWD) + getcwd (path, sizeof(path)); +# elif defined(HAVE_GETWD) + getwd (path); +# endif + if (*path) + fprintf (stderr, " Current directory is: %s\n", path); + fprintf (stderr, " PATH is:\n"); + token = strtok (strdup(token), ":"); + while (token) + { + fprintf (stderr, " %s\n", token); + token = strtok(0, ":"); + } + fprintf (stderr, "\n"); + } + } + fflush(stderr); + fflush(stdout); + exit (1); /* Note that this only exits a child fork. */ +} + + +static void +exec_complex_command (const char *shell, const char *command) +{ + char *av[5]; + int ac = 0; + char *command2 = (char *) malloc (strlen (command) + 6); + memcpy (command2, "exec ", 5); + memcpy (command2 + 5, command, strlen (command) + 1); + + /* Invoke the shell as "/bin/sh -c 'exec prog -arg -arg ...'" */ + av [ac++] = (char *) shell; + av [ac++] = "-c"; + av [ac++] = command2; + av [ac] = 0; + + execvp (av[0], av); /* shouldn't return. */ + + { + char buf [512]; + sprintf (buf, "%s: execvp(\"%s\") failed", progname, av[0]); + perror (buf); + fflush(stderr); + fflush(stdout); + exit (1); /* Note that this only exits a child fork. */ + } +} + +#else /* VMS */ + +static void +exec_vms_command (const char *command) +{ + system (command); + fflush (stderr); + fflush (stdout); + exit (1); /* Note that this only exits a child fork. */ +} + +#endif /* !VMS */ + + +static void +exec_screenhack (saver_info *si, const char *command) +{ + /* I don't believe what a sorry excuse for an operating system UNIX is! + + - I want to spawn a process. + - I want to know it's pid so that I can kill it. + - I would like to receive a message when it dies of natural causes. + - I want the spawned process to have user-specified arguments. + + If shell metacharacters are present (wildcards, backquotes, etc), the + only way to parse those arguments is to run a shell to do the parsing + for you. + + And the only way to know the pid of the process is to fork() and exec() + it in the spawned side of the fork. + + But if you're running a shell to parse your arguments, this gives you + the pid of the *shell*, not the pid of the *process* that you're + actually interested in, which is an *inferior* of the shell. This also + means that the SIGCHLD you get applies to the shell, not its inferior. + (Why isn't that sufficient? I don't remember any more, but it turns + out that it isn't.) + + So, the only solution, when metacharacters are present, is to force the + shell to exec() its inferior. What a fucking hack! We prepend "exec " + to the command string, and hope it doesn't contain unquoted semicolons + or ampersands (we don't search for them, because we don't want to + prohibit their use in quoted strings (messages, for example) and parsing + out the various quote characters is too much of a pain.) + + (Actually, Clint Wong points out that process groups + might be used to take care of this problem; this may be worth considering + some day, except that, 1: this code works now, so why fix it, and 2: from + what I've seen in Emacs, dealing with process groups isn't especially + portable.) + */ + saver_preferences *p = &si->prefs; + +#ifndef VMS + Bool hairy_p = !!strpbrk (command, "*?$&!<>[];`'\\\""); + + if (p->verbose_p) + printf ("%s: spawning \"%s\" in pid %lu%s.\n", + progname, command, (unsigned long) getpid (), + (hairy_p ? " (via shell)" : "")); + + if (hairy_p) + /* If it contains any shell metacharacters, do it the hard way, + and fork a shell to parse the arguments for us. */ + exec_complex_command (p->shell, command); + else + /* Otherwise, we can just exec the program directly. */ + exec_simple_command (command); + +#else /* VMS */ + if (p->verbose_p) + printf ("%s: spawning \"%s\" in pid %lu.\n", progname, command, getpid()); + exec_vms_command (command); +#endif /* VMS */ + + abort(); /* that shouldn't have returned. */ +} + + + +/* Management of child processes, and de-zombification. + */ + +enum job_status { + job_running, /* the process is still alive */ + job_stopped, /* we have sent it a STOP signal */ + job_killed, /* we have sent it a TERM signal */ + job_dead /* we have wait()ed for it, and it's dead -- this state only + occurs so that we can avoid calling free() from a signal + handler. Shortly after going into this state, the list + element will be removed. */ +}; + +struct screenhack_job { + char *name; + pid_t pid; + enum job_status status; + struct screenhack_job *next; +}; + +static struct screenhack_job *jobs = 0; + +#ifdef DEBUG +static void +show_job_list (void) +{ + struct screenhack_job *job; + fprintf(stderr, "%s: job list:\n", progname); + for (job = jobs; job; job = job->next) + fprintf (stderr, " %5ld: (%s) %s\n", + (long) job->pid, + (job->status == job_running ? "running" : + job->status == job_stopped ? "stopped" : + job->status == job_killed ? " killed" : + job->status == job_dead ? " dead" : " ???"), + job->name); + fprintf (stderr, "\n"); +} +#endif + + +static void clean_job_list (void); + +static struct screenhack_job * +make_job (pid_t pid, const char *cmd) +{ + struct screenhack_job *job = (struct screenhack_job *) malloc (sizeof(*job)); + + static char name [1024]; + const char *in = cmd; + char *out = name; + + clean_job_list(); + + while (isspace(*in)) in++; /* skip whitespace */ + while (!isspace(*in) && *in != ':') + *out++ = *in++; /* snarf first token */ + while (isspace(*in)) in++; /* skip whitespace */ + if (*in == ':') /* token was a visual name; skip it. */ + { + in++; + out = name; + while (isspace(*in)) in++; /* skip whitespace */ + while (!isspace(*in)) *out++ = *in++; /* snarf first token */ + } + *out = 0; + + job->name = strdup(name); + job->pid = pid; + job->status = job_running; + job->next = jobs; + jobs = job; + + return jobs; +} + + +static void +free_job (struct screenhack_job *job) +{ + if (!job) + return; + else if (job == jobs) + jobs = jobs->next; + else + { + struct screenhack_job *job2, *prev; + for (prev = 0, job2 = jobs; + job2; + prev = job2, job2 = job2->next) + if (job2 == job) + { + prev->next = job->next; + break; + } + } + free(job->name); + free(job); +} + + +/* Cleans out dead jobs from the jobs list -- this must only be called + from the main thread, not from a signal handler. + */ +static void +clean_job_list (void) +{ + struct screenhack_job *job, *prev, *next; + for (prev = 0, job = jobs, next = (job ? job->next : 0); + job; + prev = job, job = next, next = (job ? job->next : 0)) + { + if (job->status == job_dead) + { + if (prev) + prev->next = next; + free_job (job); + job = prev; + } + } +} + + +static struct screenhack_job * +find_job (pid_t pid) +{ + struct screenhack_job *job; + for (job = jobs; job; job = job->next) + if (job->pid == pid) + return job; + return 0; +} + +static void await_dying_children (saver_info *si); +#ifndef VMS +static void describe_dead_child (saver_info *, pid_t, int wait_status); +#endif + + +/* Semaphore to temporarily turn the SIGCHLD handler into a no-op. + Don't alter this directly -- use block_sigchld() / unblock_sigchld(). + */ +static int block_sigchld_handler = 0; + + +static void +block_sigchld (void) +{ +#ifdef HAVE_SIGACTION + sigset_t child_set; + sigemptyset (&child_set); + sigaddset (&child_set, SIGCHLD); + sigprocmask (SIG_BLOCK, &child_set, 0); +#endif /* HAVE_SIGACTION */ + + block_sigchld_handler++; +} + +static void +unblock_sigchld (void) +{ +#ifdef HAVE_SIGACTION + sigset_t child_set; + sigemptyset(&child_set); + sigaddset(&child_set, SIGCHLD); + sigprocmask(SIG_UNBLOCK, &child_set, 0); +#endif /* HAVE_SIGACTION */ + + block_sigchld_handler--; +} + +static int +kill_job (saver_info *si, pid_t pid, int signal) +{ + saver_preferences *p = &si->prefs; + struct screenhack_job *job; + int status = -1; + + clean_job_list(); + + if (block_sigchld_handler) + /* This function should not be called from the signal handler. */ + abort(); + + block_sigchld(); /* we control the horizontal... */ + + job = find_job (pid); + if (!job || + !job->pid || + job->status == job_killed) + { + if (p->verbose_p) + fprintf (stderr, "%s: no child %ld to signal!\n", + progname, (long) pid); + goto DONE; + } + + switch (signal) { + case SIGTERM: job->status = job_killed; break; +#ifdef SIGSTOP + /* #### there must be a way to do this on VMS... */ + case SIGSTOP: job->status = job_stopped; break; + case SIGCONT: job->status = job_running; break; +#endif /* SIGSTOP */ + default: abort(); + } + +#ifdef SIGSTOP + if (p->verbose_p) + fprintf (stderr, "%s: %s pid %lu.\n", progname, + (signal == SIGTERM ? "killing" : + signal == SIGSTOP ? "suspending" : + signal == SIGCONT ? "resuming" : "signalling"), + (unsigned long) job->pid); +#else /* !SIGSTOP */ + if (p->verbose_p) + fprintf (stderr, "%s: %s pid %lu.\n", progname, "killing", + (unsigned long) job->pid); +#endif /* !SIGSTOP */ + + status = kill (job->pid, signal); + + if (p->verbose_p && status < 0) + { + if (errno == ESRCH) + fprintf (stderr, "%s: child process %lu (%s) was already dead.\n", + progname, job->pid, job->name); + else + { + char buf [1024]; + sprintf (buf, "%s: couldn't kill child process %lu (%s)", + progname, job->pid, job->name); + perror (buf); + } + } + + await_dying_children (si); + + DONE: + unblock_sigchld(); + if (block_sigchld_handler < 0) + abort(); + + clean_job_list(); + return status; +} + + +#ifdef SIGCHLD +static RETSIGTYPE +sigchld_handler (int sig) +{ + saver_info *si = global_si_kludge; /* I hate C so much... */ + +#ifdef DEBUG + if (si->prefs.debug_p) + fprintf(stderr, "%s: got SIGCHLD%s\n", progname, + (block_sigchld_handler ? " (blocked)" : "")); +#endif /* DEBUG */ + + if (block_sigchld_handler < 0) + abort(); + else if (block_sigchld_handler == 0) + { + block_sigchld(); + await_dying_children (si); + unblock_sigchld(); + } + + init_sigchld(); +} +#endif /* SIGCHLD */ + + +#ifndef VMS +static void +await_dying_children (saver_info *si) +{ + while (1) + { + int wait_status = 0; + pid_t kid; + + errno = 0; + kid = waitpid (-1, &wait_status, WNOHANG|WUNTRACED); +#ifdef DEBUG + if (si->prefs.debug_p) + if (kid < 0 && errno) + fprintf (stderr, "%s: waitpid(-1) ==> %ld (%d)\n", progname, + (long) kid, errno); + else + fprintf (stderr, "%s: waitpid(-1) ==> %ld\n", progname, (long) kid); +#endif /* DEBUG */ + + /* 0 means no more children to reap. + -1 means error -- except "interrupted system call" isn't a "real" + error, so if we get that, we should just try again. */ + if (kid == 0 || + (kid < 0 && errno != EINTR)) + break; + + describe_dead_child (si, kid, wait_status); + } +} + + +static void +describe_dead_child (saver_info *si, pid_t kid, int wait_status) +{ + int i; + saver_preferences *p = &si->prefs; + struct screenhack_job *job = find_job (kid); + const char *name = job ? job->name : ""; + + if (WIFEXITED (wait_status)) + { + int exit_status = WEXITSTATUS (wait_status); + + /* Treat exit code as a signed 8-bit quantity. */ + if (exit_status & 0x80) exit_status |= ~0xFF; + + /* One might assume that exiting with non-0 means something went wrong. + But that loser xswarm exits with the code that it was killed with, so + it *always* exits abnormally. Treat abnormal exits as "normal" (don't + mention them) if we've just killed the subprocess. But mention them + if they happen on their own. + */ + if (!job || + (exit_status != 0 && + (p->verbose_p || job->status != job_killed))) + fprintf (stderr, + "%s: child pid %lu (%s) exited abnormally (code %d).\n", + progname, (unsigned long) kid, name, exit_status); + else if (p->verbose_p) + printf ("%s: child pid %lu (%s) exited normally.\n", + progname, (unsigned long) kid, name); + + if (job) + job->status = job_dead; + } + else if (WIFSIGNALED (wait_status)) + { + if (p->verbose_p || + !job || + job->status != job_killed || + WTERMSIG (wait_status) != SIGTERM) + fprintf (stderr, "%s: child pid %lu (%s) terminated with %s.\n", + progname, (unsigned long) kid, name, + signal_name (WTERMSIG(wait_status))); + + if (job) + job->status = job_dead; + } + else if (WIFSTOPPED (wait_status)) + { + if (p->verbose_p) + fprintf (stderr, "%s: child pid %lu (%s) stopped with %s.\n", + progname, (unsigned long) kid, name, + signal_name (WSTOPSIG (wait_status))); + + if (job) + job->status = job_stopped; + } + else + { + fprintf (stderr, "%s: child pid %lu (%s) died in a mysterious way!", + progname, (unsigned long) kid, name); + if (job) + job->status = job_dead; + } + + /* Clear out the pid so that screenhack_running_p() knows it's dead. + */ + if (!job || job->status == job_dead) + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (kid == ssi->pid) + ssi->pid = 0; + } +} + +#else /* VMS */ +static void await_dying_children (saver_info *si) { return; } +#endif /* VMS */ + + +void +init_sigchld (void) +{ +#ifdef SIGCHLD + +# ifdef HAVE_SIGACTION /* Thanks to Tom Kelly */ + + static Bool sigchld_initialized_p = 0; + if (!sigchld_initialized_p) + { + struct sigaction action, old; + + action.sa_handler = sigchld_handler; + sigemptyset(&action.sa_mask); + action.sa_flags = 0; + + if (sigaction(SIGCHLD, &action, &old) < 0) + { + char buf [255]; + sprintf (buf, "%s: couldn't catch SIGCHLD", progname); + perror (buf); + } + sigchld_initialized_p = True; + } + +# else /* !HAVE_SIGACTION */ + + if (((long) signal (SIGCHLD, sigchld_handler)) == -1L) + { + char buf [255]; + sprintf (buf, "%s: couldn't catch SIGCHLD", progname); + perror (buf); + } +# endif /* !HAVE_SIGACTION */ +#endif /* SIGCHLD */ +} + + + + + +static Bool +select_visual_of_hack (saver_screen_info *ssi, const char *hack) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + Bool selected; + static char vis [1024]; + const char *in = hack; + char *out = vis; + while (isspace(*in)) in++; /* skip whitespace */ + while (!isspace(*in) && *in != ':') + *out++ = *in++; /* snarf first token */ + while (isspace(*in)) in++; /* skip whitespace */ + *out = 0; + + if (*in == ':') + selected = select_visual(ssi, vis); + else + selected = select_visual(ssi, 0); + + if (!selected && (p->verbose_p || si->demo_mode_p)) + { + if (*in == ':') in++; + while (isspace(*in)) in++; + fprintf (stderr, + (si->demo_mode_p + ? "%s: warning, no \"%s\" visual for \"%s\".\n" + : "%s: no \"%s\" visual; skipping \"%s\".\n"), + progname, (vis ? vis : "???"), in); + } + + return selected; +} + + +static void +spawn_screenhack_1 (saver_screen_info *ssi, Bool first_time_p) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + raise_window (si, first_time_p, True, False); + XFlush (si->dpy); + + if (p->screenhacks_count || si->demo_mode_p) + { + char *hack; + pid_t forked; + char buf [255]; + int new_hack; + + if (si->demo_mode_p) + { + hack = si->demo_hack; + + /* Ignore visual-selection failure if in demo mode. */ + (void) select_visual_of_hack (ssi, hack); + } + else + { + int retry_count = 0; + + AGAIN: + if (p->screenhacks_count == 1) + new_hack = 0; + else if (si->next_mode_p == 1) + new_hack = (ssi->current_hack + 1) % p->screenhacks_count; + else if (si->next_mode_p == 2) + new_hack = ((ssi->current_hack + p->screenhacks_count - 1) + % p->screenhacks_count); + else + while ((new_hack = random () % p->screenhacks_count) + == ssi->current_hack) + ; + ssi->current_hack = new_hack; + hack = p->screenhacks[ssi->current_hack]; + + if (!select_visual_of_hack (ssi, hack)) + { + if (++retry_count > (p->screenhacks_count*4)) + { + /* Uh, oops. Odds are, there are no suitable visuals, + and we're looping. Give up. (This is totally lame, + what we should do is make a list of suitable hacks at + the beginning, then only loop over them.) + */ + if (p->verbose_p) + fprintf(stderr, + "%s: no suitable visuals for these programs.\n", + progname); + return; + } + else + goto AGAIN; + } + } + si->next_mode_p = 0; + + + /* If there's a visual description on the front of the command, nuke it. + */ + { + char *in = hack; + while (isspace(*in)) in++; /* skip whitespace */ + hack = in; + while (!isspace(*in) && *in != ':') in++; /* snarf first token */ + while (isspace(*in)) in++; /* skip whitespace */ + if (*in == ':') + { + in++; + while (isspace(*in)) in++; + hack = in; + } + } + + switch ((int) (forked = fork ())) + { + case -1: + sprintf (buf, "%s: couldn't fork", progname); + perror (buf); + restore_real_vroot (si); + saver_exit (si, 1); + + case 0: + close (ConnectionNumber (si->dpy)); /* close display fd */ + nice_subproc (p->nice_inferior); /* change process priority */ + hack_environment (ssi); /* set $DISPLAY */ + exec_screenhack (si, hack); /* this does not return */ + abort(); + break; + + default: + ssi->pid = forked; + (void) make_job (forked, hack); + break; + } + } +} + + +void +spawn_screenhack (saver_info *si, Bool first_time_p) +{ + int i; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + spawn_screenhack_1 (ssi, first_time_p); + } +} + + +void +kill_screenhack (saver_info *si) +{ + int i; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->pid) + kill_job (si, ssi->pid, SIGTERM); + ssi->pid = 0; + } +} + + +void +suspend_screenhack (saver_info *si, Bool suspend_p) +{ +#ifdef SIGSTOP /* older VMS doesn't have it... */ + int i; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->pid) + kill_job (si, ssi->pid, (suspend_p ? SIGSTOP : SIGCONT)); + } +#endif /* SIGSTOP */ +} + + +/* Called when we're exiting abnormally, to kill off the subproc. */ +void +emergency_kill_subproc (saver_info *si) +{ + int i; +#ifdef SIGCHLD + signal (SIGCHLD, SIG_IGN); +#endif /* SIGCHLD */ + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->pid) + { + kill_job (si, ssi->pid, SIGTERM); + ssi->pid = 0; + } + } +} + +Bool +screenhack_running_p (saver_info *si) +{ + Bool result = True; + int i; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (!ssi->pid) + result = False; + } + return result; +} + + +/* Restarting the xscreensaver process from scratch. */ + +static char **saved_argv; + +void +save_argv (int argc, char **argv) +{ + saved_argv = (char **) malloc ((argc + 2) * sizeof (char *)); + saved_argv [argc] = 0; + while (argc--) + { + int i = strlen (argv [argc]) + 1; + saved_argv [argc] = (char *) malloc (i); + memcpy (saved_argv [argc], argv [argc], i); + } +} + +void +restart_process (saver_info *si) +{ + fflush (real_stdout); + fflush (real_stderr); + execvp (saved_argv [0], saved_argv); /* shouldn't return */ + { + char buf [512]; + sprintf (buf, "%s: could not restart process", progname); + perror(buf); + fflush(stderr); + } +} + +/* Like restart_process(), but ensures that when it restarts, + it comes up in demo-mode. */ +void +demo_mode_restart_process (saver_info *si) +{ + int i; + for (i = 0; saved_argv [i]; i++); + /* add the -demo switch; save_argv() left room for this. */ + saved_argv [i] = "-demo"; + saved_argv [i+1] = 0; + restart_process (si); /* shouldn't return */ + saved_argv [i] = 0; + XBell(si->dpy, 0); +} + +static void +hack_environment (saver_screen_info *ssi) +{ + /* Store $DISPLAY into the environment, so that the $DISPLAY variable that + the spawned processes inherit is correct. First, it must be on the same + host and display as the value of -display passed in on our command line + (which is not necessarily the same as what our $DISPLAY variable is.) + Second, the screen number in the $DISPLAY passed to the subprocess should + be the screen on which this particular hack is running -- not the display + specification which the driver itself is using, since the driver ignores + its screen number and manages all existing screens. + */ + saver_info *si = ssi->global; + const char *odpy = DisplayString (si->dpy); + char *ndpy = (char *) malloc(strlen(odpy) + 20); + int screen_number; + char *s; + + for (screen_number = 0; screen_number < si->nscreens; screen_number++) + if (ssi == &si->screens[screen_number]) + break; + if (screen_number >= si->nscreens) abort(); + + strcpy (ndpy, "DISPLAY="); + s = ndpy + strlen(ndpy); + strcpy (s, odpy); + + while (*s && *s != ':') s++; /* skip to colon */ + while (*s == ':') s++; /* skip over colons */ + while (isdigit(*s)) s++; /* skip over dpy number */ + while (*s == '.') s++; /* skip over dot */ + if (s[-1] != '.') *s++ = '.'; /* put on a dot */ + sprintf(s, "%d", screen_number); /* put on screen number */ + + /* Allegedly, BSD 4.3 didn't have putenv(), but nobody runs such systems + any more, right? It's not Posix, but everyone seems to have it. */ +#ifdef HAVE_PUTENV + if (putenv (ndpy)) + abort (); +#endif /* HAVE_PUTENV */ +} + + +/* Change the uid/gid of the screensaver process, so that it is safe for it + to run setuid root (which it needs to do on some systems to read the + encrypted passwords from the passwd file.) + + hack_uid() is run before opening the X connection, so that XAuth works. + hack_uid_warn() is called after the connection is opened and the command + line arguments are parsed, so that the messages from hack_uid() get + printed after we know whether we're in `verbose' mode. + */ + +#ifndef NO_SETUID + +static int hack_uid_errno; +static char hack_uid_buf [255], *hack_uid_error; + +void +hack_uid (saver_info *si) +{ + + /* If we've been run as setuid or setgid to someone else (most likely root) + turn off the extra permissions so that random user-specified programs + don't get special privileges. (On some systems it might be necessary + to install this as setuid root in order to read the passwd file to + implement lock-mode...) + */ + setgid (getgid ()); + setuid (getuid ()); + + hack_uid_errno = 0; + hack_uid_error = 0; + + /* If we're being run as root (as from xdm) then switch the user id + to something safe. */ + if (getuid () == 0) + { + struct passwd *p; + /* Locking can't work when running as root, because we have no way of + knowing what the user id of the logged in user is (so we don't know + whose password to prompt for.) + */ + si->locking_disabled_p = True; + si->nolock_reason = "running as root"; + p = getpwnam ("nobody"); + if (! p) p = getpwnam ("noaccess"); + if (! p) p = getpwnam ("daemon"); + if (! p) p = getpwnam ("bin"); + if (! p) p = getpwnam ("sys"); + if (! p) + { + hack_uid_error = "couldn't find safe uid; running as root."; + hack_uid_errno = -1; + } + else + { + struct group *g = getgrgid (p->pw_gid); + hack_uid_error = hack_uid_buf; + sprintf (hack_uid_error, "changing uid/gid to %s/%s (%ld/%ld).", + p->pw_name, (g ? g->gr_name : "???"), + (long) p->pw_uid, (long) p->pw_gid); + + /* Change the gid to be a safe one. If we can't do that, then + print a warning. We change the gid before the uid so that we + change the gid while still root. */ + if (setgid (p->pw_gid) != 0) + { + hack_uid_errno = errno; + sprintf (hack_uid_error, "couldn't set gid to %s (%ld)", + (g ? g->gr_name : "???"), (long) p->pw_gid); + } + + /* Now change the uid to be a safe one. */ + if (setuid (p->pw_uid) != 0) + { + hack_uid_errno = errno; + sprintf (hack_uid_error, "couldn't set uid to %s (%ld)", + p->pw_name, (long) p->pw_uid); + } + } + } +# ifndef NO_LOCKING + else /* disable locking if already being run as "someone else" */ + { + struct passwd *p = getpwuid (getuid ()); + if (!p || + !strcmp (p->pw_name, "root") || + !strcmp (p->pw_name, "nobody") || + !strcmp (p->pw_name, "noaccess") || + !strcmp (p->pw_name, "daemon") || + !strcmp (p->pw_name, "bin") || + !strcmp (p->pw_name, "sys")) + { + si->locking_disabled_p = True; + si->nolock_reason = hack_uid_buf; + sprintf (si->nolock_reason, "running as %s", p->pw_name); + } + } +# endif /* !NO_LOCKING */ +} + +void +hack_uid_warn (saver_info *si) +{ + saver_preferences *p = &si->prefs; + + if (! hack_uid_error) + ; + else if (hack_uid_errno == 0) + { + if (p->verbose_p) + printf ("%s: %s\n", progname, hack_uid_error); + } + else + { + char buf [255]; + sprintf (buf, "%s: %s", progname, hack_uid_error); + if (hack_uid_errno == -1) + fprintf (stderr, "%s\n", buf); + else + { + errno = hack_uid_errno; + perror (buf); + } + } +} + +#endif /* !NO_SETUID */ diff --git a/driver/timers.c b/driver/timers.c new file mode 100644 index 00000000..92aa4b93 --- /dev/null +++ b/driver/timers.c @@ -0,0 +1,633 @@ +/* timers.c --- detecting when the user is idle, and other timer-related tasks. + * xscreensaver, Copyright (c) 1991-1997 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 HAVE_CONFIG_H +# include "config.h" +#endif + +/* #define DEBUG_TIMERS */ + +#include +#include +#include +#include +#ifdef HAVE_XMU +# ifndef VMS +# include +# else /* VMS */ +# include +# endif /* VMS */ +# else /* !HAVE_XMU */ +# include "xmu.h" +#endif /* !HAVE_XMU */ + +#ifdef HAVE_XIDLE_EXTENSION +#include +#endif /* HAVE_XIDLE_EXTENSION */ + +#ifdef HAVE_MIT_SAVER_EXTENSION +#include +#endif /* HAVE_MIT_SAVER_EXTENSION */ + +#ifdef HAVE_SGI_SAVER_EXTENSION +#include +#endif /* HAVE_SGI_SAVER_EXTENSION */ + +#ifdef HAVE_XHPDISABLERESET +# include + extern Bool hp_locked_p; /* from windows.c */ +#endif /* HAVE_XHPDISABLERESET */ + +#include "xscreensaver.h" + + +void +idle_timer (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + + /* What an amazingly shitty design. Not only does Xt execute timeout + events from XtAppNextEvent() instead of from XtDispatchEvent(), but + there is no way to tell Xt to block until there is an X event OR a + timeout happens. Once your timeout proc is called, XtAppNextEvent() + still won't return until a "real" X event comes in. + + So this function pushes a stupid, gratuitous, unnecessary event back + on the event queue to force XtAppNextEvent to return Right Fucking Now. + When the code in sleep_until_idle() sees an event of type XAnyEvent, + which the server never generates, it knows that a timeout has occurred. + */ + XEvent fake_event; + fake_event.type = 0; /* XAnyEvent type, ignored. */ + fake_event.xany.display = si->dpy; + fake_event.xany.window = 0; + XPutBackEvent (si->dpy, &fake_event); +} + + +static void +notice_events (saver_info *si, Window window, Bool top_p) +{ + saver_preferences *p = &si->prefs; + XWindowAttributes attrs; + unsigned long events; + Window root, parent, *kids; + unsigned int nkids; + + if (XtWindowToWidget (si->dpy, window)) + /* If it's one of ours, don't mess up its event mask. */ + return; + + if (!XQueryTree (si->dpy, window, &root, &parent, &kids, &nkids)) + return; + if (window == root) + top_p = False; + + XGetWindowAttributes (si->dpy, window, &attrs); + events = ((attrs.all_event_masks | attrs.do_not_propagate_mask) + & KeyPressMask); + + /* Select for SubstructureNotify on all windows. + Select for KeyPress on all windows that already have it selected. + Do we need to select for ButtonRelease? I don't think so. + */ + XSelectInput (si->dpy, window, SubstructureNotifyMask | events); + + if (top_p && p->verbose_p && (events & KeyPressMask)) + { + /* Only mention one window per tree (hack hack). */ + printf ("%s: selected KeyPress on 0x%lX\n", progname, + (unsigned long) window); + top_p = False; + } + + if (kids) + { + while (nkids) + notice_events (si, kids [--nkids], top_p); + XFree ((char *) kids); + } +} + + +int +BadWindow_ehandler (Display *dpy, XErrorEvent *error) +{ + /* When we notice a window being created, we spawn a timer that waits + 30 seconds or so, and then selects events on that window. This error + handler is used so that we can cope with the fact that the window + may have been destroyed <30 seconds after it was created. + */ + if (error->error_code == BadWindow || + error->error_code == BadMatch || + error->error_code == BadDrawable) + return 0; + else + return saver_ehandler (dpy, error); +} + + +struct notice_events_timer_arg { + saver_info *si; + Window w; +}; + +static void +notice_events_timer (XtPointer closure, XtIntervalId *id) +{ + struct notice_events_timer_arg *arg = + (struct notice_events_timer_arg *) closure; + + XErrorHandler old_handler = XSetErrorHandler (BadWindow_ehandler); + + saver_info *si = arg->si; + Window window = arg->w; + + free(arg); + notice_events (si, window, True); + XSync (si->dpy, False); + XSetErrorHandler (old_handler); +} + +void +start_notice_events_timer (saver_info *si, Window w) +{ + saver_preferences *p = &si->prefs; + struct notice_events_timer_arg *arg = + (struct notice_events_timer_arg *) malloc(sizeof(*arg)); + arg->si = si; + arg->w = w; + XtAppAddTimeOut (si->app, p->notice_events_timeout, notice_events_timer, + (XtPointer) arg); +} + + +/* When the screensaver is active, this timer will periodically change + the running program. + */ +void +cycle_timer (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + saver_preferences *p = &si->prefs; + Time how_long = p->cycle; + if (si->dbox_up_p) + { + if (p->verbose_p) + printf ("%s: dbox up; delaying hack change.\n", progname); + how_long = 30000; /* 30 secs */ + } + else + { + if (p->verbose_p) + printf ("%s: changing graphics hacks.\n", progname); + kill_screenhack (si); + spawn_screenhack (si, False); + } + si->cycle_id = XtAppAddTimeOut (si->app, how_long, cycle_timer, + (XtPointer) si); + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: starting cycle_timer (%ld, %ld)\n", + progname, how_long, si->cycle_id); +#endif +} + + +void +activate_lock_timer (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + saver_preferences *p = &si->prefs; + + if (p->verbose_p) + printf ("%s: timed out; activating lock\n", progname); + si->locked_p = True; + +#ifdef HAVE_XHPDISABLERESET + if (!hp_locked_p) + { + XHPDisableReset (si->dpy); /* turn off C-Sh-Reset */ + hp_locked_p = True; + } +#endif +} + + +/* Call this when user activity (or "simulated" activity) has been noticed. + */ +static void +reset_timers (saver_info *si) +{ + saver_preferences *p = &si->prefs; + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + return; + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: killing idle_timer (%ld, %ld)\n", + progname, p->timeout, si->timer_id); +#endif + XtRemoveTimeOut (si->timer_id); + si->timer_id = XtAppAddTimeOut (si->app, p->timeout, idle_timer, + (XtPointer) si); + if (si->cycle_id) abort (); + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: restarting idle_timer (%ld, %ld)\n", + progname, p->timeout, si->timer_id); +#endif + + si->last_activity_time = time ((time_t *) 0); +} + +/* When we aren't using a server extension, this timer is used to periodically + wake up and poll the mouse position, which is possibly more reliable than + selecting motion events on every window. + */ +static void +check_pointer_timer (XtPointer closure, XtIntervalId *id) +{ + int i; + saver_info *si = (saver_info *) closure; + saver_preferences *p = &si->prefs; + Bool active_p = False; + + if (p->use_xidle_extension || + p->use_mit_saver_extension || + p->use_sgi_saver_extension) + abort (); + + si->check_pointer_timer_id = + XtAppAddTimeOut (si->app, p->pointer_timeout, check_pointer_timer, + (XtPointer) si); + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + Window root, child; + int root_x, root_y, x, y; + unsigned int mask; + + XQueryPointer (si->dpy, ssi->screensaver_window, &root, &child, + &root_x, &root_y, &x, &y, &mask); + + if (root_x == ssi->poll_mouse_last_root_x && + root_y == ssi->poll_mouse_last_root_y && + child == ssi->poll_mouse_last_child && + mask == ssi->poll_mouse_last_mask) + continue; + + active_p = True; + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + if (root_x == ssi->poll_mouse_last_root_x && + root_y == ssi->poll_mouse_last_root_y && + child == ssi->poll_mouse_last_child) + printf ("%s: modifiers changed at %s on screen %d.\n", + progname, timestring(), i); + else + printf ("%s: pointer moved at %s on screen %d.\n", + progname, timestring(), i); +#endif + + si->last_activity_screen = ssi; + ssi->poll_mouse_last_root_x = root_x; + ssi->poll_mouse_last_root_y = root_y; + ssi->poll_mouse_last_child = child; + ssi->poll_mouse_last_mask = mask; + } + + if (active_p) + reset_timers (si); +} + + +void +sleep_until_idle (saver_info *si, Bool until_idle_p) +{ + saver_preferences *p = &si->prefs; + XEvent event; + + if (until_idle_p) + { + if (!p->use_mit_saver_extension && !p->use_sgi_saver_extension) + { + /* Wake up periodically to ask the server if we are idle. */ + si->timer_id = XtAppAddTimeOut (si->app, p->timeout, idle_timer, + (XtPointer) si); +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: starting idle_timer (%ld, %ld)\n", + progname, p->timeout, si->timer_id); +#endif + } + + if (!p->use_xidle_extension && + !p->use_mit_saver_extension && + !p->use_sgi_saver_extension) + /* start polling the mouse position */ + check_pointer_timer ((XtPointer) si, 0); + } + + while (1) + { + XtAppNextEvent (si->app, &event); + + switch (event.xany.type) { + case 0: /* our synthetic "timeout" event has been signalled */ + if (until_idle_p) + { + Time idle; +#ifdef HAVE_XIDLE_EXTENSION + if (p->use_xidle_extension) + { + if (! XGetIdleTime (si->dpy, &idle)) + { + fprintf (stderr, "%s: XGetIdleTime() failed.\n", progname); + saver_exit (si, 1); + } + } + else +#endif /* HAVE_XIDLE_EXTENSION */ +#ifdef HAVE_MIT_SAVER_EXTENSION + if (p->use_mit_saver_extension) + { + /* We don't need to do anything in this case - the synthetic + event isn't necessary, as we get sent specific events + to wake us up. */ + idle = 0; + } + else +#endif /* HAVE_MIT_SAVER_EXTENSION */ +#ifdef HAVE_SGI_SAVER_EXTENSION + if (p->use_sgi_saver_extension) + { + /* We don't need to do anything in this case - the synthetic + event isn't necessary, as we get sent specific events + to wake us up. */ + idle = 0; + } + else +#endif /* HAVE_SGI_SAVER_EXTENSION */ + { + idle = 1000 * (si->last_activity_time - time ((time_t *) 0)); + } + + if (idle >= p->timeout) + goto DONE; + else if (!p->use_mit_saver_extension && + !p->use_sgi_saver_extension) + { + si->timer_id = XtAppAddTimeOut (si->app, p->timeout - idle, + idle_timer, (XtPointer) si); +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: starting idle_timer (%ld, %ld)\n", + progname, p->timeout - idle, si->timer_id); +#endif /* DEBUG_TIMERS */ + } + } + break; + + case ClientMessage: + if (handle_clientmessage (si, &event, until_idle_p)) + goto DONE; + break; + + case CreateNotify: + if (!p->use_xidle_extension && + !p->use_mit_saver_extension && + !p->use_sgi_saver_extension) + { + start_notice_events_timer (si, event.xcreatewindow.window); +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: starting notice_events_timer for 0x%X (%lu)\n", + progname, + (unsigned int) event.xcreatewindow.window, + p->notice_events_timeout); +#endif /* DEBUG_TIMERS */ + } + break; + + case KeyPress: + case KeyRelease: + case ButtonPress: + case ButtonRelease: + case MotionNotify: + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + { + if (event.xany.type == MotionNotify) + printf ("%s: MotionNotify at %s\n", progname, timestring ()); + else if (event.xany.type == KeyPress) + printf ("%s: KeyPress seen on 0x%X at %s\n", progname, + (unsigned int) event.xkey.window, timestring ()); + } +#endif + + /* We got a user event */ + if (!until_idle_p) + goto DONE; + else + reset_timers (si); + break; + + default: + +#ifdef HAVE_MIT_SAVER_EXTENSION + if (event.type == si->mit_saver_ext_event_number) + { + XScreenSaverNotifyEvent *sevent = + (XScreenSaverNotifyEvent *) &event; + if (sevent->state == ScreenSaverOn) + { +# ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: ScreenSaverOn event received at %s\n", + progname, timestring ()); +# endif /* DEBUG_TIMERS */ + + /* Get the "real" server window(s) out of the way as soon + as possible. */ + int i = 0; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->server_mit_saver_window && + window_exists_p (si->dpy, + ssi->server_mit_saver_window)) + XUnmapWindow (si->dpy, ssi->server_mit_saver_window); + } + + if (sevent->kind != ScreenSaverExternal) + { +# ifdef DEBUG_TIMERS + fprintf (stderr, + "%s: ScreenSaverOn event wasn't of type External!\n", + progname); +# endif /* DEBUG_TIMERS */ + } + + if (until_idle_p) + goto DONE; + } + else if (sevent->state == ScreenSaverOff) + { +# ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: ScreenSaverOff event received at %s\n", + progname, timestring ()); +# endif /* DEBUG_TIMERS */ + if (!until_idle_p) + goto DONE; + } +# ifdef DEBUG_TIMERS + else if (p->verbose_p) + printf ("%s: unknown MIT-SCREEN-SAVER event received at %s\n", + progname, timestring ()); +# endif /* DEBUG_TIMERS */ + } + else + +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + +#ifdef HAVE_SGI_SAVER_EXTENSION + if (event.type == (si->sgi_saver_ext_event_number + ScreenSaverStart)) + { +# ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: ScreenSaverStart event received at %s\n", + progname, timestring ()); +# endif /* DEBUG_TIMERS */ + + if (until_idle_p) + goto DONE; + } + else if (event.type == (si->sgi_saver_ext_event_number + + ScreenSaverEnd)) + { +# ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: ScreenSaverEnd event received at %s\n", + progname, timestring ()); +# endif /* DEBUG_TIMERS */ + if (!until_idle_p) + goto DONE; + } + else +#endif /* HAVE_SGI_SAVER_EXTENSION */ + + XtDispatchEvent (&event); + } + } + DONE: + + + /* If there's a user event on the queue, swallow it. + If we're using a server extension, and the user becomes active, we + get the extension event before the user event -- so the keypress or + motion or whatever is still on the queue. This makes "unfade" not + work, because it sees that event, and bugs out. (This problem + doesn't exhibit itself without an extension, because in that case, + there's only one event generated by user activity, not two.) + */ + XCheckMaskEvent (si->dpy, (KeyPressMask|ButtonPressMask|PointerMotionMask), + &event); + + + if (si->check_pointer_timer_id) + { + XtRemoveTimeOut (si->check_pointer_timer_id); + si->check_pointer_timer_id = 0; + } + if (si->timer_id) + { + XtRemoveTimeOut (si->timer_id); + si->timer_id = 0; + } + + if (until_idle_p && si->cycle_id) + abort (); + + return; +} + + +/* This timer goes off every few minutes, whether the user is idle or not, + to try and clean up anything that has gone wrong. + + It calls disable_builtin_screensaver() so that if xset has been used, + or some other program (like xlock) has messed with the XSetScreenSaver() + settings, they will be set back to sensible values (if a server extension + is in use, messing with xlock can cause xscreensaver to never get a wakeup + event, and could cause monitor power-saving to occur, and all manner of + heinousness.) + + If the screen is currently blanked, it raises the window, in case some + other window has been mapped on top of it. + + If the screen is currently blanked, and there is no hack running, it + clears the window, in case there is an error message printed on it (we + don't want the error message to burn in.) + */ + +static void +watchdog_timer (XtPointer closure, XtIntervalId *id) +{ + saver_info *si = (saver_info *) closure; + if (!si->demo_mode_p) + { + disable_builtin_screensaver (si, False); + if (si->screen_blanked_p) + { + Bool running_p = screenhack_running_p(si); +#ifdef DEBUG_TIMERS + if (si->prefs.verbose_p) + printf ("%s: watchdog timer raising %sscreen.\n", + progname, (running_p ? "" : "and clearing ")); +#endif + raise_window (si, True, True, running_p); + } + } +} + + +void +reset_watchdog_timer (saver_info *si, Bool on_p) +{ + saver_preferences *p = &si->prefs; + + if (si->watchdog_id) + { + XtRemoveTimeOut (si->watchdog_id); + si->watchdog_id = 0; + } + + if (on_p && p->watchdog_timeout) + { + si->watchdog_id = XtAppAddTimeOut (si->app, p->watchdog_timeout, + watchdog_timer, (XtPointer) si); + +#ifdef DEBUG_TIMERS + if (p->verbose_p) + printf ("%s: restarting watchdog_timer (%ld, %ld)\n", + progname, p->watchdog_timeout, si->watchdog_id); +#endif + } +} diff --git a/driver/vms-getpwnam.c b/driver/vms-getpwnam.c new file mode 100644 index 00000000..9408bb54 --- /dev/null +++ b/driver/vms-getpwnam.c @@ -0,0 +1,132 @@ +/* + * getpwnam(name) - retrieves a UAF entry + * + * Author: Patrick L. Mahan + * Location: TGV, Inc + * Date: 15-Nov-1991 + * + * Purpose: Provides emulation for the UNIX getpwname routine. + * + * Modification History + * + * Date | Who | Version | Reason + * ------------+-----------+---------------+--------------------------- + * 15-Nov-1991 | PLM | 1.0 | First Write + */ + +#define PASSWDROUTINES + +#include +#include +#include +#include +#include +#include +#include "vms-pwd.h" + +struct uic { + unsigned short uid; + unsigned short gid; +}; + +#define TEST(ptr, str) { if (ptr == NULL) { \ + fprintf(stderr, "getpwnam: memory allocation failure for \"%s\"\n", \ + str); \ + return ((struct passwd *)(NULL)); \ + } } + +struct passwd *getpwnam(name) +char *name; +{ + int istatus; + int UserNameLen; + int UserOwnerLen; + int UserDeviceLen; + int UserDirLen; + static char UserName[13]; + static char UserOwner[32]; + static char UserDevice[32]; + static char UserDir[64]; + char *cptr, *sptr; + unsigned long int UserPwd[2]; + unsigned short int UserSalt; + unsigned long int UserEncrypt; + struct uic UicValue; + struct passwd *entry; + + struct dsc$descriptor_s VMSNAME = + {strlen(name), DSC$K_DTYPE_T, DSC$K_CLASS_S, name}; + + struct itmlist3 { + unsigned short int length; + unsigned short int item; + unsigned long int addr; + unsigned long int retaddr; + } ItemList[] = { + {12, UAI$_USERNAME, (unsigned long)&UserName, (unsigned long)&UserNameLen}, + {8, UAI$_PWD, (unsigned long)&UserPwd, 0}, + {4, UAI$_UIC, (unsigned long)&UicValue, 0}, + {32, UAI$_OWNER, (unsigned long)&UserOwner, (unsigned long)&UserOwnerLen}, + {32, UAI$_DEFDEV, (unsigned long)&UserDevice, (unsigned long)&UserDeviceLen}, + {64, UAI$_DEFDIR, (unsigned long)&UserDir, (unsigned long)&UserDirLen}, + {2, UAI$_SALT, (unsigned long)&UserSalt, 0}, + {4, UAI$_ENCRYPT, (unsigned long)&UserEncrypt, 0}, + {0, 0, 0, 0} + }; + + UserNameLen = 0; + istatus = sys$getuai (0, 0, &VMSNAME, &ItemList, 0, 0, 0); + + if (!(istatus & 1)) { +#ifdef DEBUG + lib$signal(istatus); +#endif /* DEBUG */ + fprintf (stderr, "getpwnam: unable to retrieve passwd entry for %s\n", + name); + fprintf (stderr, "getpwnam: vms error number is 0x%x\n", istatus); + return ((struct passwd *)NULL); + } + + entry = (struct passwd *) calloc (1, sizeof(struct passwd)); + TEST(entry, "PASSWD_ENTRY"); + + entry->pw_uid = UicValue.uid; + entry->pw_gid = UicValue.gid; + entry->pw_salt = UserSalt; + entry->pw_encrypt = UserEncrypt; + + sptr = UserName; + cptr = calloc (UserNameLen+1, sizeof(char)); + TEST(cptr, "USERNAME"); + strncpy (cptr, sptr, UserNameLen); + cptr[UserNameLen] = '\0'; + entry->pw_name = cptr; + + cptr = calloc(8, sizeof(char)); + TEST(cptr, "PASSWORD"); + memcpy(cptr, UserPwd, 8); + entry->pw_passwd = cptr; + + sptr = UserOwner; sptr++; + cptr = calloc ((int)UserOwner[0]+1, sizeof(char)); + TEST(cptr, "FULLNAME"); + strncpy (cptr, sptr, (int)UserOwner[0]); + cptr[(int)UserOwner[0]] = '\0'; + entry->pw_gecos = cptr; + + cptr = calloc ((int)UserDevice[0]+(int)UserDir[0]+1, sizeof(char)); + TEST(cptr, "HOME"); + sptr = UserDevice; sptr++; + strncpy (cptr, sptr, (int)UserDevice[0]); + sptr = UserDir; sptr++; + strncat (cptr, sptr, (int)UserDir[0]); + cptr[(int)UserDevice[0]+(int)UserDir[0]] = '\0'; + entry->pw_dir = cptr; + + cptr = calloc (strlen("SYS$SYSTEM:LOGINOUT.EXE")+1, sizeof(char)); + TEST(cptr,"SHELL"); + strcpy (cptr, "SYS$SYSTEM:LOGINOUT.EXE"); + entry->pw_shell = cptr; + + return (entry); +} diff --git a/driver/vms-hpwd.c b/driver/vms-hpwd.c new file mode 100644 index 00000000..707e3ea5 --- /dev/null +++ b/driver/vms-hpwd.c @@ -0,0 +1,75 @@ +/* + * VAX/VMS Password hashing routines: + * + * uses the System Service SYS$HASH_PASSWORD + * + * 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. + * + */ + +#include +#include +#include +#include +/* + * Hashing routine + */ +hash_vms_password(output_buf,input_buf,input_length,username,encryption_type,salt) +char *output_buf; +char *input_buf; +int input_length; +char *username; +int encryption_type; +unsigned short salt; +{ + struct dsc$descriptor_s password; + struct dsc$descriptor_s user; + + /* + * Check the VMS Version. If this is V5.4 or later, then + * we can use the new system service SYS$HASH_PASSWORD. Else + * fail and return garbage. + */ + + static char VMS_Version[32]; + struct { + unsigned short int Size; + unsigned short int Code; + char *Buffer; + unsigned short int *Resultant_Size; + } Item_List[2]={32, SYI$_VERSION, VMS_Version, 0, 0, 0}; + struct {int Size; char *Ptr;} Descr1; + + /* + * Get the information + */ + sys$getsyiw(0,0,0,Item_List,0,0,0); + /* + * Call the old routine if this isn't V5.4 or later... + */ +#ifndef __DECC + if ((VMS_Version[1] < '5') || + ((VMS_Version[1] == '5') && (VMS_Version[3] < '4'))) { + printf("Unsupported OS version\n"); + return(1); + } +#endif /* !__DECC */ + /* + * Call the SYS$HASH_PASSWORD system service... + */ + password.dsc$b_dtype = DSC$K_DTYPE_T; + password.dsc$b_class = DSC$K_CLASS_S; + password.dsc$w_length = input_length; + password.dsc$a_pointer = input_buf; + user.dsc$b_dtype = DSC$K_DTYPE_T; + user.dsc$b_class = DSC$K_CLASS_S; + user.dsc$w_length = strlen(username); + user.dsc$a_pointer = username; + sys$hash_password (&password, encryption_type, salt, &user, output_buf); +} diff --git a/driver/vms-pwd.h b/driver/vms-pwd.h new file mode 100644 index 00000000..6cb73d3e --- /dev/null +++ b/driver/vms-pwd.h @@ -0,0 +1,48 @@ +/* @(#)pwd.h 1.7 89/08/24 SMI; from S5R2 1.1 */ + +#ifndef __pwd_h +#define __pwd_h + +#ifdef vax11c +#include +#else +#include +#endif /* vax11c */ + +#ifdef PASSWDROUTINES +#define EXTERN +#else +#define EXTERN extern +#endif /* PASSWDROUTINES */ + +struct passwd { + char *pw_name; + char *pw_passwd; + int pw_uid; + int pw_gid; + short pw_salt; + int pw_encrypt; + char *pw_age; + char *pw_comment; + char *pw_gecos; + char *pw_dir; + char *pw_shell; +}; + + +#ifndef _POSIX_SOURCE +extern struct passwd *getpwent(); + +struct comment { + char *c_dept; + char *c_name; + char *c_acct; + char *c_bin; +}; + +#endif + +EXTERN struct passwd *getpwuid(/* uid_t uid */); +EXTERN struct passwd *getpwnam(/* char *name */); + +#endif /* !__pwd_h */ diff --git a/driver/vms-validate.c b/driver/vms-validate.c new file mode 100644 index 00000000..8f7141d6 --- /dev/null +++ b/driver/vms-validate.c @@ -0,0 +1,75 @@ +/* + * validate a password for a user + * + * 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. + */ + +/* + * Includes + */ +#include +#include +#include + +#include "vms-pwd.h" +int hash_vms_password(char *output_buf,char *input_buf,int input_length, + char *username,int encryption_type,unsigned short salt); + +/* + * + * Validate a VMS UserName/Password pair. + * + */ + +int validate_user(name,password) +char *name; +char *password; +{ + char password_buf[64]; + char username_buf[31]; + char encrypt_buf[8]; + register int i; + register char *cp,*cp1; + struct passwd *user_entry; + + /* + * Get the users UAF entry + */ + user_entry = getpwnam(name); + + /* + * If user_entry == NULL then we got a bad error + * return -1 to indicate a bad error + */ + if (user_entry == NULL) return (-1); + + /* + * Uppercase the password + */ + cp = password; + cp1 = password_buf; + while (*cp) + if (islower(*cp)) + *cp1++ = toupper(*cp++); + else + *cp1++ = *cp++; + /* + * Get the length of the password + */ + i = strlen(password); + /* + * Encrypt the password + */ + hash_vms_password(encrypt_buf,password_buf,i,user_entry->pw_name, + user_entry->pw_encrypt, user_entry->pw_salt); + if (memcmp(encrypt_buf,user_entry->pw_passwd,8) == 0) + return(1); + else return(0); +} + diff --git a/driver/vms_axp.opt b/driver/vms_axp.opt new file mode 100644 index 00000000..04d465df --- /dev/null +++ b/driver/vms_axp.opt @@ -0,0 +1,5 @@ +[-.UTILS]UTILS.OLB_AXP/LIB +SYS$SHARE:DECW$XMLIBSHR.EXE/SHARE +SYS$SHARE:DECW$XMULIBSHR.EXE/SHARE +SYS$SHARE:DECW$XTSHR.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/driver/vms_axp_12.opt b/driver/vms_axp_12.opt new file mode 100644 index 00000000..25dd1f18 --- /dev/null +++ b/driver/vms_axp_12.opt @@ -0,0 +1,5 @@ +[-.UTILS]UTILS.OLB_AXP/LIB +SYS$SHARE:DECW$XMLIBSHR12.EXE/SHARE +SYS$SHARE:DECW$XMULIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XTLIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/driver/vms_decc.opt b/driver/vms_decc.opt new file mode 100644 index 00000000..65bec033 --- /dev/null +++ b/driver/vms_decc.opt @@ -0,0 +1,5 @@ +[-.UTILS]UTILS.OLB_DECC/LIB +SYS$SHARE:DECW$XMLIBSHR.EXE/SHARE +SYS$SHARE:DECW$XMULIBSHR.EXE/SHARE +SYS$SHARE:DECW$XTSHR.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/driver/vms_decc_12.opt b/driver/vms_decc_12.opt new file mode 100644 index 00000000..fdd9a802 --- /dev/null +++ b/driver/vms_decc_12.opt @@ -0,0 +1,5 @@ +[-.UTILS]UTILS.OLB_DECC/LIB +SYS$SHARE:DECW$XMLIBSHR12.EXE/SHARE +SYS$SHARE:DECW$XMULIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XTLIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/driver/windows.c b/driver/windows.c new file mode 100644 index 00000000..7a938c5a --- /dev/null +++ b/driver/windows.c @@ -0,0 +1,1148 @@ +/* windows.c --- turning the screen black; dealing with visuals, virtual roots. + * xscreensaver, Copyright (c) 1991-1998 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#ifdef VMS +# include /* for getpid() */ +# include "vms-gtod.h" /* for gettimeofday() */ +# if !defined(HAVE_UNAME) && (__VMS_VER >= 70000000) +# define HAVE_UNAME 1 +# endif /* !HAVE_UNAME */ +#endif /* VMS */ + +# ifdef HAVE_UNAME +# include /* for uname() */ +# endif /* HAVE_UNAME */ + +#include +#include /* for CARD32 */ +#include +#include /* for XSetClassHint() */ +#include +#include /* for time() */ +#include /* for the signal names */ + +#ifdef HAVE_MIT_SAVER_EXTENSION +# include +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + +#ifdef HAVE_XHPDISABLERESET +# include + + /* Calls to XHPDisableReset and XHPEnableReset must be balanced, + or BadAccess errors occur. (Ok for this to be global, since it + affects the whole machine, not just the current screen.) */ + Bool hp_locked_p = False; + +#endif /* HAVE_XHPDISABLERESET */ + + +/* This file doesn't need the Xt headers, so stub these types out... */ +#undef XtPointer +#define XtAppContext void* +#define XrmDatabase void* +#define XtIntervalId void* +#define XtPointer void* +#define Widget void* + +#include "xscreensaver.h" +#include "visual.h" +#include "fade.h" + +extern int kill (pid_t, int); /* signal() is in sys/signal.h... */ + +Atom XA_VROOT, XA_XSETROOT_ID; +Atom XA_SCREENSAVER_VERSION, XA_SCREENSAVER_ID; +Atom XA_SCREENSAVER_TIME; + + +extern saver_info *global_si_kludge; /* I hate C so much... */ + + +static void store_activate_time (saver_info *si, Bool use_last_p); + +#define ALL_POINTER_EVENTS \ + (ButtonPressMask | ButtonReleaseMask | EnterWindowMask | \ + LeaveWindowMask | PointerMotionMask | PointerMotionHintMask | \ + Button1MotionMask | Button2MotionMask | Button3MotionMask | \ + Button4MotionMask | Button5MotionMask | ButtonMotionMask) + +/* I don't really understand Sync vs Async, but these seem to work... */ +#define grab_kbd(dpy,win) \ + XGrabKeyboard ((dpy), (win), True, GrabModeSync, GrabModeAsync, CurrentTime) +#define grab_mouse(dpy,win,cursor) \ + XGrabPointer ((dpy), (win), True, ALL_POINTER_EVENTS, \ + GrabModeAsync, GrabModeAsync, None, cursor, CurrentTime) + +void +grab_keyboard_and_mouse (Display *dpy, Window window, Cursor cursor) +{ + Status status; + XSync (dpy, False); + + status = grab_kbd (dpy, window); + if (status != GrabSuccess) + { /* try again in a second */ + sleep (1); + status = grab_kbd (dpy, window); + if (status != GrabSuccess) + fprintf (stderr, "%s: couldn't grab keyboard! (%d)\n", + progname, status); + } + status = grab_mouse (dpy, window, cursor); + if (status != GrabSuccess) + { /* try again in a second */ + sleep (1); + status = grab_mouse (dpy, window, cursor); + if (status != GrabSuccess) + fprintf (stderr, "%s: couldn't grab pointer! (%d)\n", + progname, status); + } +} + +void +ungrab_keyboard_and_mouse (Display *dpy) +{ + XUngrabPointer (dpy, CurrentTime); + XUngrabKeyboard (dpy, CurrentTime); +} + + +void +ensure_no_screensaver_running (Display *dpy, Screen *screen) +{ + int i; + Window root = RootWindowOfScreen (screen); + Window root2, parent, *kids; + unsigned int nkids; + XErrorHandler old_handler = XSetErrorHandler (BadWindow_ehandler); + + if (! XQueryTree (dpy, root, &root2, &parent, &kids, &nkids)) + abort (); + if (root != root2) + abort (); + if (parent) + abort (); + for (i = 0; i < nkids; i++) + { + Atom type; + int format; + unsigned long nitems, bytesafter; + char *version; + + if (XGetWindowProperty (dpy, kids[i], XA_SCREENSAVER_VERSION, 0, 1, + False, XA_STRING, &type, &format, &nitems, + &bytesafter, (unsigned char **) &version) + == Success + && type != None) + { + char *id; + if (!XGetWindowProperty (dpy, kids[i], XA_SCREENSAVER_ID, 0, 512, + False, XA_STRING, &type, &format, &nitems, + &bytesafter, (unsigned char **) &id) + == Success + || type == None) + id = "???"; + + fprintf (stderr, + "%s: already running on display %s (window 0x%x)\n from process %s.\n", + progname, DisplayString (dpy), (int) kids [i], id); + exit (1); + } + } + + if (kids) XFree ((char *) kids); + XSync (dpy, False); + XSetErrorHandler (old_handler); +} + + + +/* Virtual-root hackery */ + +#ifdef _VROOT_H_ +ERROR! You must not include vroot.h in this file. +#endif + +static void +store_vroot_property (Display *dpy, Window win, Window value) +{ +#if 0 + if (p->verbose_p) + fprintf (stderr, + "%s: storing XA_VROOT = 0x%x (%s) = 0x%x (%s)\n", progname, + win, + (win == screensaver_window ? "ScreenSaver" : + (win == real_vroot ? "VRoot" : + (win == real_vroot_value ? "Vroot_value" : "???"))), + value, + (value == screensaver_window ? "ScreenSaver" : + (value == real_vroot ? "VRoot" : + (value == real_vroot_value ? "Vroot_value" : "???")))); +#endif + XChangeProperty (dpy, win, XA_VROOT, XA_WINDOW, 32, PropModeReplace, + (unsigned char *) &value, 1); +} + +static void +remove_vroot_property (Display *dpy, Window win) +{ +#if 0 + if (p->verbose_p) + fprintf (stderr, "%s: removing XA_VROOT from 0x%x (%s)\n", progname, win, + (win == screensaver_window ? "ScreenSaver" : + (win == real_vroot ? "VRoot" : + (win == real_vroot_value ? "Vroot_value" : "???")))); +#endif + XDeleteProperty (dpy, win, XA_VROOT); +} + + +static void +kill_xsetroot_data (Display *dpy, Window window, Bool verbose_p) +{ + Atom type; + int format; + unsigned long nitems, bytesafter; + Pixmap *dataP = 0; + + /* If the user has been using xv or xsetroot as a screensaver (to display + an image on the screensaver window, as a kind of slideshow) then the + pixmap and its associated color cells have been put in RetainPermanent + CloseDown mode. Since we're not destroying the xscreensaver window, + but merely unmapping it, we need to free these resources or those + colormap cells will stay allocated while the screensaver is off. (We + could just delete the screensaver window and recreate it later, but + that could cause other problems.) This code does an atomic read-and- + delete of the _XSETROOT_ID property, and if it held a pixmap, then we + cause the RetainPermanent resources of the client which created it + (and which no longer exists) to be freed. + */ + if (XGetWindowProperty (dpy, window, XA_XSETROOT_ID, 0, 1, + True, AnyPropertyType, &type, &format, &nitems, + &bytesafter, (unsigned char **) &dataP) + == Success + && type != None) + { + if (dataP && *dataP && type == XA_PIXMAP && format == 32 && + nitems == 1 && bytesafter == 0) + { + if (verbose_p) + printf ("%s: destroying xsetroot data (0x%lX).\n", + progname, *dataP); + XKillClient (dpy, *dataP); + } + else + fprintf (stderr, "%s: deleted unrecognised _XSETROOT_ID property: \n\ + %lu, %lu; type: %lu, format: %d, nitems: %lu, bytesafter %ld\n", + progname, (unsigned long) dataP, (dataP ? *dataP : 0), type, + format, nitems, bytesafter); + } +} + + +static void handle_signals (saver_info *si, Bool on_p); + +static void +save_real_vroot (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + Display *dpy = si->dpy; + Screen *screen = ssi->screen; + int i; + Window root = RootWindowOfScreen (screen); + Window root2, parent, *kids; + unsigned int nkids; + + ssi->real_vroot = 0; + ssi->real_vroot_value = 0; + if (! XQueryTree (dpy, root, &root2, &parent, &kids, &nkids)) + abort (); + if (root != root2) + abort (); + if (parent) + abort (); + for (i = 0; i < nkids; i++) + { + Atom type; + int format; + unsigned long nitems, bytesafter; + Window *vrootP = 0; + + if (XGetWindowProperty (dpy, kids[i], XA_VROOT, 0, 1, False, XA_WINDOW, + &type, &format, &nitems, &bytesafter, + (unsigned char **) &vrootP) + != Success) + continue; + if (! vrootP) + continue; + if (ssi->real_vroot) + { + if (*vrootP == ssi->screensaver_window) abort (); + fprintf (stderr, + "%s: more than one virtual root window found (0x%x and 0x%x).\n", + progname, (int) ssi->real_vroot, (int) kids [i]); + exit (1); + } + ssi->real_vroot = kids [i]; + ssi->real_vroot_value = *vrootP; + } + + if (ssi->real_vroot) + { + handle_signals (si, True); + remove_vroot_property (si->dpy, ssi->real_vroot); + XSync (dpy, False); + } + + XFree ((char *) kids); +} + + +static Bool +restore_real_vroot_2 (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + if (p->verbose_p && ssi->real_vroot) + printf ("%s: restoring __SWM_VROOT property on the real vroot (0x%lx).\n", + progname, (unsigned long) ssi->real_vroot); + remove_vroot_property (si->dpy, ssi->screensaver_window); + if (ssi->real_vroot) + { + store_vroot_property (si->dpy, ssi->real_vroot, ssi->real_vroot_value); + ssi->real_vroot = 0; + ssi->real_vroot_value = 0; + /* make sure the property change gets there before this process + terminates! We might be doing this because we have intercepted + SIGTERM or something. */ + XSync (si->dpy, False); + return True; + } + return False; +} + +static Bool +restore_real_vroot_1 (saver_info *si) +{ + int i; + Bool did_any = False; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (restore_real_vroot_2 (ssi)) + did_any = True; + } + return did_any; +} + +void +restore_real_vroot (saver_info *si) +{ + if (restore_real_vroot_1 (si)) + handle_signals (si, False); +} + + +/* Signal hackery to ensure that the vroot doesn't get left in an + inconsistent state + */ + +const char * +signal_name(int signal) +{ + switch (signal) { + case SIGHUP: return "SIGHUP"; + case SIGINT: return "SIGINT"; + case SIGQUIT: return "SIGQUIT"; + case SIGILL: return "SIGILL"; + case SIGTRAP: return "SIGTRAP"; +#ifdef SIGABRT + case SIGABRT: return "SIGABRT"; +#endif + case SIGFPE: return "SIGFPE"; + case SIGKILL: return "SIGKILL"; + case SIGBUS: return "SIGBUS"; + case SIGSEGV: return "SIGSEGV"; + case SIGPIPE: return "SIGPIPE"; + case SIGALRM: return "SIGALRM"; + case SIGTERM: return "SIGTERM"; +#ifdef SIGSTOP + case SIGSTOP: return "SIGSTOP"; +#endif +#ifdef SIGCONT + case SIGCONT: return "SIGCONT"; +#endif +#ifdef SIGUSR1 + case SIGUSR1: return "SIGUSR1"; +#endif +#ifdef SIGUSR2 + case SIGUSR2: return "SIGUSR2"; +#endif +#ifdef SIGEMT + case SIGEMT: return "SIGEMT"; +#endif +#ifdef SIGSYS + case SIGSYS: return "SIGSYS"; +#endif +#ifdef SIGCHLD + case SIGCHLD: return "SIGCHLD"; +#endif +#ifdef SIGPWR + case SIGPWR: return "SIGPWR"; +#endif +#ifdef SIGWINCH + case SIGWINCH: return "SIGWINCH"; +#endif +#ifdef SIGURG + case SIGURG: return "SIGURG"; +#endif +#ifdef SIGIO + case SIGIO: return "SIGIO"; +#endif +#ifdef SIGVTALRM + case SIGVTALRM: return "SIGVTALRM"; +#endif +#ifdef SIGXCPU + case SIGXCPU: return "SIGXCPU"; +#endif +#ifdef SIGXFSZ + case SIGXFSZ: return "SIGXFSZ"; +#endif +#ifdef SIGDANGER + case SIGDANGER: return "SIGDANGER"; +#endif + default: + { + static char buf[50]; + sprintf(buf, "signal %d\n", signal); + return buf; + } + } +} + + + +static RETSIGTYPE +restore_real_vroot_handler (int sig) +{ + saver_info *si = global_si_kludge; /* I hate C so much... */ + + signal (sig, SIG_DFL); + if (restore_real_vroot_1 (si)) + fprintf (real_stderr, "\n%s: %s intercepted, vroot restored.\n", + progname, signal_name(sig)); + kill (getpid (), sig); +} + +static void +catch_signal (saver_info *si, int sig, Bool on_p) +{ + if (! on_p) + signal (sig, SIG_DFL); + else + { + if (((long) signal (sig, restore_real_vroot_handler)) == -1L) + { + char buf [255]; + sprintf (buf, "%s: couldn't catch %s", progname, signal_name(sig)); + perror (buf); + saver_exit (si, 1); + } + } +} + +static void +handle_signals (saver_info *si, Bool on_p) +{ +#if 0 + if (on_p) printf ("handling signals\n"); + else printf ("unhandling signals\n"); +#endif + + catch_signal (si, SIGHUP, on_p); + catch_signal (si, SIGINT, on_p); + catch_signal (si, SIGQUIT, on_p); + catch_signal (si, SIGILL, on_p); + catch_signal (si, SIGTRAP, on_p); + catch_signal (si, SIGIOT, on_p); + catch_signal (si, SIGABRT, on_p); +#ifdef SIGEMT + catch_signal (si, SIGEMT, on_p); +#endif + catch_signal (si, SIGFPE, on_p); + catch_signal (si, SIGBUS, on_p); + catch_signal (si, SIGSEGV, on_p); +#ifdef SIGSYS + catch_signal (si, SIGSYS, on_p); +#endif + catch_signal (si, SIGTERM, on_p); +#ifdef SIGXCPU + catch_signal (si, SIGXCPU, on_p); +#endif +#ifdef SIGXFSZ + catch_signal (si, SIGXFSZ, on_p); +#endif +#ifdef SIGDANGER + catch_signal (si, SIGDANGER, on_p); +#endif +} + +void +saver_exit (saver_info *si, int status) +{ + saver_preferences *p = &si->prefs; + static Bool exiting = False; + Bool vrs; + + if (exiting) + exit(status); + + exiting = True; + + vrs = restore_real_vroot_1 (si); + emergency_kill_subproc (si); + + if (vrs && (p->verbose_p || status != 0)) + fprintf (real_stderr, "%s: vroot restored, exiting.\n", progname); + else if (p->verbose_p) + fprintf (real_stderr, "%s: no vroot to restore; exiting.\n", progname); + + fflush(real_stdout); + +#ifdef VMS /* on VMS, 1 is the "normal" exit code instead of 0. */ + if (status == 0) status = 1; + else if (status == 1) status = -1; +#endif + +#ifdef DEBUG + if (si->prefs.debug_p) + /* Do this to drop a core file, so that we can get a stack trace. */ + abort(); +#endif + + exit (status); +} + + +/* Managing the actual screensaver window */ + +Bool +window_exists_p (Display *dpy, Window window) +{ + XErrorHandler old_handler; + XWindowAttributes xgwa; + xgwa.screen = 0; + old_handler = XSetErrorHandler (BadWindow_ehandler); + XGetWindowAttributes (dpy, window, &xgwa); + XSync (dpy, False); + XSetErrorHandler (old_handler); + return (xgwa.screen != 0); +} + +static void +initialize_screensaver_window_1 (saver_screen_info *ssi) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + Bool install_cmap_p = ssi->install_cmap_p; + + /* This resets the screensaver window as fully as possible, since there's + no way of knowing what some random client may have done to us in the + meantime. We could just destroy and recreate the window, but that has + its own set of problems... + */ + XColor black; + XClassHint class_hints; + XSetWindowAttributes attrs; + unsigned long attrmask; + int width = WidthOfScreen (ssi->screen); + int height = HeightOfScreen (ssi->screen); + char id [2048]; + static Bool printed_visual_info = False; /* only print the message once. */ + + black.red = black.green = black.blue = 0; + + if (ssi->cmap == DefaultColormapOfScreen (ssi->screen)) + ssi->cmap = 0; + + if (ssi->current_visual != DefaultVisualOfScreen (ssi->screen)) + install_cmap_p = True; + + if (install_cmap_p) + { + if (! ssi->cmap) + { + ssi->cmap = XCreateColormap (si->dpy, RootWindowOfScreen (ssi->screen), + ssi->current_visual, AllocNone); + if (! XAllocColor (si->dpy, ssi->cmap, &black)) abort (); + ssi->black_pixel = black.pixel; + } + } + else + { + Colormap def_cmap = DefaultColormapOfScreen (ssi->screen); + if (ssi->cmap) + { + XFreeColors (si->dpy, ssi->cmap, &ssi->black_pixel, 1, 0); + if (ssi->cmap != ssi->demo_cmap && + ssi->cmap != def_cmap) + XFreeColormap (si->dpy, ssi->cmap); + } + ssi->cmap = def_cmap; + ssi->black_pixel = BlackPixelOfScreen (ssi->screen); + } + + attrmask = (CWOverrideRedirect | CWEventMask | CWBackingStore | CWColormap | + CWBackPixel | CWBackingPixel | CWBorderPixel); + attrs.override_redirect = True; + + /* When use_mit_saver_extension or use_sgi_saver_extension is true, we won't + actually be reading these events during normal operation; but we still + need to see Button events for demo-mode to work properly. + */ + attrs.event_mask = (KeyPressMask | KeyReleaseMask | + ButtonPressMask | ButtonReleaseMask | + PointerMotionMask); + + attrs.backing_store = NotUseful; + attrs.colormap = ssi->cmap; + attrs.background_pixel = ssi->black_pixel; + attrs.backing_pixel = ssi->black_pixel; + attrs.border_pixel = ssi->black_pixel; + +#ifdef DEBUG + if (p->debug_p) width = width / 2; +#endif /* DEBUG */ + + if (!p->verbose_p || printed_visual_info) + ; + else if (ssi->current_visual == DefaultVisualOfScreen (ssi->screen)) + { + fprintf (stderr, "%s: using default visual ", progname); + describe_visual (stderr, ssi->screen, ssi->current_visual); + } + else + { + fprintf (stderr, "%s: using visual: ", progname); + describe_visual (stderr, ssi->screen, ssi->current_visual); + fprintf (stderr, "%s: default visual: ", progname); + describe_visual (stderr, ssi->screen, + DefaultVisualOfScreen (ssi->screen)); + } + printed_visual_info = True; + +#ifdef HAVE_MIT_SAVER_EXTENSION + if (p->use_mit_saver_extension) + { + XScreenSaverInfo *info; + Window root = RootWindowOfScreen (ssi->screen); + +#if 0 + /* This call sets the server screensaver timeouts to what we think + they should be (based on the resources and args xscreensaver was + started with.) It's important that we do this to sync back up + with the server - if we have turned on prematurely, as by an + ACTIVATE ClientMessage, then the server may decide to activate + the screensaver while it's already active. That's ok for us, + since we would know to ignore that ScreenSaverActivate event, + but a side effect of this would be that the server would map its + saver window (which we then hide again right away) meaning that + the bits currently on the screen get blown away. Ugly. */ + + /* #### Ok, that doesn't work - when we tell the server that the + screensaver is "off" it sends us a Deactivate event, which is + sensible... but causes the saver to never come on. Hmm. */ + disable_builtin_screensaver (si, True); +#endif /* 0 */ + +#if 0 + /* #### The MIT-SCREEN-SAVER extension gives us access to the + window that the server itself uses for saving the screen. + However, using this window in any way, in particular, calling + XScreenSaverSetAttributes() as below, tends to make the X server + crash. So fuck it, let's try and get along without using it... + + It's also inconvenient to use this window because it doesn't + always exist (though the ID is constant.) So to use this + window, we'd have to reimplement the ACTIVATE ClientMessage to + tell the *server* to tell *us* to turn on, to cause the window + to get created at the right time. Gag. */ + XScreenSaverSetAttributes (si->dpy, root, + 0, 0, width, height, 0, + current_depth, InputOutput, visual, + attrmask, &attrs); + XSync (si->dpy, False); +#endif /* 0 */ + + info = XScreenSaverAllocInfo (); + XScreenSaverQueryInfo (si->dpy, root, info); + ssi->server_mit_saver_window = info->window; + if (! ssi->server_mit_saver_window) abort (); + XFree (info); + } +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + if (ssi->screensaver_window) + { + XWindowChanges changes; + unsigned int changesmask = CWX|CWY|CWWidth|CWHeight|CWBorderWidth; + changes.x = 0; + changes.y = 0; + changes.width = width; + changes.height = height; + changes.border_width = 0; + + XConfigureWindow (si->dpy, ssi->screensaver_window, + changesmask, &changes); + XChangeWindowAttributes (si->dpy, ssi->screensaver_window, + attrmask, &attrs); + } + else + { + ssi->screensaver_window = + XCreateWindow (si->dpy, RootWindowOfScreen (ssi->screen), 0, 0, + width, height, 0, ssi->current_depth, InputOutput, + ssi->current_visual, attrmask, &attrs); + reset_stderr (ssi); + store_activate_time(si, True); + if (p->verbose_p) + fprintf (stderr, "%s: saver window is 0x%lx.\n", + progname, (unsigned long) ssi->screensaver_window); + } + +#ifdef HAVE_MIT_SAVER_EXTENSION + if (!p->use_mit_saver_extension || + window_exists_p (si->dpy, ssi->screensaver_window)) + /* When using the MIT-SCREEN-SAVER extension, the window pointed to + by screensaver_window only exists while the saver is active. + So we must be careful to only try and manipulate it while it + exists... + (#### The above comment would be true if the MIT extension actually + worked, but it's not true today -- see `server_mit_saver_window'.) + */ +#endif /* HAVE_MIT_SAVER_EXTENSION */ + { + class_hints.res_name = progname; + class_hints.res_class = progclass; + XSetClassHint (si->dpy, ssi->screensaver_window, &class_hints); + XStoreName (si->dpy, ssi->screensaver_window, "screensaver"); + XChangeProperty (si->dpy, ssi->screensaver_window, + XA_SCREENSAVER_VERSION, + XA_STRING, 8, PropModeReplace, + (unsigned char *) si->version, + strlen (si->version)); + + sprintf (id, "%lu on host ", (unsigned long) getpid ()); + +# if defined(HAVE_UNAME) + { + struct utsname uts; + if (uname (&uts) < 0) + strcat (id, "???"); + else + strcat (id, uts.nodename); + } +# elif defined(VMS) + strcat (id, getenv("SYS$NODE")); +# else /* !HAVE_UNAME && !VMS */ + strcat (id, "???"); +# endif /* !HAVE_UNAME && !VMS */ + + XChangeProperty (si->dpy, ssi->screensaver_window, + XA_SCREENSAVER_ID, XA_STRING, + 8, PropModeReplace, (unsigned char *) id, strlen (id)); + + if (!ssi->cursor) + { + Pixmap bit; + bit = XCreatePixmapFromBitmapData (si->dpy, ssi->screensaver_window, + "\000", 1, 1, + BlackPixelOfScreen (ssi->screen), + BlackPixelOfScreen (ssi->screen), + 1); + ssi->cursor = XCreatePixmapCursor (si->dpy, bit, bit, &black, &black, + 0, 0); + XFreePixmap (si->dpy, bit); + } + + XSetWindowBackground (si->dpy, ssi->screensaver_window, + ssi->black_pixel); + if (si->demo_mode_p) + XUndefineCursor (si->dpy, ssi->screensaver_window); + else + XDefineCursor (si->dpy, ssi->screensaver_window, ssi->cursor); + } +} + +void +initialize_screensaver_window (saver_info *si) +{ + int i; + for (i = 0; i < si->nscreens; i++) + initialize_screensaver_window_1 (&si->screens[i]); +} + + +void +raise_window (saver_info *si, + Bool inhibit_fade, Bool between_hacks_p, Bool dont_clear) +{ + saver_preferences *p = &si->prefs; + int i; + + initialize_screensaver_window (si); + reset_watchdog_timer (si, True); + + if (p->fade_p && !inhibit_fade && !si->demo_mode_p) + { + int grabbed = -1; + Window *current_windows = (Window *) + calloc(sizeof(Window), si->nscreens); + Colormap *current_maps = (Colormap *) + calloc(sizeof(Colormap), si->nscreens); + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + current_windows[i] = ssi->screensaver_window; + current_maps[i] = (between_hacks_p + ? ssi->cmap + : DefaultColormapOfScreen (ssi->screen)); + /* Ensure that the default background of the window is really black, + not a pixmap or something. (This does not clear the window.) */ + XSetWindowBackground (si->dpy, ssi->screensaver_window, + ssi->black_pixel); + } + + if (p->verbose_p) fprintf (stderr, "%s: fading... ", progname); + + XGrabServer (si->dpy); + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + + /* grab and blacken mouse on the root window (saver not mapped yet) + */ + if (grabbed != GrabSuccess) + grabbed = grab_mouse (si->dpy, ssi->screensaver_window, + (si->demo_mode_p ? 0 : ssi->cursor)); + + if (!dont_clear || ssi->stderr_overlay_window) + /* Do this before the fade, since the stderr cmap won't fade + even if we uninstall it (beats me...) */ + clear_stderr (ssi); + } + + fade_screens (si->dpy, current_maps, current_windows, + p->fade_seconds, p->fade_ticks, True, !dont_clear); + free(current_maps); + free(current_windows); + current_maps = 0; + current_windows = 0; + + if (p->verbose_p) fprintf (stderr, "fading done.\n"); + +#ifdef HAVE_MIT_SAVER_EXTENSION + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->server_mit_saver_window && + window_exists_p (si->dpy, ssi->server_mit_saver_window)) + XUnmapWindow (si->dpy, ssi->server_mit_saver_window); + } +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + if (grabbed == GrabSuccess) + XUngrabPointer (si->dpy, CurrentTime); + XUngrabServer (si->dpy); + } + else + { + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (!dont_clear) + XClearWindow (si->dpy, ssi->screensaver_window); + if (!dont_clear || ssi->stderr_overlay_window) + clear_stderr (ssi); + XMapRaised (si->dpy, ssi->screensaver_window); +#ifdef HAVE_MIT_SAVER_EXTENSION + if (ssi->server_mit_saver_window && + window_exists_p (si->dpy, ssi->server_mit_saver_window)) + XUnmapWindow (si->dpy, ssi->server_mit_saver_window); +#endif /* HAVE_MIT_SAVER_EXTENSION */ + } + } + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->cmap) + XInstallColormap (si->dpy, ssi->cmap); + } +} + +void +blank_screen (saver_info *si) +{ + int i; + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + + save_real_vroot (ssi); + store_vroot_property (si->dpy, + ssi->screensaver_window, + ssi->screensaver_window); + } + store_activate_time (si, si->screen_blanked_p); + raise_window (si, False, False, False); + /* #### */ + grab_keyboard_and_mouse (si->dpy, si->screens[0].screensaver_window, + (si->demo_mode_p ? 0 : si->screens[0].cursor)); +#ifdef HAVE_XHPDISABLERESET + if (si->locked_p && !hp_locked_p) + { + XHPDisableReset (si->dpy); /* turn off C-Sh-Reset */ + hp_locked_p = True; + } +#endif + + si->screen_blanked_p = True; +} + +void +unblank_screen (saver_info *si) +{ + saver_preferences *p = &si->prefs; + int i; + + store_activate_time (si, True); + reset_watchdog_timer (si, False); + + if (p->unfade_p && !si->demo_mode_p) + { + int grabbed = -1; + Window *current_windows = (Window *) + calloc(sizeof(Window), si->nscreens); + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + current_windows[i] = ssi->screensaver_window; + /* Ensure that the default background of the window is really black, + not a pixmap or something. (This does not clear the window.) */ + XSetWindowBackground (si->dpy, ssi->screensaver_window, + ssi->black_pixel); + } + + if (p->verbose_p) fprintf (stderr, "%s: unfading... ", progname); + + XSync (si->dpy, False); + XGrabServer (si->dpy); + XSync (si->dpy, False); + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (grabbed != GrabSuccess) + grabbed = grab_mouse (si->dpy, RootWindowOfScreen (ssi->screen), + 0); + clear_stderr (ssi); + } + XUngrabServer (si->dpy); + XSync (si->dpy, False); + + fade_screens (si->dpy, 0, current_windows, + p->fade_seconds, p->fade_ticks, + False, False); + + free(current_windows); + current_windows = 0; + + if (p->verbose_p) fprintf (stderr, "unfading done.\n"); + if (grabbed == GrabSuccess) + XUngrabPointer (si->dpy, CurrentTime); + } + else + { + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (ssi->cmap) + { + Colormap c = DefaultColormapOfScreen (ssi->screen); + /* avoid technicolor */ + XClearWindow (si->dpy, ssi->screensaver_window); + if (c) XInstallColormap (si->dpy, c); + } + XUnmapWindow (si->dpy, ssi->screensaver_window); + } + } + + + /* If the focus window does has a non-default colormap, then install + that colormap as well. (On SGIs, this will cause both the root map + and the focus map to be installed simultaniously. It'd be nice to + pick up the other colormaps that had been installed, too; perhaps + XListInstalledColormaps could be used for that?) + */ + { + Window focus = 0; + int revert_to; + XGetInputFocus (si->dpy, &focus, &revert_to); + if (focus && focus != PointerRoot && focus != None) + { + XWindowAttributes xgwa; + xgwa.colormap = 0; + XGetWindowAttributes (si->dpy, focus, &xgwa); + if (xgwa.colormap && + xgwa.colormap != DefaultColormapOfScreen (xgwa.screen)) + XInstallColormap (si->dpy, xgwa.colormap); + } + } + + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + kill_xsetroot_data (si->dpy, ssi->screensaver_window, p->verbose_p); + } + + store_activate_time(si, False); /* store unblank time */ + + ungrab_keyboard_and_mouse (si->dpy); + restore_real_vroot (si); + +#ifdef HAVE_XHPDISABLERESET + if (hp_locked_p) + { + XHPEnableReset (si->dpy); /* turn C-Sh-Reset back on */ + hp_locked_p = False; + } +#endif + + /* Unmap the windows a second time, dammit -- just to avoid a race + with the screen-grabbing hacks. (I'm not sure if this is really + necessary; I'm stabbing in the dark now.) + */ + for (i = 0; i < si->nscreens; i++) + XUnmapWindow (si->dpy, si->screens[i].screensaver_window); + + si->screen_blanked_p = False; +} + + +static void +store_activate_time (saver_info *si, Bool use_last_p) +{ + static time_t last_time = 0; + time_t now = ((use_last_p && last_time) ? last_time : time ((time_t) 0)); + CARD32 now32 = (CARD32) now; + int i; + last_time = now; + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + if (!ssi->screensaver_window) continue; + XChangeProperty (si->dpy, ssi->screensaver_window, XA_SCREENSAVER_TIME, + XA_INTEGER, 32, PropModeReplace, + (unsigned char *) &now32, 1); + } +} + + +Bool +select_visual (saver_screen_info *ssi, const char *visual_name) +{ + saver_info *si = ssi->global; + saver_preferences *p = &si->prefs; + Bool install_cmap_p = p->install_cmap_p; + Bool was_installed_p = (ssi->cmap != DefaultColormapOfScreen(ssi->screen)); + Visual *new_v; + Bool got_it; + + if (visual_name && *visual_name) + { + if (!strcmp(visual_name, "default-i")) + { + visual_name = "default"; + install_cmap_p = True; + } + else if (!strcmp(visual_name, "default-n")) + { + visual_name = "default"; + install_cmap_p = False; + } + new_v = get_visual (ssi->screen, visual_name, True, False); + } + else + { + new_v = ssi->default_visual; + } + + got_it = !!new_v; + + if (new_v && new_v != DefaultVisualOfScreen(ssi->screen)) + install_cmap_p = True; + + ssi->install_cmap_p = install_cmap_p; + + if (new_v && + ((ssi->current_visual != new_v) || + (install_cmap_p != was_installed_p))) + { + Colormap old_c = ssi->cmap; + Window old_w = ssi->screensaver_window; + + if (p->verbose_p) + { +#if 0 + fprintf (stderr, "%s: switching visuals\tfrom: ", progname); + describe_visual (stderr, ssi->screen, ssi->current_visual); + fprintf (stderr, "\t\t\t\tto: "); + describe_visual (stderr, ssi->screen, new_v); + fprintf (stderr, "\t\t\t\t install cmap: %s\n", + (install_cmap_p ? "yes" : "no")); +#else + fprintf (stderr, "%s: switching to visual ", progname); + describe_visual (stderr, ssi->screen, new_v); +#endif + } + + reset_stderr (ssi); + ssi->current_visual = new_v; + ssi->current_depth = visual_depth(ssi->screen, new_v); + ssi->cmap = 0; + ssi->screensaver_window = 0; + + initialize_screensaver_window_1 (ssi); + raise_window (si, True, True, False); + store_vroot_property (si->dpy, + ssi->screensaver_window, ssi->screensaver_window); + store_activate_time (si, True); + + XDestroyWindow (si->dpy, old_w); + if (old_c && + old_c != DefaultColormapOfScreen (ssi->screen) && + old_c != ssi->demo_cmap) + XFreeColormap (si->dpy, old_c); + } + + return got_it; +} diff --git a/driver/xscreensaver-command.c b/driver/xscreensaver-command.c new file mode 100644 index 00000000..2d7f3326 --- /dev/null +++ b/driver/xscreensaver-command.c @@ -0,0 +1,260 @@ +/* xscreensaver-command, Copyright (c) 1991-1997 + * 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include /* for CARD32 */ +#include +#include +#include /* for XGetClassHint() */ +#include +#include + +#include "version.h" + +#ifdef _VROOT_H_ +ERROR! you must not include vroot.h in this file +#endif + +static char *screensaver_version; +static char *usage = "usage: %s -\n\ +\n\ + This program provides external control of a running xscreensaver process.\n\ + Version %s, copyright (c) 1991-1997 Jamie Zawinski .\n\ +\n\ + -demo Enter interactive demo mode.\n\ + -deactivate Turns off the screensaver if it is on, as user input would.\n\ + -activate Turns it on as if the user had been idle for long enough.\n\ + -cycle Stops the current graphics hack and runs a new one.\n\ + -next Like either -activate or -cycle, depending on which is more\n\ + appropriate, except that the screenhack that will be run is\n\ + the next one in the list of hacks, instead of a randomly-\n\ + chosen one. This option could be used for looking at a demo\n\ + of each of the configured hacks.\n\ + -prev Like -next, but goes in the other direction.\n\ + -exit Causes the screensaver process to exit. This is the same as\n\ + killing the process with `kill', but it's easier, since you\n\ + don't need to first figure out the pid. (Note that one\n\ + must *never* kill xscreensaver with -9!)\n\ + -restart Causes the screensaver process to exit and then restart with\n\ + the same command line arguments. Do this after you've\n\ + changed the resource database, to cause the screensaver to\n\ + notice the changes.\n\ + -lock Same as -activate, but with immediate locking.\n\ + -version Prints the version of XScreenSaver that is currently running\n\ + on the display.\n\ + -time Prints the time at which the screensaver last activated or\n\ + deactivated (roughly, how long the user has been idle or\n\ + non-idle.)\n\ +\n\ + See the man page for more details.\n\ + For updates, check http://people.netscape.com/jwz/xscreensaver/\n\ +\n"; + +static Window +find_screensaver_window (Display *dpy, char *progname, char **version) +{ + int i; + Window root = RootWindowOfScreen (DefaultScreenOfDisplay (dpy)); + Window root2, parent, *kids; + unsigned int nkids; + + if (version) *version = 0; + + if (! XQueryTree (dpy, root, &root2, &parent, &kids, &nkids)) + abort (); + if (root != root2) + abort (); + if (parent) + abort (); + if (! (kids && nkids)) + abort (); + for (i = 0; i < nkids; i++) + { + Atom type; + int format; + unsigned long nitems, bytesafter; + char *v; + + if (XGetWindowProperty (dpy, kids[i], + XInternAtom (dpy, "_SCREENSAVER_VERSION", False), + 0, 200, False, XA_STRING, + &type, &format, &nitems, &bytesafter, + (unsigned char **) &v) + == Success + && type != None) + { + if (version) + *version = v; + return kids[i]; + } + } + fprintf (stderr, "%s: no screensaver is running on display %s\n", progname, + DisplayString (dpy)); + exit (1); +} + + +#define USAGE() \ + { fprintf (stderr, usage, argv[0], screensaver_version); exit (1); } + +int +main (int argc, char **argv) +{ + Display *dpy; + Window window; + int i; + int query = 0; +#define Q_version 1 +#define Q_time 2 + char *message = 0, *dpyname = 0; + char *v = 0; + + screensaver_version = (char *) malloc (5); + memcpy (screensaver_version, screensaver_id + 17, 4); + screensaver_version [4] = 0; + for (i = 1; i < argc; i++) + { + char *s = argv [i]; + int L = strlen (s); + if (L < 2) USAGE (); + if (!strncmp (s, "-display", L)) dpyname = argv [++i]; + else if (message) USAGE () + else if (!strncmp (s, "-activate", L)) message = "ACTIVATE"; + else if (!strncmp (s, "-deactivate", L)) message = "DEACTIVATE"; + else if (!strncmp (s, "-cycle", L)) message = "CYCLE"; + else if (!strncmp (s, "-next", L)) message = "NEXT"; + else if (!strncmp (s, "-prev", L)) message = "PREV"; + else if (!strncmp (s, "-exit", L)) message = "EXIT"; + else if (!strncmp (s, "-restart", L)) message = "RESTART"; + else if (!strncmp (s, "-demo", L)) message = "DEMO"; + else if (!strncmp (s, "-lock", L)) message = "LOCK"; + else if (!strncmp (s, "-version", L)) query = Q_version; + else if (!strncmp (s, "-time", L)) query = Q_time; + else USAGE (); + } + if (!message && !query) USAGE (); + if (!dpyname) dpyname = (char *) getenv ("DISPLAY"); + dpy = XOpenDisplay (dpyname); + if (!dpy) + { + fprintf (stderr, "%s: can't open display %s\n", argv[0], + (dpyname ? dpyname : "(null)")); + exit (1); + } + window = find_screensaver_window (dpy, argv[0], &v); + + if (message) + { + XEvent event; + event.xany.type = ClientMessage; + event.xclient.display = dpy; + event.xclient.window = window; + event.xclient.message_type = XInternAtom (dpy, "SCREENSAVER", False); + event.xclient.format = 32; + event.xclient.data.l[0] = (long) XInternAtom (dpy, message, False); + if (! XSendEvent (dpy, window, False, 0L, &event)) + { + fprintf (stderr, "%s: XSendEvent(dpy, 0x%x ...) failed.\n", argv [0], + (unsigned int) window); + exit (1); + } + } + else if (query) + { + XClassHint hint; + memset (&hint, 0, sizeof(hint)); + if (!v || !*v) + { + fprintf (stderr, "%s: version property not set on window 0x%x?\n", + argv [0], (unsigned int) window); + exit (1); + } + + XGetClassHint(dpy, window, &hint); + if (!hint.res_class) + { + fprintf (stderr, "%s: class hints not set on window 0x%x?\n", + argv [0], (unsigned int) window); + exit (1); + } + + fprintf (stdout, "%s %s", hint.res_class, v); + + if (query != Q_time) + { + fprintf (stdout, "\n"); + } + else + { + Atom type; + int format; + unsigned long nitems, bytesafter; + unsigned char *data = 0; + XWindowAttributes xgwa; + Bool active_p = False; + + xgwa.map_state = IsViewable; + XGetWindowAttributes (dpy, window, &xgwa); + + if (XGetWindowProperty (dpy, window, + XInternAtom (dpy, "__SWM_VROOT", False), + 0, 0, False, XA_WINDOW, + &type, &format, &nitems, &bytesafter, + &data) + == Success + && type != None) + active_p = True; + + if (data) free (data); + data = 0; + + if (XGetWindowProperty (dpy, window, + XInternAtom (dpy, "_SCREENSAVER_TIME",False), + 0, 1, False, XA_INTEGER, + &type, &format, &nitems, &bytesafter, + &data) + == Success + && type == XA_INTEGER + && data) + { + CARD32 time32 = *((CARD32 *)data); + time_t tt = (time_t) time32; + + if (active_p) + fprintf (stdout, ": active since "); + else + fprintf (stdout, ": inactive since "); + fprintf (stdout, "%s", ctime(&tt)); + if (data) free (data); + } + else + { + if (data) free (data); + fprintf (stdout, "\n"); + fflush (stdout); + fprintf (stderr, "%s: no time on window 0x%x (%s %s).\n", + argv[0], (unsigned int) window, + hint.res_class, (v ? v : "???")); + exit (1); + } + } + } + + XSync (dpy, 0); + fflush (stdout); + fflush (stderr); + exit (0); +} diff --git a/driver/xscreensaver-command.man b/driver/xscreensaver-command.man new file mode 100644 index 00000000..1416fe8c --- /dev/null +++ b/driver/xscreensaver-command.man @@ -0,0 +1,132 @@ +.de EX \"Begin example +.ne 5 +.if n .sp 1 +.if t .sp .5 +.nf +.in +.5i +.. +.de EE +.fi +.in -.5i +.if n .sp 1 +.if t .sp .5 +.. +.TH XScreenSaver 1 "31-May-97" "X Version 11" +.SH NAME +xscreensaver-command - control a running xscreensaver process +.SH SYNOPSIS +.B xscreensaver-command +[\-help] [\-demo] [\-activate] [\-deactivate] [\-lock] [\-cycle] [\-next] [\-prev] [\-exit] [\-restart] [\-version] [\-time] +.SH DESCRIPTION +The \fIxscreensaver\-command\fP program controls a running \fIxscreensaver\fP +process by sending it client-messages. +.SH OPTIONS +.I xscreensaver-command +accepts the following options: +.TP 8 +.B \-help +Prints a brief summary of command-line options. +.TP 8 +.B \-demo +Cause the screensaver to enter its interactive demo mode, in which one +can experiment with the various graphics hacks available. See +.BR xscreensaver (1) +for details. +.TP 8 +.B \-activate +Tell the screensaver to turn on immediately (that is, pretend that the +user been idle for long enough.) It will turn off as soon as there is +any user activity, as usual. + +It is useful to run this from a menu; you may wish to run it as +.EX +sleep 5 ; xscreensaver-command -activate +.EE +to be sure that you have time to remove your hand from the mouse before +the screensaver comes on. +.TP 8 +.B \-deactivate +Tell the screensaver to turn off, as if there had been user activity. +If locking is enabled, then the screensaver will prompt for a password +as usual. +.TP 8 +.B \-lock +Like \fI\-activate\fP, but a password will be required before the screensaver +turns off, even if the screensaver's \fIlock\fP resource is false. The +display will be locked immediately even if the screensaver's \fIlockTimeout\fP +resource is non-zero. +.TP 8 +.B \-cycle +Tell the screensaver to change which graphics hack it is running, just +as if the ``cycle'' timer had expired. A new hack will be chosen randomly. +.TP 8 +.B \-next +This is like either \fI\-activate\fP or \fI\-cycle\fP, depending on which is +more appropriate, except that the screenhack that will be run is the next +one in the list of programs, instead of a randomly-chosen one. Repeatedly +executing this will cycle through each hack in turn (though using +the \fI\-demo\fP option is probably an easier way to accomplish that.) +.TP 8 +.B \-prev +This is like \fI\-next\fP, but cycles in the other direction. +.TP 8 +.B \-exit +Causes the screensaver process to exit gracefully. This is a safer and +easier way to kill the screensaver than by using \fIkill\fP. + +.B Warning: +never use \fIkill -9\fP with \fIxscreensaver\fP while the screensaver is +active. If you are using a virtual root window manager, that can leave +things in an inconsistent state, and you may need to restart your window +manager to repair the damage. +.TP 8 +.B \-restart +Causes the screensaver process to exit and then restart with the same command +line arguments. This is a good way of causing the screensaver to re-read the +resource database. + +If the screensaver is run from \fIxdm(1)\fP (that is, it is already running +before you log in) then you may want to issue the ``restart'' command from +one of your startup scripts, so that the screensaver gets your resource +settings instead of the default ones. +.TP 8 +.B \-version +Print (on stdout) the version number of the xscreensaver program that is +running on $DISPLAY. (To see the version number of \fIxscreensaver-command\fP +itself, use the \fI\-help\fP option.) +.TP 8 +.B \-time +This option prints on stdout the time at which the screensaver last activated +(blanked the screen) or deactivated (restored the screen.) Note that the +activation-time is not the last time at which the user was active, but is +some time later (it is the time at which either: xscreensaver decided that +the user has been idle long enough; or, the user explicitly activated the +screensaver or locker.) +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the host and display number of the screen whose saver is +to be manipulated. +.TP 8 +.B PATH +to find the executable to restart (for the \fI\-restart\fP command). +Note that this variable is consulted in the environment of +the \fIxscreensaver\fP process, not the \fIxscreensaver-command\fP process. +.SH "SEE ALSO" +.BR X (1), +.BR xscreensaver (1) +.SH BUGS +Some diagnostics are reported on the stderr of the \fIxscreensaver\fP +process, not this process, so the caller of \fIxscreensaver-command\fP +may not see the error messages. +.SH COPYRIGHT +Copyright \(co 1992, 1993, 1997 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. diff --git a/driver/xscreensaver.c b/driver/xscreensaver.c new file mode 100644 index 00000000..d820d0ab --- /dev/null +++ b/driver/xscreensaver.c @@ -0,0 +1,1137 @@ +/* xscreensaver, Copyright (c) 1991-1998 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. + */ + +/* ======================================================================== + * First we wait until the keyboard and mouse become idle for the specified + * amount of time. We do this in one of three different ways: periodically + * checking with the XIdle server extension; selecting key and mouse events + * on (nearly) all windows; or by waiting for the MIT-SCREEN-SAVER extension + * to send us a "you are idle" event. + * + * Then, we map a full screen black window (or, in the case of the + * MIT-SCREEN-SAVER extension, use the one it gave us.) + * + * We place a __SWM_VROOT property on this window, so that newly-started + * clients will think that this window is a "virtual root" window. + * + * If there is an existing "virtual root" window (one that already had + * an __SWM_VROOT property) then we remove that property from that window. + * Otherwise, clients would see that window (the real virtual root) instead + * of ours (the impostor.) + * + * Then we pick a random program to run, and start it. Two assumptions + * are made about this program: that it has been specified with whatever + * command-line options are necessary to make it run on the root window; + * and that it has been compiled with vroot.h, so that it is able to find + * the root window when a virtual-root window manager (or this program) is + * running. + * + * Then, we wait for keyboard or mouse events to be generated on the window. + * When they are, we kill the inferior process, unmap the window, and restore + * the __SWM_VROOT property to the real virtual root window if there was one. + * + * While we are waiting, we also set up timers so that, after a certain + * amount of time has passed, we can start a different screenhack. We do + * this by killing the running child process with SIGTERM, and then starting + * a new one in the same way. + * + * If there was a real virtual root, meaning that we removed the __SWM_VROOT + * property from it, meaning we must (absolutely must) restore it before we + * exit, then we set up signal handlers for most signals (SIGINT, SIGTERM, + * etc.) that do this. Most Xlib and Xt routines are not reentrant, so it + * is not generally safe to call them from signal handlers; however, this + * program spends most of its time waiting, so the window of opportunity + * when code could be called reentrantly is fairly small; and also, the worst + * that could happen is that the call would fail. If we've gotten one of + * these signals, then we're on our way out anyway. If we didn't restore the + * __SWM_VROOT property, that would be very bad, so it's worth a shot. Note + * that this means that, if you're using a virtual-root window manager, you + * can really fuck up the world by killing this process with "kill -9". + * + * This program accepts ClientMessages of type SCREENSAVER; these messages + * may contain the atom ACTIVATE or DEACTIVATE, meaning to turn the + * screensaver on or off now, regardless of the idleness of the user, + * and a few other things. The included "xscreensaver_command" program + * sends these messsages. + * + * If we don't have the XIdle, MIT-SCREEN-SAVER, or SGI SCREEN_SAVER + * extensions, then we do the XAutoLock trick: notice every window that + * gets created, and wait 30 seconds or so until its creating process has + * settled down, and then select KeyPress events on those windows which + * already select for KeyPress events. It's important that we not select + * KeyPress on windows which don't select them, because that would + * interfere with event propagation. This will break if any program + * changes its event mask to contain KeyRelease or PointerMotion more than + * 30 seconds after creating the window, but that's probably pretty rare. + * + * The reason that we can't select KeyPresses on windows that don't have + * them already is that, when dispatching a KeyPress event, X finds the + * lowest (leafmost) window in the hierarchy on which *any* client selects + * for KeyPress, and sends the event to that window. This means that if a + * client had a window with subwindows, and expected to receive KeyPress + * events on the parent window instead of the subwindows, then that client + * would malfunction if some other client selected KeyPress events on the + * subwindows. It is an incredible misdesign that one client can make + * another client malfunction in this way. + * + * To detect mouse motion, we periodically wake up and poll the mouse + * position and button/modifier state, and notice when something has + * changed. We make this check every five seconds by default, and since the + * screensaver timeout has a granularity of one minute, this makes the + * chance of a false positive very small. We could detect mouse motion in + * the same way as keyboard activity, but that would suffer from the same + * "client changing event mask" problem that the KeyPress events hack does. + * I think polling is more reliable. + * + * None of this crap happens if we're using one of the extensions, so install + * one of them if the description above sounds just too flaky to live. It + * is, but those are your choices. + * + * A third idle-detection option could be implemented (but is not): when + * running on the console display ($DISPLAY is `localhost`:0) and we're on a + * machine where /dev/tty and /dev/mouse have reasonable last-modification + * times, we could just stat() those. But the incremental benefit of + * implementing this is really small, so forget I said anything. + * + * Debugging hints: + * - Have a second terminal handy. + * - Be careful where you set your breakpoints, you don't want this to + * stop under the debugger with the keyboard grabbed or the blackout + * window exposed. + * - If you run your debugger under XEmacs, try M-ESC (x-grab-keyboard) + * to keep your emacs window alive even when xscreensaver has grabbed. + * - Go read the code related to -DDEBUG. + * - You probably can't set breakpoints in functions that are called on + * the other side of a call to fork() -- if your clients are dying + * with signal 5, Trace/BPT Trap, you're losing in this way. + * - If you aren't using a server extension, don't leave this stopped + * under the debugger for very long, or the X input buffer will get + * huge because of the keypress events it's selecting for. This can + * make your X server wedge with "no more input buffers." + * + * ======================================================================== */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#ifdef HAVE_XMU +# ifndef VMS +# include +# else /* !VMS */ +# include +# endif /* !VMS */ +#else /* !HAVE_XMU */ +# include "xmu.h" +#endif /* !HAVE_XMU */ + +#ifdef HAVE_XIDLE_EXTENSION +#include +#endif /* HAVE_XIDLE_EXTENSION */ + +#include "xscreensaver.h" +#include "version.h" +#include "yarandom.h" +#include "resources.h" +#include "visual.h" + +saver_info *global_si_kludge = 0; /* I hate C so much... */ + +char *progname = 0; +char *progclass = 0; +XrmDatabase db = 0; + + +static Atom XA_SCREENSAVER; +static Atom XA_ACTIVATE, XA_DEACTIVATE, XA_CYCLE, XA_NEXT, XA_PREV; +static Atom XA_EXIT, XA_RESTART, XA_DEMO, XA_LOCK; + + +static XrmOptionDescRec options [] = { + { "-timeout", ".timeout", XrmoptionSepArg, 0 }, + { "-cycle", ".cycle", XrmoptionSepArg, 0 }, + { "-idelay", ".initialDelay", XrmoptionSepArg, 0 }, + { "-nice", ".nice", XrmoptionSepArg, 0 }, + { "-visual", ".visualID", XrmoptionSepArg, 0 }, + { "-lock-timeout", ".lockTimeout", XrmoptionSepArg, 0 }, + { "-install", ".installColormap", XrmoptionNoArg, "on" }, + { "-no-install", ".installColormap", XrmoptionNoArg, "off" }, + { "-verbose", ".verbose", XrmoptionNoArg, "on" }, + { "-silent", ".verbose", XrmoptionNoArg, "off" }, + { "-xidle-extension", ".xidleExtension", XrmoptionNoArg, "on" }, + { "-no-xidle-extension", ".xidleExtension", XrmoptionNoArg, "off" }, + { "-mit-extension", ".mitSaverExtension",XrmoptionNoArg, "on" }, + { "-no-mit-extension", ".mitSaverExtension",XrmoptionNoArg, "off" }, + { "-sgi-extension", ".sgiSaverExtension",XrmoptionNoArg, "on" }, + { "-no-sgi-extension", ".sgiSaverExtension",XrmoptionNoArg, "off" }, + { "-lock", ".lock", XrmoptionNoArg, "on" }, + { "-no-lock", ".lock", XrmoptionNoArg, "off" } +}; + +static char *defaults[] = { +#include "XScreenSaver_ad.h" + 0 +}; + +static void +do_help (saver_info *si) +{ + printf ("\ +xscreensaver %s, copyright (c) 1991-1998 by Jamie Zawinski \n\ +The standard Xt command-line options are accepted; other options include:\n\ +\n\ + -timeout When the screensaver should activate.\n\ + -cycle How long to let each hack run.\n\ + -idelay How long to sleep before startup.\n\ + -visual Which X visual to run on.\n\ + -demo Enter interactive demo mode on startup.\n\ + -install Install a private colormap.\n\ + -no-install Don't.\n\ + -verbose Be loud.\n\ + -silent Don't.\n\ + -xidle-extension Use the R5 XIdle server extension.\n\ + -no-xidle-extension Don't.\n\ + -mit-extension Use the R6 MIT_SCREEN_SAVER server extension.\n\ + -no-mit-extension Don't.\n\ + -sgi-extension Use the SGI SCREEN-SAVER server extension.\n\ + -no-sgi-extension Don't.\n\ + -lock Require a password before deactivating.\n\ + -no-lock Don't.\n\ + -lock-timeout Grace period before locking; default 0.\n\ + -help This message.\n\ +\n\ +Use the `xscreensaver-command' program to control a running screensaver.\n\ +\n\ +The *programs resource controls which graphics demos will be launched by the\n\ +screensaver. See the man page for more details. For updates, check\n\ +http://people.netscape.com/jwz/xscreensaver/\n\n", + si->version); + +#ifdef NO_LOCKING + printf ("Support for locking was not enabled at compile-time.\n"); +#endif +#ifdef NO_DEMO_MODE + printf ("Support for demo mode was not enabled at compile-time.\n"); +#endif +#if !defined(HAVE_XIDLE_EXTENSION) && !defined(HAVE_MIT_SAVER_EXTENSION) && !defined(HAVE_SGI_SAVER_EXTENSION) + printf ("Support for the XIDLE, SCREEN_SAVER, and MIT-SCREEN-SAVER server\ + extensions\nwas not enabled at compile-time.\n"); +#endif /* !HAVE_XIDLE_EXTENSION && !HAVE_MIT_SAVER_EXTENSION && !HAVE_SGI_SAVER_EXTENSION */ + + fflush (stdout); + exit (1); +} + + +static char * +reformat_hack(const char *hack) +{ + int i; + const char *in = hack; + int indent = 13; + char *h2 = (char *) malloc(strlen(in) + indent + 2); + char *out = h2; + + while (isspace(*in)) in++; /* skip whitespace */ + while (*in && !isspace(*in) && *in != ':') + *out++ = *in++; /* snarf first token */ + while (isspace(*in)) in++; /* skip whitespace */ + + if (*in == ':') + *out++ = *in++; /* copy colon */ + else + { + in = hack; + out = h2; /* reset to beginning */ + } + + *out = 0; + + while (isspace(*in)) in++; /* skip whitespace */ + for (i = strlen(h2); i < indent; i++) /* indent */ + *out++ = ' '; + + while (*in) *out++ = *in++; /* copy rest of line */ + *out = 0; + + return h2; +} + + +static void +get_screenhacks (saver_info *si) +{ + saver_preferences *p = &si->prefs; + int i = 0; + int hacks_size = 60; + int size; + char *d; + + d = get_string_resource ("monoPrograms", "MonoPrograms"); + if (d && !*d) { free(d); d = 0; } + if (!d) + d = get_string_resource ("colorPrograms", "ColorPrograms"); + if (d && !*d) { free(d); d = 0; } + + if (d) + { + fprintf (stderr, + "%s: the `monoPrograms' and `colorPrograms' resources are obsolete;\n\ + see the manual for details.\n", progname); + free(d); + } + + d = get_string_resource ("programs", "Programs"); + + size = strlen (d); + p->screenhacks = (char **) malloc (sizeof (char *) * hacks_size); + p->screenhacks_count = 0; + + while (i < size) + { + int end, start = i; + if (d[i] == ' ' || d[i] == '\t' || d[i] == '\n' || d[i] == 0) + { + i++; + continue; + } + if (hacks_size <= p->screenhacks_count) + p->screenhacks = (char **) realloc (p->screenhacks, + (hacks_size = hacks_size * 2) * + sizeof (char *)); + p->screenhacks [p->screenhacks_count++] = d + i; + while (d[i] != 0 && d[i] != '\n') + i++; + end = i; + while (i > start && (d[i-1] == ' ' || d[i-1] == '\t')) + i--; + d[i] = 0; + i = end + 1; + } + + /* shrink all whitespace to one space, for the benefit of the "demo" + mode display. We only do this when we can easily tell that the + whitespace is not significant (no shell metachars). + */ + for (i = 0; i < p->screenhacks_count; i++) + { + char *s = p->screenhacks [i]; + char *s2; + int L = strlen (s); + int j, k; + for (j = 0; j < L; j++) + { + switch (s[j]) + { + case '\'': case '"': case '`': case '\\': + goto DONE; + case '\t': + s[j] = ' '; + case ' ': + k = 0; + for (s2 = s+j+1; *s2 == ' ' || *s2 == '\t'; s2++) + k++; + if (k > 0) + { + for (s2 = s+j+1; s2[k]; s2++) + *s2 = s2[k]; + *s2 = 0; + } + break; + } + } + DONE: + p->screenhacks[i] = reformat_hack(s); /* mallocs */ + } + + if (p->screenhacks_count) + { + /* Shrink down the screenhacks array to be only as big as it needs to. + This doesn't really matter at all. */ + p->screenhacks = (char **) + realloc (p->screenhacks, ((p->screenhacks_count + 1) * + sizeof(char *))); + p->screenhacks [p->screenhacks_count] = 0; + } + else + { + free (p->screenhacks); + p->screenhacks = 0; + } +} + + +static void +get_resources (saver_info *si) +{ + char *s; + saver_preferences *p = &si->prefs; + + p->verbose_p = get_boolean_resource ("verbose", "Boolean"); + p->lock_p = get_boolean_resource ("lock", "Boolean"); + p->fade_p = get_boolean_resource ("fade", "Boolean"); + p->unfade_p = get_boolean_resource ("unfade", "Boolean"); + p->fade_seconds = get_seconds_resource ("fadeSeconds", "Time"); + p->fade_ticks = get_integer_resource ("fadeTicks", "Integer"); + p->install_cmap_p = get_boolean_resource ("installColormap", "Boolean"); + p->nice_inferior = get_integer_resource ("nice", "Nice"); + + p->initial_delay = get_seconds_resource ("initialDelay", "Time"); + p->timeout = 1000 * get_minutes_resource ("timeout", "Time"); + p->lock_timeout = 1000 * get_minutes_resource ("lockTimeout", "Time"); + p->cycle = 1000 * get_minutes_resource ("cycle", "Time"); + +#ifndef NO_LOCKING + p->passwd_timeout = 1000 * get_seconds_resource ("passwdTimeout", "Time"); +#endif + + p->pointer_timeout = 1000 * get_seconds_resource ("pointerPollTime", "Time"); + p->notice_events_timeout = 1000*get_seconds_resource("windowCreationTimeout", + "Time"); + p->shell = get_string_resource ("bourneShell", "BourneShell"); + + + /* don't set use_xidle_extension unless it is explicitly specified */ + if ((s = get_string_resource ("xidleExtension", "Boolean"))) + p->use_xidle_extension = get_boolean_resource ("xidleExtension","Boolean"); + else +#ifdef HAVE_XIDLE_EXTENSION /* pick a default */ + p->use_xidle_extension = True; /* if we have it, use it */ +#else /* !HAVE_XIDLE_EXTENSION */ + p->use_xidle_extension = False; +#endif /* !HAVE_XIDLE_EXTENSION */ + if (s) free (s); + + /* don't set use_mit_extension unless it is explicitly specified */ + if ((s = get_string_resource ("mitSaverExtension", "Boolean"))) + p->use_mit_saver_extension = get_boolean_resource ("mitSaverExtension", + "Boolean"); + else +#ifdef HAVE_MIT_SAVER_EXTENSION /* pick a default */ + p->use_mit_saver_extension = False; /* Default false, because it sucks */ +#else /* !HAVE_MIT_SAVER_EXTENSION */ + p->use_mit_saver_extension = False; +#endif /* !HAVE_MIT_SAVER_EXTENSION */ + if (s) free (s); + + + /* don't set use_mit_extension unless it is explicitly specified */ + if ((s = get_string_resource ("sgiSaverExtension", "Boolean"))) + p->use_sgi_saver_extension = get_boolean_resource ("sgiSaverExtension", + "Boolean"); + else +#ifdef HAVE_SGI_SAVER_EXTENSION /* pick a default */ + p->use_sgi_saver_extension = True; /* if we have it, use it */ +#else /* !HAVE_SGI_SAVER_EXTENSION */ + p->use_sgi_saver_extension = False; +#endif /* !HAVE_SGI_SAVER_EXTENSION */ + if (s) free (s); + + + /* Throttle the various timeouts to reasonable values. + */ +#ifndef NO_LOCKING + if (p->passwd_timeout == 0) p->passwd_timeout = 30000; /* 30 secs */ +#endif + if (p->timeout < 10000) p->timeout = 10000; /* 10 secs */ + if (p->cycle != 0 && p->cycle < 2000) p->cycle = 2000; /* 2 secs */ + if (p->pointer_timeout == 0) p->pointer_timeout = 5000; /* 5 secs */ + if (p->notice_events_timeout == 0) + p->notice_events_timeout = 10000; /* 10 secs */ + if (p->fade_seconds == 0 || p->fade_ticks == 0) + p->fade_p = False; + if (! p->fade_p) p->unfade_p = False; + + p->watchdog_timeout = p->cycle; + if (p->watchdog_timeout < 30000) p->watchdog_timeout = 30000; /* 30 secs */ + if (p->watchdog_timeout > 3600000) p->watchdog_timeout = 3600000; /* 1 hr */ + +#ifdef NO_LOCKING + si->locking_disabled_p = True; + si->nolock_reason = "not compiled with locking support"; + if (p->lock_p) + { + p->lock_p = False; + fprintf (stderr, "%s: not compiled with support for locking.\n", + progname); + } +#else /* ! NO_LOCKING */ + if (p->lock_p && si->locking_disabled_p) + { + fprintf (stderr, "%s: locking is disabled (%s).\n", progname, + si->nolock_reason); + p->lock_p = False; + } +#endif /* ! NO_LOCKING */ + + get_screenhacks (si); + +#ifdef DEBUG + if (p->debug_p) + { + XSynchronize(si->dpy, True); + p->verbose_p = True; + p->initial_delay = 0; + } +#endif /* DEBUG */ +} + + +char * +timestring (void) +{ + time_t now = time ((time_t *) 0); + char *str = (char *) ctime (&now); + char *nl = (char *) strchr (str, '\n'); + if (nl) *nl = 0; /* take off that dang newline */ + return str; +} + +static void initialize (saver_info *si, int argc, char **argv); +static void main_loop (saver_info *si); + +int +main (int argc, char **argv) +{ + saver_info si; + memset(&si, 0, sizeof(si)); + global_si_kludge = &si; /* I hate C so much... */ + initialize (&si, argc, argv); + main_loop (&si); /* doesn't return */ + return 0; +} + + +int +saver_ehandler (Display *dpy, XErrorEvent *error) +{ + saver_info *si = global_si_kludge; /* I hate C so much... */ + + fprintf (real_stderr, "\nX error in %s:\n", progname); + if (XmuPrintDefaultErrorMessage (dpy, error, real_stderr)) + saver_exit (si, -1); + else + fprintf (real_stderr, " (nonfatal.)\n"); + return 0; +} + +static void +initialize_connection (saver_info *si, int argc, char **argv) +{ + int i; + Widget toplevel_shell = XtAppInitialize (&si->app, progclass, + options, XtNumber (options), + &argc, argv, defaults, 0, 0); + + si->dpy = XtDisplay (toplevel_shell); + si->db = XtDatabase (si->dpy); + XtGetApplicationNameAndClass (si->dpy, &progname, &progclass); + + db = si->db; /* resources.c needs this */ + + if (argc == 2 && !strcmp (argv[1], "-help")) + do_help (si); +#ifdef DEBUG + else if (argc == 2 && !strcmp (argv[1], "-debug")) + si->prefs.debug_p = True; /* no resource for this one, out of paranoia. */ +#endif /* DEBUG */ + else if (argc > 1) + { + fprintf (stderr, "%s: unknown option %s\n", progname, argv [1]); + exit (1); + } + get_resources (si); +#ifndef NO_SETUID + hack_uid_warn (si); +#endif /* NO_SETUID */ + XA_VROOT = XInternAtom (si->dpy, "__SWM_VROOT", False); + XA_SCREENSAVER = XInternAtom (si->dpy, "SCREENSAVER", False); + XA_SCREENSAVER_VERSION = XInternAtom (si->dpy, "_SCREENSAVER_VERSION",False); + XA_SCREENSAVER_ID = XInternAtom (si->dpy, "_SCREENSAVER_ID", False); + XA_SCREENSAVER_TIME = XInternAtom (si->dpy, "_SCREENSAVER_TIME", False); + XA_XSETROOT_ID = XInternAtom (si->dpy, "_XSETROOT_ID", False); + XA_ACTIVATE = XInternAtom (si->dpy, "ACTIVATE", False); + XA_DEACTIVATE = XInternAtom (si->dpy, "DEACTIVATE", False); + XA_RESTART = XInternAtom (si->dpy, "RESTART", False); + XA_CYCLE = XInternAtom (si->dpy, "CYCLE", False); + XA_NEXT = XInternAtom (si->dpy, "NEXT", False); + XA_PREV = XInternAtom (si->dpy, "PREV", False); + XA_EXIT = XInternAtom (si->dpy, "EXIT", False); + XA_DEMO = XInternAtom (si->dpy, "DEMO", False); + XA_LOCK = XInternAtom (si->dpy, "LOCK", False); + + si->nscreens = ScreenCount(si->dpy); + si->screens = (saver_screen_info *) + calloc(sizeof(saver_screen_info), si->nscreens); + + si->default_screen = &si->screens[DefaultScreen(si->dpy)]; + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + ssi->global = si; + ssi->screen = ScreenOfDisplay (si->dpy, i); + + /* Note: we can't use the resource ".visual" because Xt is SO FUCKED. */ + ssi->default_visual = + get_visual_resource (ssi->screen, "visualID", "VisualID", False); + + ssi->current_visual = ssi->default_visual; + ssi->current_depth = visual_depth (ssi->screen, ssi->current_visual); + + if (ssi == si->default_screen) + /* Since this is the default screen, use the one already created. */ + ssi->toplevel_shell = toplevel_shell; + else + /* Otherwise, each screen must have its own unmapped root widget. */ + ssi->toplevel_shell = + XtVaAppCreateShell(progname, progclass, applicationShellWidgetClass, + si->dpy, + XtNscreen, ssi->screen, + XtNvisual, ssi->current_visual, + XtNdepth, visual_depth(ssi->screen, + ssi->current_visual), + 0); + } +} + + +static void +initialize (saver_info *si, int argc, char **argv) +{ + int i; + saver_preferences *p = &si->prefs; + Bool initial_demo_mode_p = False; + si->version = (char *) malloc (5); + memcpy (si->version, screensaver_id + 17, 4); + si->version [4] = 0; + progname = argv[0]; /* reset later; this is for the benefit of lock_init() */ + +#ifdef NO_LOCKING + si->locking_disabled_p = True; + si->nolock_reason = "not compiled with locking support"; +#else + si->locking_disabled_p = False; + +#ifdef SCO + set_auth_parameters(argc, argv); +#endif + + if (! lock_init (argc, argv)) /* before hack_uid() for proper permissions */ + { + si->locking_disabled_p = True; + si->nolock_reason = "error getting password"; + } +#endif + +#ifndef NO_SETUID + hack_uid (si); +#endif + + progclass = "XScreenSaver"; + + /* remove -demo switch before saving argv */ + for (i = 1; i < argc; i++) + while (!strcmp ("-demo", argv [i])) + { + int j; + initial_demo_mode_p = True; + for (j = i; j < argc; j++) + argv [j] = argv [j+1]; + argv [j] = 0; + argc--; + if (argc <= i) break; + } + save_argv (argc, argv); + initialize_connection (si, argc, argv); + + if (p->verbose_p) + printf ("\ +%s %s, copyright (c) 1991-1998 by Jamie Zawinski \n\ + pid = %d.\n", progname, si->version, (int) getpid ()); + + + for (i = 0; i < si->nscreens; i++) + ensure_no_screensaver_running (si->dpy, si->screens[i].screen); + + si->demo_mode_p = initial_demo_mode_p; + srandom ((int) time ((time_t *) 0)); + + if (p->use_sgi_saver_extension) + { +#ifdef HAVE_SGI_SAVER_EXTENSION + if (! query_sgi_saver_extension (si)) + { + fprintf (stderr, + "%s: display %s does not support the SGI SCREEN_SAVER extension.\n", + progname, DisplayString (si->dpy)); + p->use_sgi_saver_extension = False; + } + else if (p->use_mit_saver_extension) + { + fprintf (stderr, "%s: SGI SCREEN_SAVER extension used instead\ + of MIT-SCREEN-SAVER extension.\n", + progname); + p->use_mit_saver_extension = False; + } + else if (p->use_xidle_extension) + { + fprintf (stderr, + "%s: SGI SCREEN_SAVER extension used instead of XIDLE extension.\n", + progname); + p->use_xidle_extension = False; + } +#else /* !HAVE_MIT_SAVER_EXTENSION */ + fprintf (stderr, + "%s: not compiled with support for the SGI SCREEN_SAVER extension.\n", + progname); + p->use_sgi_saver_extension = False; +#endif /* !HAVE_SGI_SAVER_EXTENSION */ + } + + if (p->use_mit_saver_extension) + { +#ifdef HAVE_MIT_SAVER_EXTENSION + if (! query_mit_saver_extension (si)) + { + fprintf (stderr, + "%s: display %s does not support the MIT-SCREEN-SAVER extension.\n", + progname, DisplayString (si->dpy)); + p->use_mit_saver_extension = False; + } + else if (p->use_xidle_extension) + { + fprintf (stderr, + "%s: MIT-SCREEN-SAVER extension used instead of XIDLE extension.\n", + progname); + p->use_xidle_extension = False; + } +#else /* !HAVE_MIT_SAVER_EXTENSION */ + fprintf (stderr, + "%s: not compiled with support for the MIT-SCREEN-SAVER extension.\n", + progname); + p->use_mit_saver_extension = False; +#endif /* !HAVE_MIT_SAVER_EXTENSION */ + } + + if (p->use_xidle_extension) + { +#ifdef HAVE_XIDLE_EXTENSION + int first_event, first_error; + if (! XidleQueryExtension (si->dpy, &first_event, &first_error)) + { + fprintf (stderr, + "%s: display %s does not support the XIdle extension.\n", + progname, DisplayString (si->dpy)); + p->use_xidle_extension = False; + } +#else /* !HAVE_XIDLE_EXTENSION */ + fprintf (stderr, "%s: not compiled with support for XIdle.\n", + progname); + p->use_xidle_extension = False; +#endif /* !HAVE_XIDLE_EXTENSION */ + } + + /* Call this only after having probed for presence of desired extension. */ + initialize_screensaver_window (si); + + init_sigchld (); + + disable_builtin_screensaver (si, True); + + if (p->verbose_p && p->use_mit_saver_extension) + fprintf (stderr, "%s: using MIT-SCREEN-SAVER server extension.\n", + progname); + if (p->verbose_p && p->use_sgi_saver_extension) + fprintf (stderr, "%s: using SGI SCREEN_SAVER server extension.\n", + progname); + if (p->verbose_p && p->use_xidle_extension) + fprintf (stderr, "%s: using XIdle server extension.\n", + progname); + + initialize_stderr (si); + XSetErrorHandler (saver_ehandler); + + if (initial_demo_mode_p) + /* If the user wants demo mode, don't wait around before doing it. */ + p->initial_delay = 0; + + if (!p->use_xidle_extension && + !p->use_mit_saver_extension && + !p->use_sgi_saver_extension) + { + if (p->initial_delay) + { + if (p->verbose_p) + { + printf ("%s: waiting for %d second%s...", progname, + (int) p->initial_delay, + (p->initial_delay == 1 ? "" : "s")); + fflush (stdout); + } + sleep (p->initial_delay); + if (p->verbose_p) + printf (" done.\n"); + } + if (p->verbose_p) + { + printf ("%s: selecting events on extant windows...", progname); + fflush (stdout); + } + + /* Select events on the root windows of every screen. This also selects + for window creation events, so that new subwindows will be noticed. + */ + for (i = 0; i < si->nscreens; i++) + start_notice_events_timer (si, + RootWindowOfScreen (si->screens[i].screen)); + + if (p->verbose_p) + printf (" done.\n"); + } +} + +static void +main_loop (saver_info *si) +{ + saver_preferences *p = &si->prefs; + while (1) + { + if (! si->demo_mode_p) + sleep_until_idle (si, True); + +#ifndef NO_DEMO_MODE + if (si->demo_mode_p) + demo_mode (si); + else +#endif /* !NO_DEMO_MODE */ + { + if (p->verbose_p) + printf ("%s: user is idle; waking up at %s.\n", progname, + timestring()); + blank_screen (si); + spawn_screenhack (si, True); + if (p->cycle) + si->cycle_id = XtAppAddTimeOut (si->app, p->cycle, cycle_timer, + (XtPointer) si); + +#ifndef NO_LOCKING + if (p->lock_p && p->lock_timeout == 0) + si->locked_p = True; + if (p->lock_p && !si->locked_p) + /* locked_p might be true already because of ClientMessage */ + si->lock_id = XtAppAddTimeOut (si->app, p->lock_timeout, + activate_lock_timer, + (XtPointer) si); +#endif /* !NO_LOCKING */ + + PASSWD_INVALID: + + sleep_until_idle (si, False); /* until not idle */ + +#ifndef NO_LOCKING + if (si->locked_p) + { + Bool val; + if (si->locking_disabled_p) abort (); + si->dbox_up_p = True; + + /* We used to ungrab the keyboard here, before calling unlock_p() + to pop up the dialog box. This left the keyboard ungrabbed + for a small window, during an insecure state. Bennett Todd + was seeing the bahavior that, when the load was high, he could + actually get characters through to a shell under the saver + window (he accidentally typed his password there...) + + So the ungrab has been moved down into pop_passwd_dialog() + just after the server is grabbed, closing this window + entirely. + */ + /* ungrab_keyboard_and_mouse (); */ + + { + saver_screen_info *ssi = si->default_screen; + suspend_screenhack (si, True); + XUndefineCursor (si->dpy, ssi->screensaver_window); + if (p->verbose_p) + printf ("%s: prompting for password.\n", progname); + val = unlock_p (si); + if (p->verbose_p && val == False) + printf ("%s: password incorrect!\n", progname); + si->dbox_up_p = False; + XDefineCursor (si->dpy, ssi->screensaver_window, ssi->cursor); + suspend_screenhack (si, False); + + /* I think this grab is now redundant, but it shouldn't hurt. + */ + if (!si->demo_mode_p) + grab_keyboard_and_mouse (si->dpy, ssi->screensaver_window, + ssi->cursor); + } + + if (! val) + goto PASSWD_INVALID; + si->locked_p = False; + } +#endif /* !NO_LOCKING */ + + /* Let's kill it before unblanking, to get it to stop drawing as + soon as possible... */ + kill_screenhack (si); + unblank_screen (si); + + if (si->cycle_id) + { + XtRemoveTimeOut (si->cycle_id); + si->cycle_id = 0; + } + +#ifndef NO_LOCKING + if (si->lock_id) + { + XtRemoveTimeOut (si->lock_id); + si->lock_id = 0; + } +#endif /* !NO_LOCKING */ + + if (p->verbose_p) + printf ("%s: user is active; going to sleep at %s.\n", progname, + timestring ()); + } + } +} + + + +Bool +handle_clientmessage (saver_info *si, XEvent *event, Bool until_idle_p) +{ + saver_preferences *p = &si->prefs; + Atom type = 0; + if (event->xclient.message_type != XA_SCREENSAVER) + { + char *str; + str = XGetAtomName (si->dpy, event->xclient.message_type); + fprintf (stderr, "%s: unrecognised ClientMessage type %s received\n", + progname, (str ? str : "(null)")); + if (str) XFree (str); + return False; + } + if (event->xclient.format != 32) + { + fprintf (stderr, "%s: ClientMessage of format %d received, not 32\n", + progname, event->xclient.format); + return False; + } + + type = event->xclient.data.l[0]; + if (type == XA_ACTIVATE) + { + if (until_idle_p) + { + if (p->verbose_p) + printf ("%s: ACTIVATE ClientMessage received.\n", progname); + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + { + XForceScreenSaver (si->dpy, ScreenSaverActive); + return False; + } + else + { + return True; + } + } + fprintf (stderr, + "%s: ClientMessage ACTIVATE received while already active.\n", + progname); + } + else if (type == XA_DEACTIVATE) + { + if (! until_idle_p) + { + if (p->verbose_p) + printf ("%s: DEACTIVATE ClientMessage received.\n", progname); + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + { + XForceScreenSaver (si->dpy, ScreenSaverReset); + return False; + } + else + { + return True; + } + } + fprintf (stderr, + "%s: ClientMessage DEACTIVATE received while inactive.\n", + progname); + } + else if (type == XA_CYCLE) + { + if (! until_idle_p) + { + if (p->verbose_p) + printf ("%s: CYCLE ClientMessage received.\n", progname); + if (si->cycle_id) + XtRemoveTimeOut (si->cycle_id); + si->cycle_id = 0; + cycle_timer ((XtPointer) si, 0); + return False; + } + fprintf (stderr, "%s: ClientMessage CYCLE received while inactive.\n", + progname); + } + else if (type == XA_NEXT || type == XA_PREV) + { + if (p->verbose_p) + printf ("%s: %s ClientMessage received.\n", progname, + (type == XA_NEXT ? "NEXT" : "PREV")); + si->next_mode_p = 1 + (type == XA_PREV); + + if (! until_idle_p) + { + if (si->cycle_id) + XtRemoveTimeOut (si->cycle_id); + si->cycle_id = 0; + cycle_timer ((XtPointer) si, 0); + } + else + return True; + } + else if (type == XA_EXIT) + { + /* Ignore EXIT message if the screen is locked. */ + if (until_idle_p || !si->locked_p) + { + if (p->verbose_p) + printf ("%s: EXIT ClientMessage received.\n", progname); + if (! until_idle_p) + { + unblank_screen (si); + kill_screenhack (si); + XSync (si->dpy, False); + } + saver_exit (si, 0); + } + else + fprintf (stderr, "%s: EXIT ClientMessage received while locked.\n", + progname); + } + else if (type == XA_RESTART) + { + /* The RESTART message works whether the screensaver is active or not, + unless the screen is locked, in which case it doesn't work. + */ + if (until_idle_p || !si->locked_p) + { + if (p->verbose_p) + printf ("%s: RESTART ClientMessage received.\n", progname); + if (! until_idle_p) + { + unblank_screen (si); + kill_screenhack (si); + XSync (si->dpy, False); + } + + /* make sure error message shows up before exit. */ + if (real_stderr && stderr != real_stderr) + dup2 (fileno(real_stderr), fileno(stderr)); + + restart_process (si); + exit (1); /* shouldn't get here; but if restarting didn't work, + make this command be the same as EXIT. */ + } + else + fprintf(stderr, "%s: RESTART ClientMessage received while locked.\n", + progname); + } + else if (type == XA_DEMO) + { +#ifdef NO_DEMO_MODE + fprintf (stderr, "%s: not compiled with support for DEMO mode\n", + progname); +#else + if (until_idle_p) + { + if (p->verbose_p) + printf ("%s: DEMO ClientMessage received.\n", progname); + si->demo_mode_p = True; + return True; + } + fprintf (stderr, + "%s: DEMO ClientMessage received while active.\n", progname); +#endif + } + else if (type == XA_LOCK) + { +#ifdef NO_LOCKING + fprintf (stderr, "%s: not compiled with support for LOCK mode\n", + progname); +#else + if (si->locking_disabled_p) + fprintf (stderr, + "%s: LOCK ClientMessage received, but locking is disabled.\n", + progname); + else if (si->locked_p) + fprintf (stderr, + "%s: LOCK ClientMessage received while already locked.\n", + progname); + else + { + si->locked_p = True; + if (p->verbose_p) + printf ("%s: LOCK ClientMessage received;%s locking.\n", + progname, until_idle_p ? " activating and" : ""); + + if (si->lock_id) /* we're doing it now, so lose the timeout */ + { + XtRemoveTimeOut (si->lock_id); + si->lock_id = 0; + } + + if (until_idle_p) + { + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + { + XForceScreenSaver (si->dpy, ScreenSaverActive); + return False; + } + else + { + return True; + } + } + } +#endif + } + else + { + char *str; + str = (type ? XGetAtomName(si->dpy, type) : 0); + if (str) + fprintf (stderr, + "%s: unrecognised screensaver ClientMessage %s received\n", + progname, str); + else + fprintf (stderr, + "%s: unrecognised screensaver ClientMessage 0x%x received\n", + progname, (unsigned int) event->xclient.data.l[0]); + if (str) XFree (str); + } + return False; +} diff --git a/driver/xscreensaver.h b/driver/xscreensaver.h new file mode 100644 index 00000000..2650215c --- /dev/null +++ b/driver/xscreensaver.h @@ -0,0 +1,376 @@ +/* xscreensaver, Copyright (c) 1993-1997 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. + */ + +#ifndef __XSCREENSAVER_H__ +#define __XSCREENSAVER_H__ + +#include +#ifdef HAVE_UNISTD_H +# include +#endif + +#include +#include + +extern char *progname; +extern char *progclass; + +typedef struct saver_preferences saver_preferences; +typedef struct saver_info saver_info; +typedef struct saver_screen_info saver_screen_info; + + +#undef countof +#define countof(x) (sizeof((x))/sizeof((*x))) + + + +/* This structure holds all the user-specified parameters, read from the + command line, the resource database, or entered through a dialog box. + */ +struct saver_preferences { + Bool verbose_p; + Bool lock_p; /* whether to lock as well as save */ + + Bool debug_p; + Bool fade_p; /* whether to fade to black */ + Bool unfade_p; /* whether to fade from black */ + int fade_seconds; /* how long that should take */ + int fade_ticks; /* how many ticks should be used */ + + Bool install_cmap_p; /* whether we should use our own colormap + when using the screen's default visual. */ + + char **screenhacks; /* the programs to run */ + int screenhacks_count; + + int nice_inferior; /* nice value for subprocs */ + + int initial_delay; /* how long to sleep after launch */ + Time timeout; /* how much idle time before activation */ + Time lock_timeout; /* how long after activation locking starts */ + Time cycle; /* how long each hack should run */ +#ifndef NO_LOCKING + Time passwd_timeout; /* how much time before pw dialog goes down */ +#endif + Time pointer_timeout; /* how often to check mouse position */ + Time notice_events_timeout; /* how long after window creation to select */ + Time watchdog_timeout; /* how often to re-raise and re-blank screen */ + + Bool use_xidle_extension; /* which extension to use, if possible */ + Bool use_mit_saver_extension; + Bool use_sgi_saver_extension; + + char *shell; /* where to find /bin/sh */ + +}; + + +/* This structure holds all the data that applies to the program as a whole, + or to the non-screen-specific parts of the display connection. + */ +struct saver_info { + char *version; + saver_preferences prefs; + + int nscreens; + saver_screen_info *screens; + saver_screen_info *default_screen; /* ...on which dialogs will appear. */ + + /* ======================================================================= + global connection info + ======================================================================= */ + + XtAppContext app; + Display *dpy; + XrmDatabase db; + + /* ======================================================================= + server extension info + ======================================================================= */ + +# ifdef HAVE_MIT_SAVER_EXTENSION + int mit_saver_ext_event_number; + int mit_saver_ext_error_number; +# endif +# ifdef HAVE_SGI_SAVER_EXTENSION + int sgi_saver_ext_event_number; + int sgi_saver_ext_error_number; +# endif + + + /* ======================================================================= + blanking + ======================================================================= */ + + Bool screen_blanked_p; /* Whether the saver is currently active. */ + + + /* ======================================================================= + locking + ======================================================================= */ + + Bool locking_disabled_p; /* Sometimes locking is impossible. */ + char *nolock_reason; /* This is why. */ + Bool locked_p; /* Whether the screen is currently locked. */ + Bool dbox_up_p; /* Whether the demo-mode or passwd dialogs + are currently visible */ + + + /* ======================================================================= + demoing + ======================================================================= */ + + Bool demo_mode_p; /* Whether demo-mode is active */ + char *demo_hack; /* The hack that has been selected from the + dialog box, which should be run next. */ + + + /* ======================================================================= + timers + ======================================================================= */ + + XtIntervalId lock_id; /* Timer to implement `prefs.lock_timeout' */ + XtIntervalId cycle_id; /* Timer to implement `prefs.cycle' */ + XtIntervalId timer_id; /* Timer to implement `prefs.timeout' */ + XtIntervalId watchdog_id; /* Timer to implement `prefs.watchdog */ + XtIntervalId check_pointer_timer_id; /* `prefs.pointer_timeout' */ + + time_t last_activity_time; /* Used only when no server exts. */ + saver_screen_info *last_activity_screen; + + + /* ======================================================================= + remote control + ======================================================================= */ + + int next_mode_p; /* Set to 1 if the NEXT ClientMessage has just + been received; set to 2 if PREV has just + been received. (#### This is nasty.) */ + + /* ======================================================================= + subprocs + ======================================================================= */ + + XtIntervalId stderr_popup_timer; + +}; + + +/* This structure holds all the data that applies to the screen-specific parts + of the display connection; if the display has multiple screens, there will + be one of these for each screen. + */ +struct saver_screen_info { + saver_info *global; + + Screen *screen; + Widget toplevel_shell; + + /* ======================================================================= + blanking + ======================================================================= */ + + Window screensaver_window; /* The window that will impersonate the root, + when the screensaver activates. Note that + the window stored here may change, as we + destroy and recreate it on different + visuals. */ + Colormap cmap; /* The colormap that goes with the window. */ + Bool install_cmap_p; /* whether we should use our own colormap. + This can be overridden on a per-hack basis. + */ + Visual *current_visual; /* The visual of the window. */ + Visual *default_visual; /* visual to use when none other specified */ + int current_depth; /* How deep the visual (and the window) are. */ + + Window real_vroot; /* The original virtual-root window. */ + Window real_vroot_value; /* What was in the __SWM_VROOT property. */ + + Cursor cursor; /* A blank cursor that goes with the + real root window. */ + unsigned long black_pixel; /* Black, allocated from `cmap'. */ + +# ifdef HAVE_MIT_SAVER_EXTENSION + Window server_mit_saver_window; +# endif + + + /* ======================================================================= + demoing + ======================================================================= */ + + Colormap demo_cmap; /* The colormap that goes with the dialogs: + this might be the same as `cmap' so care + must be taken not to free it while it's + still in use. */ + + /* ======================================================================= + timers + ======================================================================= */ + + int poll_mouse_last_root_x; /* Used only when no server exts. */ + int poll_mouse_last_root_y; + Window poll_mouse_last_child; + unsigned int poll_mouse_last_mask; + + + /* ======================================================================= + subprocs + ======================================================================= */ + + int current_hack; /* Index into `prefs.screenhacks' */ + pid_t pid; + + int stderr_text_x; + int stderr_text_y; + int stderr_line_height; + XFontStruct *stderr_font; + GC stderr_gc; + Window stderr_overlay_window; /* Used if the server has overlay planes */ + Colormap stderr_cmap; +}; + + + + +/* ======================================================================= + server extensions and virtual roots + ======================================================================= */ + +extern void restore_real_vroot (saver_info *si); +extern void disable_builtin_screensaver (saver_info *si, Bool turn_off_p); +extern void ensure_no_screensaver_running (Display *, Screen *); + +#ifdef HAVE_MIT_SAVER_EXTENSION +extern Bool query_mit_saver_extension (saver_info *); +#endif +#ifdef HAVE_SGI_SAVER_EXTENSION +extern Bool query_sgi_saver_extension (saver_info *); +#endif + + +/* ======================================================================= + blanking + ======================================================================= */ + +extern void initialize_screensaver_window (saver_info *si); +extern void raise_window (saver_info *si, + Bool inhibit_fade, Bool between_hacks_p, + Bool dont_clear); +extern void blank_screen (saver_info *si); +extern void unblank_screen (saver_info *si); +extern void grab_keyboard_and_mouse (Display *, Window, Cursor); +extern void ungrab_keyboard_and_mouse (Display *dpy); + +/* ======================================================================= + locking + ======================================================================= */ + +#ifndef NO_LOCKING +extern Bool unlock_p (saver_info *si); +extern create_passwd_dialog (Widget, Visual *, Colormap); +extern Bool lock_init (int argc, char **argv); +extern Bool passwd_valid_p (const char *typed_passwd); +#endif + +/* ======================================================================= + demoing + ======================================================================= */ + +#ifndef NO_DEMO_MODE +extern void demo_mode (saver_info *si); +extern void demo_mode_restart_process (saver_info *si); +extern create_demo_dialog (Widget, Visual *, Colormap); +extern create_resources_dialog (Widget, Visual *, Colormap); +#endif + +#if !defined(NO_LOCKING) || !defined(NO_DEMO_MODE) +extern void pop_up_dialog_box (Widget dialog, Widget form, int where); +extern void format_into_label (Widget label, const char *arg); +extern void steal_focus_and_colormap (Widget dialog); +#endif + +#ifdef HAVE_MOTIF +extern void disable_motif_drag_and_drop(Widget w); +#endif + + +/* ======================================================================= + timers + ======================================================================= */ + +extern void start_notice_events_timer (saver_info *, Window); +extern void cycle_timer (XtPointer si, XtIntervalId *id); +extern void activate_lock_timer (XtPointer si, XtIntervalId *id); +extern void reset_watchdog_timer (saver_info *si, Bool on_p); +extern void idle_timer (XtPointer si, XtIntervalId *id); +extern void sleep_until_idle (saver_info *si, Bool until_idle_p); + +/* ======================================================================= + remote control + ======================================================================= */ + +extern Bool handle_clientmessage (saver_info *, XEvent *, Bool); + +/* ======================================================================= + subprocs + ======================================================================= */ + +extern void init_sigchld (void); +extern void spawn_screenhack (saver_info *si, Bool first_time_p); +extern void kill_screenhack (saver_info *si); +extern void suspend_screenhack (saver_info *si, Bool suspend_p); +extern Bool screenhack_running_p (saver_info *si); +extern void emergency_kill_subproc (saver_info *si); +extern Bool select_visual (saver_screen_info *ssi, const char *visual_name); +extern const char *signal_name (int signal); + +/* ======================================================================= + subprocs security + ======================================================================= */ + +#ifdef NO_SETUID +# define hack_uid() +# define hack_uid_warn() +#else /* !NO_SETUID */ + extern void hack_uid (saver_info *si); + extern void hack_uid_warn (saver_info *si); +#endif /* NO_SETUID */ + +/* ======================================================================= + subprocs diagnostics + ======================================================================= */ + +extern FILE *real_stderr; +extern FILE *real_stdout; +extern void initialize_stderr (saver_info *si); +extern void reset_stderr (saver_screen_info *ssi); +extern void clear_stderr (saver_screen_info *ssi); + +/* ======================================================================= + misc + ======================================================================= */ + +extern void save_argv (int argc, char **argv); +extern void saver_exit (saver_info *si, int status); +extern void restart_process (saver_info *si); + +extern int saver_ehandler (Display *dpy, XErrorEvent *error); +extern int BadWindow_ehandler (Display *dpy, XErrorEvent *error); +extern Bool window_exists_p (Display *dpy, Window window); +extern char *timestring (void); + +extern Atom XA_VROOT, XA_XSETROOT_ID; +extern Atom XA_SCREENSAVER_VERSION, XA_SCREENSAVER_ID; +extern Atom XA_SCREENSAVER_TIME; + +#endif /* __XSCREENSAVER_H__ */ diff --git a/driver/xscreensaver.man b/driver/xscreensaver.man new file mode 100644 index 00000000..bff441a5 --- /dev/null +++ b/driver/xscreensaver.man @@ -0,0 +1,853 @@ +..de EX \"Begin example +.ne 5 +.if n .sp 1 +.if t .sp .5 +.nf +.in +.5i +.. +.de EE +.fi +.in -.5i +.if n .sp 1 +.if t .sp .5 +.. +.TH XScreenSaver 1 "16-Jan-98" "X Version 11" +.SH NAME +xscreensaver - graphics hack and screen locker, launched when the user is idle +.SH SYNOPSIS +.B xscreensaver +[\-display \fIhost:display.screen\fP] [\-timeout \fIint\fP] [\-cycle \fIint\fP] [\-nice \fIint\fP] [\-lock] [\-no\-lock] [\-lock\-timeout \fIint\fP] [\-demo] [\-visual \fIvisual\fP] [\-install] [\-no\-install] [\-verbose] [\-silent] [\-xidle\-extension] [\-no\-xidle\-extension] [\-sgi\-extension] [\-no\-sgi\-extension] [\-mit\-extension] [\-no\-mit\-extension] [\-xrm \fIresources\fP] +.SH DESCRIPTION +The \fIxscreensaver\fP program waits until the keyboard and mouse have been +idle for a period, and then runs a graphics demo chosen at random. It +turns off as soon as there is any mouse or keyboard activity. + +This program can lock your terminal in order to prevent others from using it, +though its default mode of operation is merely to display pretty pictures on +your screen when it is not in use. + +The benefit that this program has over the combination of the +.BR xlock (1) +and +.BR xautolock (1) +programs is the ease with which new graphics hacks can be installed. You +don't need to recompile (or even re-run) this program to add a new display +mode. +.SH GETTING STARTED +For the impatient, try this: + +.EX + xscreensaver & + xscreensaver-command -demo +.EE +.RS 0 +After a few seconds, the screen should go black, and a dialog box should +appear in the upper right corner. This is \fIDemo Mode\fP. +.SH DEMO MODE +If \fIxscreensaver\fP receives the \fBDEMO\fP ClientMessage, which is done +by running the +.BR xscreensaver\-command (1) +program with the \fB\-demo\fP option, the screensaver will black the screen +and pop up a dialog box from which you can examine and experiment with the +client programs. + +The dialog box contains a scrolling list, a text field, and a number of +buttons. + +Double-clicking on one of the programs in the list will run it. The dialog +box will disappear, allowing the program access to the full screen. Clicking +the mouse again will bring the dialog box back. + +Single-clicking in the list will place the indicated program and its args +in the text field to be edited. Edit the arguments and hit return to run +the program with the parameters you have specified. (Note that these are +one-time changes and won't be remembered; to make the changes permanent, +you need to edit your X resource file.) + +The buttons are: +.TP 8 +.B Run Next +Clicking this button will run the next program in the list after the +currently-selected one, and will scroll around to the top when it reaches +the bottom. +.TP 8 +.B Run Previous +Opposite of Run Next; at the top, it scrolls around to the bottom. +.TP 8 +.B Edit Parameters +This pops up a second dialog box, in which you have the option to +interactively change most of the screensaver's operational parameters, +such as its timeouts, and whether it should lock the screen. Changing +these parameters here will affect only the running \fIxscreensaver\fP +process; to make the changes permanent, you need to edit your X resource +file. (See below.) +.TP 8 +.B Exit Demo Mode +Returns to normal screensaver operation. +.TP 8 +.B Reinitialize +This causes the X resource database to be re-read, to pick up any changes +you might have made. This works by causing the screensaver process to exit +and then restart itself with the same command-line arguments. This is just +like the \fI\-restart\fP argument to +.BR xscreensaver\-command (1) +except that when executed from this button, the screensaver will +automatically return to demo mode after restarting. +.SH OPTIONS +.I xscreensaver +accepts the following command line options: +.TP 8 +.B \-timeout \fIminutes\fP +The screensaver will activate after the keyboard and mouse have been idle +for this many minutes. Default 10. +.TP 8 +.B \-cycle \fIminutes\fP +After the screensaver has been running for this many minutes, the currently +running graphics hack sub-process will be killed (with \fBSIGTERM\fP), and a +new one started. If this is 0, then the graphics hack will not be changed: +only one demo will run until the screensaver is deactivated by user activity. +Default 10. +.TP 8 +.B \-nice \fIinteger\fP +The sub-processes created by \fIxscreensaver\fP will be ``niced'' to this +level, so that they are given lower priority than other processes on the +system, and don't increase the load unnecessarily. The default is 20. + +(Higher numbers mean lower priority; see +.BR nice (1) +for details.) +.TP 8 +.B \-lock +Enable locking: before the screensaver will turn off, it requires you to +type the password of the person who launched the screensaver, or the root +password. (Note: this doesn't work if the screensaver is launched +by +.BR xdm (1) +because it can't know the user-id of the logged-in user.) +.TP 8 +.B \-no\-lock +Disable locking. This is the default. +.TP 8 +.B \-lock\-timeout \fIminutes\fP +This is how long after the screensaver activates that locking is enabled. +For example, if this is 5, and \fI\-timeout\fP is 10, then after 10 minutes, +the screen would blank. If there was user activity at 12 minutes, no password +would be required. But, if there was user activity at 15 minutes or later +(\fI\-lock\-timeout\fP minutes after activation) then a password would be +required. The default is 0, meaning that if locking is enabled, then +a password will be required as soon as the screensaver activates. +.TP 8 +.B \-demo +Enter the interactive demo mode immediately after startup. Normally +demo mode is invoked via the +.BR xscreensaver\-command (1) +program, but this is a shortcut for new users. See below for a description +of how demo-mode works. +.TP 8 +.B \-visual \fIvisual\fP +Specify which X visual to use by default. Legal values are: +.RS 8 +.TP 8 +.B default +Use the screen's default visual (the visual of the root window.) +This is the default. +.TP 8 +.B best +Use the visual which supports the most colors. Note, however, that the +visual with the most colors might be a TrueColor visual, which does not +support colormap animation. Some programs have more interesting behavior +when run on PseudoColor visuals than on TrueColor. +.TP 8 +.B mono +Use a monochrome visual, if there is one. +.TP 8 +.B gray +Use a grayscale or staticgray visual, if there is one and it has more than +one plane (that is, it's not monochrome.) +.TP 8 +.B color +Use the best of the color visuals, if there are any. +.TP 8 +.I class +where \fIclass\fP is one of \fBStaticGray\fP, \fBStaticColor\fP, +\fBTrueColor\fP, \fBGrayScale\fP, \fBPseudoColor\fP, or \fBDirectColor\fP. +Selects the deepest visual of the given class. +.TP 8 +.I number +where \fInumber\fP (decimal or hex) is interpreted as a visual id number, +as reported by the +.BR xdpyinfo (1) +program; in this way you can have finer control over exactly which visual +gets used, for example, to select a shallower one than would otherwise +have been chosen. +.RE +.RS 8 +.PP +Note that this option specifies only the \fIdefault\fP visual that will +be used: the visual used may be overridden on a program-by-program basis. +See the description of the \fBprograms\fP resource, below. +.RE +.TP 8 +.B \-install +Install a private colormap while the screensaver is active, so that the +graphics hacks can get as many colors as possible. This is the +default. (This only applies when the screen's default visual is being +used, since non-default visuals get their own colormaps automatically.) +This can also be overridden on a per-hack basis: see the discussion of +the \fBdefault\-n\fP name in the section about the \fBprograms\fP resource. +.TP 8 +.B \-no\-install +Use the default colormap. +.TP 8 +.B \-verbose +Print diagnostics. +.TP 8 +.B \-silent + +.TP 8 +.B \-xidle\-extension +Use the \fBXIDLE\fP server extension to decide whether the user is idle. +This is the default if \fIxscreensaver\fP has been compiled with support +for this extension. On X11R4 or X11R5 systems, the XIdle method is faster +and more reliable than what will be done otherwise, so use it if you can. +.TP 8 +.B \-no\-xidle\-extension +Don't use the \fBXIDLE\fP server extension. +.TP 8 +.B \-sgi\-extension +Use the SGI \fBSCREEN_SAVER\fP server extension to decide whether the user +is idle. This is the default if \fIxscreensaver\fP has been compiled with +support for this extension (which is the default on SGI systems.). If it +is available, the \fBSCREEN_SAVER\fP method is faster and more reliable than +what will be done otherwise, so use it if you can. +.TP 8 +.B \-no\-sgi\-extension +Don't use the SGI \fBSCREEN_SAVER\fP server extension. +.TP 8 +.B \-mit\-extension +Use the \fBMIT\-SCREEN\-SAVER\fP server extension to decide whether the user +is idle. This is the default if \fIxscreensaver\fP has been compiled with +support for this extension. However, this extension is flaky, so it's use +is not really recommended. (It also makes the \fIfade\fP option not work +properly.) +.TP 8 +.B \-no\-mit\-extension +Don't use the \fBMIT\-SCREEN\-SAVER\fP server extension. +.SH X RESOURCES +\fIxscreensaver\fP understands the following resources: +.PP +.TP 8 +.B timeout \fR(class \fBTime\fP) +Same as the \fI\-timeout\fP command-line option. Default 10 minutes. +.TP 8 +.B cycle \fR(class \fBTime\fP) +Same as the \fI\-cycle\fP command-line option. Default 10 minutes. +.TP 8 +.B nice \fR(class \fBNice\fP) +Same as the \fI\-nice\fP command-line option. Default 10. +.TP 8 +.B lock \fR(class \fBBoolean\fP) +Same as the \fI\-lock\fP command-line option. +.TP 8 +.B lockTimeout \fR(class \fBTime\fP) +Same as the \fI\-lock\-timeout\fP command-line option. +.TP 8 +.B passwdTimeout \fR(class \fBTime\fP) +If the screen is locked, then this is how many seconds the password dialog box +should be left on the screen before giving up (default 30.) This should not +be too large: the X server is grabbed for the duration that the password +dialog box is up (for security purposes) and leaving the server grabbed for +too long can cause problems. +.TP 8 +.B verbose \fR(class \fBBoolean\fP) +Same as the \fI\-verbose\fP command-line option. +.TP 8 +.B xidle \fR(class \fBBoolean\fP) +Same as the \fI\-xidle\fP command-line option. +.TP 8 +.B fade \fR(class \fBBoolean\fP) +If this is true, then when the screensaver activates, the current contents +of the screen will fade to black instead of simply winking out. This only +works on displays with writable colormaps, that is, if the screen's default +visual is a PseudoColor visual. Default true. A fade will also be done when +switching graphics hacks (when the \fIcycle\fP timer expires.) +.TP 8 +.B unfade \fR(class \fBBoolean\fP) +If this is true, then when the screensaver deactivates, the original contents +of the screen will fade in from black instead of appearing immediately. This +only works on displays with writable colormaps, and if \fIfade\fP is true +as well. Default false. +.TP 8 +.B fadeSeconds \fR(class \fBTime\fP) +If \fIfade\fP is true, this is how long the fade will be in +seconds (default 3.) +.TP 8 +.B fadeTicks \fR(class \fBInteger\fP) +If \fIfade\fP is true, this is how many times a second the colormap will +be changed to effect a fade. Higher numbers yield smoother fades, but +may make the fades take longer than the specified \fIfadeSeconds\fP if +your server isn't fast enough to keep up. Default 20. +.TP 8 +.B visualID \fR(class \fBVisualID\fP) +Same as the \fI\-visual\fP command-line option. Default \fBdefault\fP. +.TP 8 +.B installColormap \fR(class \fBBoolean\fP) +Same as the \fI\-install\fP command-line option. Default true. +.TP 8 +.B captureStderr \fR(class \fBBoolean\fP) +Whether \fIxscreensaver\fP should redirect its standard-error stream to the +window itself. Since its nature is to take over the screen, you would not +normally see error messages generated by the screensaver or the programs it +runs; this resource will cause the output of all relevant programs to be +drawn on the screensaver window itself instead of written to the controlling +terminal of the screensaver driver process. Default true. +.TP 8 +.B captureStdout \fR(class \fBBoolean\fP) +Like \fBcaptureStderr\fP but for the standard-output stream. Default true. +.TP 8 +.B font \fR(class \fBFont\fP) +The font used for the stdout/stderr text, if \fBcaptureStdout\fP or +\fBcaptureStderr\fP are true. Default \fB*\-medium\-r\-*\-140\-*\-m\-*\fP +(a 14 point fixed-width font.) +.TP 8 +.B textForeground \fR(class \fBForeground\fP) +The foreground color used for the stdout/stderr text, if \fBcaptureStdout\fP +or \fBcaptureStderr\fP are true. Default: Yellow. +.TP 8 +.B textBackground \fR(class \fBBackground\fP) +The background color used for the stdout/stderr text, if \fBcaptureStdout\fP +or \fBcaptureStderr\fP are true. Default: Black. +.TP 8 +.B programs \fR(class \fBPrograms\fP) +The graphics hacks which \fIxscreensaver\fP runs when the user is idle. +The value of this resource is a string, one \fIsh\fP-syntax command per line. +Each line must contain exactly one command -- no semicolons, no ampersands. + +When the screensaver starts up, one of these is selected at random, and +run. After the \fIcycle\fP period expires, it is killed, and another +is selected and run. + +If the value of this resource is empty, then no programs will be run; the +screen will simply be made black. + +If the display has multiple screens, then a different program will be run +for each screen. + +Note that you must escape the newlines; here is an example of how you +might set this in your \fI.Xdefaults\fP file: + +.EX +xscreensaver.programs: \\ + qix -root \\n\\ + ico -r -faces -sleep 1 -obj ico \\n\\ + xdaliclock -builtin2 -root \\n\\ + xv -root -rmode 5 image.gif -quit \\n +.EE +.RS 8 +Make sure your \fB$PATH\fP environment variable is set up correctly +\fIbefore\fP xscreensaver is launched, or it won't be able to find the +programs listed in the \fIprograms\fP resource. + +To use a program as a screensaver, two things are required: that that +program draw on the root window (or be able to be configured to draw on +the root window); and that that program understand ``virtual root'' +windows, as used by virtual window managers such as \fItvtwm\fP. (Generally, +this is accomplished by just including the \fI"vroot.h"\fP header file in +the program's source.) + +If there are some programs that you want to run only when using a color +display, and others that you want to run only when using a monochrome +display, you can specify that like this: + +.EX + mono: mono-program -root \\n\\ + color: color-program -root \\n\\ +.EE +.RE +.RS 8 +More generally, you can specify the kind of visual that should be used for +the window on which the program will be drawing. For example, if one +program works best if it has a colormap, but another works best if it has +a 24-bit visual, both can be accomidated: + +.EX + PseudoColor: cmap-program -root \\n\\ + TrueColor: 24bit-program -root \\n\\ +.EE +.RE +.RS 8 +(This sort of thing used to be accomplished with the \fIcolorPrograms\fP +and \fImonoPrograms\fP resources, but those resources have now been removed; +a warning will be issued if they are used.) + +In addition to the symbolic visual names described above (in the section +about the \fI\-visual\fP command-line option) one other visual name is +supported in the \fIprograms\fP list: +.TP 8 +.B default-n +This is like \fBdefault\fP, but also requests the use of the default colormap, +instead of a private colormap. (That is, it behaves as if +the \fI\-no\-install\fP command-line option was specified, but only for +this particular hack.) This is provided because some third-party programs +that draw on the root window make assumptions about the visual and colormap +of that window: assumptions which xscreensaver can violate. +.PP +If you specify a particular visual for a program, and that visual does not +exist on the screen, then that program will not be chosen to run. This +means that on displays with multiple screens of different depths, you can +arrange for appropriate hacks to be run on each. For example, if one screen +is color and the other is monochrome, hacks that look good in mono can be +run on one, and hacks that only look good in color will show up on the other. +.RE +.PP +.PP +Normally you won't need to change the following resources: +.TP 8 +.B bourneShell \fR(class \fBBourneShell\fP) +The pathname of the shell that \fIxscreensaver\fP uses to start subprocesses. +This must be whatever your local variant of \fB/bin/sh\fP is -- in particular, +it must not be \fBcsh\fP. +.TP 8 +.B windowCreationTimeout \fR(class \fBTime\fP) +When server extensions are not in use, this controls the delay between when +windows are created and when \fIxscreensaver\fP selects events on them. +Default 30 seconds. +.TP 8 +.B pointerPollTime \fR(class \fBTime\fP) +When server extensions are not in use, this controls how +frequently \fIxscreensaver\fP checks to see if the mouse position or buttons +have changed. Default 5 seconds. +.TP 8 +.B initialDelay \fR(class \fBTime\fP) +When server extensions are not in use, \fIxscreensaver\fP will wait this many +seconds before selecting events on existing windows, under the assumption that +\fIxscreensaver\fP is started during your login procedure, and the window +state may be in flux. Default 30 seconds. +.TP 8 +.B overlayStderr \fR(class \fBBoolean\fP) +If \fBcaptureStderr\fP or \fBcaptureStdout\fP are True, and your server +supports ``overlay'' visuals, then the text will be written into one of +the higher layers instead of into the same layer as the running screenhack. +Set this to False to disable that (though you shouldn't need to.) +.SH "HOW IT WORKS" +When it is time to activate the screensaver, a full-screen black window is +created on each screen of the display. The window or windows is given the +appropriate properties so that, to any subsequently-created programs, it +will appear to be a ``virtual root'' window. Because of this, any program +which draws on the root window (and which understands virtual roots) can be +used as a screensaver. + +When the user becomes active again, the screensaver windows are unmapped and +the running subprocesses are killed by sending them \fBSIGTERM\fP. This is +also how the subprocesses are killed when the screensaver decides that it's +time to run a different demo: the old one is killed and a new one is launched. + +Before launching a subprocess, \fIxscreensaver\fP stores an appropriate value +for \fB$DISPLAY\fP in the environment that the child will recieve. (This is +so that if you start \fIxscreensaver\fP with a \fI-display\fP argument, the +programs which \fIxscreensaver\fP launches will draw on the same display; +and so that the child will end up drawing on the appropriate screen of a +multi-headed display.) + +When the screensaver turns off, or is killed, care is taken to restore +the ``real'' virtual root window if there is one. Because of this, it is +important that you not kill the screensaver process with \fIkill -9\fP if +you are running a virtual-root window manager. If you kill it with \-9, +you may need to restart your window manager to repair the damage. This +isn't an issue if you aren't running a virtual-root window manager. + +For all the gory details, see the commentary at the top of xscreensaver.c. + +You can control a running screensaver process by using the +.BR xscreensaver\-command (1) +program (which see.) +.SH USING XDM(1) +You can run \fIxscreensaver\fP from your xdm session, so that the +screensaver will run even when nobody is logged in on the console. +Simply add \fB"xscreensaver &"\fP to your \fI/usr/lib/X11/xdm/Xsetup\fP +file. Because \fIxdm\fP grabs the keyboard, keypresses will not make +the screensaver deactivate, but any mouse activity will. + +Make sure you have \fB$PATH\fP set up correctly in the Xsetup script, or +\fIxdm\fP won't be able to find \fIxscreensaver\fP, and/or \fIxscreensaver\fP +won't be able to find its graphics hacks. + +(If your system does not seem to be executing the \fIXsetup\fP file, you +may need to configure it to do so -- the traditional way to do this is +to make that file the value of the \fIDisplayManager*setup\fP resource +in the \fIxdm-config\fP file. See the man page for +.BR xdm (1) +for more details.) + +Users may want to add \fB"xscreensaver-command -restart"\fP to their +startup scripts, so that the screensaver will be reinitialized with +their private resource settings when they log in. + +It is safe to run this program as root (as \fIxdm\fP is likely to do.) If +run as root, \fIxscreensaver\fP changes its effective user and group ids to +something safe (like \fI"nobody"\fP) before connecting to the X server +or launching user-specified programs. + +Locking doesn't work if the screensaver is launched by \fIxdm\fP. To get +around this, you can run the screensaver from \fIxdm\fP without locking, +and kill and restart it from your personal X startup script to enable +locking; for example, by using this pair of commands: + +.EX + xscreensaver-command -exit ; xscreensaver +.EE +.SH USING CDE (COMMON DESKTOP ENVIRONMENT) +The easiest way to use \fIxscreensaver\fP on a system with CDE is to simply +switch off the built-in CDE screensaver, and use \fIxscreensaver\fP instead; +and second, to tell the front panel to run +.BR xscreensaver\-command (1) +with the \fI\-lock\fP option when the \fILock\fP icon is clicked. + +To accomplish this involves five steps: +.RS 4 +.TP 3 +\fB1: Switch off CDE's locker\fP +Do this by turning off ``\fIScreen Saver and Screen Lock\fP'' in the +Screen section of the Style Manager. +.TP 3 +\fB2: Edit sessionetc\fP +Edit the file \fI~/.dt/sessions/sessionetc\fP and add to it the line + + xscreensaver & + +This will cause \fIxscreensaver\fP to be launched when you log in. +(As always, make sure that xscreensaver and the graphics demos are on +your \fB$PATH\fP; the path needs to be set in \fI.cshrc\fP +and/or \fI.dtprofile\fP, not \fI.login\fP.) +.TP 3 +\fB3: Create XScreenSaver.dt\fP +Create a file called \fI~/.dt/types/XScreenSaver.dt\fP with the following +contents: + + ACTION XScreenSaver + { + LABEL XScreenSaver + TYPE COMMAND + EXEC_STRING xscreensaver-command -lock + ICON Dtkey + WINDOW_TYPE NO_STDIO + } + +This defines a ``lock'' command for the CDE front panel, that knows how +to talk to \fIxscreensaver\fP. +.TP 3 +\fB4: Create Lock.fp\fP +Create a file called \fI~/.dt/types/Lock.fp\fP with the following +contents: + + CONTROL Lock + { + TYPE icon + CONTAINER_NAME Switch + CONTAINER_TYPE SWITCH + POSITION_HINTS 1 + ICON Fplock + LABEL Lock + PUSH_ACTION XScreenSaver + HELP_TOPIC FPOnItemLock + HELP_VOLUME FPanel + } + +This associates the CDE front panel ``Lock'' icon with the lock command +we just defined in step 3. +.TP 3 +\fB5: Restart\fP +Select ``\fIRestart Workspace Manager\fP'' from the popup menu to make +your changes take effect. If things seem not to be working, check the +file \fI~/.dt/errorlog\fP for error messages. +.RE +.PP +.SH BUGS +(This is not a bug, but) note that as of release 1.32, the \fBcolorPrograms\fP +and \fBmonoPrograms\fP resources are no longer used: they have been +supplanted by the extended syntax of the \fBprograms\fP resource (which is +described above, in the \fIresources\fP section.) +.TP 8 +Extensions +If you are not making use of one of the server extensions (\fBXIDLE\fP, +\fBSGI SCREEN_SAVER\fP, or \fBMIT-SCREEN-SAVER\fP), then it is possible, in +rare situations, for \fIxscreensaver\fP to interfere with event propagation +and make another X program malfunction. For this to occur, that other +application would need to \fInot\fP select \fBKeyPress\fP events on its +non-leaf windows within the first 30 seconds of their existence, but then +select for them later. In this case, that client \fImight\fP fail to receive +those events. This isn't very likely, since programs generally select a +constant set of events immediately after creating their windows and then +don't change them, but this is the reason that it's a good idea to install +and use one of the server extensions instead, to work around this shortcoming +in the X protocol. +.TP 8 +Machine Load +Although this program ``nices'' the subprocesses that it starts, +graphics-intensive subprograms can still overload the machine by causing +the X server process itself (which is not ``niced'') to suck a lot of +cycles. Care should be taken to slow down programs intended for use as +screensavers by inserting strategic calls to +.BR sleep (3) +or +.BR usleep (3) +(or making liberal use of any \fI\-delay\fP options which the programs +may provide.) + +Also, an active screensaver will cause your X server to be pretty much +permanently swapped in; but the same is true of any program that draws +periodically, like +.BR xclock (1) +or +.BR xload (1). +.TP 8 +Latency and Responsiveness +If the subprocess is drawing too quickly and the connection to the X +server is a slow one (such as an X terminal running over a phone line) then +the screensaver might not turn off right away when the user becomes active +again (the +.BR ico (1) +demo has this problem if being run in full-speed mode). This can be +alleviated by inserting strategic calls to +.BR XSync (3) +in code intended for use as a screensaver. This prevents too much graphics +activity from being buffered up. +.TP 8 +Locking and XDM +Locking doesn't work if the screensaver is launched by \fIxdm\fP. +The reason for this is that when it is launched by \fIxdm\fP, the +screensaver process is owned by some standard user id (such as \fIroot\fP +or \fIdaemon\fP) instead of the user who is logged in on the console: +because the screensaver was started \fIbefore\fP anyone was logged in. +In order for the screensaver to prompt for the password of the person +who had logged in from \fIxdm\fP, it would need to know who that user was, +and there is no reliable and safe way to figure that out. (And even if +there was, there would be some other security issues here as well.) + +So if you want to use it as a locker, you must start it with your user id. +If it has already been started by \fIxdm\fP, you can kill it with +\fBxscreensaver-command -exit\fP, and then start it again as you. +.TP 8 +Passwords +If you get an error message like ``couldn't get password of \fIuser\fP'' +then this probably means that you're on a system in which the +.BR getpwent (3) +library routine can only be effectively used by root. If this is the case, +then \fIxscreensaver\fP must be installed as setuid to root. Care has +been taken to make this a safe thing to do. + +It also may mean that your system uses shadow passwords instead of the +standard \fIgetpwent\fP interface; in that case, you may need to change +some options with \fIconfigure\fP and recompile. + +If you change your password after xscreensaver has been launched, it will +continue using your old password to unlock the screen until xscreensaver +is restarted. This turns out to be kind of hard to fix. (But remember, +kids! Unix security doesn't do much more than keep honest people honest...) +.TP 8 +Colormap lossage: TWM +The \fBinstallColormap\fP option doesn't work very well with the +.BR twm (1) +window manager and its descendants. + +There is a race condition between the screensaver and this window manager, +which can result in the screensaver's colormap not getting installed +properly, meaning the graphics hacks will appear in essentially random +colors. (If the screen goes white instead of black, this is probably why.) + +The +.BR mwm (1) +and +.BR olwm (1) +window managers don't seem to have this problem. The race condition exists +because X does not provide a way for an OverrideRedirect window to have its +own colormap, short of grabbing the server (which is neither a good idea, nor +really possible with the current design.) What happens is that, as soon as +the screensaver installs its colormap, \fBtwm\fP responds to +the \fBColormapNotify\fP event that is generated by re-instaling the default +colormap. Apparently, \fBtwm\fP doesn't \fIalways\fP do this; it seems to do +it regularly if the screensaver is activated from a menu item, but seems to +not do it if the screensaver comes on of its own volition, or is activated +from another console. Any thoughts on this problem are welcome... +.TP 8 +Colormap lossage: XV, XAnim, XEarth +Some programs don't operate properly on visuals other than the default one, +or with colormaps other than the default one. See the discussion of the +magic "default-n" visual name in the section about the \fBprograms\fP +resource. When programs only work with the default colormap, you need to +use a syntax like this: + + default-n: xv -root image-1.gif -quit \\n\\ + default-n: xearth -nostars -wait 0 \\n\\ + +It would also work to turn off the \fBinstallColormap\fP option altogether, +but that would deny extra colors to those programs that \fIcan\fP take +advantage of them. +.TP 8 +XView Clients +Apparently there are some problems with XView programs getting confused +and thinking that the screensaver window is the real root window even when +the screensaver is not active: ClientMessages intended for the window manager +are sent to the screensaver window instead. This could be solved by making +xscreensaver forward all unrecognised ClientMessages to the real root window, +but there may be other problems as well. If anyone has any insight on the +cause of this problem, please let me know. (XView is an X11 toolkit that +implements the (quite abominable) Sun OpenLook look-and-feel.) +.TP 8 +MIT Extension and Fading +When using the \fBMIT-SCREEN-SAVER\fP extension in conjunction with +the \fBfade\fP option, you may notice an unattractive flicker just before +the fade begins. This is because the server maps a black window just before +it tells the \fIxscreensaver\fP process to activate. The \fIxscreensaver\fP +process immediately unmaps that window, but this results in a flicker. I +haven't figured a way to get around this; it seems to be a fundamental +property of the (mis-) design of this server extension. +.TP 8 +LessTif (Motif Clone) +Demo mode is buggy if XScreenSaver was compiled against really old versions +LessTif; if you use LessTif, use version 0.82 or newer. +.TP 8 +Athena Widgets +If you compiled against the Athena widget toolkit, the dialog boxes are +pretty ugly, especially the password dialog. Use Motif! If you don't +have OSF Motif, use GNU LessTif, it's free: http://www.lesstif.org/ +.TP 8 +SGI Power Saver +If you're running Irix 6.3, you might find that your monitor is powering down +after an hour or two even if you've told it not to. This is fixed by SGI +patches 2447 and 2537. +.TP 8 +Red Hot Lava +There need to be a lot more graphics hacks. In particular, there should be +a simulation of a Lavalite (tm). +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number, and to inform the sub-programs +of the screen on which to draw. +.TP 8 +.B PATH +to find the sub-programs to run. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH UPGRADES +The latest version can always be found at +http://people.netscape.com/jwz/xscreensaver/ +.SH SEE ALSO +.BR X (1), +.BR xscreensaver\-command (1), +.BR xdm (1), +.BR ant (1), +.BR attraction (1), +.BR blitspin (1), +.BR bouboule (1), +.BR braid (1), +.BR bubbles (1), +.BR cage (1), +.BR coral (1), +.BR cynosure (1), +.BR decayscreen (1), +.BR deco (1), +.BR drift (1), +.BR fadeplot (1), +.BR flag (1), +.BR flame (1), +.BR forest (1), +.BR galaxy (1), +.BR gears (1), +.BR goop (1), +.BR grav (1), +.BR greynetic (1), +.BR halo (1), +.BR helix (1), +.BR hopalong (1), +.BR hypercube (1), +.BR ifs (1), +.BR imsmap (1), +.BR julia (1), +.BR kaleidescope (1), +.BR laser (1), +.BR lightning (1), +.BR lisa (1), +.BR lissie (1), +.BR lmorph (1), +.BR maze (1), +.BR moebius (1), +.BR moire (1), +.BR moire2 (1), +.BR morph3d (1), +.BR mountain (1), +.BR munch (1), +.BR noseguy (1), +.BR pedal (1), +.BR penrose (1), +.BR pipes (1), +.BR puzzle (1), +.BR pyro (1), +.BR qix (1), +.BR rd-bomb (1), +.BR rocks (1), +.BR rorschach (1), +.BR rotor (1), +.BR rubik (1), +.BR sierpinski (1), +.BR slidescreen (1), +.BR slip (1), +.BR sphere (1), +.BR spiral (1), +.BR sproingies (1), +.BR stairs (1), +.BR starfish (1), +.BR strange (1), +.BR superquadrics (1), +.BR swirl (1), +.BR triangle (1), +.BR vines (1), +.BR worm (1), +.BR xjack (1), +.BR xlyap (1), +.BR xroger (1), +.BR bongo (1), +.BR ico (1), +.BR xaos (1), +.BR xbouncebits (1), +.BR xcthugha (1), +.BR xdaliclock (1), +.BR xfishtank (1), +.BR xmountains (1), +.BR xsplinefun (1), +.BR xswarm (1), +.BR xtacy (1), +.BR xv (1), +.BR xwave (1). +.SH COPYRIGHT +Copyright \(co 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998 +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. +.SH AUTHOR +Jamie Zawinski . Written in late 1991; first posted +to comp.sources.x on 13-Aug-1992. + +Please let me know if you find any bugs or make any improvements. +.SH ACKNOWLEDGEMENTS +Thanks to David Wojtowicz for implementing \fIlockTimeout\fP. + +Thanks to Martin Kraemer for adding support for shadow passwords and +locking-disabled diagnostics. + +Thanks to the many people who have contributed graphics demos to the package. + +Thanks to Patrick Moreau for the VMS port. + +Thanks to Mark Bowyer for figuring out how to hook it up to CDE. + +And huge thanks to Jon A. Christopher for implementing the Athena dialog +support, so that locking and demo-mode work even if you don't have Motif. diff --git a/driver/xset.c b/driver/xset.c new file mode 100644 index 00000000..0c6f6f89 --- /dev/null +++ b/driver/xset.c @@ -0,0 +1,236 @@ +/* xset.c --- interacting with server extensions and the builtin screensaver. + * xscreensaver, Copyright (c) 1991-1998 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include +#include +#include + +/* This file doesn't need the Xt headers, so stub these types out... */ +#undef XtPointer +#define XtAppContext void* +#define XrmDatabase void* +#define XtIntervalId void* +#define XtPointer void* +#define Widget void* + +#include "xscreensaver.h" + + +/* MIT SCREEN-SAVER server extension hackery. + */ + +#ifdef HAVE_MIT_SAVER_EXTENSION + +# include + +Bool +query_mit_saver_extension (saver_info *si) +{ + return XScreenSaverQueryExtension (si->dpy, + &si->mit_saver_ext_event_number, + &si->mit_saver_ext_error_number); +} + +static int +ignore_all_errors_ehandler (Display *dpy, XErrorEvent *error) +{ + return 0; +} + +static void +init_mit_saver_extension (saver_info *si) +{ + int i; + Pixmap *blank_pix = (Pixmap *) calloc (sizeof(Pixmap), si->nscreens); + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + XID kill_id = 0; + Atom kill_type = 0; + Window root = RootWindowOfScreen (ssi->screen); + blank_pix[i] = XCreatePixmap (si->dpy, root, 1, 1, 1); + + /* Kill off the old MIT-SCREEN-SAVER client if there is one. + This tends to generate X errors, though (possibly due to a bug + in the server extension itself?) so just ignore errors here. */ + if (XScreenSaverGetRegistered (si->dpy, + XScreenNumberOfScreen (ssi->screen), + &kill_id, &kill_type) + && kill_id != blank_pix[i]) + { + XErrorHandler old_handler = + XSetErrorHandler (ignore_all_errors_ehandler); + XKillClient (si->dpy, kill_id); + XSync (si->dpy, False); + XSetErrorHandler (old_handler); + } + XScreenSaverSelectInput (si->dpy, root, ScreenSaverNotifyMask); + XScreenSaverRegister (si->dpy, + XScreenNumberOfScreen (ssi->screen), + (XID) blank_pix[i], XA_PIXMAP); + } + free(blank_pix); +} +#endif /* HAVE_MIT_SAVER_EXTENSION */ + + +/* SGI SCREEN_SAVER server extension hackery. + */ + +#ifdef HAVE_SGI_SAVER_EXTENSION + +# include + +Bool +query_sgi_saver_extension (saver_info *si) +{ + return XScreenSaverQueryExtension (si->dpy, + &si->sgi_saver_ext_event_number, + &si->sgi_saver_ext_error_number); +} + +static void +init_sgi_saver_extension (saver_info *si) +{ + saver_preferences *p = &si->prefs; + int i; + if (si->screen_blanked_p) + /* If you mess with this while the server thinks it's active, + the server crashes. */ + return; + + for (i = 0; i < si->nscreens; i++) + { + saver_screen_info *ssi = &si->screens[i]; + XScreenSaverDisable (si->dpy, XScreenNumberOfScreen(ssi->screen)); + if (! XScreenSaverEnable (si->dpy, XScreenNumberOfScreen(ssi->screen))) + { + fprintf (stderr, + "%s: SGI SCREEN_SAVER extension exists, but can't be initialized;\n\ + perhaps some other screensaver program is already running?\n", + progname); + p->use_sgi_saver_extension = False; + return; + } + } +} + +#endif /* HAVE_SGI_SAVER_EXTENSION */ + + +/* Figuring out what the appropriate XSetScreenSaver() paramters are + (one wouldn't expect this to be rocket science.) + */ + +void +disable_builtin_screensaver (saver_info *si, Bool turn_off_p) +{ + saver_preferences *p = &si->prefs; + int current_server_timeout, current_server_interval; + int current_prefer_blank, current_allow_exp; + int desired_server_timeout, desired_server_interval; + int desired_prefer_blank, desired_allow_exp; + + XGetScreenSaver (si->dpy, ¤t_server_timeout, ¤t_server_interval, + ¤t_prefer_blank, ¤t_allow_exp); + + desired_server_timeout = current_server_timeout; + desired_server_interval = current_server_interval; + desired_prefer_blank = current_prefer_blank; + desired_allow_exp = current_allow_exp; + + /* On SGIs, if interval is non-zero, it is the number of seconds after + screen saving starts at which the monitor should be powered down. + Obviously I don't want that, so set it to 0 (meaning "never".) + + Power saving is disabled if DontPreferBlanking, but in that case, + we don't get extension events either. So we can't turn it off that way. + + Note: if you're running Irix 6.3 (O2), you may find that your monitor is + powering down anyway, regardless of the xset settings. This is fixed by + installing SGI patches 2447 and 2537. + */ + desired_server_interval = 0; + + /* I suspect (but am not sure) that DontAllowExposures might have + something to do with powering off the monitor as well. */ + desired_allow_exp = AllowExposures; + +#if defined(HAVE_MIT_SAVER_EXTENSION) || defined(HAVE_SGI_SAVER_EXTENSION) + if (p->use_mit_saver_extension || p->use_sgi_saver_extension) + { + desired_server_timeout = (p->timeout / 1000); + + /* The SGI extension won't give us events unless blanking is on. + I think (unsure right now) that the MIT extension is the opposite. */ + if (p->use_sgi_saver_extension) + desired_prefer_blank = PreferBlanking; + else + desired_prefer_blank = DontPreferBlanking; + } + else +#endif /* HAVE_MIT_SAVER_EXTENSION || HAVE_SGI_SAVER_EXTENSION */ + { + desired_server_timeout = 0; + } + + if (desired_server_timeout != current_server_timeout || + desired_server_interval != current_server_interval || + desired_prefer_blank != current_prefer_blank || + desired_allow_exp != current_allow_exp) + { + if (desired_server_timeout == 0) + printf ("%s%sisabling server builtin screensaver.\n\ + You can re-enable it with \"xset s on\".\n", + (p->verbose_p ? "" : progname), + (p->verbose_p ? "\n\tD" : ": d")); + + if (p->verbose_p) + fprintf (stderr, "%s: (xset s %d %d %s %s)\n", progname, + desired_server_timeout, desired_server_interval, + (desired_prefer_blank ? "blank" : "noblank"), + (desired_allow_exp ? "noexpose" : "expose")); + + XSetScreenSaver (si->dpy, + desired_server_timeout, desired_server_interval, + desired_prefer_blank, desired_allow_exp); + XSync(si->dpy, False); + } + + +#if defined(HAVE_MIT_SAVER_EXTENSION) || defined(HAVE_SGI_SAVER_EXTENSION) + { + static Bool extension_initted = False; + if (!extension_initted) + { + extension_initted = True; +# ifdef HAVE_MIT_SAVER_EXTENSION + if (p->use_mit_saver_extension) init_mit_saver_extension(si); +# endif +# ifdef HAVE_SGI_SAVER_EXTENSION + if (p->use_sgi_saver_extension) init_sgi_saver_extension(si); +# endif + } + } +#endif /* HAVE_MIT_SAVER_EXTENSION || HAVE_SGI_SAVER_EXTENSION */ + + if (turn_off_p) + /* Turn off the server builtin saver if it is now running. */ + XForceScreenSaver (si->dpy, ScreenSaverReset); +} diff --git a/hacks/.gdbinit b/hacks/.gdbinit new file mode 100644 index 00000000..78a72360 --- /dev/null +++ b/hacks/.gdbinit @@ -0,0 +1,4 @@ +set args -geom =600x480+0+0 -sync +b screenhack_ehandler +b exit +b abort diff --git a/hacks/Makefile.in b/hacks/Makefile.in new file mode 100644 index 00000000..68714534 --- /dev/null +++ b/hacks/Makefile.in @@ -0,0 +1,1257 @@ +# hacks/Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# the `../configure' script generates `hacks/Makefile' from this file. + +@SET_MAKE@ +.SUFFIXES: +.SUFFIXES: .c .o + +srcdir = @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) +SGI_VIDEO_OBJS = @SGI_VIDEO_OBJS@ +SGI_VIDEO_LIBS = @SGI_VIDEO_LIBS@ + +UTILS_SRC = $(srcdir)/../utils +UTILS_BIN = ../utils + +INCLUDES = -I$(srcdir) -I$(srcdir)/.. -I$(UTILS_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 +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 + +SRCS = attraction.c blitspin.c bouboule.c braid.c bubbles.c \ + bubbles-default.c decayscreen.c deco.c drift.c flag.c \ + flame.c forest.c vines.c galaxy.c grav.c greynetic.c \ + halo.c helix.c hopalong.c hypercube.c ifs.c imsmap.c \ + julia.c kaleidescope.c laser.c lightning.c lisa.c lmorph.c \ + maze.c moire.c noseguy.c pedal.c penrose.c pyro.c qix.c \ + rocks.c rorschach.c screenhack.c sierpinski.c slidescreen.c \ + slip.c sphere.c spiral.c strange.c swirl.c xlockmore.c \ + xroger-hack.c goop.c starfish.c munch.c fadeplot.c \ + rd-bomb.c coral.c mountain.c triangle.c lissie.c worm.c \ + rotor.c ant.c xjack.c xlyap.c puzzle.c xscreensaver-sgigl.c \ + cynosure.c moire2.c + +OBJS = attraction.o blitspin.o bouboule.o braid.o bubbles.o \ + bubbles-default.o decayscreen.o deco.o drift.o flag.o \ + flame.o forest.o vines.o galaxy.o grav.o greynetic.o \ + halo.o helix.o hopalong.o hypercube.o ifs.o imsmap.o \ + julia.o kaleidescope.o laser.o lightning.o lisa.o lmorph.o \ + maze.o moire.o noseguy.o pedal.o penrose.o pyro.o qix.o \ + rocks.o rorschach.o screenhack.o sierpinski.o slidescreen.o \ + slip.o sphere.o spiral.o strange.o swirl.o xlockmore.o \ + xroger-hack.o goop.o starfish.o munch.o fadeplot.o \ + rd-bomb.o coral.o mountain.o triangle.o lissie.o worm.o \ + rotor.o ant.o xjack.o xlyap.o puzzle.o xscreensaver-sgigl.o \ + cynosure.o moire2.o + +EXES = attraction blitspin bouboule braid bubbles decayscreen deco \ + drift flag flame forest vines galaxy grav greynetic halo \ + helix hopalong hypercube ifs imsmap julia kaleidescope \ + laser lightning lisa lmorph maze moire noseguy pedal \ + penrose pyro qix rocks rorschach sierpinski slidescreen \ + slip sphere spiral strange swirl xroger goop starfish munch \ + fadeplot rd-bomb coral mountain triangle lissie worm rotor \ + ant xjack xlyap puzzle cynosure moire2 + +HACK_OBJS_1 = $(UTILS_BIN)/resources.o $(UTILS_BIN)/visual.o \ + $(UTILS_BIN)/usleep.o $(UTILS_BIN)/yarandom.o @XMU_OBJS@ +HACK_OBJS = screenhack.o $(HACK_OBJS_1) +XLOCK_OBJS = screenhack-xlock.o xlockmore.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 = bubbles.h screenhack.h xlockmore.h xlockmoreI.h +MEN = attraction.man blitspin.man bouboule.man braid.man \ + bubbles.man decayscreen.man deco.man drift.man flag.man \ + flame.man forest.man vines.man galaxy.man grav.man \ + greynetic.man halo.man helix.man hopalong.man hypercube.man \ + ifs.man imsmap.man julia.man kaleidescope.man laser.man \ + lightning.man lisa.man lmorph.man maze.man moire.man \ + noseguy.man pedal.man penrose.man pyro.man qix.man \ + rocks.man rorschach.man sierpinski.man slidescreen.man \ + slip.man sphere.man spiral.man strange.man swirl.man \ + xroger.man goop.man starfish.man munch.man rd-bomb.man \ + xjack.man xlyap.man puzzle.man +STAR = * +EXTRAS = README Makefile.in xlock.h .gdbinit \ + vidwhacker \ + images/$(STAR).xbm \ + images/bubbles/$(STAR).pov \ + images/bubbles/$(STAR).xpm \ + images/noseguy/$(STAR).xbm \ + images/noseguy/$(STAR).xpm \ + images/puzzle/$(STAR).xbm \ + +VMSFILES = compile_axp.com compile_decc.com link_axp.com link_decc.com \ + vms_axp.opt vms_axp_12.opt vms_decc.opt vms_decc_12.opt + +TARFILES = $(SRCS) $(HDRS) $(MEN) $(EXTRAS) $(VMSFILES) + + +all: $(EXES) + +install: install-program install-man +uninstall: uninstall-program uninstall-man + +install-strip: + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install + +install-program: + @if [ ! -d $(HACKDIR) ]; then mkdir $(HACKDIR) ; fi ; \ + for program in $(EXES); do \ + echo $(INSTALL_PROGRAM) $$program $(HACKDIR)/$$program ; \ + $(INSTALL_PROGRAM) $$program $(HACKDIR)/$$program ; \ + done + +install-man: + @if [ ! -d $(mandir) ]; then mkdir $(mandir) ; fi ; \ + if [ ! -d $(man1dir) ]; then mkdir $(man1dir) ; fi ; \ + 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@ \([^$$]\)@ $$(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) + + +# Rules for generating the VMS makefiles on Unix, so that it doesn't have to +# be done by hand... +# +VMS_AXP_COMPILE_1=$$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE +VMS_AXP_COMPILE_2=)/INCL=([],[-],[-.UTILS]) + +compile_axp.com: Makefile.in + @echo generating $@ from $<... ; \ + ( for c in $(SRCS) ; do \ + c=`echo $$c | tr a-z A-Z` ; \ + echo "$(VMS_AXP_COMPILE_1)$(VMS_AXP_COMPILE_2) $$c" ; \ + done ; \ + foo="$(VMS_AXP_COMPILE_1),XLOCKMORE$(VMS_AXP_COMPILE_2)" ; \ + echo $${foo}/OBJ=SCREENHACK-XLOCK.OBJ SCREENHACK.C ; \ + ) | sort > $@ + +compile_decc.com: compile_axp.com + @echo generating $@ from $<... ; \ + sed 's/axp/decc/g' < $< > $@ + +#### TODO: generating link_axp.com is kinda tricky... + +link_decc.com: link_axp.com + @echo generating $@ from $<... ; \ + sed 's/axp/decc/g' < $< > $@ + +$(srcdir)/../setup.com: Makefile.in + @echo generating $@ from $<... ; \ + ( echo '$$! Xscreensaver - definition of various DCL symbols' ; \ + echo '$$ set NOON' ; \ + echo '$$ set def [.HACKS]' ; \ + echo '$$ mydisk = f$$trnlmn("SYS$$DISK")' ; \ + echo '$$ mydir = mydisk+f$$directory()' ; \ + ( for c in $(EXES) ; do \ + c2="$${c} " ; \ + c2=`echo "$${c2}" | sed 's/^\(........*\) $$/\1/'` ; \ + echo '$$' "$${c2}:== $$'mydir'$${c}" ; \ + done ; \ + ) | sort ; \ + echo '$$ set def [-.DRIVER]' ; \ + echo '$$ mydir = mydisk+f$$directory()' ; \ + echo "$$ xscreensaver :== $$'mydir'xscreensaver" ; \ + echo "$$ xscreen*command :== $$'mydir'xscreensaver-command" ; \ + echo '$$ set def [-]' ; \ + echo '$$ exit' ; \ + ) > $@ + +distdepend:: compile_axp.com compile_decc.com +distdepend:: link_axp.com link_decc.com +distdepend:: $(srcdir)/../setup.com + + +# 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 + +$(UTIL_OBJS): + cd $(UTILS_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. +# +screenhack-xlock.o: screenhack.c + $(CC) -o $@ -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) \ + -DXLOCKMORE $(srcdir)/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 +COL = $(COLOR_OBJS) + +CC_HACK = $(CC) $(LDFLAGS) + +xscreensaver-sgigl: xscreensaver-sgigl.c + $(CC) $(LDFLAGS) -o $@ $< -I$(UTILS_SRC) $(HACK_PRE) \ + -lXmu -lX11 -lXext $(X_EXTRA_LIBS) -lm + + +# The rules for those hacks which follow the `screenhack.c' API. +# If make wasn't such an utter abomination, these could all be combined +# into one rule, but we don't live in such a perfect world. The $< rule +# is pretty much useless in the face of more than one dependency, as far +# as I can tell. +# +attraction: $(HACK_OBJS) attraction.o $(COL) $(SPL) + $(CC_HACK) -o $@ $(HACK_OBJS) attraction.o $(COL) $(SPL) $(HACK_LIBS) + +blitspin: $(HACK_OBJS) blitspin.o $(GRAB) + $(CC_HACK) -o $@ $(HACK_OBJS) blitspin.o $(GRAB) $(XPM_LIBS) $(GRAB_LIBS) + +bubbles: $(HACK_OBJS) bubbles.o bubbles-default.o + $(CC_HACK) -o $@ $(HACK_OBJS) bubbles.o bubbles-default.o $(XPM_LIBS) + +decayscreen: $(HACK_OBJS) decayscreen.o $(GRAB) + $(CC_HACK) -o $@ $(HACK_OBJS) decayscreen.o $(GRAB) $(HACK_LIBS) $(GRAB_LIBS) + +deco: $(HACK_OBJS) deco.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) deco.o $(COL) $(HACK_LIBS) + +flame: $(HACK_OBJS) flame.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) flame.o $(COL) $(HACK_LIBS) + +greynetic: $(HACK_OBJS) greynetic.o + $(CC_HACK) -o $@ $(HACK_OBJS) greynetic.o $(HACK_LIBS) + +halo: $(HACK_OBJS) halo.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) halo.o $(COL) $(HACK_LIBS) + +helix: $(HACK_OBJS) helix.o $(HSV) $(ERASE) + $(CC_HACK) -o $@ $(HACK_OBJS) helix.o $(HSV) $(ERASE) $(HACK_LIBS) + +hypercube: $(HACK_OBJS) hypercube.o + $(CC_HACK) -o $@ $(HACK_OBJS) hypercube.o $(HACK_LIBS) + +imsmap: $(HACK_OBJS) imsmap.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) imsmap.o $(COL) $(HACK_LIBS) + +kaleidescope: $(HACK_OBJS) kaleidescope.o + $(CC_HACK) -o $@ $(HACK_OBJS) kaleidescope.o $(HACK_LIBS) + +lmorph: $(HACK_OBJS) lmorph.o + $(CC_HACK) -o $@ $(HACK_OBJS) lmorph.o $(HACK_LIBS) + +maze: $(HACK_OBJS) maze.o $(ERASE) $(XROG) + $(CC_HACK) -o $@ $(HACK_OBJS) maze.o $(ERASE) $(XROG) $(HACK_LIBS) + +moire: $(HACK_OBJS) moire.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) moire.o $(COL) $(HACK_LIBS) + +moire2: $(HACK_OBJS) moire2.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) moire2.o $(COL) $(HACK_LIBS) + +noseguy: $(HACK_OBJS) noseguy.o + $(CC_HACK) -o $@ $(HACK_OBJS) noseguy.o $(XPM_LIBS) + +pedal: $(HACK_OBJS) pedal.o $(HSV) + $(CC_HACK) -o $@ $(HACK_OBJS) pedal.o $(HSV) $(HACK_LIBS) + +pyro: $(HACK_OBJS) pyro.o $(HSV) + $(CC_HACK) -o $@ $(HACK_OBJS) pyro.o $(HSV) $(HACK_LIBS) + +qix: $(HACK_OBJS) qix.o $(ALP) + $(CC_HACK) -o $@ $(HACK_OBJS) qix.o $(ALP) $(HACK_LIBS) + +rocks: $(HACK_OBJS) rocks.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) rocks.o $(COL) $(HACK_LIBS) + +rorschach: $(HACK_OBJS) rorschach.o $(HSV) $(ERASE) + $(CC_HACK) -o $@ $(HACK_OBJS) rorschach.o $(HSV) $(ERASE) $(HACK_LIBS) + +slidescreen: $(HACK_OBJS) slidescreen.o $(GRAB) + $(CC_HACK) -o $@ $(HACK_OBJS) slidescreen.o $(GRAB) $(HACK_LIBS) $(GRAB_LIBS) + +xroger: $(HACK_OBJS) xroger-hack.o $(HSV) $(XROG) + $(CC_HACK) -o $@ $(HACK_OBJS) xroger-hack.o $(HSV) $(XROG) $(HACK_LIBS) + +goop: $(HACK_OBJS) goop.o $(ALP) $(SPL) + $(CC_HACK) -o $@ $(HACK_OBJS) goop.o $(ALP) $(SPL) $(HACK_LIBS) + +starfish: $(HACK_OBJS) starfish.o $(COL) $(SPL) + $(CC_HACK) -o $@ $(HACK_OBJS) starfish.o $(COL) $(SPL) $(HACK_LIBS) + +munch: $(HACK_OBJS) munch.o $(COL) $(SPL) + $(CC_HACK) -o $@ $(HACK_OBJS) munch.o $(COL) $(SPL) $(HACK_LIBS) + +rd-bomb: $(HACK_OBJS) rd-bomb.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) rd-bomb.o $(COL) $(HACK_LIBS) + +coral: $(HACK_OBJS) coral.o $(COL) $(ERASE) + $(CC_HACK) -o $@ $(HACK_OBJS) coral.o $(COL) $(ERASE) $(HACK_LIBS) + +xjack: $(HACK_OBJS) xjack.o + $(CC_HACK) -o $@ $(HACK_OBJS) xjack.o $(HACK_LIBS) + +xlyap: $(HACK_OBJS) xlyap.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) xlyap.o $(COL) $(HACK_LIBS) + +puzzle: $(HACK_OBJS) puzzle.o $(GRAB) + $(CC_HACK) -o $@ $(HACK_OBJS) puzzle.o $(GRAB) $(HACK_LIBS) $(GRAB_LIBS) + +cynosure: $(HACK_OBJS) cynosure.o $(COL) + $(CC_HACK) -o $@ $(HACK_OBJS) cynosure.o $(COL) $(HACK_LIBS) + + +# The rules for those hacks which follow the `xlockmore' API. +# + +bouboule: bouboule.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) + +drift: drift.o $(XLOCK_OBJS) $(ERASE) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS) + +flag: flag.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(XPM_LIBS) + +forest: forest.o $(XLOCK_OBJS) $(ERASE) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS) + +vines: vines.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) + +grav: grav.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +hopalong: hopalong.o $(XLOCK_OBJS) $(ERASE) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS) + +ifs: ifs.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +julia: julia.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +laser: laser.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(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) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +penrose: penrose.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) + +strange: strange.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +swirl: swirl.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +fadeplot: fadeplot.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +mountain: mountain.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +triangle: triangle.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +worm: worm.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +rotor: rotor.o $(XLOCK_OBJS) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(HACK_LIBS) + +ant: ant.o $(XLOCK_OBJS) $(ERASE) + $(CC_HACK) -o $@ $@.o $(XLOCK_OBJS) $(ERASE) $(HACK_LIBS) + + +############################################################################## +# +# DO NOT DELETE: updated by make distdepend + +attraction.o: $(srcdir)/screenhack.h +attraction.o: ../config.h +attraction.o: $(UTILS_SRC)/yarandom.h +attraction.o: $(UTILS_SRC)/usleep.h +attraction.o: $(UTILS_SRC)/resources.h +attraction.o: $(UTILS_SRC)/hsv.h +attraction.o: $(UTILS_SRC)/colors.h +attraction.o: $(UTILS_SRC)/grabscreen.h +attraction.o: $(UTILS_SRC)/visual.h +attraction.o: $(UTILS_SRC)/spline.h +blitspin.o: $(srcdir)/screenhack.h +blitspin.o: ../config.h +blitspin.o: $(UTILS_SRC)/yarandom.h +blitspin.o: $(UTILS_SRC)/usleep.h +blitspin.o: $(UTILS_SRC)/resources.h +blitspin.o: $(UTILS_SRC)/hsv.h +blitspin.o: $(UTILS_SRC)/colors.h +blitspin.o: $(UTILS_SRC)/grabscreen.h +blitspin.o: $(UTILS_SRC)/visual.h +blitspin.o: $(srcdir)/images/som.xbm +bouboule.o: $(srcdir)/xlockmore.h +bouboule.o: ../config.h +bouboule.o: $(srcdir)/xlockmoreI.h +bouboule.o: $(srcdir)/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 +braid.o: $(srcdir)/xlockmore.h +braid.o: ../config.h +braid.o: $(srcdir)/xlockmoreI.h +braid.o: $(srcdir)/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 +bubbles.o: $(srcdir)/screenhack.h +bubbles.o: ../config.h +bubbles.o: $(UTILS_SRC)/yarandom.h +bubbles.o: $(UTILS_SRC)/usleep.h +bubbles.o: $(UTILS_SRC)/resources.h +bubbles.o: $(UTILS_SRC)/hsv.h +bubbles.o: $(UTILS_SRC)/colors.h +bubbles.o: $(UTILS_SRC)/grabscreen.h +bubbles.o: $(UTILS_SRC)/visual.h +bubbles.o: $(srcdir)/bubbles.h +bubbles-default.o: ../config.h +bubbles-default.o: $(srcdir)/bubbles.h +bubbles-default.o: $(UTILS_SRC)/yarandom.h +bubbles-default.o: $(srcdir)/images/bubbles/blood1.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood2.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood3.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood4.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood5.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood6.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood7.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood8.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood9.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood10.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blood11.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue1.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue2.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue3.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue4.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue5.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue6.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue7.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue8.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue9.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue10.xpm +bubbles-default.o: $(srcdir)/images/bubbles/blue11.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass1.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass2.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass3.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass4.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass5.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass6.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass7.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass8.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass9.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass10.xpm +bubbles-default.o: $(srcdir)/images/bubbles/glass11.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade1.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade2.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade3.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade4.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade5.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade6.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade7.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade8.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade9.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade10.xpm +bubbles-default.o: $(srcdir)/images/bubbles/jade11.xpm +decayscreen.o: $(srcdir)/screenhack.h +decayscreen.o: ../config.h +decayscreen.o: $(UTILS_SRC)/yarandom.h +decayscreen.o: $(UTILS_SRC)/usleep.h +decayscreen.o: $(UTILS_SRC)/resources.h +decayscreen.o: $(UTILS_SRC)/hsv.h +decayscreen.o: $(UTILS_SRC)/colors.h +decayscreen.o: $(UTILS_SRC)/grabscreen.h +decayscreen.o: $(UTILS_SRC)/visual.h +deco.o: $(srcdir)/screenhack.h +deco.o: ../config.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 +drift.o: $(srcdir)/xlockmore.h +drift.o: ../config.h +drift.o: $(srcdir)/xlockmoreI.h +drift.o: $(srcdir)/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 +flag.o: $(srcdir)/xlockmore.h +flag.o: ../config.h +flag.o: $(srcdir)/xlockmoreI.h +flag.o: $(srcdir)/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: $(srcdir)/images/bob.xbm +flame.o: $(srcdir)/screenhack.h +flame.o: ../config.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 +forest.o: $(srcdir)/xlockmore.h +forest.o: ../config.h +forest.o: $(srcdir)/xlockmoreI.h +forest.o: $(srcdir)/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 +vines.o: $(srcdir)/xlockmore.h +vines.o: ../config.h +vines.o: $(srcdir)/xlockmoreI.h +vines.o: $(srcdir)/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 +galaxy.o: $(srcdir)/xlockmore.h +galaxy.o: ../config.h +galaxy.o: $(srcdir)/xlockmoreI.h +galaxy.o: $(srcdir)/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 +grav.o: $(srcdir)/xlockmore.h +grav.o: ../config.h +grav.o: $(srcdir)/xlockmoreI.h +grav.o: $(srcdir)/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 +greynetic.o: $(srcdir)/screenhack.h +greynetic.o: ../config.h +greynetic.o: $(UTILS_SRC)/yarandom.h +greynetic.o: $(UTILS_SRC)/usleep.h +greynetic.o: $(UTILS_SRC)/resources.h +greynetic.o: $(UTILS_SRC)/hsv.h +greynetic.o: $(UTILS_SRC)/colors.h +greynetic.o: $(UTILS_SRC)/grabscreen.h +greynetic.o: $(UTILS_SRC)/visual.h +halo.o: $(srcdir)/screenhack.h +halo.o: ../config.h +halo.o: $(UTILS_SRC)/yarandom.h +halo.o: $(UTILS_SRC)/usleep.h +halo.o: $(UTILS_SRC)/resources.h +halo.o: $(UTILS_SRC)/hsv.h +halo.o: $(UTILS_SRC)/colors.h +halo.o: $(UTILS_SRC)/grabscreen.h +halo.o: $(UTILS_SRC)/visual.h +helix.o: $(srcdir)/screenhack.h +helix.o: ../config.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 +helix.o: $(UTILS_SRC)/erase.h +hopalong.o: $(srcdir)/xlockmore.h +hopalong.o: ../config.h +hopalong.o: $(srcdir)/xlockmoreI.h +hopalong.o: $(srcdir)/screenhack.h +hopalong.o: $(UTILS_SRC)/yarandom.h +hopalong.o: $(UTILS_SRC)/usleep.h +hopalong.o: $(UTILS_SRC)/resources.h +hopalong.o: $(UTILS_SRC)/hsv.h +hopalong.o: $(UTILS_SRC)/colors.h +hopalong.o: $(UTILS_SRC)/grabscreen.h +hopalong.o: $(UTILS_SRC)/visual.h +hopalong.o: $(UTILS_SRC)/erase.h +hypercube.o: $(srcdir)/screenhack.h +hypercube.o: ../config.h +hypercube.o: $(UTILS_SRC)/yarandom.h +hypercube.o: $(UTILS_SRC)/usleep.h +hypercube.o: $(UTILS_SRC)/resources.h +hypercube.o: $(UTILS_SRC)/hsv.h +hypercube.o: $(UTILS_SRC)/colors.h +hypercube.o: $(UTILS_SRC)/grabscreen.h +hypercube.o: $(UTILS_SRC)/visual.h +ifs.o: $(srcdir)/xlockmore.h +ifs.o: ../config.h +ifs.o: $(srcdir)/xlockmoreI.h +ifs.o: $(srcdir)/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 +imsmap.o: $(srcdir)/screenhack.h +imsmap.o: ../config.h +imsmap.o: $(UTILS_SRC)/yarandom.h +imsmap.o: $(UTILS_SRC)/usleep.h +imsmap.o: $(UTILS_SRC)/resources.h +imsmap.o: $(UTILS_SRC)/hsv.h +imsmap.o: $(UTILS_SRC)/colors.h +imsmap.o: $(UTILS_SRC)/grabscreen.h +imsmap.o: $(UTILS_SRC)/visual.h +julia.o: $(srcdir)/xlockmore.h +julia.o: ../config.h +julia.o: $(srcdir)/xlockmoreI.h +julia.o: $(srcdir)/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 +kaleidescope.o: $(UTILS_SRC)/spline.h +kaleidescope.o: $(srcdir)/screenhack.h +kaleidescope.o: ../config.h +kaleidescope.o: $(UTILS_SRC)/yarandom.h +kaleidescope.o: $(UTILS_SRC)/usleep.h +kaleidescope.o: $(UTILS_SRC)/resources.h +kaleidescope.o: $(UTILS_SRC)/hsv.h +kaleidescope.o: $(UTILS_SRC)/colors.h +kaleidescope.o: $(UTILS_SRC)/grabscreen.h +kaleidescope.o: $(UTILS_SRC)/visual.h +laser.o: $(srcdir)/xlockmore.h +laser.o: ../config.h +laser.o: $(srcdir)/xlockmoreI.h +laser.o: $(srcdir)/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 +lightning.o: $(srcdir)/xlockmore.h +lightning.o: ../config.h +lightning.o: $(srcdir)/xlockmoreI.h +lightning.o: $(srcdir)/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: $(srcdir)/xlockmore.h +lisa.o: ../config.h +lisa.o: $(srcdir)/xlockmoreI.h +lisa.o: $(srcdir)/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 +lmorph.o: $(srcdir)/screenhack.h +lmorph.o: ../config.h +lmorph.o: $(UTILS_SRC)/yarandom.h +lmorph.o: $(UTILS_SRC)/usleep.h +lmorph.o: $(UTILS_SRC)/resources.h +lmorph.o: $(UTILS_SRC)/hsv.h +lmorph.o: $(UTILS_SRC)/colors.h +lmorph.o: $(UTILS_SRC)/grabscreen.h +lmorph.o: $(UTILS_SRC)/visual.h +maze.o: $(srcdir)/screenhack.h +maze.o: ../config.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: $(UTILS_SRC)/erase.h +moire.o: $(srcdir)/screenhack.h +moire.o: ../config.h +moire.o: $(UTILS_SRC)/yarandom.h +moire.o: $(UTILS_SRC)/usleep.h +moire.o: $(UTILS_SRC)/resources.h +moire.o: $(UTILS_SRC)/hsv.h +moire.o: $(UTILS_SRC)/colors.h +moire.o: $(UTILS_SRC)/grabscreen.h +moire.o: $(UTILS_SRC)/visual.h +noseguy.o: $(srcdir)/screenhack.h +noseguy.o: ../config.h +noseguy.o: $(UTILS_SRC)/yarandom.h +noseguy.o: $(UTILS_SRC)/usleep.h +noseguy.o: $(UTILS_SRC)/resources.h +noseguy.o: $(UTILS_SRC)/hsv.h +noseguy.o: $(UTILS_SRC)/colors.h +noseguy.o: $(UTILS_SRC)/grabscreen.h +noseguy.o: $(UTILS_SRC)/visual.h +noseguy.o: $(srcdir)/images/noseguy/nose-f1.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-f2.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-f3.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-f4.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-l1.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-l2.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-r1.xpm +noseguy.o: $(srcdir)/images/noseguy/nose-r2.xpm +pedal.o: $(srcdir)/screenhack.h +pedal.o: ../config.h +pedal.o: $(UTILS_SRC)/yarandom.h +pedal.o: $(UTILS_SRC)/usleep.h +pedal.o: $(UTILS_SRC)/resources.h +pedal.o: $(UTILS_SRC)/hsv.h +pedal.o: $(UTILS_SRC)/colors.h +pedal.o: $(UTILS_SRC)/grabscreen.h +pedal.o: $(UTILS_SRC)/visual.h +penrose.o: $(srcdir)/xlockmore.h +penrose.o: ../config.h +penrose.o: $(srcdir)/xlockmoreI.h +penrose.o: $(srcdir)/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 +pyro.o: $(srcdir)/screenhack.h +pyro.o: ../config.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: $(srcdir)/screenhack.h +qix.o: ../config.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 +qix.o: $(UTILS_SRC)/alpha.h +rocks.o: $(srcdir)/screenhack.h +rocks.o: ../config.h +rocks.o: $(UTILS_SRC)/yarandom.h +rocks.o: $(UTILS_SRC)/usleep.h +rocks.o: $(UTILS_SRC)/resources.h +rocks.o: $(UTILS_SRC)/hsv.h +rocks.o: $(UTILS_SRC)/colors.h +rocks.o: $(UTILS_SRC)/grabscreen.h +rocks.o: $(UTILS_SRC)/visual.h +rorschach.o: $(srcdir)/screenhack.h +rorschach.o: ../config.h +rorschach.o: $(UTILS_SRC)/yarandom.h +rorschach.o: $(UTILS_SRC)/usleep.h +rorschach.o: $(UTILS_SRC)/resources.h +rorschach.o: $(UTILS_SRC)/hsv.h +rorschach.o: $(UTILS_SRC)/colors.h +rorschach.o: $(UTILS_SRC)/grabscreen.h +rorschach.o: $(UTILS_SRC)/visual.h +rorschach.o: $(UTILS_SRC)/erase.h +screenhack.o: $(UTILS_SRC)/xmu.h +screenhack.o: $(srcdir)/screenhack.h +screenhack.o: ../config.h +screenhack.o: $(UTILS_SRC)/yarandom.h +screenhack.o: $(UTILS_SRC)/usleep.h +screenhack.o: $(UTILS_SRC)/resources.h +screenhack.o: $(UTILS_SRC)/hsv.h +screenhack.o: $(UTILS_SRC)/colors.h +screenhack.o: $(UTILS_SRC)/grabscreen.h +screenhack.o: $(UTILS_SRC)/visual.h +screenhack.o: $(UTILS_SRC)/version.h +screenhack.o: $(UTILS_SRC)/vroot.h +sierpinski.o: $(srcdir)/xlockmore.h +sierpinski.o: ../config.h +sierpinski.o: $(srcdir)/xlockmoreI.h +sierpinski.o: $(srcdir)/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 +slidescreen.o: $(srcdir)/screenhack.h +slidescreen.o: ../config.h +slidescreen.o: $(UTILS_SRC)/yarandom.h +slidescreen.o: $(UTILS_SRC)/usleep.h +slidescreen.o: $(UTILS_SRC)/resources.h +slidescreen.o: $(UTILS_SRC)/hsv.h +slidescreen.o: $(UTILS_SRC)/colors.h +slidescreen.o: $(UTILS_SRC)/grabscreen.h +slidescreen.o: $(UTILS_SRC)/visual.h +slip.o: $(srcdir)/xlockmore.h +slip.o: ../config.h +slip.o: $(srcdir)/xlockmoreI.h +slip.o: $(srcdir)/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: $(srcdir)/xlockmore.h +sphere.o: ../config.h +sphere.o: $(srcdir)/xlockmoreI.h +sphere.o: $(srcdir)/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: $(srcdir)/xlockmore.h +spiral.o: ../config.h +spiral.o: $(srcdir)/xlockmoreI.h +spiral.o: $(srcdir)/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 +strange.o: $(srcdir)/xlockmore.h +strange.o: ../config.h +strange.o: $(srcdir)/xlockmoreI.h +strange.o: $(srcdir)/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 +swirl.o: $(srcdir)/xlockmore.h +swirl.o: ../config.h +swirl.o: $(srcdir)/xlockmoreI.h +swirl.o: $(srcdir)/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 +xlockmore.o: $(srcdir)/screenhack.h +xlockmore.o: ../config.h +xlockmore.o: $(UTILS_SRC)/yarandom.h +xlockmore.o: $(UTILS_SRC)/usleep.h +xlockmore.o: $(UTILS_SRC)/resources.h +xlockmore.o: $(UTILS_SRC)/hsv.h +xlockmore.o: $(UTILS_SRC)/colors.h +xlockmore.o: $(UTILS_SRC)/grabscreen.h +xlockmore.o: $(UTILS_SRC)/visual.h +xlockmore.o: $(srcdir)/xlockmoreI.h +xroger-hack.o: $(srcdir)/screenhack.h +xroger-hack.o: ../config.h +xroger-hack.o: $(UTILS_SRC)/yarandom.h +xroger-hack.o: $(UTILS_SRC)/usleep.h +xroger-hack.o: $(UTILS_SRC)/resources.h +xroger-hack.o: $(UTILS_SRC)/hsv.h +xroger-hack.o: $(UTILS_SRC)/colors.h +xroger-hack.o: $(UTILS_SRC)/grabscreen.h +xroger-hack.o: $(UTILS_SRC)/visual.h +goop.o: $(srcdir)/screenhack.h +goop.o: ../config.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: $(UTILS_SRC)/spline.h +goop.o: $(UTILS_SRC)/alpha.h +starfish.o: $(srcdir)/screenhack.h +starfish.o: ../config.h +starfish.o: $(UTILS_SRC)/yarandom.h +starfish.o: $(UTILS_SRC)/usleep.h +starfish.o: $(UTILS_SRC)/resources.h +starfish.o: $(UTILS_SRC)/hsv.h +starfish.o: $(UTILS_SRC)/colors.h +starfish.o: $(UTILS_SRC)/grabscreen.h +starfish.o: $(UTILS_SRC)/visual.h +starfish.o: $(UTILS_SRC)/spline.h +munch.o: $(srcdir)/screenhack.h +munch.o: ../config.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 +fadeplot.o: $(srcdir)/xlockmore.h +fadeplot.o: ../config.h +fadeplot.o: $(srcdir)/xlockmoreI.h +fadeplot.o: $(srcdir)/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 +rd-bomb.o: $(srcdir)/screenhack.h +rd-bomb.o: ../config.h +rd-bomb.o: $(UTILS_SRC)/yarandom.h +rd-bomb.o: $(UTILS_SRC)/usleep.h +rd-bomb.o: $(UTILS_SRC)/resources.h +rd-bomb.o: $(UTILS_SRC)/hsv.h +rd-bomb.o: $(UTILS_SRC)/colors.h +rd-bomb.o: $(UTILS_SRC)/grabscreen.h +rd-bomb.o: $(UTILS_SRC)/visual.h +coral.o: $(srcdir)/screenhack.h +coral.o: ../config.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 +coral.o: $(UTILS_SRC)/erase.h +mountain.o: $(srcdir)/xlockmore.h +mountain.o: ../config.h +mountain.o: $(srcdir)/xlockmoreI.h +mountain.o: $(srcdir)/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 +triangle.o: $(srcdir)/xlockmore.h +triangle.o: ../config.h +triangle.o: $(srcdir)/xlockmoreI.h +triangle.o: $(srcdir)/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 +lissie.o: $(srcdir)/xlockmore.h +lissie.o: ../config.h +lissie.o: $(srcdir)/xlockmoreI.h +lissie.o: $(srcdir)/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 +worm.o: $(srcdir)/xlockmore.h +worm.o: ../config.h +worm.o: $(srcdir)/xlockmoreI.h +worm.o: $(srcdir)/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 +rotor.o: $(srcdir)/xlockmore.h +rotor.o: ../config.h +rotor.o: $(srcdir)/xlockmoreI.h +rotor.o: $(srcdir)/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 +ant.o: $(srcdir)/xlockmore.h +ant.o: ../config.h +ant.o: $(srcdir)/xlockmoreI.h +ant.o: $(srcdir)/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 +xjack.o: $(srcdir)/screenhack.h +xjack.o: ../config.h +xjack.o: $(UTILS_SRC)/yarandom.h +xjack.o: $(UTILS_SRC)/usleep.h +xjack.o: $(UTILS_SRC)/resources.h +xjack.o: $(UTILS_SRC)/hsv.h +xjack.o: $(UTILS_SRC)/colors.h +xjack.o: $(UTILS_SRC)/grabscreen.h +xjack.o: $(UTILS_SRC)/visual.h +xlyap.o: $(srcdir)/screenhack.h +xlyap.o: ../config.h +xlyap.o: $(UTILS_SRC)/yarandom.h +xlyap.o: $(UTILS_SRC)/usleep.h +xlyap.o: $(UTILS_SRC)/resources.h +xlyap.o: $(UTILS_SRC)/hsv.h +xlyap.o: $(UTILS_SRC)/colors.h +xlyap.o: $(UTILS_SRC)/grabscreen.h +xlyap.o: $(UTILS_SRC)/visual.h +xlyap.o: $(UTILS_SRC)/vroot.h +puzzle.o: $(srcdir)/screenhack.h +puzzle.o: ../config.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: $(srcdir)/images/puzzle/puzzle_a_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_n_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_ne_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_e_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_se_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_s_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_sw_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_w_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_nw_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_n_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_ne_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_e_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_se_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_s_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_sw_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_w_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_nw_h.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_n_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_ne_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_e_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_se_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_s_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_sw_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_w_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_a_nw_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_n_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_ne_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_e_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_se_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_s_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_sw_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_w_f.xbm +puzzle.o: $(srcdir)/images/puzzle/puzzle_b_nw_f.xbm +xscreensaver-sgigl.o: $(UTILS_SRC)/vroot.h +cynosure.o: $(srcdir)/screenhack.h +cynosure.o: ../config.h +cynosure.o: $(UTILS_SRC)/yarandom.h +cynosure.o: $(UTILS_SRC)/usleep.h +cynosure.o: $(UTILS_SRC)/resources.h +cynosure.o: $(UTILS_SRC)/hsv.h +cynosure.o: $(UTILS_SRC)/colors.h +cynosure.o: $(UTILS_SRC)/grabscreen.h +cynosure.o: $(UTILS_SRC)/visual.h +moire2.o: $(srcdir)/screenhack.h +moire2.o: ../config.h +moire2.o: $(UTILS_SRC)/yarandom.h +moire2.o: $(UTILS_SRC)/usleep.h +moire2.o: $(UTILS_SRC)/resources.h +moire2.o: $(UTILS_SRC)/hsv.h +moire2.o: $(UTILS_SRC)/colors.h +moire2.o: $(UTILS_SRC)/grabscreen.h +moire2.o: $(UTILS_SRC)/visual.h + diff --git a/hacks/README b/hacks/README new file mode 100644 index 00000000..34e687ea --- /dev/null +++ b/hacks/README @@ -0,0 +1,6 @@ + +This directory contains various graphics hacks. These are independent from +the xscreensaver program (in the ../driver/ directory) but some of them use +the utility functions found in the ../utils/ directory. + +If you have compilation problems, check the parameters in ../config.h. diff --git a/hacks/ant.c b/hacks/ant.c new file mode 100644 index 00000000..cf019b62 --- /dev/null +++ b/hacks/ant.c @@ -0,0 +1,1094 @@ +/* -*- 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.04 97/07/28 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 . 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 (9? or 12) <- 9 and 12 are not implemented + + 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: -7 \n" \ + "*ncolors: 64 \n" +# include "xlockmore.h" /* in xscreensaver distribution */ +# include "erase.h" +#else /* STANDALONE */ +# include "xlock.h" /* in xlockmore distribution */ + +#endif /* STANDALONE */ + +#define DEF_TRUCHET "False" + +#ifdef STANDALONE +static int neighbors; +#else +extern int neighbors; +#endif /* !STANDALONE */ + +static Bool truchet; + +static XrmOptionDescRec opts[] = +{ + {"-truchet", ".ant.truchet", XrmoptionNoArg, (caddr_t) "on"}, + {"+truchet", ".ant.truchet", XrmoptionNoArg, (caddr_t) "off"}, + +#ifdef STANDALONE + {"-neighbors", ".ant.neighbors", XrmoptionNoArg, (caddr_t) "on"}, + {"+neighbors", ".ant.neighbors", XrmoptionNoArg, (caddr_t) "off"} +#endif /* STANDALONE */ + +}; +static argtype vars[] = +{ + {(caddr_t *) & truchet, "truchet", "Truchet", DEF_TRUCHET, t_Bool}, +#ifdef STANDALONE + {(caddr_t *) & neighbors, "neighbors", "Neighbors", 0, t_Bool} +#endif /* STANDALONE */ +}; +static OptionStruct desc[] = +{ + {"-/+truchet", "turn on/off Truchet lines"} +}; + +ModeSpecOpt ant_opts = +{2, opts, 1, vars, desc}; + + +#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 COLORS 11 +#define MINANTS 1 +#define PATTERNSIZE 8 +#define REDRAWSTEP 2000 /* How much tape to draw per cycle */ +#define MINGRIDSIZE 24 +#define MINSIZE 1 +#define ANGLES 360 +#define NEIGHBORKINDS 3 + +#ifdef STANDALONE +static XPoint hexagonUnit[6] = +{ + {0, 0}, + {1, 1}, + {0, 2}, + {-1, 1}, + {-1, -1}, + {0, -2} +}; + +static XPoint triangleUnit[2][3] = +{ + { + {0, 0}, + {1, -1}, + {0, 2} + }, + { + {0, 0}, + {-1, 1}, + {0, -2} + } +}; + +#endif /* STANDALONE */ + + +static unsigned char patterns[COLORS - 1][PATTERNSIZE] = +{ + {0x11, 0x22, 0x11, 0x22, 0x11, 0x22, 0x11, 0x22}, /* grey+white | stripe */ + {0x00, 0x66, 0x66, 0x00, 0x00, 0x66, 0x66, 0x00}, /* spots */ + {0x89, 0x44, 0x22, 0x11, 0x88, 0x44, 0x22, 0x11}, /* lt. / stripe */ + {0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66}, /* | bars */ + {0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa}, /* 50% grey */ + {0xff, 0xff, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00}, /* - bars */ + {0xee, 0xdd, 0xbb, 0x77, 0xee, 0xdd, 0xbb, 0x76}, /* dark \ stripe */ + {0xff, 0x99, 0x99, 0xff, 0xff, 0x99, 0x99, 0xff}, /* spots */ + {0xaa, 0xff, 0xff, 0x55, 0xaa, 0xff, 0xff, 0x55}, /* black+grey - stripe */ + {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff} /* black */ +}; + +typedef struct { + unsigned char color; + short direction; + unsigned char next; +} statestruct; + +typedef struct { + int col, row; + short direction; + unsigned char state; +} antstruct; + +typedef struct { + int init_bits; + 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 */ + statestruct machine[COLORS * STATES]; + unsigned char *tape; + unsigned char *truchet_state; + antstruct *ants; + unsigned char colors[COLORS - 1]; + GC stippledGC; + Pixmap pixmaps[COLORS - 1]; + XPoint hexagonList[7]; + XPoint triangleList[2][4]; +} antfarmstruct; + +static int initVal[NEIGHBORKINDS] = +{3, 4, 6}; /* Neighborhoods, 8 just makes a mess */ + + +/* 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 * COLORS * 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->hexagonList[0].x = ap->xb + ccol * ap->xs; + ap->hexagonList[0].y = ap->yb + crow * ap->ys; + if (ap->xs == 1 && ap->ys == 1) + XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc, + ap->hexagonList[0].x, ap->hexagonList[0].y, 1, 1); + else + XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc, + ap->hexagonList, 6, Convex, CoordModePrevious); + +#if 0 /* jwz sez: this looks like crap */ + } 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->ys); +#endif + + } else { /* TRI */ + int orient = (col + row) % 2; /* O left 1 right */ + + ap->triangleList[orient][0].x = ap->xb + col * ap->xs; + ap->triangleList[orient][0].y = ap->yb + row * ap->ys; + if (ap->xs <= 3 || ap->ys <= 3) + XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), gc, + ((orient) ? -1 : 1) + ap->triangleList[orient][0].x, + ap->triangleList[orient][0].y, 1, 1); + else { + if (orient) + ap->triangleList[orient][0].x += (ap->xs / 2 - 1); + else + ap->triangleList[orient][0].x -= (ap->xs / 2 - 1); + XFillPolygon(MI_DISPLAY(mi), MI_WINDOW(mi), gc, + ap->triangleList[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; + XPoint hex, hex2; + + /* 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->hexagonList[side].x; + hex.y += ap->hexagonList[side].y; + } + hex2.x = hex.x + ap->hexagonList[side + 1].x / 2; + hex2.y = hex.y + ap->hexagonList[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, + ap->yb + ap->ys * row + ap->ys / 2, + ap->xs, ap->ys, + 1 * 64, 88 * 64); + XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + ap->xb + ap->xs * col + ap->xs / 2, + ap->yb + ap->ys * row - ap->ys / 2, + ap->xs, ap->ys, + -91 * 64, -88 * 64); + } else { + XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + ap->xb + ap->xs * col - ap->xs / 2, + ap->yb + ap->ys * row - ap->ys / 2, + ap->xs, ap->ys, + -1 * 64, -88 * 64); + XDrawArc(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + ap->xb + ap->xs * col + ap->xs / 2, + ap->yb + ap->ys * row + ap->ys / 2, + ap->xs, ap->ys, + 91 * 64, 88 * 64); + } + } else if (ap->neighbors == 3) { + int orient = (col + row) % 2; /* O left 1 right */ + int side, ang; + XPoint tri; + + tri.x = ap->xb + col * ap->xs; + tri.y = ap->yb + row * ap->ys; + if (orient) { + tri.x += (ap->xs / 2 - 2); + } else { + tri.x -= (ap->xs / 2 + 2); + } + for (side = 0; side < 3; side++) { + if (side > 0) { + tri.x += ap->triangleList[orient][side].x; + tri.y += ap->triangleList[orient][side].y; + } + if (truchetstate == side % 3) { + if (orient) + ang = (518 - 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 * 64, 45 * 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_WIN_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_WIN_WHITE_PIXEL(mi); + gcv.background = MI_WIN_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_WIN_WHITE_PIXEL(mi)); + else if (MI_NPIXELS(mi) > 2 || color > ap->ncolors / 2) + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + else + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_WHITE_PIXEL(mi)); + truchetcell(mi, col, row, truchetstate); +} + +static void +draw_anant(ModeInfo * mi, int col, int row) +{ + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_WHITE_PIXEL(mi)); + fillcell(mi, MI_GC(mi), col, row); +#if 0 /* Can not see eyes */ + { + antfarmstruct *ap = &antfarms[MI_SCREEN(mi)]; + Display *display = MI_DISPLAY(mi); + Window window = MI_WINDOW(mi); + + if (ap->xs > 2 && ap->ys > 2) { /* Draw Eyes */ + + XSetForeground(display, MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + switch (direction) { + case 0: + XDrawPoint(display, window, MI_GC(mi), + ap->xb + ap->xs - 1, ap->yb + 1); + XDrawPoint(display, window, MI_GC(mi), + ap->xb + ap->xs - 1, ap->yb + ap->ys - 2); + break; + case 180: + XDrawPoint(display, window, MI_GC(mi), ap->xb, ap->yb + 1); + XDrawPoint(display, window, MI_GC(mi), ap->xb, ap->yb + ap->ys - 2); + break; + if (neighbors == 4) { + case 90: + XDrawPoint(display, window, MI_GC(mi), ap->xb + 1, ap->yb); + XDrawPoint(display, window, MI_GC(mi), + ap->xb + ap->xs - 2, ap->yb); + break; + case 270: + XDrawPoint(display, window, MI_GC(mi), + ap->xb + 1, ap->yb + ap->ys - 1); + XDrawPoint(display, window, MI_GC(mi), + ap->xb + ap->xs - 2, ap->yb + ap->ys - 1); + break; + } /* else BEE */ + default: + } + } + } +#endif +} + +#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 neighbors) +{ + switch (dir) { + case FS: + return 0; + case TRS: + return (ANGLES / neighbors); + case THRS: + return (ANGLES / (2 * neighbors)); + case TBS: + return (ANGLES / 2); + case THLS: + return (ANGLES - ANGLES / (2 * neighbors)); + case TLS: + return (ANGLES - ANGLES / neighbors); + case SF: + return ANGLES; + case STR: + return (ANGLES + ANGLES / neighbors); + case STHR: + return (ANGLES + ANGLES / (2 * neighbors)); + case STB: + return (3 * ANGLES / 2); + case STHL: + return (2 * ANGLES - ANGLES / (2 * neighbors)); + case STL: + return (2 * ANGLES - ANGLES / 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_WIN_IS_VERBOSE(mi)) + (void) fprintf(stdout, + "neighbors %d, table number %d, colors %d, states %d\n", + ap->neighbors, i, ap->ncolors, ap->nstates); + for (j = 0; j < total; j++) { + ap->machine[j].color = *patptr++; + 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 has i + 2 (or 4) digits in binary */ + power2 = 1 << (i + 1); + /* Dont want numbers which in binary are all 1's. */ + number = NRAND(power2 - 1) + power2; + /* To force a particular number, say */ + + 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; + ap->machine[j].direction = (power2 & number) ? + fromTableDirection(TRS, ap->neighbors) : + fromTableDirection(TLS, ap->neighbors); + ap->machine[j].next = 0; + power2 >>= 1; + } + if (ap->neighbors != 3 && ap->neighbors != 4 && ap->neighbors != 6) + ap->truchet = False; + else if (truchet) + ap->truchet = True; + if (MI_WIN_IS_VERBOSE(mi)) + (void) fprintf(stdout, "neighbors %d, Turk's number %d, colors %d\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); + XGCValues gcv; + antfarmstruct *ap; + int col, row, i, dir; + + /* jwz sez: small sizes look like crap */ + if (size < 0) + size = NRAND(-size)+1; + if (size < 5) + size += 5; + + 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) { + gcv.fill_style = FillOpaqueStippled; + ap->stippledGC = XCreateGC(display, window, GCFillStyle, &gcv); + } + if (ap->init_bits == 0) { + for (i = 0; i < COLORS - 1; i++) + ANTBITS(patterns[i], PATTERNSIZE, PATTERNSIZE); + } + } + ap->generation = 0; + ap->n = MI_BATCHCOUNT(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_WIN_WIDTH(mi); + ap->height = MI_WIN_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 == initVal[i]) { + ap->neighbors = initVal[i]; + break; + } + if (i == NEIGHBORKINDS - 1) { + ap->neighbors = initVal[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; + 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 < 7; i++) { + ap->hexagonList[i].x = (ap->xs - 1) * hexagonUnit[i].x; + ap->hexagonList[i].y = ((ap->ys - 1) * hexagonUnit[i].y / 2) * 4 / 3; + } + } 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; + 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; + 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 < 4; i++) { + ap->triangleList[orient][i].x = + (ap->xs - 2) * triangleUnit[orient][i].x; + ap->triangleList[orient][i].y = + (ap->ys - 2) * triangleUnit[orient][i].y; + } + } + } + XClearWindow(display, MI_WINDOW(mi)); + + /* Exclude odd # of neighbors, stepping forward not defined */ + if (!NRAND(COLORS) && ((ap->neighbors + 1) % 2)) { + getTable(mi, (int) (NRAND(NTABLES))); + } else + getTurk(mi, (int) (NRAND(COLORS - 1))); + if (MI_NPIXELS(mi) > 2) + for (i = 0; i < (int) ap->ncolors - 1; i++) + ap->colors[i] = (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, 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; + + 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) { + 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->col, anant->row); + } + if (++ap->generation > MI_CYCLES(mi)) { +#ifdef STANDALONE + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif + 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)]; + + ap->redrawing = 1; + ap->redrawpos = 0; +} diff --git a/hacks/attraction.c b/hacks/attraction.c new file mode 100644 index 00000000..42930046 --- /dev/null +++ b/hacks/attraction.c @@ -0,0 +1,666 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +/* Simulation of a pair of quasi-gravitational fields, maybe sorta kinda + a little like the strong and weak electromagnetic forces. Derived from + a Lispm screensaver by John Pezaris . Mouse control and + viscosity added by "Philip Edward Cutone, III" . + + John sez: + + The simulation started out as a purely accurate gravitational simulation, + but, with constant simulation step size, I quickly realized the field being + simulated while grossly gravitational was, in fact, non-conservative. It + also had the rather annoying behavior of dealing very badly with colliding + orbs. Therefore, I implemented a negative-gravity region (with two + thresholds; as I read your code, you only implemented one) to prevent orbs + from every coming too close together, and added a viscosity factor if the + speed of any orb got too fast. This provides a nice stable system with + interesting behavior. + + I had experimented with a number of fields including the van der Waals + force (very interesting orbiting behavior) and 1/r^3 gravity (not as + interesting as 1/r^2). An even normal viscosity (rather than the + thresholded version to bleed excess energy) is also not interesting. + The 1/r^2, -1/r^2, -10/r^2 thresholds proved not only robust but also + interesting -- the orbs never collided and the threshold viscosity fixed + the non-conservational problem. + + Philip sez: + > An even normal viscosity (rather than the thresholded version to + > bleed excess energy) is also not interesting. + + unless you make about 200 points.... set the viscosity to about .8 + and drag the mouse through it. it makes a nice wave which travels + through the field. + + And (always the troublemaker) Joe Keane sez: + + Despite what John sez, the field being simulated is always conservative. + The real problem is that it uses a simple hack, computing acceleration + *based only on the starting position*, instead of a real differential + equation solver. Thus you'll always have energy coming out of nowhere, + although it's most blatant when balls get close together. If it were + done right, you wouldn't need viscosity or artificial limits on how + close the balls can get. + */ + +#include +#include +#include "screenhack.h" +#include "spline.h" + +struct ball { + double x, y; + double vx, vy; + double dx, dy; + double mass; + int size; + int pixel_index; + int hue; +}; + +static struct ball *balls; +static int npoints; +static int threshold; +static int delay; +static int global_size; +static int segments; +static Bool glow_p; +static Bool orbit_p; +static XPoint *point_stack; +static int point_stack_size, point_stack_fp; +static XColor *colors; +static int ncolors; +static int fg_index; +static int color_shift; + +/*flip mods for mouse interaction*/ +static Bool mouse_p; +int mouse_x, mouse_y, mouse_mass, root_x, root_y; +static double viscosity; + +static enum object_mode { + ball_mode, line_mode, polygon_mode, spline_mode, spline_filled_mode, + tail_mode +} mode; + +static GC draw_gc, erase_gc; + +#define MAX_SIZE 16 + +#define min(a,b) ((a)<(b)?(a):(b)) +#define max(a,b) ((a)>(b)?(a):(b)) + +static void +init_balls (Display *dpy, Window window) +{ + int i; + XWindowAttributes xgwa; + XGCValues gcv; + int xlim, ylim, midx, midy, r, vx, vy; + double th; + Colormap cmap; + char *mode_str; + XGetWindowAttributes (dpy, window, &xgwa); + xlim = xgwa.width; + ylim = xgwa.height; + cmap = xgwa.colormap; + midx = xlim/2; + midy = ylim/2; + r = get_integer_resource ("radius", "Integer"); + if (r <= 0 || r > min (xlim/2, ylim/2)) + r = min (xlim/2, ylim/2) - 50; + vx = get_integer_resource ("vx", "Integer"); + vy = get_integer_resource ("vy", "Integer"); + npoints = get_integer_resource ("points", "Integer"); + if (npoints < 1) + npoints = 3 + (random () % 5); + balls = (struct ball *) malloc (npoints * sizeof (struct ball)); + segments = get_integer_resource ("segments", "Integer"); + if (segments < 0) segments = 1; + threshold = get_integer_resource ("threshold", "Integer"); + if (threshold < 0) threshold = 0; + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + global_size = get_integer_resource ("size", "Integer"); + if (global_size < 0) global_size = 0; + glow_p = get_boolean_resource ("glow", "Boolean"); + orbit_p = get_boolean_resource ("orbit", "Boolean"); + color_shift = get_integer_resource ("colorShift", "Integer"); + if (color_shift <= 0) color_shift = 5; + + /*flip mods for mouse interaction*/ + mouse_p = get_boolean_resource ("mouse", "Boolean"); + mouse_mass = get_integer_resource ("mouseSize", "Integer"); + mouse_mass = mouse_mass * mouse_mass *10; + + viscosity = get_float_resource ("viscosity", "Float"); + + mode_str = get_string_resource ("mode", "Mode"); + if (! mode_str) mode = ball_mode; + else if (!strcmp (mode_str, "balls")) mode = ball_mode; + else if (!strcmp (mode_str, "lines")) mode = line_mode; + else if (!strcmp (mode_str, "polygons")) mode = polygon_mode; + else if (!strcmp (mode_str, "tails")) mode = tail_mode; + else if (!strcmp (mode_str, "splines")) mode = spline_mode; + else if (!strcmp (mode_str, "filled-splines")) mode = spline_filled_mode; + else { + fprintf (stderr, + "%s: mode must be balls, lines, tails, polygons, splines, or\n\ + filled-splines, not \"%s\"\n", + progname, mode_str); + exit (1); + } + + if (mode != ball_mode && mode != tail_mode) glow_p = False; + + if (mode == polygon_mode && npoints < 3) + mode = line_mode; + + ncolors = get_integer_resource ("colors", "Colors"); + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + colors = 0; + + if (!mono_p) + { + fg_index = 0; + switch (mode) + { + case ball_mode: + if (glow_p) + { + int H = random() % 360; + double S1 = 0.25; + double S2 = 1.00; + double V = frand(0.25) + 0.75; + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + make_color_ramp (dpy, cmap, H, S1, V, H, S2, V, colors, &ncolors, + False, True, False); + } + else + { + ncolors = npoints; + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + make_random_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, True, False, True); + } + break; + case line_mode: + case polygon_mode: + case spline_mode: + case spline_filled_mode: + case tail_mode: + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + make_smooth_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, False, True); + break; + default: + abort (); + } + } + + if (!mono_p && ncolors <= 2) + { + if (colors) free (colors); + colors = 0; + mono_p = True; + } + + if (mode != ball_mode) + { + int size = (segments ? segments : 1); + point_stack_size = size * (npoints + 1); + point_stack = (XPoint *) calloc (point_stack_size, sizeof (XPoint)); + point_stack_fp = 0; + } + + gcv.line_width = (mode == tail_mode + ? (global_size ? global_size : (MAX_SIZE * 2 / 3)) + : 1); + gcv.cap_style = (mode == tail_mode ? CapRound : CapButt); + + if (mono_p) + gcv.foreground = get_pixel_resource("foreground", "Foreground", dpy, cmap); + else + gcv.foreground = colors[fg_index].pixel; + draw_gc = XCreateGC (dpy, window, GCForeground|GCLineWidth|GCCapStyle, &gcv); + + gcv.foreground = get_pixel_resource("background", "Background", dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground|GCLineWidth|GCCapStyle,&gcv); + + +#define rand_size() min (MAX_SIZE, 8 + (random () % (MAX_SIZE - 9))) + + if (orbit_p && !global_size) + /* To orbit, all objects must be the same mass, or the math gets + really hairy... */ + global_size = rand_size (); + + th = frand (M_PI+M_PI); + for (i = 0; i < npoints; i++) + { + int new_size = (global_size ? global_size : rand_size ()); + balls [i].dx = 0; + balls [i].dy = 0; + balls [i].size = new_size; + balls [i].mass = (new_size * new_size * 10); + balls [i].x = midx + r * cos (i * ((M_PI+M_PI) / npoints) + th); + balls [i].y = midy + r * sin (i * ((M_PI+M_PI) / npoints) + th); + if (! orbit_p) + { + balls [i].vx = vx ? vx : ((6.0 - (random () % 11)) / 8.0); + balls [i].vy = vy ? vy : ((6.0 - (random () % 11)) / 8.0); + } + if (mono_p || mode != ball_mode) + balls [i].pixel_index = -1; + else if (glow_p) + balls [i].pixel_index = 0; + else + balls [i].pixel_index = random() % ncolors; + } + + if (orbit_p) + { + double a = 0; + double v; + double v_mult = get_float_resource ("vMult", "Float"); + if (v_mult == 0.0) v_mult = 1.0; + + for (i = 1; i < npoints; i++) + { + double _2ipi_n = (2 * i * M_PI / npoints); + double x = r * cos (_2ipi_n); + double y = r * sin (_2ipi_n); + double distx = r - x; + double dist2 = (distx * distx) + (y * y); + double dist = sqrt (dist2); + double a1 = ((balls[i].mass / dist2) * + ((dist < threshold) ? -1.0 : 1.0) * + (distx / dist)); + a += a1; + } + if (a < 0.0) + { + fprintf (stderr, "%s: domain error: forces on balls too great\n", + progname); + exit (-1); + } + v = sqrt (a * r) * v_mult; + for (i = 0; i < npoints; i++) + { + double k = ((2 * i * M_PI / npoints) + th); + balls [i].vx = -v * sin (k); + balls [i].vy = v * cos (k); + } + } + + if (mono_p) glow_p = False; + XClearWindow (dpy, window); +} + +static void +compute_force (int i, double *dx_ret, double *dy_ret) +{ + int j; + double x_dist, y_dist, dist, dist2; + *dx_ret = 0; + *dy_ret = 0; + for (j = 0; j < npoints; j++) + { + if (i == j) continue; + x_dist = balls [j].x - balls [i].x; + y_dist = balls [j].y - balls [i].y; + dist2 = (x_dist * x_dist) + (y_dist * y_dist); + dist = sqrt (dist2); + + if (dist > 0.1) /* the balls are not overlapping */ + { + double new_acc = ((balls[j].mass / dist2) * + ((dist < threshold) ? -1.0 : 1.0)); + double new_acc_dist = new_acc / dist; + *dx_ret += new_acc_dist * x_dist; + *dy_ret += new_acc_dist * y_dist; + } + else + { /* the balls are overlapping; move randomly */ + *dx_ret += (frand (10.0) - 5.0); + *dy_ret += (frand (10.0) - 5.0); + } + } + + if (mouse_p) + { + x_dist = mouse_x - balls [i].x; + y_dist = mouse_y - balls [i].y; + dist2 = (x_dist * x_dist) + (y_dist * y_dist); + dist = sqrt (dist2); + + if (dist > 0.1) /* the balls are not overlapping */ + { + double new_acc = ((mouse_mass / dist2) * + ((dist < threshold) ? -1.0 : 1.0)); + double new_acc_dist = new_acc / dist; + *dx_ret += new_acc_dist * x_dist; + *dy_ret += new_acc_dist * y_dist; + } + else + { /* the balls are overlapping; move randomly */ + *dx_ret += (frand (10.0) - 5.0); + *dy_ret += (frand (10.0) - 5.0); + } + } +} + +static void +run_balls (Display *dpy, Window window) +{ + int last_point_stack_fp = point_stack_fp; + static int tick = 500, xlim, ylim; + static Colormap cmap; + int i; + + /*flip mods for mouse interaction*/ + Window root1, child1; + unsigned int mask; + if (mouse_p) + { + XQueryPointer(dpy, window, &root1, &child1, + &root_x, &root_y, &mouse_x, &mouse_y, &mask); + } + + if (tick++ == 500) + { + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + tick = 0; + xlim = xgwa.width; + ylim = xgwa.height; + cmap = xgwa.colormap; + } + + /* compute the force of attraction/repulsion among all balls */ + for (i = 0; i < npoints; i++) + compute_force (i, &balls[i].dx, &balls[i].dy); + + /* move the balls according to the forces now in effect */ + for (i = 0; i < npoints; i++) + { + double old_x = balls[i].x; + double old_y = balls[i].y; + double new_x, new_y; + int size = balls[i].size; + balls[i].vx += balls[i].dx; + balls[i].vy += balls[i].dy; + + /* don't let them get too fast: impose a terminal velocity + (actually, make the medium have friction) */ + if (balls[i].vx > 10) + { + balls[i].vx *= 0.9; + balls[i].dx = 0; + } + else if (viscosity != 1) + { + balls[i].vx *= viscosity; + } + + if (balls[i].vy > 10) + { + balls[i].vy *= 0.9; + balls[i].dy = 0; + } + else if (viscosity != 1) + { + balls[i].vy *= viscosity; + } + + balls[i].x += balls[i].vx; + balls[i].y += balls[i].vy; + + /* bounce off the walls */ + if (balls[i].x >= (xlim - balls[i].size)) + { + balls[i].x = (xlim - balls[i].size - 1); + if (balls[i].vx > 0) + balls[i].vx = -balls[i].vx; + } + if (balls[i].y >= (ylim - balls[i].size)) + { + balls[i].y = (ylim - balls[i].size - 1); + if (balls[i].vy > 0) + balls[i].vy = -balls[i].vy; + } + if (balls[i].x <= 0) + { + balls[i].x = 0; + if (balls[i].vx < 0) + balls[i].vx = -balls[i].vx; + } + if (balls[i].y <= 0) + { + balls[i].y = 0; + if (balls[i].vy < 0) + balls[i].vy = -balls[i].vy; + } + + new_x = balls[i].x; + new_y = balls[i].y; + + if (!mono_p) + { + if (mode == ball_mode) + { + if (glow_p) + { + /* make color saturation be related to particle + acceleration. */ + double limit = 0.5; + double s, fraction; + double vx = balls [i].dx; + double vy = balls [i].dy; + if (vx < 0) vx = -vx; + if (vy < 0) vy = -vy; + fraction = vx + vy; + if (fraction > limit) fraction = limit; + + s = 1 - (fraction / limit); + balls[i].pixel_index = (ncolors * s); + } + XSetForeground (dpy, draw_gc, + colors[balls[i].pixel_index].pixel); + } + } + + if (mode == ball_mode) + { + XFillArc (dpy, window, erase_gc, (int) old_x, (int) old_y, + size, size, 0, 360*64); + XFillArc (dpy, window, draw_gc, (int) new_x, (int) new_y, + size, size, 0, 360*64); + } + else + { + point_stack [point_stack_fp].x = new_x; + point_stack [point_stack_fp].y = new_y; + point_stack_fp++; + } + } + + /* draw the lines or polygons after computing all points */ + if (mode != ball_mode) + { + point_stack [point_stack_fp].x = balls [0].x; /* close the polygon */ + point_stack [point_stack_fp].y = balls [0].y; + point_stack_fp++; + if (point_stack_fp == point_stack_size) + point_stack_fp = 0; + else if (point_stack_fp > point_stack_size) /* better be aligned */ + abort (); + if (!mono_p) + { + static int tick = 0; + if (tick++ == color_shift) + { + tick = 0; + fg_index = (fg_index + 1) % ncolors; + XSetForeground (dpy, draw_gc, colors[fg_index].pixel); + } + } + } + + switch (mode) + { + case ball_mode: + break; + case line_mode: + if (segments > 0) + XDrawLines (dpy, window, erase_gc, point_stack + point_stack_fp, + npoints + 1, CoordModeOrigin); + XDrawLines (dpy, window, draw_gc, point_stack + last_point_stack_fp, + npoints + 1, CoordModeOrigin); + break; + case polygon_mode: + if (segments > 0) + XFillPolygon (dpy, window, erase_gc, point_stack + point_stack_fp, + npoints + 1, (npoints == 3 ? Convex : Complex), + CoordModeOrigin); + XFillPolygon (dpy, window, draw_gc, point_stack + last_point_stack_fp, + npoints + 1, (npoints == 3 ? Convex : Complex), + CoordModeOrigin); + break; + case tail_mode: + { + for (i = 0; i < npoints; i++) + { + int index = point_stack_fp + i; + int next_index = (index + (npoints + 1)) % point_stack_size; + XDrawLine (dpy, window, erase_gc, + point_stack [index].x, + point_stack [index].y, + point_stack [next_index].x, + point_stack [next_index].y); + + index = last_point_stack_fp + i; + next_index = (index - (npoints + 1)) % point_stack_size; + if (next_index < 0) next_index += point_stack_size; + if (point_stack [next_index].x == 0 && + point_stack [next_index].y == 0) + continue; + XDrawLine (dpy, window, draw_gc, + point_stack [index].x, + point_stack [index].y, + point_stack [next_index].x, + point_stack [next_index].y); + } + } + break; + case spline_mode: + case spline_filled_mode: + { + static spline *s = 0; + if (! s) s = make_spline (npoints); + if (segments > 0) + { + for (i = 0; i < npoints; i++) + { + s->control_x [i] = point_stack [point_stack_fp + i].x; + s->control_y [i] = point_stack [point_stack_fp + i].y; + } + compute_closed_spline (s); + if (mode == spline_filled_mode) + XFillPolygon (dpy, window, erase_gc, s->points, s->n_points, + (s->n_points == 3 ? Convex : Complex), + CoordModeOrigin); + else + XDrawLines (dpy, window, erase_gc, s->points, s->n_points, + CoordModeOrigin); + } + for (i = 0; i < npoints; i++) + { + s->control_x [i] = point_stack [last_point_stack_fp + i].x; + s->control_y [i] = point_stack [last_point_stack_fp + i].y; + } + compute_closed_spline (s); + if (mode == spline_filled_mode) + XFillPolygon (dpy, window, draw_gc, s->points, s->n_points, + (s->n_points == 3 ? Convex : Complex), + CoordModeOrigin); + else + XDrawLines (dpy, window, draw_gc, s->points, s->n_points, + CoordModeOrigin); + } + break; + default: + abort (); + } + + XSync (dpy, True); +} + + +char *progclass = "Attraction"; + +char *defaults [] = { + "Attraction.background: black", /* to placate SGI */ + "Attraction.foreground: white", + "*mode: balls", + "*points: 0", + "*size: 0", + "*colors: 200", + "*threshold: 100", + "*delay: 10000", + "*glow: false", + "*mouseSize: 10", + "*mouse: false", + "*viscosity: 1", + "*orbit: false", + "*colorShift: 3", + "*segments: 500", + "*vMult: 0.9", + 0 +}; + +XrmOptionDescRec options [] = { + { "-mode", ".mode", XrmoptionSepArg, 0 }, + { "-colors", ".colors", XrmoptionSepArg, 0 }, + { "-points", ".points", XrmoptionSepArg, 0 }, + { "-color-shift", ".colorShift", XrmoptionSepArg, 0 }, + { "-threshold", ".threshold", XrmoptionSepArg, 0 }, + { "-segments", ".segments", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-size", ".size", XrmoptionSepArg, 0 }, + { "-radius", ".radius", XrmoptionSepArg, 0 }, + { "-vx", ".vx", XrmoptionSepArg, 0 }, + { "-vy", ".vy", XrmoptionSepArg, 0 }, + { "-vmult", ".vMult", XrmoptionSepArg, 0 }, + { "-mouse-size", ".mouseSize", XrmoptionSepArg, 0 }, + { "-mouse", ".mouse", XrmoptionNoArg, "true" }, + { "-nomouse", ".mouse", XrmoptionNoArg, "false" }, + { "-viscosity", ".viscosity", XrmoptionSepArg, 0 }, + { "-glow", ".glow", XrmoptionNoArg, "true" }, + { "-noglow", ".glow", XrmoptionNoArg, "false" }, + { "-orbit", ".orbit", XrmoptionNoArg, "true" }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_balls (dpy, window); + while (1) + { + run_balls (dpy, window); + if (delay) usleep (delay); + } +} diff --git a/hacks/attraction.man b/hacks/attraction.man new file mode 100644 index 00000000..9f5e98f7 --- /dev/null +++ b/hacks/attraction.man @@ -0,0 +1,178 @@ +.de EX \"Begin example +.ne 5 +.if n .sp 1 +.if t .sp .5 +.nf +.in +.5i +.. +.de EE +.fi +.in -.5i +.if n .sp 1 +.if t .sp .5 +.. +.TH XScreenSaver 1 "14-Jun-97" "X Version 11" +.SH NAME +attraction - interactions of opposing forces +.SH SYNOPSIS +.B attraction +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-points \fIint\fP] [\-threshold \fIint\fP] [\-mode balls | lines | polygons | splines | filled-splines | tails ] [\-size \fIint\fP] [\-segments \fIint\fP] [\-delay \fIusecs\fP] [\-color-shift \fIint\fP] [\-radius \fIint\fP] [\-vx \fIint\fP] [\-vy \fIint\fP] [\-glow] [\-noglow] [\-orbit] [\-viscosity \fIfloat\fP] [\-mouse] [\-no-mouse] [\-mouse-size] +.SH DESCRIPTION +The \fIattraction\fP program has several visually different modes of +operation, all of which are based on the interactions of a set of control +points which attract each other up to a certain distance, and then begin +to repel each other. The attraction/repulsion is proportional to the +distance between any two particles. +.SH OPTIONS +.I attraction +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-points integer +How many control points should be used, or 0 to select the number randomly. +Default 0. Between 3 and 15 works best. +.TP 8 +.B \-threshold integer +The distance (in pixels) from each particle at which the attractive force +becomes repulsive. Default 100. +.TP 8 +.B \-mode "balls | lines | polygons | tails | splines | filled-splines" +In \fIballs\fP mode (the default) the control points are drawn as filled +circles. The larger the circle, the more massive the particle. + +In \fIlines\fP mode, the control points are connected by straight lines; +the effect is something like \fIqix\fP. + +In \fIpolygons\fP mode, the control points are connected by straight +lines, and filled in. This is most interesting in color. + +In \fIsplines\fP mode, a closed spline is interpolated from the control +points. + +In \fIfilled-splines\fP mode, the splines are filled in instead of being +outlines. This is most interesting in color. + +In \fItails\fP mode, the path which each particle follows is indicated +by a worm-like trail, whose length is controlled by the \fIsegments\fP +parameter. +.TP 8 +.B \-size integer +The size of the balls in pixels, or 0, meaning to select the sizes +randomly (the default.) If this is specified, then all balls will be +the same size. This option has an effect in all modes, since the ``size'' +of the balls controls their mass. +.TP 8 +.B \-segments integer +If in \fIlines\fP or \fIpolygons\fP mode, how many sets of line segments +or polygons should be drawn. Default 100. This has no effect in \fIballs\fP +mode. If \fIsegments\fP is 0, then no segments will ever be erased (this +is only useful in color.) +.TP 8 +.B \-delay microseconds +How much of a delay should be introduced between steps of the animation. +Default 10000, or about 0.01 seconds. +.TP 8 +.B \-color-shift int +If on a color display, the color of the line segments or polygons will +cycle through the color map. This specifies how many lines will be drawn +before a new color is chosen. (When a small number of colors are available, +increasing this value will yield smoother transitions.) Default 3. +This has no effect in \fIballs\fP mode. +.TP 8 +.B \-radius +The size in pixels of the circle on which the points are initially positioned. +The default is slightly smaller than the size of the window. +.TP 8 +.B \-glow +This is consulted only in \fIballs\fP mode. If this is specified, then +the saturation of the colors of the points will vary according to their +current acceleration. This has the effect that the balls flare brighter +when they are reacting to each other most strongly. + +In \fIglow\fP mode, all of the balls will be drawn the same (random) +color, modulo the saturation shifts. In non-glow mode, the balls will +each be drawn in a random color that doesn't change. +.TP 8 +.B \-noglow +Don't do ``glowing.'' This is the default. +.TP 8 +.B \-vx pixels +.TP 8 +.B \-vy pixels +Initial velocity of the balls. This has no effect in \fB\-orbit\fP mode. +.TP 8 +.B \-orbit +Make the initial force on each ball be tangential to the circle on which +they are initially placed, with the right velocity to hold them in orbit +about each other. After a while, roundoff errors will cause the orbit +to decay. +.TP 8 +.B \-vmult float +In orbit mode, the initial velocity of the balls is multiplied by this; +a number less than 1 will make the balls pull closer together, and a larger +number will make them move apart. The default is 0.9, meaning a slight +inward pull. +.TP 8 +.B \-viscosity float +This sets the viscosity of the hypothetical fluid through which the control +points move; the default is 1, meaning no resistance. Values higher than 1 +aren't interesting; lower values cause less motion. + +One interesting thing to try is +.EX +attraction -viscosity 0.8 -points 75 \\ + -mouse -geometry =500x500 +.EE +Give it a few seconds to settle down into a stable clump, and then move +the mouse through it to make "waves". +.TP 8 +.B \-mouse +This will cause the mouse to be considered a control point; it will not be +drawn, but it will influence the other points, so you can wave the mouse +and influence the images being created. +.TP 8 +.B \-no-mouse +Turns off \fB\-mouse\fP. +.TP 8 +.B \-mouse-size integer +In \fB\-mouse\fP mode, this sets the mass of the mouse (analagously to the +\fB\-size\fP parameter.) +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1992, 1993, 1997 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. + +Viscosity and mouse support by Philip Edward Cutone, III. diff --git a/hacks/blitspin.c b/hacks/blitspin.c new file mode 100644 index 00000000..5b66f7d6 --- /dev/null +++ b/hacks/blitspin.c @@ -0,0 +1,365 @@ +/* xscreensaver, Copyright (c) 1992-1997 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. + */ + +/* Rotate a bitmap using using bitblts. + The bitmap must be square, and must be a power of 2 in size. + This was translated from SmallTalk code which appeared in the + August 1981 issue of Byte magazine. + + The input bitmap may be non-square, it is padded and centered + with the background color. Another way would be to subdivide + the bitmap into square components and rotate them independently + (and preferably in parallel), but I don't think that would be as + interesting looking. + + It's too bad almost nothing uses blitter hardware these days, + or this might actually win. + */ + +#include "screenhack.h" +#include + +#ifdef HAVE_XPM +# include +# ifndef PIXEL_ALREADY_TYPEDEFED +# define PIXEL_ALREADY_TYPEDEFED /* Sigh, Xmu/Drawing.h needs this... */ +# endif +#endif + +#ifdef HAVE_XMU +# ifndef VMS +# include +#else /* VMS */ +# include +# endif /* VMS */ +#endif + +#include "images/som.xbm" + +static Display *dpy; +static Window window; +static unsigned int size; +static Pixmap self, temp, mask; +static GC SET, CLR, CPY, IOR, AND, XOR; +static GC gc; +static int delay, delay2; +static Pixmap bitmap; +static int depth; +static unsigned int fg, bg; + +static void display (Pixmap); + +#define copy_all_to(from, xoff, yoff, to, gc) \ + XCopyArea (dpy, (from), (to), (gc), 0, 0, \ + size-(xoff), size-(yoff), (xoff), (yoff)) + +#define copy_all_from(to, xoff, yoff, from, gc) \ + XCopyArea (dpy, (from), (to), (gc), (xoff), (yoff), \ + size-(xoff), size-(yoff), 0, 0) + +static void +rotate (void) +{ + int qwad; /* fuckin' C, man... who needs namespaces? */ + XFillRectangle (dpy, mask, CLR, 0, 0, size, size); + XFillRectangle (dpy, mask, SET, 0, 0, size>>1, size>>1); + for (qwad = size>>1; qwad > 0; qwad>>=1) + { + if (delay) usleep (delay); + copy_all_to (mask, 0, 0, temp, CPY); /* 1 */ + copy_all_to (mask, 0, qwad, temp, IOR); /* 2 */ + copy_all_to (self, 0, 0, temp, AND); /* 3 */ + copy_all_to (temp, 0, 0, self, XOR); /* 4 */ + copy_all_from (temp, qwad, 0, self, XOR); /* 5 */ + copy_all_from (self, qwad, 0, self, IOR); /* 6 */ + copy_all_to (temp, qwad, 0, self, XOR); /* 7 */ + copy_all_to (self, 0, 0, temp, CPY); /* 8 */ + copy_all_from (temp, qwad, qwad, self, XOR); /* 9 */ + copy_all_to (mask, 0, 0, temp, AND); /* A */ + copy_all_to (temp, 0, 0, self, XOR); /* B */ + copy_all_to (temp, qwad, qwad, self, XOR); /* C */ + copy_all_from (mask, qwad>>1, qwad>>1, mask, AND); /* D */ + copy_all_to (mask, qwad, 0, mask, IOR); /* E */ + copy_all_to (mask, 0, qwad, mask, IOR); /* F */ + display (self); + } +} + +static void +read_bitmap (char *bitmap_name, int *widthP, int *heightP) +{ +#ifdef HAVE_XPM + XWindowAttributes xgwa; + XpmAttributes xpmattrs; + int result; + xpmattrs.valuemask = 0; + bitmap = 0; + + XGetWindowAttributes (dpy, window, &xgwa); + +# ifdef XpmCloseness + xpmattrs.valuemask |= XpmCloseness; + xpmattrs.closeness = 40000; +# endif +# ifdef XpmVisual + xpmattrs.valuemask |= XpmVisual; + xpmattrs.visual = xgwa.visual; +# endif +# ifdef XpmDepth + xpmattrs.valuemask |= XpmDepth; + xpmattrs.depth = xgwa.depth; +# endif +# ifdef XpmColormap + xpmattrs.valuemask |= XpmColormap; + xpmattrs.colormap = xgwa.colormap; +# endif + + result = XpmReadFileToPixmap (dpy, window, bitmap_name, &bitmap, 0, + &xpmattrs); + switch (result) + { + case XpmColorError: + fprintf (stderr, "%s: warning: xpm color substitution performed\n", + progname); + /* fall through */ + case XpmSuccess: + *widthP = xpmattrs.width; + *heightP = xpmattrs.height; + break; + case XpmFileInvalid: + case XpmOpenFailed: + bitmap = 0; + break; + case XpmColorFailed: + fprintf (stderr, "%s: xpm: color allocation failed\n", progname); + exit (-1); + case XpmNoMemory: + fprintf (stderr, "%s: xpm: out of memory\n", progname); + exit (-1); + default: + fprintf (stderr, "%s: xpm: unknown error code %d\n", progname, result); + exit (-1); + } + if (! bitmap) +#endif + +#ifdef HAVE_XMU + { + int xh, yh; + Pixmap b2; + bitmap = XmuLocateBitmapFile (DefaultScreenOfDisplay (dpy), bitmap_name, + 0, 0, widthP, heightP, &xh, &yh); + if (! bitmap) + { + fprintf (stderr, "%s: couldn't find bitmap %s\n", progname, + bitmap_name); + exit (1); + } + b2 = XmuCreatePixmapFromBitmap (dpy, window, bitmap, *widthP, *heightP, + depth, fg, bg); + XFreePixmap (dpy, bitmap); + bitmap = b2; + } +#else /* !XMU */ + { + fprintf (stderr, + "%s: your vendor doesn't ship the standard Xmu library.\n", + progname); + fprintf (stderr, "\tWe can't load XBM files without it.\n"); + exit (1); + } +#endif /* !XMU */ +} + + +static Pixmap +read_screen (Display *dpy, Window window, int *widthP, int *heightP) +{ + Pixmap p; + XWindowAttributes xgwa; + XGCValues gcv; + GC gc; + XGetWindowAttributes (dpy, window, &xgwa); + *widthP = xgwa.width; + *heightP = xgwa.height; + + grab_screen_image(xgwa.screen, window); + p = XCreatePixmap(dpy, window, *widthP, *heightP, xgwa.depth); + gcv.function = GXcopy; + gc = XCreateGC (dpy, window, GCFunction, &gcv); + XCopyArea (dpy, window, p, gc, 0, 0, *widthP, *heightP, 0, 0); + + /* Reset the window's background color... */ + XSetWindowBackground (dpy, window, + get_pixel_resource ("background", "Background", + dpy, xgwa.colormap)); + XCopyArea (dpy, p, window, gc, 0, 0, *widthP, *heightP, 0, 0); + XFreeGC (dpy, gc); + + return p; +} + + +static int +to_pow2(int n, Bool up) +{ + /* sizeof(Dimension) == 2. */ + int powers_of_2[] = { 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, + 2048, 4096, 8192, 16384, 32768, 65536 }; + int i = 0; + if (n > 65536) size = 65536; + while (n >= powers_of_2[i]) i++; + if (n == powers_of_2[i-1]) + return n; + else + return powers_of_2[up ? i : i-1]; +} + +static void +init (void) +{ + XWindowAttributes xgwa; + Colormap cmap; + XGCValues gcv; + int width, height; + char *bitmap_name; + Bool scale_up; + + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + depth = xgwa.depth; + + fg = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + bg = get_pixel_resource ("background", "Background", dpy, cmap); + delay = get_integer_resource ("delay", "Integer"); + delay2 = get_integer_resource ("delay2", "Integer"); + if (delay < 0) delay = 0; + if (delay2 < 0) delay2 = 0; + bitmap_name = get_string_resource ("bitmap", "Bitmap"); + if (! bitmap_name || !*bitmap_name) + bitmap_name = "(default)"; + + if (!strcmp (bitmap_name, "(default)")) + { + width = som_width; + height = som_height; + bitmap = XCreatePixmapFromBitmapData (dpy, window, (char *) som_bits, + width, height, fg, bg, depth); + scale_up = True; /* definitely. */ + } + else if (!strcmp (bitmap_name, "(screen)")) + { + bitmap = read_screen (dpy, window, &width, &height); + scale_up = True; /* maybe? */ + } + else + { + read_bitmap (bitmap_name, &width, &height); + scale_up = True; /* probably? */ + } + + size = (width < height) ? height : width; /* make it square */ + size = to_pow2(size, scale_up); /* round up to power of 2 */ + { /* don't exceed screen size */ + int s = XScreenNumberOfScreen(xgwa.screen); + int w = to_pow2(XDisplayWidth(dpy, s), False); + int h = to_pow2(XDisplayHeight(dpy, s), False); + if (size > w) size = w; + if (size > h) size = h; + } + + self = XCreatePixmap (dpy, window, size, size, depth); + temp = XCreatePixmap (dpy, window, size, size, depth); + mask = XCreatePixmap (dpy, window, size, size, depth); + gcv.foreground = (depth == 1 ? 1 : (~0)); + gcv.function=GXset; SET = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + gcv.function=GXclear;CLR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + gcv.function=GXcopy; CPY = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + gcv.function=GXor; IOR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + gcv.function=GXand; AND = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + gcv.function=GXxor; XOR = XCreateGC(dpy,self,GCFunction|GCForeground,&gcv); + + gcv.foreground = gcv.background = bg; + gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + /* Clear self to the background color (not to 0, which CLR does.) */ + XFillRectangle (dpy, self, gc, 0, 0, size, size); + XSetForeground (dpy, gc, fg); + + XCopyArea (dpy, bitmap, self, CPY, 0, 0, width, height, + (size - width)>>1, (size - height)>>1); + XFreePixmap(dpy, bitmap); + + display (self); + XSync(dpy, False); +} + +static void +display (Pixmap pixmap) +{ + XWindowAttributes xgwa; + static int last_w = 0, last_h = 0; + XGetWindowAttributes (dpy, window, &xgwa); + if (xgwa.width != last_w || xgwa.height != last_h) + { + XClearWindow (dpy, window); + last_w = xgwa.width; + last_h = xgwa.height; + } +#ifdef HAVE_XPM + if (depth != 1) + XCopyArea (dpy, pixmap, window, gc, 0, 0, size, size, + (xgwa.width-size)>>1, (xgwa.height-size)>>1); + else +#endif + XCopyPlane (dpy, pixmap, window, gc, 0, 0, size, size, + (xgwa.width-size)>>1, (xgwa.height-size)>>1, 1); +/* + XDrawRectangle (dpy, window, gc, + ((xgwa.width-size)>>1)-1, ((xgwa.height-size)>>1)-1, + size+2, size+2); +*/ + XSync (dpy, True); +} + + +char *progclass = "BlitSpin"; + +char *defaults [] = { + "BlitSpin.background: black", /* to placate SGI */ + "BlitSpin.foreground: white", + "*delay: 500000", + "*delay2: 500000", + "*bitmap: (default)", + "*geometry: 512x512", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { "-bitmap", ".bitmap", XrmoptionSepArg, 0 }, + { "-grab-screen", ".bitmap", XrmoptionNoArg, "(screen)" }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *d, Window w) +{ + dpy = d; + window = w; + init (); + if (delay2) usleep (delay2 * 2); + while (1) + { + rotate (); + if (delay2) usleep (delay2); + } +} diff --git a/hacks/blitspin.man b/hacks/blitspin.man new file mode 100644 index 00000000..9d8dc08e --- /dev/null +++ b/hacks/blitspin.man @@ -0,0 +1,106 @@ +.TH XScreenSaver 1 "24-Nov-97" "X Version 11" +.SH NAME +blitspin - rotate a bitmap in an interesting way +.SH SYNOPSIS +.B blitspin +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-bitmap \fIfilename\fP] [\-delay \fIusecs\fP] [\-delay2 \fIusecs\fP] +.SH DESCRIPTION +The \fIblitspin\fP program repeatedly rotates a bitmap by 90 degrees by +using logical operations: the bitmap is divided into quadrants, and the +quadrants are shifted clockwise. Then the same thing is done again with +progressively smaller quadrants, except that all sub-quadrants of a +given size are rotated in parallel. So this takes \fBO(16*log2(N))\fP +blits of size NxN, with the limitation that the image must be square, +and the size must be a power of 2. +.SH OPTIONS +.I blitspin +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-bitmap \fIfilename\fP +The file name of a bitmap to rotate. It need not be square: it +will be padded with the background color. If unspecified or the +string \fI(default)\fP, a builtin bitmap is used. + +If support for the \fIXPM\fP library was enabled at compile-time, +the specified file may be in \fIXPM\fP format as well as \fIXBM\fP, and +thus may be a color image. + +The \fB*bitmapFilePath\fP resource will be searched if the bitmap +name is not a fully-qualified pathname. +.TP 8 +.B \-grab\-screen +If this option is specified, then the image which is spun will be grabbed +from the portion of the screen underlying the blitspin window. (Or, it +may come from an external video source: see below.) +.PP +.TP 8 +.B \-delay \fImicroseconds\fP +How long to delay between steps of the rotation process, in microseconds. +Default is 500000, one-half second. +.PP +.TP 8 +.B \-delay2 \fImicroseconds\fP +How long to delay between each 90-degree rotation, in microseconds. +Default is 500000, one-half second. +.B DISPLAY +to get the default host and display number. +.SH RESOURCES +On some systems (currently, only SGIs), this program can, instead of grabbing +a desktop image, grab a frame of video from an external camera and manipulate +that instead. The following resources control that. +.PP +.TP 8 +.B grabVideoProbability \fR(Float)\fP +What portion of the time to grab video rather than a screen image, +between 0.0 and 1.0. Defaults to 0.5, or half the time. +.TP 8 +.B videoDevice \fR(Integer)\fP +The number of the default video input device to check first. If unspecified, +the default camera (from videopanel(1)) will be checked first. After that, all +other available video input devices will be checked in order. + +The first one which produces a non-black image will be used. If all images +are black, the others will be re-checked a few times before giving up and +falling back to simply grabbing a desktop image (but note that this takes a +few seconds, so if you don't actually have any video sources hooked up, you +should consider turning off video grabbing by setting +\fBgrabVideoProbability\fP to 0.0.) +.TP 8 +.B videoGain \fR(Float)\fP +The amount by which to brighten the grabbed image. This defaults to 2.2. +.SH ENVIRONMENT +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1992, 1993, 1997 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. +.SH AUTHOR +Jamie Zawinski , 17-aug-92. + +Based on SmallTalk code which appeared in the August 1981 issue of Byte +magazine. diff --git a/hacks/bouboule.c b/hacks/bouboule.c new file mode 100644 index 00000000..4f6e8ecb --- /dev/null +++ b/hacks/bouboule.c @@ -0,0 +1,841 @@ +/* -*- Mode: C; tab-width: 4 -*- + Ported from xlockmore 4.03a12 to be a standalone program and thus usable + with xscreensaver by Jamie Zawinski on 15-May-97. + + Original copyright notice from xlock.c: + + * 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. + */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)bouboule.c 4.00 97/01/01 xlockmore"; + +#endif + +/*- + * bouboule.c (bouboule mode for xlockmore) + * + * Sort of starfield for xlockmore. I found that making a starfield for + * a 3D engine and thought it could be a nice lock mode. 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. + * + * Code Copyright 1996 by Jeremie PETIT (petit@eurecom.fr, jpetit@essi.fr) + * + * Use: batchcount is the number of stars. + * cycles is the maximum size for a star + * + * 15-May-97: jwz@netscape.com: 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 + * 01-Feb-96: Patched by Jouk Jansen for VMS + * Patched by for TrueColor displays + * 30-Jan-96: Wrote all that I wanted to. + * + * 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 "*count: 100 \n" \ + "*size: 15 \n" \ + "*delay: 5000 \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" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt bouboule_opts = { + 0, NULL, 0, NULL, NULL }; + +#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 +# endif +#endif + +#include + +#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 +/* jwz: I think slower color changes look better */ +#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_WIN_WIDTH(mi); + sp->height = MI_WIN_HEIGHT(mi); + + /* use the right `black' pixel values: */ + if (MI_WIN_IS_INSTALL(mi) && MI_WIN_IS_USE3D(mi)) { + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_NONE_COLOR(mi)); + XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + 0, 0, sp->width, sp->height); + } else + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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_BATCHCOUNT(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_WIN_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_WIN_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_WIN_IS_USE3D(mi)) + arcleft = &(sp->xarcleft[i]); +#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1)) + oarc = &(sp->oldxarc[i]); + if (MI_WIN_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 */ + arc->x = arc->y = 0; + if (MI_WIN_IS_USE3D(mi)) { + arcleft->x = arcleft->y = 0; + } +#if ((USEOLDXARCS == 1) || (ADAPT_ERASE == 1)) + oarc->x = oarc->y = 0; + if (MI_WIN_IS_USE3D(mi)) { + oarcleft->x = oarcleft->y = 0; + } +#endif + arc->width = 2 + star->size; + arc->height = 2 + star->size; + if (MI_WIN_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_WIN_IS_USE3D(mi)) { + oarcleft->width = 2 + star->size; + oarcleft->height = 2 + star->size; + } +#endif + + arc->angle1 = 0; + arc->angle2 = 360 * 64; + if (MI_WIN_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_WIN_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_WIN_IS_USE3D(mi) && MI_NPIXELS(mi) > 2) + sp->color = MI_PIXEL(mi, sp->colorp); + else + sp->color = MI_WIN_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 + +#if ((USEOLDXARCS == 0) || (ADAPT_ERASE == 1)) + if (MI_WIN_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_WIN_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_WIN_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_WIN_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_WIN_IS_USE3D(mi)) { + arcleft->x -= star->size; + arcleft->y -= star->size; + } + } + } + + /* First, we erase the previous starfield */ + if (MI_WIN_IS_INSTALL(mi) && MI_WIN_IS_USE3D(mi)) + XSetForeground(display, gc, MI_NONE_COLOR(mi)); + else + XSetForeground(display, gc, MI_WIN_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_WIN_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_WIN_IS_USE3D(mi)) + XFillArcs(display, window, gc, + sp->oldxarcleft, sp->NbStars); + } else { + long usec; + + if (sp->hasbeenchecked > ADAPT_CHECKS) { +#ifdef GETTIMEOFDAY_TWO_ARGS + (void) gettimeofday(&tv1, NULL); +#else + (void) gettimeofday(&tv1); +#endif + XFillRectangle(display, window, gc, + x_1, y_1, x_2, y_2); +#ifdef GETTIMEOFDAY_TWO_ARGS + (void) gettimeofday(&tv2, NULL); +#else + (void) gettimeofday(&tv2); +#endif + 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 { +#ifdef GETTIMEOFDAY_TWO_ARGS + (void) gettimeofday(&tv1, NULL); +#else + (void) gettimeofday(&tv1); +#endif + XFillArcs(display, window, gc, + sp->oldxarc, sp->NbStars); + if (MI_WIN_IS_USE3D(mi)) + XFillArcs(display, window, gc, + sp->oldxarcleft, sp->NbStars); +#ifdef GETTIMEOFDAY_TWO_ARGS + (void) gettimeofday(&tv2, NULL); +#else + (void) gettimeofday(&tv2); +#endif + 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_WIN_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_WIN_IS_USE3D(mi)) { + if (MI_WIN_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_WIN_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_WIN_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_WIN_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_WIN_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) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/bouboule.man b/hacks/bouboule.man new file mode 100644 index 00000000..cdffed43 --- /dev/null +++ b/hacks/bouboule.man @@ -0,0 +1,76 @@ +.TH XScreenSaver 1 "15-May-97" "X Version 11" +.SH NAME +bouboule - draws spinning 3D blobs +.SH SYNOPSIS +.B bouboule +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] [\-3d] + +.SH DESCRIPTION +The \fIbouboule\fP program draws spinning 3D blobs. +.SH OPTIONS +.I bouboule +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-3d +Do red/blue 3d separations (for 3d glasses.) + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1996 by Jeremie Petit. + +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. + +.SH AUTHOR +Jeremie Petit , 1996. + +3D support by Henrik Theiling , 04-Sep-96. + +VMS support by Jouk Jansen , 01-Feb-96. + +TrueColor support by David Bagley , 01-Feb-96. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 15-May-97. diff --git a/hacks/braid.c b/hacks/braid.c new file mode 100644 index 00000000..4bbd93a6 --- /dev/null +++ b/hacks/braid.c @@ -0,0 +1,434 @@ +/* -*- Mode: C; tab-width: 4 -*- + * braid --- draws random color-cyling rotating braids around a circle. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)braid.c 4.00 97/01/01 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: jwz@netscape.com: turned into a standalone program. + * 01-Sep-95: color knotted components differently, J. Neil. + * 29-Aug-95: Written. John Neil + */ + +#ifdef STANDALONE +# define PROGCLASS "Braid" +# define HACK_INIT init_braid +# define HACK_DRAW draw_braid +# define braid_opts xlockmore_opts +# define DEFAULTS "*count: 15 \n" \ + "*size: -7 \n" \ + "*cycles: 100 \n" \ + "*delay: 1000 \n" \ + "*ncolors: 64 \n" +# define UNIFORM_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include "erase.h" +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt braid_opts = { + 0, NULL, 0, NULL, NULL }; + + +#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 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) +{ + Display *display = MI_DISPLAY(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_WIN_WIDTH(mi) / 2; + braid->center_y = MI_WIN_HEIGHT(mi) / 2; + braid->age = 0; + + /* jwz: go in the other direction sometimes. */ + braid->color_direction = ((LRAND() & 1) ? 1 : -1); + XClearWindow(display, MI_WINDOW(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_BATCHCOUNT(mi) < MINSTRANDS) + braid->nstrands = MINSTRANDS; + else + braid->nstrands = INTRAND(MINSTRANDS, + MAX(MIN(MIN(MAXSTRANDS, MI_BATCHCOUNT(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); + + { + int line_width = MI_SIZE(mi); + if (line_width == 0) + line_width = -8; + if (line_width < 0) + line_width = NRAND(-line_width)+1; + if (line_width == 1) + line_width = 0; + XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), line_width, + LineSolid, + (line_width <= 3 ? CapButt : CapRound), + JoinMiter); + } + + + 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)]; + float num_points, 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; + + num_points = 500.0; + theta = (2.0 * M_PI) / (float) (braid->braidlength); + t_inc = (2.0 * M_PI) / num_points; + color_inc = (float) MI_NPIXELS(mi) / num_points; + color_inc *= braid->color_direction; + + braid->startcolor += SPINRATE * color_inc; + if (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 (color >= (float) (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 (color_use >= (float) MI_NPIXELS(mi)) + color_use -= (float) MI_NPIXELS(mi); + while (color_use < 0.0) + color_use += (float) MI_NPIXELS(mi); + } +#endif +#ifdef COLORROUND + if (MI_NPIXELS(mi) > 2) { + color_use += SPINRATE * color_inc; + while (color_use >= (float) (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_WIN_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 (color_use >= (float) MI_NPIXELS(mi)) + color_use -= (float) MI_NPIXELS(mi); + while (color_use < 0.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_WIN_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 (color_use >= (float) MI_NPIXELS(mi)) + color_use -= (float) MI_NPIXELS(mi); + while (color_use < 0.0) + color_use += (float) MI_NPIXELS(mi); + } +#endif +#ifdef COLORROUND + if (MI_NPIXELS(mi) > 2) { + color_use += SPINRATE * color_inc; + while (color_use >= (float) 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_WIN_WHITE_PIXEL(mi)); + + XDrawLine(display, window, MI_GC(mi), + (int) (x_1), (int) (y_1), (int) (x_2), (int) (y_2)); + } + } + } + } + + if (++braid->age > MI_CYCLES(mi)) { +#ifdef STANDALONE + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif + init_braid(mi); + } +} + +void +release_braid(ModeInfo * mi) +{ + if (braids != NULL) { + (void) free((void *) braids); + braids = NULL; + } +} + +void +refresh_braid(ModeInfo * mi) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/braid.man b/hacks/braid.man new file mode 100644 index 00000000..3310616d --- /dev/null +++ b/hacks/braid.man @@ -0,0 +1,65 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +braid - draws random color-cycling braids around a circle +.SH SYNOPSIS +.B braid +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIbraid\fP program draws random color-cycling braids around a circle. +.SH OPTIONS +.I braid +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +John Neil , 29-Aug-95. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/bubbles-default.c b/hacks/bubbles-default.c new file mode 100644 index 00000000..8f9058e6 --- /dev/null +++ b/hacks/bubbles-default.c @@ -0,0 +1,151 @@ +/* bubbles_default.c - pick images for bubbles.c + * By Jamie Zawinski , 20-Jan-98. + * + * 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include "bubbles.h" +#include "yarandom.h" + +#ifndef NO_DEFAULT_BUBBLE + +# define BLOOD 0 +# include "images/bubbles/blood1.xpm" +# include "images/bubbles/blood2.xpm" +# include "images/bubbles/blood3.xpm" +# include "images/bubbles/blood4.xpm" +# include "images/bubbles/blood5.xpm" +# include "images/bubbles/blood6.xpm" +# include "images/bubbles/blood7.xpm" +# include "images/bubbles/blood8.xpm" +# include "images/bubbles/blood9.xpm" +# include "images/bubbles/blood10.xpm" +# include "images/bubbles/blood11.xpm" + +# define BLUE 1 +# include "images/bubbles/blue1.xpm" +# include "images/bubbles/blue2.xpm" +# include "images/bubbles/blue3.xpm" +# include "images/bubbles/blue4.xpm" +# include "images/bubbles/blue5.xpm" +# include "images/bubbles/blue6.xpm" +# include "images/bubbles/blue7.xpm" +# include "images/bubbles/blue8.xpm" +# include "images/bubbles/blue9.xpm" +# include "images/bubbles/blue10.xpm" +# include "images/bubbles/blue11.xpm" + +# define GLASS 2 +# include "images/bubbles/glass1.xpm" +# include "images/bubbles/glass2.xpm" +# include "images/bubbles/glass3.xpm" +# include "images/bubbles/glass4.xpm" +# include "images/bubbles/glass5.xpm" +# include "images/bubbles/glass6.xpm" +# include "images/bubbles/glass7.xpm" +# include "images/bubbles/glass8.xpm" +# include "images/bubbles/glass9.xpm" +# include "images/bubbles/glass10.xpm" +# include "images/bubbles/glass11.xpm" + +# define JADE 3 +# include "images/bubbles/jade1.xpm" +# include "images/bubbles/jade2.xpm" +# include "images/bubbles/jade3.xpm" +# include "images/bubbles/jade4.xpm" +# include "images/bubbles/jade5.xpm" +# include "images/bubbles/jade6.xpm" +# include "images/bubbles/jade7.xpm" +# include "images/bubbles/jade8.xpm" +# include "images/bubbles/jade9.xpm" +# include "images/bubbles/jade10.xpm" +# include "images/bubbles/jade11.xpm" + +# define END 4 + + +char **default_bubbles[50]; +int num_default_bubbles; + +void init_default_bubbles(void) +{ + int i = 0; + switch (random() % END) { + case BLOOD: + default_bubbles[i++] = blood1; + default_bubbles[i++] = blood2; + default_bubbles[i++] = blood3; + default_bubbles[i++] = blood4; + default_bubbles[i++] = blood5; + default_bubbles[i++] = blood6; + default_bubbles[i++] = blood7; + default_bubbles[i++] = blood8; + default_bubbles[i++] = blood9; + default_bubbles[i++] = blood10; + default_bubbles[i++] = blood11; + break; + + case BLUE: + default_bubbles[i++] = blue1; + default_bubbles[i++] = blue2; + default_bubbles[i++] = blue3; + default_bubbles[i++] = blue4; + default_bubbles[i++] = blue5; + default_bubbles[i++] = blue6; + default_bubbles[i++] = blue7; + default_bubbles[i++] = blue8; + default_bubbles[i++] = blue9; + default_bubbles[i++] = blue10; + default_bubbles[i++] = blue11; + break; + + case GLASS: + default_bubbles[i++] = glass1; + default_bubbles[i++] = glass2; + default_bubbles[i++] = glass3; + default_bubbles[i++] = glass4; + default_bubbles[i++] = glass5; + default_bubbles[i++] = glass6; + default_bubbles[i++] = glass7; + default_bubbles[i++] = glass8; + default_bubbles[i++] = glass9; + default_bubbles[i++] = glass10; + default_bubbles[i++] = glass11; + break; + + case JADE: + default_bubbles[i++] = jade1; + default_bubbles[i++] = jade2; + default_bubbles[i++] = jade3; + default_bubbles[i++] = jade4; + default_bubbles[i++] = jade5; + default_bubbles[i++] = jade6; + default_bubbles[i++] = jade7; + default_bubbles[i++] = jade8; + default_bubbles[i++] = jade9; + default_bubbles[i++] = jade10; + default_bubbles[i++] = jade11; + break; + + default: + abort(); + break; + } + + default_bubbles[i] = 0; + num_default_bubbles = i; +} + +#endif /* NO_DEFAULT_BUBBLE */ diff --git a/hacks/bubbles.c b/hacks/bubbles.c new file mode 100644 index 00000000..99e64b10 --- /dev/null +++ b/hacks/bubbles.c @@ -0,0 +1,1321 @@ +/* bubbles.c - frying pan / soft drink in a glass simulation */ + +/*$Id: bubbles.c,v 1.13 1998/02/21 21:55:14 jwz Exp $*/ + +/* + * Copyright (C) 1995-1996 James Macnicol + * + * 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. + */ + +/* + * I got my original inspiration for this by looking at the bottom of a + * frying pan while something was cooking and watching the little bubbles + * coming off the bottom of the pan as the oil was boiling joining together + * to form bigger bubbles and finally to *pop* and disappear. I had some + * time on my hands so I wrote this little xscreensaver module to imitate + * it. Now that it's done it reminds me more of the bubbles you get in + * a glass of fizzy soft drink..... + * + * The problem seemed to be that the position/size etc. of all the bubbles + * on the screen had to be remembered and searched through to find when + * bubbles hit each other and combined. To do this more efficiently, the + * window/screen is divided up into a square mesh of side length mesh_length + * and separate lists of bubbles contained in each cell of the mesh are + * kept. Only the cells in the immediate vicinity of the bubble in question + * are searched. This should make things more efficient although the whole + * thing seems to use up too much CPU, but then I'm using an ancient PC so + * perhaps it's not surprising . + * (Six months after I wrote the above I now have a Pentium with PCI graphics + * and things are _much_ nicer.) + * + * Author: James Macnicol + * Internet E-mail : J.Macnicol@student.anu.edu.au + */ + +#include +#include "screenhack.h" +#include "bubbles.h" + +#include + +#include +#include + +#ifndef VMS +# include +#else /* VMS */ +# if __DECC_VER >= 50200000 +# include +# endif +#endif /* VMS */ + +#ifdef HAVE_UNISTD_H +# include +#endif +#include "yarandom.h" + +#ifdef HAVE_XPM +# include +#endif + +/* + * Public variables + */ + +extern void init_default_bubbles(void); +extern int num_default_bubbles; +extern char **default_bubbles[]; + +char *progclass = "Bubbles"; + +char *defaults [] = { + "Bubbles.background: black", + "*foreground: white", + "*simple: false", + "*broken: false", + "*delay: 800", + "*quiet: false", + "*nodelay: false", + "*3D: false", + 0 +}; + +XrmOptionDescRec options [] = { + { "-simple", ".simple", XrmoptionNoArg, "true" }, +#ifdef HAVE_XPM + { "-broken", ".broken", XrmoptionNoArg, "true" }, +#endif /* HAVE_XPM */ + { "-quiet", ".quiet", XrmoptionNoArg, "true" }, + { "-nodelay", ".nodelay", XrmoptionNoArg, "true" }, + { "-3D", ".3D", XrmoptionNoArg, "true" }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +/* + * Private variables + */ + +static Bubble **mesh; +static int mesh_length; +static int mesh_width; +static int mesh_height; +static int mesh_cells; + +static int **adjacent_list; + +static int screen_width; +static int screen_height; +static int screen_depth; +static unsigned int default_fg_pixel, default_bg_pixel; +/* + * I know it's not elegant to save this stuff in global variables + * but we need it for the signal handler. + */ +static Display *defdsp; +static Window defwin; +static Colormap defcmap; +static Visual *defvisual; + +/* For simple mode only */ +static int bubble_min_radius; +static int bubble_max_radius; +static long *bubble_areas; +static GC draw_gc, erase_gc; + +#ifdef HAVE_XPM +static int num_bubble_pixmaps; +static Bubble_Step **step_pixmaps; +#endif /* HAVE_XPM */ + +/* Options stuff */ +#ifdef HAVE_XPM +static Bool simple = False; +#else +static Bool simple = True; +#endif +static Bool broken = False; +static Bool quiet = False; +static Bool threed = False; +static int delay; + +/* + * To prevent forward references, some stuff is up here + */ + +static long +calc_bubble_area(int r) +/* Calculate the area of a bubble of radius r */ +{ +#ifdef DEBUG + printf("%d %g\n", r, + 10.0 * PI * (double)r * (double)r * (double)r); +#endif /* DEBUG */ + if (threed) + return (long)(10.0 * PI * (double)r * (double)r * (double)r); + else + return (long)(10.0 * PI * (double)r * (double)r); +} + +static void * +xmalloc(size_t size) +/* Safe malloc */ +{ + void *ret; + + if ((ret = malloc(size)) == NULL) { + fprintf(stderr, "%s: out of memory\n", progname); + exit(1); + } + return ret; +} + +#ifdef DEBUG +static void +die_bad_bubble(Bubble *bb) +/* This is for use with GDB */ +{ + fprintf(stderr, "Bad bubble detected at 0x%x!\n", (int)bb); + exit(1); +} +#endif + +static int +null_bubble(Bubble *bb) +/* Returns true if the pointer passed is NULL. If not then this checks to +see if the bubble is valid (i.e. the (x,y) position is valid and the magic +number is set correctly. This only a sanity check for debugging and is +turned off if DEBUG isn't set. */ +{ + if (bb == (Bubble *)NULL) + return 1; +#ifdef DEBUG + if ((bb->cell_index < 0) || (bb->cell_index > mesh_cells)) { + fprintf(stderr, "cell_index = %d\n", bb->cell_index); + die_bad_bubble(bb); + } + if (bb->magic != BUBBLE_MAGIC) { + fprintf(stderr, "Magic = %d\n", bb->magic); + die_bad_bubble(bb); + } + if (simple) { + if ((bb->x < 0) || (bb->x > screen_width) || + (bb->y < 0) || (bb->y > screen_height) || + (bb->radius < bubble_min_radius) || (bb->radius > + bubble_max_radius)) { + fprintf(stderr, + "radius = %d, x = %d, y = %d, magic = %d, cell index = %d\n", + bb->radius, bb->x, bb->y, bb->magic, bb->cell_index); + die_bad_bubble(bb); + } +#ifdef HAVE_XPM + } else { + if ((bb->x < 0) || (bb->x > screen_width) || + (bb->y < 0) || (bb->y > screen_height) || + (bb->radius < step_pixmaps[0]->radius) || + (bb->radius > step_pixmaps[num_bubble_pixmaps-1]->radius)) { + fprintf(stderr, + "radius = %d, x = %d, y = %d, magic = %d, cell index = %d\n", + bb->radius, bb->x, bb->y, bb->magic, bb->cell_index); + die_bad_bubble(bb); + } +#endif /* HAVE_XPM */ + } +#endif /* DEBUG */ + return 0; +} + +#ifdef DEBUG +static void +print_bubble_list(Bubble *bb) +/* Print list of where all the bubbles are. For debugging purposes only. */ +{ + if (! null_bubble(bb)) { + printf(" (%d, %d) %d\n", bb->x, bb->y, bb->radius); + print_bubble_list(bb->next); + } +} +#endif /* DEBUG */ + +static void +add_bubble_to_list(Bubble **list, Bubble *bb) +/* Take a pointer to a list of bubbles and stick bb at the head of the + list. */ +{ + Bubble *head = *list; + + if (null_bubble(head)) { + bb->prev = (Bubble *)NULL; + bb->next = (Bubble *)NULL; + } else { + bb->next = head; + bb->prev = (Bubble *)NULL; + head->prev = bb; + } + *list = bb; +} + + +/* + * Mesh stuff + */ + + +static void +init_mesh (void) +/* Setup the mesh of bubbles */ +{ + int i; + + mesh = (Bubble **)xmalloc(mesh_cells * sizeof(Bubble *)); + for (i = 0; i < mesh_cells; i++) + mesh[i] = (Bubble *)NULL; +} + +static int +cell_to_mesh(int x, int y) +/* convert cell coordinates to mesh index */ +{ +#ifdef DEBUG + if ((x < 0) || (y < 0)) { + fprintf(stderr, "cell_to_mesh: x = %d, y = %d\n", x, y); + exit(1); + } +#endif + return ((mesh_width * y) + x); +} + +static void +mesh_to_cell(int mi, int *cx, int *cy) +/* convert mesh index into cell coordinates */ +{ + *cx = mi % mesh_width; + *cy = mi / mesh_width; +} + +static int +pixel_to_mesh(int x, int y) +/* convert screen coordinates into mesh index */ +{ + return cell_to_mesh((x / mesh_length), (y / mesh_length)); +} + +static int +verify_mesh_index(int x, int y) +/* check to see if (x,y) is in the mesh */ +{ + if ((x < 0) || (y < 0) || (x >= mesh_width) || (y >= mesh_height)) + return (-1); + return (cell_to_mesh(x, y)); +} + +#ifdef DEBUG +static void +print_adjacents(int *adj) +/* Print a list of the cells calculated above. For debugging only. */ +{ + int i; + + printf("("); + for (i = 0; i < 8; i++) + printf("%d ", adj[i]); + printf(")\n"); +} +#endif /* DEBUG */ + +static void +add_to_mesh(Bubble *bb) +/* Add the given bubble to the mesh by sticking it on the front of the +list. bb is already allocated so no need to malloc() anything, just +adjust pointers. */ +{ +#ifdef DEBUG + if (null_bubble(bb)) { + fprintf(stderr, "Bad bubble passed to add_to_mesh()!\n"); + exit(1); + } +#endif /* DEBUG */ + + add_bubble_to_list(&mesh[bb->cell_index], bb); +} + +#ifdef DEBUG +static void +print_mesh (void) +/* Print the contents of the mesh */ +{ + int i; + + for (i = 0; i < mesh_cells; i++) { + if (! null_bubble(mesh[i])) { + printf("Mesh cell %d\n", i); + print_bubble_list(mesh[i]); + } + } +} + +static void +valid_mesh (void) +/* Check to see if the mesh is Okay. For debugging only. */ +{ + int i; + Bubble *b; + + for (i = 0; i < mesh_cells; i++) { + b = mesh[i]; + while (! null_bubble(b)) + b = b->next; + } +} + +static int +total_bubbles (void) +/* Count how many bubbles there are in total. For debugging only. */ +{ + int rv = 0; + int i; + Bubble *b; + + for (i = 0; i < mesh_cells; i++) { + b = mesh[i]; + while (! null_bubble(b)) { + rv++; + b = b->next; + } + } + + return rv; +} +#endif /* DEBUG */ + +static void +calculate_adjacent_list (void) +/* Calculate the list of cells adjacent to a particular cell for use + later. */ +{ + int i; + int ix, iy; + + adjacent_list = (int **)xmalloc(mesh_cells * sizeof(int *)); + for (i = 0; i < mesh_cells; i++) { + adjacent_list[i] = (int *)xmalloc(9 * sizeof(int)); + mesh_to_cell(i, &ix, &iy); + adjacent_list[i][0] = verify_mesh_index(--ix, --iy); + adjacent_list[i][1] = verify_mesh_index(++ix, iy); + adjacent_list[i][2] = verify_mesh_index(++ix, iy); + adjacent_list[i][3] = verify_mesh_index(ix, ++iy); + adjacent_list[i][4] = verify_mesh_index(ix, ++iy); + adjacent_list[i][5] = verify_mesh_index(--ix, iy); + adjacent_list[i][6] = verify_mesh_index(--ix, iy); + adjacent_list[i][7] = verify_mesh_index(ix, --iy); + adjacent_list[i][8] = i; + } +} + +static void +adjust_areas (void) +/* Adjust areas of bubbles so we don't get overflow in weighted_mean() */ +{ + double maxvalue; + long maxarea; + long factor; + int i; + +#ifdef HAVE_XPM + if (simple) + maxarea = bubble_areas[bubble_max_radius+1]; + else + maxarea = step_pixmaps[num_bubble_pixmaps]->area; +#else + maxarea = bubble_areas[bubble_max_radius+1]; +#endif /* HAVE_XPM */ + maxvalue = (double)screen_width * 2.0 * (double)maxarea; + factor = (long)ceil(maxvalue / (double)LONG_MAX); + if (factor > 1) { + /* Overflow will occur in weighted_mean(). We must divide areas + each by factor so it will never do so. */ +#ifdef HAVE_XPM + if (simple) { + for (i = bubble_min_radius; i <= bubble_max_radius+1; i++) { + bubble_areas[i] /= factor; + if (bubble_areas[i] == 0) + bubble_areas[i] = 1; + } + } else { + for (i = 0; i <= num_bubble_pixmaps; i++) { +#ifdef DEBUG + printf("area = %ld", step_pixmaps[i]->area); +#endif /* DEBUG */ + step_pixmaps[i]->area /= factor; + if (step_pixmaps[i]->area == 0) + step_pixmaps[i]->area = 1; +#ifdef DEBUG + printf("-> %ld\n", step_pixmaps[i]->area); +#endif /* DEBUG */ + } + } +#else + for (i = bubble_min_radius; i <= bubble_max_radius+1; i++) { + bubble_areas[i] /= factor; + if (bubble_areas[i] == 0) + bubble_areas[i] = 1; + } +#endif /* HAVE_XPM */ + } +#ifdef DEBUG + printf("maxarea = %ld\n", maxarea); + printf("maxvalue = %g\n", maxvalue); + printf("LONG_MAX = %ld\n", LONG_MAX); + printf("factor = %ld\n", factor); +#endif /* DEBUG */ +} + +/* + * Bubbles stuff + */ + +static Bubble * +new_bubble (void) +/* Add a new bubble at some random position on the screen of the smallest +size. */ +{ + Bubble *rv = (Bubble *)xmalloc(sizeof(Bubble)); + + /* Can't use null_bubble() here since magic number hasn't been set */ + if (rv == (Bubble *)NULL) { + fprintf(stderr, "Ran out of memory!\n"); + exit(1); + } + + if (simple) { + rv->radius = bubble_min_radius; + rv->area = bubble_areas[bubble_min_radius]; +#ifdef HAVE_XPM + } else { + rv->step = 0; + rv->radius = step_pixmaps[0]->radius; + rv->area = step_pixmaps[0]->area; +#endif /* HAVE_XPM */ + } + rv->visible = 0; + rv->magic = BUBBLE_MAGIC; + rv->x = ya_random() % screen_width; + rv->y = ya_random() % screen_height; + rv->cell_index = pixel_to_mesh(rv->x, rv->y); + + return rv; +} + +static void +show_bubble(Bubble *bb) +/* paint the bubble on the screen */ +{ + if (null_bubble(bb)) { + fprintf(stderr, "NULL bubble passed to show_bubble\n"); + exit(1); + } + + if (! bb->visible) { + bb->visible = 1; + + if (simple) { + XDrawArc(defdsp, defwin, draw_gc, (bb->x - bb->radius), + (bb->y - bb->radius), bb->radius*2, bb->radius*2, 0, + 360*64); + } else { +#ifdef HAVE_XPM + XSetClipOrigin(defdsp, step_pixmaps[bb->step]->draw_gc, + (bb->x - bb->radius), + (bb->y - bb->radius)); + + XCopyArea(defdsp, step_pixmaps[bb->step]->ball, defwin, + step_pixmaps[bb->step]->draw_gc, + 0, 0, (bb->radius * 2), + (bb->radius * 2), + (bb->x - bb->radius), + (bb->y - bb->radius)); +#endif /* HAVE_XPM */ + } + } +} + +static void +hide_bubble(Bubble *bb) +/* erase the bubble */ +{ + if (null_bubble(bb)) { + fprintf(stderr, "NULL bubble passed to hide_bubble\n"); + exit(1); + } + + if (bb->visible) { + bb->visible = 0; + + if (simple) { + XDrawArc(defdsp, defwin, erase_gc, (bb->x - bb->radius), + (bb->y - bb->radius), bb->radius*2, bb->radius*2, 0, + 360*64); + } else { +#ifdef HAVE_XPM + if (! broken) { + XSetClipOrigin(defdsp, step_pixmaps[bb->step]->erase_gc, + (bb->x - bb->radius), (bb->y - bb->radius)); + + XFillRectangle(defdsp, defwin, step_pixmaps[bb->step]->erase_gc, + (bb->x - bb->radius), + (bb->y - bb->radius), + (bb->radius * 2), + (bb->radius * 2)); + } +#endif /* HAVE_XPM */ + } + } +} + +static void +delete_bubble_in_mesh(Bubble *bb, int keep_bubble) +/* Delete an individual bubble, adjusting list of bubbles around it. + If keep_bubble is true then the bubble isn't actually deleted. We + use this to allow bubbles to change mesh cells without reallocating, + (it needs this when two bubbles collide and the centre position is + recalculated, and this may stray over a mesh boundary). */ +{ + if ((!null_bubble(bb->prev)) && (!null_bubble(bb->next))) { + bb->prev->next = bb->next; + bb->next->prev = bb->prev; + } else if ((!null_bubble(bb->prev)) && + (null_bubble(bb->next))) { + bb->prev->next = (Bubble *)NULL; + bb->next = mesh[bb->cell_index]; + } else if ((null_bubble(bb->prev)) && + (!null_bubble(bb->next))) { + bb->next->prev = (Bubble *)NULL; + mesh[bb->cell_index] = bb->next; + bb->next = mesh[bb->cell_index]; + } else { + /* Only item on list */ + mesh[bb->cell_index] = (Bubble *)NULL; + } + if (! keep_bubble) + free(bb); +} + +static unsigned long +ulongsqrint(int x) +/* Saves ugly inline code */ +{ + return ((unsigned long)x * (unsigned long)x); +} + +static Bubble * +get_closest_bubble(Bubble *bb) +/* Find the closest bubble touching the this bubble, NULL if none are + touching. */ +{ + Bubble *rv = (Bubble *)NULL; + Bubble *tmp; + unsigned long separation2, touchdist2; + int dx, dy; + unsigned long closest2 = ULONG_MAX; + int i; + +#ifdef DEBUG + if (null_bubble(bb)) { + fprintf(stderr, "NULL pointer 0x%x passed to get_closest_bubble()!", + (int)bb); + exit(1); + } +#endif /* DEBUG */ + + for (i = 0; i < 9; i++) { + /* There is a bug here where bb->cell_index is negaitve.. */ +#ifdef DEBUG + if ((bb->cell_index < 0) || (bb->cell_index >= mesh_cells)) { + fprintf(stderr, "bb->cell_index = %d\n", bb->cell_index); + exit(1); + } +#endif /* DEBUG */ +/* printf("%d,", bb->cell_index); */ + if (adjacent_list[bb->cell_index][i] != -1) { + tmp = mesh[adjacent_list[bb->cell_index][i]]; + while (! null_bubble(tmp)) { + if (tmp != bb) { + dx = tmp->x - bb->x; + dy = tmp->y - bb->y; + separation2 = ulongsqrint(dx) + ulongsqrint(dy); + /* Add extra leeway so circles _never_ overlap */ + touchdist2 = ulongsqrint(tmp->radius + bb->radius + 2); + if ((separation2 <= touchdist2) && (separation2 < + closest2)) { + rv = tmp; + closest2 = separation2; + } + } + tmp = tmp->next; + } + } + } + + return rv; +} + +#ifdef DEBUG +static void +ldr_barf (void) +{ +} +#endif /* DEBUG */ + +static long +long_div_round(long num, long dem) +{ + long divvie, moddo; + +#ifdef DEBUG + if ((num < 0) || (dem < 0)) { + fprintf(stderr, "long_div_round: %ld, %ld\n", num, dem); + ldr_barf(); + exit(1); + } +#endif /* DEBUG */ + + divvie = num / dem; + moddo = num % dem; + if (moddo > (dem / 2)) + ++divvie; + +#ifdef DEBUG + if ((divvie < 0) || (moddo < 0)) { + fprintf(stderr, "long_div_round: %ld, %ld\n", divvie, moddo); + ldr_barf(); + exit(1); + } +#endif /* DEBUG */ + + return divvie; +} + +static int +weighted_mean(int n1, int n2, long w1, long w2) +/* Mean of n1 and n2 respectively weighted by weights w1 and w2. */ +{ +#ifdef DEBUG + if ((w1 <= 0) || (w2 <= 0)) { + fprintf(stderr, + "Bad weights passed to weighted_mean() - (%d, %d, %ld, %ld)!\n", + n1, n2, w1, w2); + exit(1); + } +#endif /* DEBUG */ + return ((int)long_div_round((long)n1 * w1 + (long)n2 * w2, + w1 + w2)); +} + +static int +bubble_eat(Bubble *diner, Bubble *food) +/* The diner eats the food. Returns true (1) if the diner still exists */ +{ + int i; + int newmi; + +#ifdef DEBUG + if ((null_bubble(diner)) || (null_bubble(food))) { + fprintf(stderr, "Bad bubbles passed to bubble_eat()!\n"); + exit(1); + } +#endif /* DEBUG */ + + /* We hide the diner even in the case that it doesn't grow so that + if the food overlaps its boundary it is replaced. This could + probably be solved by letting bubbles eat others which are close + but not quite touching. It's probably worth it, too, since we + would then not have to redraw bubbles which don't change in + size. */ + + hide_bubble(diner); + hide_bubble(food); + diner->x = weighted_mean(diner->x, food->x, diner->area, food->area); + diner->y = weighted_mean(diner->y, food->y, diner->area, food->area); + newmi = pixel_to_mesh(diner->x, diner->y); + diner->area += food->area; + delete_bubble_in_mesh(food, DELETE_BUBBLE); + + if ((simple) && (diner->area > bubble_areas[bubble_max_radius])) { + delete_bubble_in_mesh(diner, DELETE_BUBBLE); + return 0; + } +#ifdef HAVE_XPM + if ((! simple) && (diner->area > + step_pixmaps[num_bubble_pixmaps]->area)) { + delete_bubble_in_mesh(diner, DELETE_BUBBLE); + return 0; + } +#endif /* HAVE_XPM */ + + if (simple) { + if (diner->area > bubble_areas[diner->radius + 1]) { + /* Move the bubble to a new radius */ + i = diner->radius; + while (diner->area > bubble_areas[i+1]) + ++i; + diner->radius = i; + } + show_bubble(diner); +#ifdef HAVE_XPM + } else { + if (diner->area > step_pixmaps[diner->step+1]->area) { + i = diner->step; + while (diner->area > step_pixmaps[i+1]->area) + ++i; + diner->step = i; + diner->radius = step_pixmaps[diner->step]->radius; + } + show_bubble(diner); +#endif /* HAVE_XPM */ + } + + /* Now adjust locations and cells if need be */ + if (newmi != diner->cell_index) { + delete_bubble_in_mesh(diner, KEEP_BUBBLE); + diner->cell_index = newmi; + add_to_mesh(diner); + } + + return 1; +} + +static int +merge_bubbles(Bubble *b1, Bubble *b2) +/* These two bubbles merge into one. If the first one wins out return +1 else return 2. If there is no winner (it explodes) then return 0 */ +{ + int b1size, b2size; + + b1size = b1->area; + b2size = b2->area; + +#ifdef DEBUG + if ((null_bubble(b1) || null_bubble(b2))) { + fprintf(stderr, "NULL bubble passed to merge_bubbles()!\n"); + exit(1); + } +#endif /* DEBUG */ + + if (b1 == b2) { + hide_bubble(b1); + delete_bubble_in_mesh(b1, DELETE_BUBBLE); + return 0; + } + + if (b1size > b2size) { + switch (bubble_eat(b1, b2)) { + case 0: + return 0; + break; + case 1: + return 1; + break; + default: + break; + } + } else if (b1size < b2size) { + switch (bubble_eat(b2, b1)) { + case 0: + return 0; + break; + case 1: + return 2; + break; + default: + break; + } + } else { + if ((ya_random() % 2) == 0) { + switch (bubble_eat(b1, b2)) { + case 0: + return 0; + break; + case 1: + return 1; + break; + default: + break; + } + } else { + switch (bubble_eat(b2, b1)) { + case 0: + return 0; + break; + case 1: + return 2; + break; + default: + break; + } + } + } + fprintf(stderr, "An error occurred in merge_bubbles()\n"); + exit(1); +} + +static void +insert_new_bubble(Bubble *tmp) +/* Calculates which bubbles are eaten when a new bubble tmp is + inserted. This is called recursively in case when a bubble grows + it eats others. Careful to pick out disappearing bubbles. */ +{ + Bubble *nextbub; + Bubble *touch; + +#ifdef DEBUG + if (null_bubble(tmp)) { + fprintf(stderr, "Bad bubble passed to insert_new_bubble()!\n"); + exit(1); + } +#endif /* DEBUG */ + + nextbub = tmp; + touch = get_closest_bubble(nextbub); + while (! null_bubble(touch)) { + switch (merge_bubbles(nextbub, touch)) { + case 2: + /* touch ate nextbub and survived */ + nextbub = touch; + break; + case 1: + /* nextbub ate touch and survived */ + break; + case 0: + /* somebody ate someone else but they exploded */ + nextbub = (Bubble *)NULL; + break; + default: + /* something went wrong */ + fprintf(stderr, "Error occurred in insert_new_bubble()\n"); + exit(1); + } + /* Check to see if there are any other bubbles still in the area + and if we need to do this all over again for them. */ + if (! null_bubble(nextbub)) + touch = get_closest_bubble(nextbub); + else + touch = (Bubble *)NULL; + } +} + +#ifdef DEBUG +static int +get_length_of_bubble_list(Bubble *bb) +{ + Bubble *tmp = bb; + int rv = 0; + + while (! null_bubble(tmp)) { + rv++; + tmp = tmp->next; + } + + return rv; +} +#endif /* DEBUG */ + +/* + * Pixmap stuff used regardless of whether file I/O is available. Must + * still check for XPM, though! + */ + +#ifdef HAVE_XPM + +/* + * Pixmaps without file I/O (but do have XPM) + */ + +static void +pixmap_sort(Bubble_Step **head, int numelems) +/* Couldn't get qsort to work right with this so I wrote my own. This puts +the numelems length array with first element at head into order of radius. +*/ +{ + Bubble_Step tmp; + Bubble_Step *least = 0; + int minradius = INT_MAX; + int i; + + for (i = 0; i < numelems; i++) { + if (head[i]->radius < minradius) { + least = head[i]; + minradius = head[i]->radius; + } + } + if (*head != least) { + memcpy(&tmp, least, sizeof(Bubble_Step)); + memcpy(least, *head, sizeof(Bubble_Step)); + memcpy(*head, &tmp, sizeof(Bubble_Step)); + } + + if (numelems > 2) + pixmap_sort(&head[1], numelems-1); +} + +static int +extrapolate(int i1, int i2) +{ + return (i2 + (i2 - i1)); +} + +static void +make_pixmap_array(Bubble_Step *list) +/* From a linked list of bubbles construct the array step_pixmaps */ +{ + Bubble_Step *tmp = list; + int ind; +#ifdef DEBUG + int prevrad = -1; +#endif + + if (list == (Bubble_Step *)NULL) { + fprintf(stderr, "NULL list passed to make_pixmap_array\n"); + exit(1); + } + + num_bubble_pixmaps = 1; + while(tmp->next != (Bubble_Step *)NULL) { + tmp = tmp->next; + ++num_bubble_pixmaps; + } + + if (num_bubble_pixmaps < 2) { + fprintf(stderr, "Must be at least two bubbles in file\n"); + exit(1); + } + + step_pixmaps = (Bubble_Step **)xmalloc((num_bubble_pixmaps + 1) * + sizeof(Bubble_Step *)); + + /* Copy them blindly into the array for sorting. */ + ind = 0; + tmp = list; + do { + step_pixmaps[ind++] = tmp; + tmp = tmp->next; + } while(tmp != (Bubble_Step *)NULL); + + /* We make another bubble beyond the ones with pixmaps so that the final + bubble hangs around and doesn't pop immediately. It's radius and area + are found by extrapolating from the largest two bubbles with pixmaps. */ + + step_pixmaps[num_bubble_pixmaps] = + (Bubble_Step *)xmalloc(sizeof(Bubble_Step)); + step_pixmaps[num_bubble_pixmaps]->radius = INT_MAX; + + pixmap_sort(step_pixmaps, (num_bubble_pixmaps + 1)); + +#ifdef DEBUG + if (step_pixmaps[num_bubble_pixmaps]->radius != INT_MAX) { + fprintf(stderr, "pixmap_sort() screwed up make_pixmap_array\n"); + } +#endif /* DEBUG */ + + step_pixmaps[num_bubble_pixmaps]->radius = + extrapolate(step_pixmaps[num_bubble_pixmaps-2]->radius, + step_pixmaps[num_bubble_pixmaps-1]->radius); + step_pixmaps[num_bubble_pixmaps]->area = + calc_bubble_area(step_pixmaps[num_bubble_pixmaps]->radius); + + +#ifdef DEBUG + /* Now check for correct order */ + for (ind = 0; ind < num_bubble_pixmaps; ind++) { + if (prevrad > 0) { + if (step_pixmaps[ind]->radius < prevrad) { + fprintf(stderr, "Pixmaps not in ascending order of radius\n"); + exit(1); + } + } + prevrad = step_pixmaps[ind]->radius; + } +#endif /* DEBUG */ +} + +static void +make_pixmap_from_default(char **pixmap_data, Bubble_Step *bl) +/* Read pixmap data which has been compiled into the program and a pointer + to which has been passed. + + This is virtually copied verbatim from make_pixmap_from_file() above and +changes made to either should be propagated onwards! */ +{ + int result; + XGCValues gcv; + +#ifdef DEBUG + if (pixmap_data == (char **)0) { + fprintf(stderr, "make_pixmap_from_default(): NULL passed\n"); + exit(1); + } +#endif + + if (bl == (Bubble_Step *)NULL) { + fprintf(stderr, "NULL pointer passed to make_pixmap()\n"); + exit(1); + } + + bl->xpmattrs.valuemask = 0; + +#ifdef XpmCloseness + bl->xpmattrs.valuemask |= XpmCloseness; + bl->xpmattrs.closeness = 40000; +#endif +#ifdef XpmVisual + bl->xpmattrs.valuemask |= XpmVisual; + bl->xpmattrs.visual = defvisual; +#endif +#ifdef XpmDepth + bl->xpmattrs.valuemask |= XpmDepth; + bl->xpmattrs.depth = screen_depth; +#endif +#ifdef XpmColormap + bl->xpmattrs.valuemask |= XpmColormap; + bl->xpmattrs.colormap = defcmap; +#endif + + + /* This is the only line which is different from make_pixmap_from_file() */ + result = XpmCreatePixmapFromData(defdsp, defwin, pixmap_data, &bl->ball, + &bl->shape_mask, &bl->xpmattrs); + + switch(result) { + case XpmColorError: + fprintf(stderr, "xpm: color substitution performed\n"); + /* fall through */ + case XpmSuccess: + bl->radius = MAX(bl->xpmattrs.width, bl->xpmattrs.height) / 2; + bl->area = calc_bubble_area(bl->radius); + break; + case XpmColorFailed: + fprintf(stderr, "xpm: color allocation failed\n"); + exit(1); + case XpmNoMemory: + fprintf(stderr, "xpm: out of memory\n"); + exit(1); + default: + fprintf(stderr, "xpm: unknown error code %d\n", result); + exit(1); + } + + gcv.plane_mask = AllPlanes; + gcv.foreground = default_fg_pixel; + gcv.function = GXcopy; + bl->draw_gc = XCreateGC (defdsp, defwin, GCForeground, &gcv); + XSetClipMask(defdsp, bl->draw_gc, bl->shape_mask); + + gcv.foreground = default_bg_pixel; + gcv.function = GXcopy; + bl->erase_gc = XCreateGC (defdsp, defwin, GCForeground, &gcv); + XSetClipMask(defdsp, bl->erase_gc, bl->shape_mask); +} + +static void +default_to_pixmaps (void) +/* Make pixmaps out of default ball data stored in bubbles_default.c */ +{ + int i; + Bubble_Step *pixmap_list = (Bubble_Step *)NULL; + Bubble_Step *newpix, *tmppix; + char **pixpt; + + init_default_bubbles(); + + for (i = 0; i < num_default_bubbles; i++) { + pixpt = default_bubbles[i]; + newpix = (Bubble_Step *)xmalloc(sizeof(Bubble_Step)); + make_pixmap_from_default(pixpt, newpix); + /* Now add to list */ + if (pixmap_list == (Bubble_Step *)NULL) { + pixmap_list = newpix; + } else { + tmppix = pixmap_list; + while (tmppix->next != (Bubble_Step *)NULL) + tmppix = tmppix->next; + tmppix->next = newpix; + } + newpix->next = (Bubble_Step *)NULL; + } + + /* Finally construct step_pixmaps[] */ + make_pixmap_array(pixmap_list); +} + +#endif /* HAVE_XPM */ + + +/* + * Main stuff + */ + + +static void +get_resources(Display *dpy, Window window) +/* Get the appropriate X resources and warn about any inconsistencies. */ +{ + Bool nodelay; + XWindowAttributes xgwa; + Colormap cmap; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + + threed = get_boolean_resource("3D", "Boolean"); + quiet = get_boolean_resource("quiet", "Boolean"); + simple = get_boolean_resource("simple", "Boolean"); + /* Forbid rendered bubbles on monochrome displays */ + if ((mono_p) && (! simple)) { + if (! quiet) + fprintf(stderr, + "Rendered bubbles not supported on monochrome displays\n"); + simple = True; + } + delay = get_integer_resource("delay", "Integer"); + nodelay = get_boolean_resource("nodelay", "Boolean"); + if (nodelay) + delay = 0; + if (delay < 0) + delay = 0; + + default_fg_pixel = get_pixel_resource ("foreground", "Foreground", dpy, + cmap); + default_bg_pixel = get_pixel_resource ("background", "Background", dpy, + cmap); + + if (simple) { + /* This is easy */ + broken = get_boolean_resource("broken", "Boolean"); + if (broken) + if (! quiet) + fprintf(stderr, "-broken not available in simple mode\n"); + } else { +#ifndef HAVE_XPM + simple = 1; +#else + broken = get_boolean_resource("broken", "Boolean"); +#endif /* HAVE_XPM */ + } +} + +static void +init_bubbles (Display *dpy, Window window) +{ + XGCValues gcv; + XWindowAttributes xgwa; + int i; + + defdsp = dpy; + defwin = window; + + ya_rand_init(0); + + get_resources(dpy, window); + + XGetWindowAttributes (dpy, window, &xgwa); + +#ifdef DEBUG + printf("sizof(int) on this platform is %d\n", sizeof(int)); + printf("sizof(long) on this platform is %d\n", sizeof(long)); +#endif /* DEBUG */ + + screen_width = xgwa.width; + screen_height = xgwa.height; + screen_depth = xgwa.depth; + defcmap = xgwa.colormap; + defvisual = xgwa.visual; + + if (simple) { + /* These are pretty much plucked out of the air */ + bubble_min_radius = (int)(0.006*(double)(MIN(screen_width, + screen_height))); + bubble_max_radius = (int)(0.045*(double)(MIN(screen_width, + screen_height))); + /* Some trivial values */ + if (bubble_min_radius < 1) + bubble_min_radius = 1; + if (bubble_max_radius <= bubble_min_radius) + bubble_max_radius = bubble_min_radius + 1; + + mesh_length = (2 * bubble_max_radius) + 3; + + /* store area of each bubble of certain radius as number of 1/10s of + a pixel area. PI is defined in */ + bubble_areas = (long *)xmalloc((bubble_max_radius + 2) * sizeof(int)); + for (i = 0; i < bubble_min_radius; i++) + bubble_areas[i] = 0; + for (i = bubble_min_radius; i <= (bubble_max_radius+1); i++) + bubble_areas[i] = calc_bubble_area(i); + + mesh_length = (2 * bubble_max_radius) + 3; + } else { +#ifndef HAVE_XPM + fprintf(stderr, + "Bug: simple mode code not set but HAVE_XPM not defined\n"); + exit(1); +#else + /* Make sure all #ifdef sort of things have been taken care of in + get_resources(). */ + default_to_pixmaps(); + + /* Set mesh length */ + mesh_length = (2 * step_pixmaps[num_bubble_pixmaps-1]->radius) + 3; +#endif /* HAVE_XPM */ + + /* Am I missing something in here??? */ + } + + mesh_width = (screen_width / mesh_length) + 1; + mesh_height = (screen_height / mesh_length) + 1; + mesh_cells = mesh_width * mesh_height; + init_mesh(); + + calculate_adjacent_list(); + + adjust_areas(); + + /* Graphics contexts for simple mode */ + if (simple) { + gcv.foreground = default_fg_pixel; + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = default_bg_pixel; + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + } + + XClearWindow (dpy, window); +} + +static void +bubbles (Display *dpy, Window window) +{ + Bubble *tmp; + + tmp = new_bubble(); + add_to_mesh(tmp); + insert_new_bubble(tmp); + + XSync (dpy, True); +} + + +void +screenhack (Display *dpy, Window window) +{ + init_bubbles (dpy, window); + while (1) { + bubbles (dpy, window); + if (delay) + usleep(delay); + } +} + diff --git a/hacks/bubbles.h b/hacks/bubbles.h new file mode 100644 index 00000000..89935f45 --- /dev/null +++ b/hacks/bubbles.h @@ -0,0 +1,214 @@ +/* bubbles.h - definitions for bubbles screensaver */ + +/* $Id: bubbles.h,v 1.2 1997/05/19 03:26:05 jwz Exp $ */ + +#ifndef _BUBBLES_H_ +#define _BUBBLES_H_ + +#ifdef HAVE_XPM +#include +#endif + +/*************************************************************************** + * Options you might like to change to affect the program's behaviour * + ***************************************************************************/ + +/* + * Uncommenting the following will enable support for reading bubbles from + * files (using the -file and -directory options to bubbles). This is + * disabled by default since such operations are inherently non-portable + * and we want the program to compile on as many systems as possible. + * + * If you uncomment this and you figure out how to get it working, please + * let me (J.Macnicol@student.anu.edu.au) know. Diffs against the standard + * distribution would be appreciated. Possible sources of problems are + * dirent and possibly the use of tmpnam(). + */ + +/* #define BUBBLES_IO */ + +/* + * The following only makes sense if BUBBLES_IO above is defined. + * + * Uncomment the following if you always want to use the -file or + * -directory options on the command line and never to use a default bubble + * compiled into the program. This way you would save memory and disk space + * since if you do use -file or -directory only one bubble will be loaded + * into memory at any one time (and remember the default bubble is really + * uncompressed, unlike bubbles in files which can be compressed). This + * is disabled by default only so people running the program for the first + * time with no knowldege of the command line options don't get error + * messages ;) + * + * NOTE: You will still need to have a bubbles_default.c file, else the + * build sequence will fail. Well constructed bubbles_default.c files + * have #ifdef's which simply exclude everything else in the file at + * compile time. The bubblestodefault script does this. + */ + +/* #define NO_DEFAULT_BUBBLE */ + +/* + * This turns on any debugging messages and sanity checks. Hopefully you + * won't need this :) It slows things down a bit, too. + * + * NOTE: If you uncomment this you will get some messages about unused + * functions when you compile. You can ignore these - they refer to + * convenient checking routines which simply aren't called but are left + * in case someone wants to use them. + */ + +/* #define DEBUG */ + +/*************************************************************************** + * Things you might need to change to get things working right * + ***************************************************************************/ + +/* + * Name of the gzip binary. You shouldn't need to change this unless it's + * not in your PATH when the program is run, in which case you will need to + * substitute the full path here. Keep the double quotes else things won't + * compile! + */ + +#define GZIP "gzip" + +/* + * Likewise for the Bourne shell. + */ + +#define BOURNESH "sh" + +/* + * The name of the directory entry structure is different under Linux + * (under which this code is being developed) than other systems. The case + * alternate form here is that given in Kernighan & Ritchie's C book (which + * must be authoratitive, no?) + * + * 04/07/96 : People will have to hack this to get it working on some + * systems. I believe it doesn't work on SGI, for example. + */ + +#ifdef _POSIX_SOURCE +#define STRUCT_DIRENT struct dirent +#else +#define STRUCT_DIRENT Dirent +#endif + +/* + * The naming of fields in struct dirent also seems to differ from system to + * system. This may have to be extended to make things truly portable. + * What we want here is the name field from a dirent struct pointed to + * by "dp". + * + * 04/07/96 : See above. This may need to be changed too. + */ + +#ifdef _POSIX_SOURCE +#define DIRENT_NAME dp->d_name +#else +#define DIRENT_NAME dp->name +#endif + +/* I don't know why this isn't defined. */ +#ifdef linux +/* apparently it is defined in recent linuxes. who knows. */ +/*extern char *tempnam(char *, char *);*/ +#endif + +/**************************************************************************** + * Buffer lengths and things you probably won't need to touch * + ****************************************************************************/ + +/* Maximum length of a full path name we can deal with */ +#define PATH_BUF_SIZE 1024 + +/* Size of string passed to shell as command */ +#define COMMAND_BUF_SIZE 2500 + +/* Size increments for read_line() buffers */ +#define READ_LINE_BUF_SIZE 24 + +/**************************************************************************** + * End of options * + ****************************************************************************/ + +/* Some machines define M_PI and not PI. If they don't define either, use +own own. Really, the accuracy of this is _not_ very important. */ +#ifndef PI +# define PI M_PI +# ifndef M_PI +# define M_PI 3.1415926535 +# endif +#endif + +/* for delete_bubble_in_mesh() */ +#define DELETE_BUBBLE 0 +#define KEEP_BUBBLE 1 + +/* Status codes for read_line */ +#define LINE_READ 0 +#define EOF_REACHED 1 +#define IO_ERROR 2 + +/* + * Magic number for Bubble struct, in case it's trashed when debugging code + * (which happened to me often.... :( + */ + +#define BUBBLE_MAGIC 5674 + +/* Useful macros */ +#define MAX(A, B) ((A) > (B) ? (A) : (B)) +#define MIN(A, B) ((A) < (B) ? (A) : (B)) + +/* How we represent bubbles */ +struct bub { + int radius; + int step; /* for rendered bubbles */ + long area; + int x; + int y; + int magic; + int cell_index; + int visible; + struct bub *next; + struct bub *prev; +}; + +typedef struct bub Bubble; + +/* + * How we represent pixmaps of rendered bubbles. Because the range of radii + * available may not be continuous, we call each a step (for the lack of a + * better name...) + */ + +#ifdef HAVE_XPM +struct bub_step { + int radius; + long area; + Pixmap ball, shape_mask; + GC draw_gc, erase_gc; + XpmAttributes xpmattrs; + struct bub_step *next; +}; + +typedef struct bub_step Bubble_Step; +#endif /* HAVE_XPM */ + +/* Make sure default bubble isn't compiled when we don't have XPM +Disable file I/O code too. */ +#ifndef HAVE_XPM +# define NO_DEFAULT_BUBBLE +# undef BUBBLES_IO +#endif /* HAVE_XPM */ + +/* Make sure default bubble is compiled in when we have XPM and no file I/O */ +#ifdef HAVE_XPM +# ifndef BUBBLES_IO +# undef NO_DEFAULT_BUBBLE +# endif /* BUBBLES_IO */ +#endif /* HAVE_XPM */ + +#endif /* _BUBBLES_H_ */ diff --git a/hacks/bubbles.man b/hacks/bubbles.man new file mode 100644 index 00000000..c9016e64 --- /dev/null +++ b/hacks/bubbles.man @@ -0,0 +1,142 @@ +.de EX \"Begin example +.ne 5 +.if n .sp 1 +.if t .sp .5 +.nf +.in +.5i +.. +.de EE +.fi +.in -.5i +.if n .sp 1 +.if t .sp .5 +.. +.TH XScreenSaver 1 "14-Dec-95" "X Version 11" +.SH NAME +bubbles - frying pan / soft drink simulation +.SH SYNOPSIS +.B bubbles +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-simple] [\-broken] [\-3D] [\-file filename] [\-directory directoryname] +.SH DESCRIPTION +\fIBubbles\fP sprays lots of little random bubbles all over the window which +then grow until they reach their maximum size and go pop. The inspiration +for this was watching little globules of oil on the bottom of a frying pan +and it also looks a little like bubbles in fizzy soft drink. The default +mode uses fancy ray-traced bubbles but there is also a mode which just draws +circles in case the default mode is too taxing on your hardware. +.SH OPTIONS +Depending on how your +.I bubbles +was compiled, it accepts the following options: +.TP 8 +.B \-foreground +Colour of circles if \fI\-simple\fP mode is selected. +.TP 8 +.B \-background +Colour of window background. +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay microseconds +How much of a delay should be introduced between steps of the animation. +Default 1, or about 1 microsecond. Actually, this is the delay between each +group of 15 new bubbles since such a delay between each step results in a +very slow animation rate. +.TP 8 +.B \-nodelay +Same as \fI\-delay 0\fP. +.TP 8 +.B \-simple +Don't use the default fancy pixmap bubbles. Just draw circles instead. +This may give more bearable performance if your hardware wasn't made for +this sort of thing. +.TP 8 +.B \-broken +Don't hide bubbles when they pop. This was a bug during development +but the results were actually quite attractive. (This option is only +available if you have the XPM library available and the imake generated +Makefile has defined HAVE_XPM). +.TP 8 +.B \-3D +Normally, the simulation is done completely in two dimensions. When a +bubble swallows up another bubble, the areas of each are added to get +the area of the resulting bubble. This option changes the algorithm +to instead add volume (imagining each to be a sphere in 3D space). The +whole thing looks more realistic but I find it attracts attention to +the flickering of each bubble as they are move and are redrawn. Your +mileage may vary. +.TP 8 +.B \-file filename +Use the pixmap definitions in the given file, instead of the default (if +one is compiled in). This is ignored if \fI\-simple\fP is specified. If +the file is compressed (either with compress or gzip), it is decompressed +before use. (This option only works if you have XPM compiled into your +binary and you have compiled with BUBBLES_IO set in bubbles.h. This is +\fBnot\fP the default). +.TP 8 +.B \-directory directoryname +Similar to \fI-file\fP except the file is taken randomly from the +contents of the specified directory. (Again, this option is only available +if you have XPM and BUBBLES_IO was set when compiling. See above). +.TP 8 +.B \-quiet +Don't print messages explaining why one or several command line options +were ignored. This is disabled by default. +.SH NOTES +If you find the pace of things too slow, remember that there is a delay +even though you specify no \fI\-delay\fP option. Try using \fI\-nodelay\fP +although beware of the effects of irritation of other users if you're on a +shared system as you bleed their CPU time away. + +Some tools to assist in creation of new bubbles are included in the source +distribution. These can either be loaded with the \fI\-file\fP or +\fI\-directory\fP options (if available) or they can be used in place +of the distributed default bubble (bubble_default.c). +You might like to copy these scripts to a permanent location and +use them. Read bubbles.README. + +Rendered bubbles are not supported on monochrome displays. I'm not +convinced that small bubbles, even dithered properly are going to look +like anything more than a jumble of random dots. +.SH BUGS +There is a delay before something appears on the screen when using +rendered bubbles. The XPM library seems to take a \fBlong\fP time to make +pixmaps out of raw data. This can be irritating on slower systems. + +The movement of the bubbles looks jerky if an incomplete set of bubbles +is used. + +The hide/display algorithm could do with some work to avoid flickering +when \fI\-nodelay\fP is set. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH DISTRIBUTION POLICY +This work is Copyright \(co 1995, 1996 by James Macnicol. Distribution is +allowed under the terms of the GNU General Public License. Look at the +sources for the legalese. +.SH AUTHOR +James Macnicol . diff --git a/hacks/compile_axp.com b/hacks/compile_axp.com new file mode 100644 index 00000000..336175bd --- /dev/null +++ b/hacks/compile_axp.com @@ -0,0 +1,66 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ANT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ATTRACTION.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BLITSPIN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BOUBOULE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BRAID.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BUBBLES-DEFAULT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BUBBLES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) CORAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) CYNOSURE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DECAYSCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DECO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DRIFT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FADEPLOT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FLAG.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FLAME.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FOREST.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GALAXY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GOOP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GRAV.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GREYNETIC.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HALO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HELIX.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HOPALONG.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HYPERCUBE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) IFS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) IMSMAP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) JULIA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) KALEIDESCOPE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LASER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LIGHTNING.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LISA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LISSIE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LMORPH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MAZE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOIRE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOIRE2.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOUNTAIN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MUNCH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) NOSEGUY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PEDAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PENROSE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PUZZLE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PYRO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) QIX.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) RD-BOMB.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ROCKS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) RORSCHACH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ROTOR.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SCREENHACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SIERPINSKI.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SLIDESCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SLIP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SPHERE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SPIRAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) STARFISH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) STRANGE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SWIRL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRIANGLE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VINES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WORM.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XJACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XLOCKMORE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XLYAP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XROGER-HACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XSCREENSAVER-SGIGL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE,XLOCKMORE)/INCL=([],[-],[-.UTILS])/OBJ=SCREENHACK-XLOCK.OBJ SCREENHACK.C diff --git a/hacks/compile_decc.com b/hacks/compile_decc.com new file mode 100644 index 00000000..336175bd --- /dev/null +++ b/hacks/compile_decc.com @@ -0,0 +1,66 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ANT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ATTRACTION.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BLITSPIN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BOUBOULE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BRAID.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BUBBLES-DEFAULT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) BUBBLES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) CORAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) CYNOSURE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DECAYSCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DECO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) DRIFT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FADEPLOT.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FLAG.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FLAME.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) FOREST.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GALAXY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GOOP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GRAV.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) GREYNETIC.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HALO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HELIX.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HOPALONG.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) HYPERCUBE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) IFS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) IMSMAP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) JULIA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) KALEIDESCOPE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LASER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LIGHTNING.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LISA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LISSIE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) LMORPH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MAZE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOIRE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOIRE2.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MOUNTAIN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) MUNCH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) NOSEGUY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PEDAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PENROSE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PUZZLE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) PYRO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) QIX.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) RD-BOMB.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ROCKS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) RORSCHACH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) ROTOR.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SCREENHACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SIERPINSKI.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SLIDESCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SLIP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SPHERE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SPIRAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) STARFISH.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) STRANGE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) SWIRL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRIANGLE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VINES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WORM.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XJACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XLOCKMORE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XLYAP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XROGER-HACK.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) XSCREENSAVER-SGIGL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE,XLOCKMORE)/INCL=([],[-],[-.UTILS])/OBJ=SCREENHACK-XLOCK.OBJ SCREENHACK.C diff --git a/hacks/coral.c b/hacks/coral.c new file mode 100644 index 00000000..74b5120b --- /dev/null +++ b/hacks/coral.c @@ -0,0 +1,257 @@ +/* coral, by "Frederick G.M. Roeber" , 15-jul-97. + * + * 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. + */ + +#include "screenhack.h" +#include "colors.h" +#include "erase.h" + +static GC draw_gc, erase_gc; +static unsigned int default_fg_pixel; +#define NCOLORSMAX 200 +static XColor colors[NCOLORSMAX]; +static int ncolors = 0; +static int colorindex = 0; +static int colorsloth; + +static XPoint *walkers; +static int nwalkers; +static int width, widthb; +static int height; + +static unsigned int *board; +#define getdot(x,y) (board[(y*widthb)+(x>>5)] & (1<<(x & 31))) +#define setdot(x,y) (board[(y*widthb)+(x>>5)] |= (1<<(x & 31))) + + +static void +init_coral(Display *dpy, Window window) +{ + XGCValues gcv; + Colormap cmap; + XWindowAttributes xgwa; + Bool writeable = False; + int seeds; + int density; + int i; + + XClearWindow(dpy, window); + XGetWindowAttributes(dpy, window, &xgwa); + width = xgwa.width; + widthb = ((xgwa.width + 31) >> 5); + height = xgwa.height; + board = (unsigned int *)calloc(widthb * xgwa.height, sizeof(unsigned int)); + if(!board) exit(1); + cmap = xgwa.colormap; + if( ncolors ) { + free_colors(dpy, cmap, colors, ncolors); + ncolors = 0; + } + gcv.foreground = default_fg_pixel = get_pixel_resource("foreground", "Foreground", dpy, cmap); + draw_gc = XCreateGC(dpy, window, GCForeground, &gcv); + gcv.foreground = get_pixel_resource ("background", "Background",dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + ncolors = NCOLORSMAX; + make_uniform_colormap(dpy, xgwa.visual, cmap, colors, &ncolors, True, &writeable, False); + if (ncolors <= 0) { + ncolors = 2; + colors[0].red = colors[0].green = colors[0].blue = 0; + colors[1].red = colors[1].green = colors[1].blue = 0xFFFF; + XAllocColor(dpy, cmap, &colors[0]); + XAllocColor(dpy, cmap, &colors[1]); + } + colorindex = random()%ncolors; + + density = get_integer_resource("density", "Integer"); + if( density < 1 ) density = 1; + if( density > 100 ) density = 90; /* more like mold than coral */ + nwalkers = (width*height*density)/100; + walkers = (XPoint *)calloc(nwalkers, sizeof(XPoint)); + if( (XPoint *)0 == walkers ) exit(1); + + seeds = get_integer_resource("seeds", "Integer"); + if( seeds < 1 ) seeds = 1; + if( seeds > 1000 ) seeds = 1000; + + colorsloth = nwalkers*2/ncolors; + XSetForeground(dpy, draw_gc, colors[colorindex].pixel); + + for( i = 0; i < seeds; i++ ) { + int x, y; + do { + x = random() % width; + y = random() % 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(dpy, window, draw_gc, x, y); + } + + for( i = 0; i < nwalkers; i++ ) { + walkers[i].x = (random() % (width-2)) + 1; + walkers[i].y = (random() % (height-2)) + 1; + } +} + + +/* returns 2 bits of randomness (conserving calls to random()). + 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 != 0) { + i--; + } else { + i = 15; + r = random(); + } + + { + register int j = (r & 3); + r = r >> 2; + return j; + } +} + + +static void +coral(Display *dpy, Window window) +{ + int delay2 = get_integer_resource ("delay2", "Integer"); + + int max_points = 200; + int npoints = 0; + XPoint *pointbuf = (XPoint *) calloc(sizeof(XPoint), max_points+2); + if (!pointbuf) exit(-1); + + while( 1 ) { + int i; + + for( i = 0; i < nwalkers; i++ ) { + int x = walkers[i].x; + int y = walkers[i].y; + + if( getdot(x, y) ) { + + Bool flush = False; + Bool color = False; + + /* XDrawPoint(dpy, window, draw_gc, x, y); */ + pointbuf[npoints].x = x; + 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)); + nwalkers--; + walkers[i].x = walkers[nwalkers].x; + walkers[i].y = walkers[nwalkers].y; + if( 0 == (nwalkers%colorsloth) ) { + color = True; + } + + if (flush || color || 0 == nwalkers || npoints >= max_points) { + XDrawPoints(dpy, window, draw_gc, pointbuf, npoints, + CoordModeOrigin); + npoints = 0; + XSync(dpy, True); + } + + if (color) { + colorindex++; + if( colorindex == ncolors ) + colorindex = 0; + XSetForeground(dpy, draw_gc, colors[colorindex].pixel); + } + + if( 0 == nwalkers ) { + XSync(dpy, True); + free(pointbuf); + return; + } + } else { + /* move it a notch */ + do { + switch(rand_2()) { + case 0: + if( 1 == x ) continue; + walkers[i].x--; + break; + case 1: + if( width-2 == x ) continue; + walkers[i].x++; + break; + case 2: + if( 1 == y ) continue; + walkers[i].y--; + break; + default: /* case 3: */ + if( height-2 == y ) continue; + walkers[i].y++; + break; + /* default: + abort(); */ + } + } while(0); + } + } + + if (delay2 > 0) { + if (npoints > 0) { + XDrawPoints(dpy, window, draw_gc, pointbuf, npoints, + CoordModeOrigin); + npoints = 0; + XSync(dpy, True); + } + usleep(delay2); + } + } +} + +char *progclass = "Coral"; + +char *defaults[] = { + "Coral.background: black", + "Coral.foreground: white", + "*density: 25", + "*seeds: 20", /* too many for 640x480, too few for 1280x1024 */ + "*delay: 5", + "*delay2: 1000", + 0 +}; + +XrmOptionDescRec options[] = { + { "-density", ".density", XrmoptionSepArg, 0 }, + { "-seeds", ".seeds", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack(dpy, window) +Display *dpy; +Window window; +{ + int delay = get_integer_resource ("delay", "Integer"); + while( 1 ) { + init_coral(dpy, window); + coral(dpy, window); + if( delay ) sleep(delay); + erase_full_window(dpy, window); + } +} diff --git a/hacks/cynosure.c b/hacks/cynosure.c new file mode 100644 index 00000000..6a2be2df --- /dev/null +++ b/hacks/cynosure.c @@ -0,0 +1,390 @@ +/* cynosure --- draw some rectangles + * + * 01-aug-96: written in Java by ozymandias G desiderata + * 25-dec-97: ported to C and XScreenSaver by Jamie Zawinski + * + * Original version: + * http://www.organic.com/staff/ogd/java/cynosure.html + * http://www.organic.com/staff/ogd/java/source/cynosure/Cynosure-java.txt + * + * Original comments and copyright: + * + * Cynosure.java + * A Java implementation of Stephen Linhart's Cynosure screen-saver as a + * drop-in class. + * + * Header: /home/ogd/lib/cvs/aoaioxxysz/graphics/Cynosure.java,v 1.2 1996/08/02 02:41:21 ogd Exp + * + * ozymandias G desiderata + * Thu Aug 1 1996 + * + * COPYRIGHT NOTICE + * + * Copyright 1996 ozymandias G desiderata. Title, ownership rights, and + * intellectual property rights in and to this software remain with + * ozymandias G desiderata. This software may be copied, modified, + * or used as long as this copyright is retained. Use this code at your + * own risk. + * + * Revision: 1.2 + * + * Log: Cynosure.java,v + * Revision 1.2 1996/08/02 02:41:21 ogd + * Added a few more comments, fixed messed-up header. + * + * Revision 1.1.1.1 1996/08/02 02:30:45 ogd + * First version + */ + +#include "screenhack.h" +static Display *dpy; +static Window window; +static XColor *colors; +static int ncolors; +static int fg_pixel, bg_pixel; +static GC fg_gc, bg_gc, shadow_gc; + +static void paint(void); +static int genNewColor(void); +static int genConstrainedColor(int base, int tweak); +static int c_tweak(int base, int tweak); + +/** + * The current color that is being tweaked to create the + * rectangles. + **/ +static int curColor; + +/** + * A variable used for the progression of the colors (yes, I know + * that's a lame explanation, but if your read the source, it should + * become obvious what I'm doing with this variable). + **/ +static int curBase; + +/** + * The width of the right and bottom edges of the rectangles. + **/ +static int shadowWidth; + +/* The offset of the dropshadow beneath the rectangles. */ +static int elevation; + +/** + * The approximate amount of time that will elapse before the base + * color is permanently changed. + * + * @see #tweak + **/ +static int sway; + +/** + * The counter of time left until the base color value used. This class + * variable is necessary because Java doesn't support static method + * variables (grr grr). + **/ +static int timeLeft; + +/** + * The amount by which the color of the polygons drawn will vary. + * + * @see #sway; + **/ +static int tweak; + +/** + * The smallest size for an individual cell. + **/ +#define MINCELLSIZE 16 + +/** + * The narrowest a rectangle can be. + **/ +#define MINRECTSIZE 6 + +/** + * The size of the grid that the rectangles are placed within. + **/ +static int gridSize; + +/** + * Every so often genNewColor() generates a completely random + * color. This variable sets how frequently that happens. It's + * currently set to happen 1% of the time. + * + * @see #genNewColor + **/ +#define THRESHOLD 100 /*0.01*/ + + +char *progclass = "Cynosure"; +char *defaults [] = { + "Cynosure.background: black", /* to placate SGI */ + "*delay: 500000", + "*colors: 128", + "*iterations: 100", + "*shadowWidth: 2", + "*elevation: 5", + "*sway: 30", + "*tweak: 20", + "*gridSize: 12", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-ncolors", ".colors", XrmoptionSepArg, 0 }, + { "-iterations", ".iterations", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + + +void screenhack(Display *d, Window w) +{ + XWindowAttributes xgwa; + XGCValues gcv; + int delay; + int i, iterations; + + dpy = d; + window = w; + + curColor = 0; + curBase = curColor; + shadowWidth = get_integer_resource ("shadowWidth", "Integer"); + elevation = get_integer_resource ("elevation", "Integer"); + sway = get_integer_resource ("sway", "Integer"); + tweak = get_integer_resource ("tweak", "Integer"); + gridSize = get_integer_resource ("gridSize", "Integer"); + timeLeft = 0; + + XGetWindowAttributes (dpy, window, &xgwa); + + ncolors = get_integer_resource ("colors", "Colors"); + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + + if (mono_p) + colors = 0; + else + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + + if (mono_p) + ; + else { + make_smooth_colormap (dpy, xgwa.visual, xgwa.colormap, colors, &ncolors, + True, 0, True); + if (ncolors <= 2) { + mono_p = True; + ncolors = 2; + if (colors) free(colors); + colors = 0; + } + } + + bg_pixel = get_pixel_resource("background", "Background", dpy, + xgwa.colormap); + fg_pixel = get_pixel_resource("foreground", "Foreground", dpy, + xgwa.colormap); + + gcv.foreground = fg_pixel; + fg_gc = XCreateGC(dpy, window, GCForeground, &gcv); + gcv.foreground = bg_pixel; + bg_gc = XCreateGC(dpy, window, GCForeground, &gcv); + + gcv.fill_style = FillStippled; + gcv.stipple = XCreateBitmapFromData(dpy, window, "\125\252", 8, 2); + shadow_gc = XCreateGC(dpy, window, GCForeground|GCFillStyle|GCStipple, &gcv); + XFreePixmap(dpy, gcv.stipple); + + delay = get_integer_resource ("delay", "Delay"); + iterations = get_integer_resource ("iterations", "Iterations"); + + while (1) + { + if (iterations > 0 && ++i >= iterations) + { + i = 0; + if (!mono_p) + XSetWindowBackground(dpy, window, + colors[random() % ncolors].pixel); + XClearWindow(dpy, window); + } + paint(); + XSync(dpy, False); + if (delay) + usleep(delay); + } +} + +/** + * paint adds a new layer of multicolored rectangles within a grid of + * randomly generated size. Each row of rectangles is the same color, + * but colors vary slightly from row to row. Each rectangle is placed + * within a regularly-sized cell, but each rectangle is sized and + * placed randomly within that cell. + * + * @param g the Graphics coordinate in which to draw + * @see #genNewColor + **/ +static void paint(void) +{ + int i; + int cellsWide, cellsHigh, cellWidth, cellHeight; + static int width, height; + static int size_check = 1; + + if (--size_check <= 0) + { + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + size_check = 1000; + } + + /* How many cells wide the grid is (equal to gridSize +/- (gridSize / 2)) + */ + cellsWide = c_tweak(gridSize, gridSize / 2); + /* How many cells high the grid is (equal to gridSize +/- (gridSize / 2)) + */ + cellsHigh = c_tweak(gridSize, gridSize / 2); + /* How wide each cell in the grid is */ + cellWidth = width / cellsWide; + /* How tall each cell in the grid is */ + cellHeight = height / cellsHigh; + + /* Ensure that each cell is above a certain minimum size */ + + if (cellWidth < MINCELLSIZE) { + cellWidth = MINCELLSIZE; + cellsWide = width / cellWidth; + } + + if (cellHeight < MINCELLSIZE) { + cellHeight = MINCELLSIZE; + cellsHigh = width / cellWidth; + } + + /* fill the grid with randomly-generated cells */ + for(i = 0; i < cellsHigh; i++) { + int j; + + /* Each row is a different color, randomly generated (but constrained) */ + if (!mono_p) + { + int c = genNewColor(); + XSetForeground(dpy, fg_gc, colors[c].pixel); + } + + for(j = 0; j < cellsWide; j++) { + int curWidth, curHeight, curX, curY; + + /* Generate a random height for a rectangle and make sure that */ + /* it's above a certain minimum size */ + curHeight = random() % (cellHeight - shadowWidth); + if (curHeight < MINRECTSIZE) + curHeight = MINRECTSIZE; + /* Generate a random width for a rectangle and make sure that + it's above a certain minimum size */ + curWidth = random() % (cellWidth - shadowWidth); + if (curWidth < MINRECTSIZE) + curWidth = MINRECTSIZE; + /* Figure out a random place to locate the rectangle within the + cell */ + curY = (i * cellHeight) + (random() % ((cellHeight - curHeight) - + shadowWidth)); + curX = (j * cellWidth) + (random() % ((cellWidth - curWidth) - + shadowWidth)); + + /* Draw the shadow */ + if (elevation > 0) + XFillRectangle(dpy, window, shadow_gc, + curX + elevation, curY + elevation, + curWidth, curHeight); + + /* Draw the edge */ + if (shadowWidth > 0) + XFillRectangle(dpy, window, bg_gc, + curX + shadowWidth, curY + shadowWidth, + curWidth, curHeight); + + XFillRectangle(dpy, window, fg_gc, curX, curY, curWidth, curHeight); + + /* Draw a 1-pixel black border around the rectangle */ + XDrawRectangle(dpy, window, bg_gc, curX, curY, curWidth, curHeight); + } + + } +} + + +/** + * genNewColor returns a new color, gradually mutating the colors and + * occasionally returning a totally random color, just for variety. + * + * @return the new color + **/ +static int genNewColor(void) +{ + /* These lines handle "sway", or the gradual random changing of */ + /* colors. After genNewColor() has been called a given number of */ + /* times (specified by a random permutation of the tweak variable), */ + /* take whatever color has been most recently randomly generated and */ + /* make it the new base color. */ + if (timeLeft == 0) { + timeLeft = c_tweak(sway, sway / 3); + curColor = curBase; + } else { + timeLeft--; + } + + /* If a randomly generated number is less than the threshold value, + produce a "sport" color value that is completely unrelated to the + current palette. */ + if (0 == (random() % THRESHOLD)) { + return (random() % ncolors); + } else { + curBase = genConstrainedColor(curColor, tweak); + return curBase; + } + +} + +/** + * genConstrainedColor creates a random new color within a certain + * range of an existing color. Right now this works with RGB color + * values, but a future version of the program will most likely use HSV + * colors, which should generate a more pleasing progression of values. + * + * @param base the color on which the new color will be based + * @param tweak the amount that the new color can be tweaked + * @return a new constrained color + * @see #genNewColor + **/ +static int genConstrainedColor(int base, int tweak) +{ + int i = 1 + (random() % tweak); + if (random() & 1) + i = -i; + i = (base + i) % ncolors; + while (i < 0) + i += ncolors; + return i; +} + +/** + * Utility function to generate a tweaked color value + * + * @param base the byte value on which the color is based + * @param tweak the amount the value will be skewed + * @see #tweak + * @return the tweaked byte + **/ +static int c_tweak(int base, int tweak) +{ + int ranTweak = (random() % (2 * tweak)); + int n = (base + (ranTweak - tweak)); + if (n < 0) n = -n; + return (n < 255 ? n : 255); +} diff --git a/hacks/decayscreen.c b/hacks/decayscreen.c new file mode 100644 index 00000000..ebcecfbc --- /dev/null +++ b/hacks/decayscreen.c @@ -0,0 +1,212 @@ +/* xscreensaver, Copyright (c) 1992, 1993, 1994, 1996, 1997 + * 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. + */ + +/* 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 + * 5-AUG-1993 + * + * Hacked by jwz, 28-Nov-97 (sped up and added new motion directions) + */ + +#include "screenhack.h" + +static int sizex, sizey; +static int delay; +static GC gc; +static int mode; + +#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 + + +static void +init_decay (Display *dpy, Window window) +{ + XGCValues gcv; + XWindowAttributes xgwa; + long gcflags; + + char *s = get_string_resource("mode", "Mode"); + if (s && !strcmp(s, "shuffle")) mode = SHUFFLE; + else if (s && !strcmp(s, "up")) mode = UP; + else if (s && !strcmp(s, "left")) mode = LEFT; + else if (s && !strcmp(s, "right")) mode = RIGHT; + else if (s && !strcmp(s, "down")) mode = DOWN; + else if (s && !strcmp(s, "upleft")) mode = UPLEFT; + else if (s && !strcmp(s, "downleft")) mode = DOWNLEFT; + else if (s && !strcmp(s, "upright")) mode = UPRIGHT; + else if (s && !strcmp(s, "downright")) mode = DOWNRIGHT; + else if (s && !strcmp(s, "in")) mode = IN; + else if (s && !strcmp(s, "out")) mode = OUT; + else { + if (s && *s && !!strcmp(s, "random")) + fprintf(stderr, "%s: unknown mode %s\n", progname, s); + mode = random() % (OUT+1); + } + + delay = get_integer_resource ("delay", "Integer"); + + if (delay < 0) delay = 0; + + XGetWindowAttributes (dpy, window, &xgwa); + + gcv.function = GXcopy; + gcv.subwindow_mode = IncludeInferiors; + gcflags = GCForeground |GCFunction; + if (use_subwindow_mode_p(xgwa.screen, window)) /* see grabscreen.c */ + gcflags |= GCSubwindowMode; + gc = XCreateGC (dpy, window, gcflags, &gcv); + + sizex = xgwa.width; + sizey = xgwa.height; + + grab_screen_image (xgwa.screen, window); +} + + +/* + * perform one iteration of decay + */ +static void +decay1 (Display *dpy, Window window) +{ + 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; + + switch (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(); + } + +#define nrnd(x) (random() % (x)) + + left = nrnd(sizex - 1); + top = nrnd(sizey); + width = nrnd(sizex - left); + height = nrnd(sizey - top); + + toleft = left; + totop = top; + + if (mode == IN || mode == OUT) { + int x = left+(width/2); + int y = top+(height/2); + int cx = sizex/2; + int cy = sizey/2; + if (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[random() % (sizeof(no_bias)/sizeof(*no_bias))]) { + case L: toleft = left-1; break; + case R: toleft = left+1; break; + case U: totop = top-1; break; + case D: totop = top+1; break; + default: abort(); break; + } + + XCopyArea (dpy, window, window, gc, left, top, width, height, + toleft, totop); +#undef nrnd +} + + +char *progclass = "DecayScreen"; + +char *defaults [] = { + "*dontClearRoot: True", + +#ifdef __sgi /* really, HAVE_READ_DISPLAY_EXTENSION */ + "*visualID: Best", +#endif + + "*delay: 10000", + "*mode: random", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-mode", ".mode", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_decay (dpy, window); + while (1) { + int i; + for (i = 0; i < 100; i++) + decay1 (dpy, window); + XSync(dpy, False); + if (delay) usleep (delay); + } +} diff --git a/hacks/decayscreen.man b/hacks/decayscreen.man new file mode 100644 index 00000000..b5493c7b --- /dev/null +++ b/hacks/decayscreen.man @@ -0,0 +1,86 @@ +.TH XScreenSaver 1 "24-Nov-97" "X Version 11" +.SH NAME +decayscreen - make a screen meltdown. +.SH SYNOPSIS +.B decayscreen +[\-display \fIhost:display.screen\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-delay \fIusecs\fP] [\-mode \fImode\fP] +.SH DESCRIPTION +The \fIdecayscreen\fP program creates a melting effect by randomly +shifting rectangles around the screen. +.SH OPTIONS +.I decayscreen +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fImicroseconds\fP +Slow it down. +.TP 8 +.B \-mode \fImode\fP +The direction in which the image should tend to slide. Legal values are +\fIrandom\fP (meaning pick one), \fIup\fP, \fIleft\fP, \fIright\fP, +\fIdown\fP, \fIupleft\fP, \fIdownleft\fP, \fIupright\fP, \fIdownright\fP, +\fIshuffle\fP (meaning perfer no particular direction), \fIin\fP (meaning +move things toward the center), and \fIout\fP (meaing move things away +from the center). +.SH RESOURCES +On some systems (currently, only SGIs), this program can, instead of grabbing +a desktop image, grab a frame of video from an external camera and manipulate +that instead. The following resources control that. +.PP +.TP 8 +.B grabVideoProbability \fR(Float)\fP +What portion of the time to grab video rather than a screen image, +between 0.0 and 1.0. Defaults to 0.5, or half the time. +.TP 8 +.B videoDevice \fR(Integer)\fP +The number of the default video input device to check first. If unspecified, +the default camera (from videopanel(1)) will be checked first. After that, all +other available video input devices will be checked in order. + +The first one which produces a non-black image will be used. If all images +are black, the others will be re-checked a few times before giving up and +falling back to simply grabbing a desktop image (but note that this takes a +few seconds, so if you don't actually have any video sources hooked up, you +should consider turning off video grabbing by setting +\fBgrabVideoProbability\fP to 0.0.) +.TP 8 +.B videoGain \fR(Float)\fP +The amount by which to brighten the grabbed image. This defaults to 2.2. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH "SEE ALSO" +X(1), +xscreensaver(1) +.SH COPYRIGHT +Copyright 1992 by Vivek Khera. 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. +.SH AUTHOR +Vivek Khera , 05-Aug-93; based on code by David Wald, 1988. +Modified by jwz, 28-Nov-97. diff --git a/hacks/deco.c b/hacks/deco.c new file mode 100644 index 00000000..bd9e62d8 --- /dev/null +++ b/hacks/deco.c @@ -0,0 +1,152 @@ +/* xscreensaver, Copyright (c) 1997 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. + * + * Concept snarfed from Michael D. Bayne in + * http://www.go2net.com/internet/deep/1997/04/16/body.html + */ + +#include "screenhack.h" +#include + +static XColor colors[255]; +static int ncolors = 0; +static int max_depth = 0; +static int min_height = 0; +static int min_width = 0; + +static void +deco (Display *dpy, + Window window, + Colormap cmap, + GC fgc, GC bgc, + int x, int y, int w, int h, int depth) +{ + if (((random() % max_depth) < depth) || (w < min_width) || (h < min_height)) + { + if (!mono_p) + { + static int current_color = 0; + if (++current_color >= ncolors) + current_color = 0; + XSetForeground(dpy, bgc, colors[current_color].pixel); + } + XFillRectangle (dpy, window, bgc, x, y, w, h); + XDrawRectangle (dpy, window, fgc, x, y, w, h); + } + else + { + if (random() & 1) + { + deco (dpy, window, cmap, fgc, bgc, x, y, w/2, h, depth+1); + deco (dpy, window, cmap, fgc, bgc, x+w/2, y, w/2, h, depth+1); + } + else + { + deco (dpy, window, cmap, fgc, bgc, x, y, w, h/2, depth+1); + deco (dpy, window, cmap, fgc, bgc, x, y+h/2, w, h/2, depth+1); + } + } +} + + +char *progclass = "Deco"; + +char *defaults [] = { + "Deco.background: black", /* to placate SGI */ + "Deco.foreground: white", + "*maxDepth: 12", + "*minWidth: 20", + "*minHeight: 20", + "*cycle: False", + "*delay: 5", + "*cycleDelay: 1000000", + "*ncolors: 64", + 0 +}; + +XrmOptionDescRec options [] = { + { "-max-depth", ".maxDepth", XrmoptionSepArg, 0 }, + { "-min-width", ".minWidth", XrmoptionSepArg, 0 }, + { "-min-height", ".minHeight", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-ncolors", ".ncolors", XrmoptionSepArg, 0 }, + { "-cycle", ".cycle", XrmoptionNoArg, "True" }, + { "-no-cycle", ".cycle", XrmoptionNoArg, "False" }, + { "-cycle-delay", ".cycleDelay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + GC fgc, bgc; + XGCValues gcv; + XWindowAttributes xgwa; + int delay = get_integer_resource ("delay", "Integer"); + int cycle_delay = get_integer_resource ("cycleDelay", "Integer"); + Bool writable = get_boolean_resource ("cycle", "Boolean"); + + max_depth = get_integer_resource ("maxDepth", "Integer"); + if (max_depth < 1) max_depth = 1; + else if (max_depth > 1000) max_depth = 1000; + + min_width = get_integer_resource ("minWidth", "Integer"); + if (min_width < 2) min_width = 2; + min_height = get_integer_resource ("minHeight", "Integer"); + if (min_height < 2) min_height = 2; + + XGetWindowAttributes (dpy, window, &xgwa); + + gcv.foreground = get_pixel_resource("foreground", "Foreground", + dpy, xgwa.colormap); + fgc = XCreateGC (dpy, window, GCForeground, &gcv); + + gcv.foreground = get_pixel_resource("background", "Background", + dpy, xgwa.colormap); + bgc = XCreateGC (dpy, window, GCForeground, &gcv); + + ncolors = get_integer_resource ("ncolors", "Integer"); + + make_random_colormap (dpy, xgwa.visual, xgwa.colormap, colors, &ncolors, + False, True, &writable, True); + + if (ncolors <= 2) + mono_p = True; + + if (!mono_p) + { + GC tmp = fgc; + fgc = bgc; + bgc = tmp; + } + + while (1) + { + XGetWindowAttributes (dpy, window, &xgwa); + XFillRectangle(dpy, window, bgc, 0, 0, xgwa.width, xgwa.height); + deco (dpy, window, xgwa.colormap, fgc, bgc, + 0, 0, xgwa.width, xgwa.height, 0); + XSync (dpy, True); + + if (!delay) continue; + if (!writable) + sleep (delay); + else + { + time_t start = time((time_t) 0); + while (start - delay < time((time_t) 0)) + { + rotate_colors (dpy, xgwa.colormap, colors, ncolors, 1); + if (cycle_delay) + usleep (cycle_delay); + } + } + } +} diff --git a/hacks/deco.man b/hacks/deco.man new file mode 100644 index 00000000..e9f61c54 --- /dev/null +++ b/hacks/deco.man @@ -0,0 +1,72 @@ +.TH XScreenSaver 1 "27-Apr-97" "X Version 11" +.SH NAME +deco - draw tacky 70s basement wall panelling +.SH SYNOPSIS +.B deco +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-delay \fIseconds\fP] [\-max\-depth \fIint\fP] [\-min\-width \fIint\fP] [\-min\-height \fIint\fP] [\-cycle] [\-no\-cycle] [\-cycle\-delay] +.SH DESCRIPTION +The \fIdeco\fP program subdivides and colors rectangles randomly. +It looks kind of like Brady-Bunch-era rec-room wall paneling. +(Raven says: "this screensaver is ugly enough to peel paint.") +.SH OPTIONS +.I deco +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fIseconds\fP +How long to wait before starting over. Default 5 seconds. +.TP 8 +.B \-max\-depth \fIinteger\fP +How deep to subdivide. Default 12. +Default 8. +.TP 8 +.B \-min-width \fIinteger\fP +.B \-min-height \fIinteger\fP +The size of the smallest rectangle to draw. Default 20x20. +.TP 8 +.B \-cycle +.TP 8 +.B \-no\-cycle +Whether to do color cycling. Default False. +.TP 8 +.B \-cycle\-delay \fIusecs\fP +If color cycling, how often to change the colors. Default 1000000, +or 1 second. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 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. +.SH AUTHOR +Jamie Zawinski , 26-Apr-97, based on code by +Michael D. Bayne . diff --git a/hacks/drift.c b/hacks/drift.c new file mode 100644 index 00000000..a9995832 --- /dev/null +++ b/hacks/drift.c @@ -0,0 +1,630 @@ +/* -*- Mode: C; tab-width: 4 -*- + * drift --- drifting recursive fractal cosmic flames. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)drift.c 4.02 97/04/01 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: jwz@netscape.com: turned into a standalone program. + * 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 "*count: 30 \n" \ + "*delay: 10000 \n" \ + "*ncolors: 200 \n" +# define SMOOTH_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include "erase.h" +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + + +#define MAXBATCH1 200 /* mono */ +#define MAXBATCH2 20 /* color */ +#define FUSE 10 /* discard this many initial iterations */ +#define NMAJORVARS 7 +#define MAXLEV 10 + +#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 = { 4, opts, 2, vars, desc }; + + +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[NUMCOLORS]; + XPoint cpts[NUMCOLORS][MAXBATCH2]; + + double x, y, c; + int liss_time; + Bool grow, liss; +} driftstruct; + +static driftstruct *drifts = NULL; + +static short +halfrandom(int mv) +{ + static short lasthalf = 0; + unsigned long r; + + if (lasthalf) { + r = lasthalf; + lasthalf = 0; + } else { + r = LRAND(); + lasthalf = r >> 16; + } + r = r % mv; + return r; +} + +static int +frandom(int n) +{ + static long saved_random_bits = 0; + static int nbits = 0; + int result; + + if (3 > nbits) { + saved_random_bits = LRAND(); + nbits = 31; + } + switch (n) { + case 2: + result = saved_random_bits & 1; + saved_random_bits >>= 1; + nbits -= 1; + return result; + + case 3: + result = saved_random_bits & 3; + saved_random_bits >>= 2; + nbits -= 2; + if (3 == result) + return frandom(3); + return result; + + case 4: + result = saved_random_bits & 3; + saved_random_bits >>= 2; + nbits -= 2; + return result; + + case 5: + result = saved_random_bits & 7; + saved_random_bits >>= 3; + nbits -= 3; + if (4 < result) + return frandom(5); + return result; + default: + (void) fprintf(stderr, "bad arg to frandom\n"); + exit(1); + } + return 0; +} + +#define DISTRIB_A (halfrandom(7000) + 9000) +#define DISTRIB_B ((frandom(3) + 1) * (frandom(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(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(8)) { + dp->nfractals = halfrandom(30) + 5; + dp->fractal_len = DISTRIB_A; + } else { + dp->nfractals = halfrandom(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_BATCHCOUNT(mi)) / 20; + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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(1000) / 500.0 - 1.0); + r += dp->df[j][k][i] * dp->df[j][k][i]; + } + r = (3 + halfrandom(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->rainbow) + for (i = 0; i < MI_NPIXELS(mi); i++) + dp->ncpoints[i] = 0; + else + dp->npoints = 0; + dp->nxforms = halfrandom(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(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(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(1000) / 500.0 - 1.0); + } + } + if (dp->color) + dp->pixcol = MI_PIXEL(mi, halfrandom(MI_NPIXELS(mi))); + else + dp->pixcol = MI_WIN_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_WIN_WIDTH(mi); + dp->height = MI_WIN_HEIGHT(mi); + dp->color = MI_NPIXELS(mi) > 2; + + if (MI_WIN_IS_FULLRANDOM(mi)) { +#if 1 /* jwz: even up the odds */ + switch ((int) (LRAND() % 3)) { + case 0: dp->grow = True; dp->liss = False; break; + case 1: dp->grow = False; dp->liss = True; break; + default: dp->grow = False; dp->liss = False; break; + /* liss and grow don't work together. */ + } +#else /* 0 */ + if (LRAND() & 1) + dp->grow = True; + else { + dp->grow = False; + dp->liss = (Bool) (LRAND() & 1); + } +#endif + } 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->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(1000) / 500.0 - 1.0; + ny = halfrandom(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][n].x = fixed_x; + dp->cpts[c][n].y = fixed_y; + if (++dp->ncpoints[c] == MAXBATCH2) { + XSetForeground(display, gc, MI_PIXEL(mi, c)); + XDrawPoints(display, d, gc, dp->cpts[c], + 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], + 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; + + 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) { +#ifdef STANDALONE + XSync(MI_DISPLAY(mi), False); + sleep(4); /* #### make settable */ + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif /* STANDALONE */ + initmode(mi, frandom(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) { + (void) free((void *) drifts); + drifts = NULL; + } +} + +void +refresh_drift(ModeInfo * mi) +{ + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); +} diff --git a/hacks/drift.man b/hacks/drift.man new file mode 100644 index 00000000..5cc69775 --- /dev/null +++ b/hacks/drift.man @@ -0,0 +1,75 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +drift - draws drifting recursive fractal cosmic flames +.SH SYNOPSIS +.B drift +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-count \fIinteger\fP] [\-grow] [\-no\-grow] [\-liss] [\-no\-liss] + +.SH DESCRIPTION +The \fIdrift\fP program draws drifting recursive fractal cosmic flames +.SH OPTIONS +.I drift +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-grow +.TP 8 +.B \-no\-grow +Whether fractals should grow; otherwise, they are animated. + +.TP 8 +.B \-liss +.TP 8 +.B \-no\-liss +Whether we should use lissojous figures to get points. + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR flame (1), +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1991, 1995 by Scott Draves. + +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. +.SH AUTHOR +Scott Draves , 06-Jun-91, 01-Jun-95. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/fadeplot.c b/hacks/fadeplot.c new file mode 100644 index 00000000..5b715522 --- /dev/null +++ b/hacks/fadeplot.c @@ -0,0 +1,177 @@ +/* -*- Mode: C; tab-width: 4 -*- + * fadeplot.c --- some easy plotting stuff, by Bas van Gaalen, Holland, PD + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)fadeplot.c 4.04 97/07/26 xlockmore"; +#endif + +/* Converted for xlock by Charles Vidal + * See xlock.c for copying information. + * + * 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. + */ + +/*- + 1) Not random enough, i.e. always same starting position. + 2) Needs to be less flashy + */ + +#ifdef STANDALONE +# define PROGCLASS "Fadeplot" +# define HACK_INIT init_fadeplot +# define HACK_DRAW draw_fadeplot +# define fadeplot_opts xlockmore_opts +# define DEFAULTS "*count: 10 \n" \ + "*delay: 30000 \n" \ + "*cycles: 1500 \n" \ + "*ncolors: 64 \n" +# define BRIGHT_COLORS +# define UNIFORM_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* STANDALONE */ + +ModeSpecOpt fadeplot_opts = { + 0, NULL, 0, NULL, NULL }; + +#define MINSTEPS 1 +#define ANGLES 1000 + +typedef struct { + XPoint speed, step, factor, st; + int temps, maxpts, nbstep; + int min; + int width, height; + int pix; + int stab[ANGLES]; + XPoint *pts; +} fadeplotstruct; + +static fadeplotstruct *fadeplots = NULL; + +static void +initSintab(ModeInfo * mi) +{ + fadeplotstruct *fp = &fadeplots[MI_SCREEN(mi)]; + int i; + float x; + + for (i = 0; i < ANGLES; i++) { + x = SINF(i * 2 * M_PI / 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_WIN_WIDTH(mi); + fp->height = MI_WIN_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_BATCHCOUNT(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)); + + initSintab(mi); + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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; + long temp; + + XSetForeground(display, gc, MI_WIN_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_WIN_WHITE_PIXEL(mi)); + + for (temp = fp->nbstep - 1; temp >= 0; temp--) { + j = temp; + for (i = 0; i < fp->maxpts / fp->nbstep; i++) { + fp->pts[temp * i + i].x = + fp->stab[(fp->st.x + fp->speed.x * j + i * fp->step.x) % ANGLES] * + fp->factor.x + fp->width / 2 - fp->min; + fp->pts[temp * i + i].y = + fp->stab[(fp->st.y + fp->speed.y * j + i * fp->step.y) % ANGLES] * + fp->factor.y + fp->height / 2 - fp->min; + } + } + XDrawPoints(display, window, gc, fp->pts, fp->maxpts, CoordModeOrigin); + XFlush(display); + fp->st.x = (fp->st.x + fp->speed.x) % ANGLES; + fp->st.y = (fp->st.y + fp->speed.y) % ANGLES; + fp->temps++; + if ((fp->temps % (ANGLES / 2)) == 0) { + fp->temps = fp->temps % ANGLES * 5; + if ((fp->temps % (ANGLES)) == 0) + fp->speed.y = (fp->speed.y++) % 30 + 1; + if ((fp->temps % (ANGLES * 2)) == 0) + fp->speed.x = (fp->speed.x) % 20; + if ((fp->temps % (ANGLES * 3)) == 0) + fp->step.y = (fp->step.y++) % 2 + 1; + XClearWindow(display, window); + } +} +void +refresh_fadeplot(ModeInfo * mi) +{ + +} + +void +release_fadeplot(ModeInfo * mi) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/flag.c b/hacks/flag.c new file mode 100644 index 00000000..643aff10 --- /dev/null +++ b/hacks/flag.c @@ -0,0 +1,597 @@ +/* -*- Mode: C; tab-width: 4 -*- + * flag --- a waving flag + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)flag.c 4.02 97/04/01 xlockmore"; +#endif + +/* Copyright (c) 1996 Charles Vidal . + * PEtite demo X11 de charles vidal 15 05 96 + * tourne sous Linux et SOLARIS + * thank's to Bas van Gaalen, Holland, PD, for his sources + * in pascal vous devez rajouter une ligne dans mode.c + * + * 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-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.) + * 13-May-97: jwz@netscape.com: turned into a standalone program. + * Made it able to animate arbitrary (runtime) text or bitmaps. + * 01-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" +# define BRIGHT_COLORS +# define UNIFORM_COLORS +# define DEF_FONT "-*-helvetica-bold-r-*-240-*" +# define DEF_BITMAP "" +# define DEF_TEXT "" +# include "xlockmore.h" /* from the xscreensaver distribution */ + +# ifdef HAVE_XPM +# include +# ifndef PIXEL_ALREADY_TYPEDEFED +# define PIXEL_ALREADY_TYPEDEFED /* Sigh, Xmu/Drawing.h needs this... */ +# endif +# endif + +#ifdef HAVE_XMU +# ifndef VMS +# include +# else /* VMS */ +# include +# endif /* VMS */ +#endif /* HAVE_XMU */ + +#include "images/bob.xbm" + +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +# include "flag.h" +#endif /* !STANDALONE */ + + +#if defined(VMS) && !defined(HAVE_UNAME) && (__VMS_VER >= 70000000) +# define HAVE_UNAME 1 +#endif + +#ifdef HAVE_UNAME +# include +#endif /* HAVE_UNAME */ + +#ifdef STANDALONE +static XrmOptionDescRec opts[] = +{ + { "-bitmap", ".flag.bitmap", XrmoptionSepArg, 0 } +}; + +#endif /* STANDALONE */ + +ModeSpecOpt flag_opts = { +#ifdef STANDALONE + 1, opts, 0, NULL, NULL +#else /* !STANDALONE */ + 0, NULL, 0, NULL, NULL +#endif /* STANDALONE */ +}; + +#include +#include + +#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) +#define MAXH(fp) (MAXSCALE * (fp)->image->height+ 2 * MAXAMP + (fp)->pointsize) +#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 + +typedef struct { + int samp; + int sofs; + int sidx; + int x_flag, y_flag; + int timer; + int initialized; + int stab[ANGLES]; + Pixmap cache; + int width, height; + int pointsize; + float size; + float inctaille; + int startcolor; + XImage *image; +} flagstruct; + +static flagstruct *flags = NULL; + +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;istab[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 (fp->image->depth > 1) + XSetForeground(display, MI_GC(mi), + XGetPixel(fp->image, x, y)); + else if (XGetPixel(fp->image, x, y)) + XSetForeground(display, MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + else if (MI_NPIXELS(mi) <= 2) + XSetForeground(display, MI_GC(mi), MI_WIN_WHITE_PIXEL(mi)); + else + XSetForeground(display, MI_GC(mi), + MI_PIXEL(mi, (y + x + fp->sidx + fp->startcolor) % MI_NPIXELS(mi))); + + if (fp->pointsize <= 1) + XDrawPoint(display, fp->cache, MI_GC(mi), xp, yp); + else if (fp->pointsize < 6) + XFillRectangle(display, fp->cache, MI_GC(mi), xp, yp, + fp->pointsize, fp->pointsize); + else + XFillArc(display, fp->cache, MI_GC(mi), xp, yp, + fp->pointsize, fp->pointsize, 0, 360*64); + } +} + +#ifdef STANDALONE + +static void +make_flag_bits(ModeInfo *mi) +{ + Display *dpy = MI_DISPLAY(mi); + flagstruct *fp = &flags[MI_SCREEN(mi)]; + char *bitmap_name = get_string_resource ("bitmap", "Bitmap"); + char *text = get_string_resource ("text", "Text"); + + /* If neither a bitmap nor text are specified, randomly select either + the builtin bitmap or builtin text. */ + if ((!bitmap_name || !*bitmap_name) && (!text || !*text)) + { + if (random() & 1) + { + free(bitmap_name); + bitmap_name = strdup("(default)"); + } + else + { + free(text); + text = strdup("(default)"); + } + } + + if (bitmap_name && + *bitmap_name && + !!strcmp(bitmap_name, "(default)")) + { +#ifdef HAVE_XPM + Window window = MI_WINDOW(mi); + XWindowAttributes xgwa; + XpmAttributes xpmattrs; + int result; + Pixmap bitmap = 0; + int width = 0, height = 0; + xpmattrs.valuemask = 0; + + XGetWindowAttributes (dpy, window, &xgwa); + +# ifdef XpmCloseness + xpmattrs.valuemask |= XpmCloseness; + xpmattrs.closeness = 40000; +# endif +# ifdef XpmVisual + xpmattrs.valuemask |= XpmVisual; + xpmattrs.visual = xgwa.visual; +# endif +# ifdef XpmDepth + xpmattrs.valuemask |= XpmDepth; + xpmattrs.depth = xgwa.depth; +# endif +# ifdef XpmColormap + xpmattrs.valuemask |= XpmColormap; + xpmattrs.colormap = xgwa.colormap; +# endif + + /* Uh, we don't need these now. We use the colors from the xpm. + It kinda sucks that we already allocated them. */ + XFreeColors(dpy, xgwa.colormap, mi->pixels, mi->npixels, 0L); + + result = XpmReadFileToPixmap (dpy, window, bitmap_name, &bitmap, 0, + &xpmattrs); + switch (result) + { + case XpmColorError: + fprintf (stderr, "%s: warning: xpm color substitution performed\n", + progname); + /* fall through */ + case XpmSuccess: + width = xpmattrs.width; + height = xpmattrs.height; + break; + case XpmFileInvalid: + case XpmOpenFailed: + bitmap = 0; + break; + case XpmColorFailed: + fprintf (stderr, "%s: xpm: color allocation failed\n", progname); + exit (-1); + case XpmNoMemory: + fprintf (stderr, "%s: xpm: out of memory\n", progname); + exit (-1); + default: + fprintf (stderr, "%s: xpm: unknown error code %d\n", progname, + result); + exit (-1); + } + + if (bitmap) + { + fp->image = XGetImage(dpy, bitmap, 0, 0, width, height, ~0L, + ZPixmap); + XFreePixmap(dpy, bitmap); + } + else +#endif /* HAVE_XPM */ + +#ifdef HAVE_XMU + { + int width, height, xh, yh; + Pixmap bitmap = + XmuLocateBitmapFile (DefaultScreenOfDisplay (dpy), + bitmap_name, 0, 0, &width, &height, &xh, &yh); + if (!bitmap) + { + fprintf(stderr, "%s: unable to load bitmap file %s\n", + progname, bitmap_name); + exit (1); + } + fp->image = XGetImage(dpy, bitmap, 0, 0, width, height, + 1L, XYPixmap); + XFreePixmap(dpy, bitmap); + } + +#else /* !XMU */ + fprintf (stderr, + "%s: your vendor doesn't ship the standard Xmu library.\n", + progname); + fprintf (stderr, "\tWe can't load XBM files without it.\n"); + exit (1); +#endif /* !XMU */ + + } + else if (text && *text) + { + char *text2; + char *fn = get_string_resource ("font", "Font"); + char *def_fn = "fixed"; + char *line, *token; + int width, height; + int lines; + int margin = 2; + int fg = 1; + int bg = 0; + Pixmap bitmap; + XFontStruct *font; + XCharStruct overall; + XGCValues gcv; + GC gc; + + if (!strcmp(text, "(default)")) + { +# ifdef HAVE_UNAME + struct utsname uts; + if (uname (&uts) < 0) + { + text = strdup("uname() failed"); + } + else + { + char *s; + if ((s = strchr(uts.nodename, '.'))) + *s = 0; + text = (char *) malloc(strlen(uts.nodename) + + strlen(uts.sysname) + + strlen(uts.release) + 10); + sprintf(text, "%s\n%s %s", + uts.nodename, uts.sysname, uts.release); + } +#else /* !HAVE_UNAME */ +# ifdef VMS + text = strdup(getenv("SYS$NODE")); +# else + text = strdup("X\nScreen\nSaver"); +# endif +#endif /* !HAVE_UNAME */ + } + + while (*text && + (text[strlen(text)-1] == '\r' || + text[strlen(text)-1] == '\n')) + text[strlen(text)-1] = 0; + + text2 = strdup(text); + + if (!fn) fn = def_fn; + font = XLoadQueryFont (dpy, fn); + if (! font) + { + fprintf(stderr, "%s: unable to load font %s; using %s\n", + progname, fn, def_fn); + font = XLoadQueryFont (dpy, def_fn); + } + + memset(&overall, 0, sizeof(overall)); + token = text; + lines = 0; + while ((line = strtok(token, "\r\n"))) + { + XCharStruct o2; + int ascent, descent, direction; + token = 0; + XTextExtents(font, 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 = ((font->ascent + font->descent) * lines) + margin + margin; + + bitmap = XCreatePixmap(dpy, MI_WINDOW(mi), width, height, 1); + + gcv.font = font->fid; + gcv.foreground = bg; + gc = XCreateGC (dpy, bitmap, (GCFont | GCForeground), &gcv); + XFillRectangle(dpy, bitmap, gc, 0, 0, width, height); + XSetForeground(dpy, gc, fg); + + token = text2; + lines = 0; + while ((line = strtok(token, "\r\n"))) + { + XCharStruct o2; + int ascent, descent, direction, xoff; + token = 0; + + XTextExtents(font, line, strlen(line), + &direction, &ascent, &descent, &o2); + xoff = ((overall.lbearing + overall.rbearing) - + (o2.lbearing + o2.rbearing)) / 2; + + XDrawString(dpy, bitmap, gc, + overall.lbearing + margin + xoff, + ((font->ascent * (lines + 1)) + + (font->descent * lines) + + margin), + line, strlen(line)); + lines++; + } + free(text2); + XUnloadFont(dpy, font->fid); + XFree((XPointer) font); + XFreeGC(dpy, gc); + + fp->image = XGetImage(dpy, bitmap, 0, 0, width, height, 1L, XYPixmap); + XFreePixmap(dpy, bitmap); + } + else + { + fp->image = XCreateImage (dpy, MI_VISUAL(mi), 1, XYBitmap, 0, + (char *) bob_bits, bob_width, bob_height, + 8, 0); + fp->image->byte_order = LSBFirst; + fp->image->bitmap_bit_order = LSBFirst; + } + + if (bitmap_name) + free (bitmap_name); + if (text) + free (text); +} + +#else /* !STANDALONE */ + +static void +make_flag_bits(ModeInfo *mi) +{ + flagstruct *fp = &flags[MI_SCREEN(mi)]; + int x, y; + int w = flag_width; + int h = flag_height; + int i = 0; + fp->image = + XCreateImage(MI_DISPLAY(mi), MI_VISUAL(mi), + 1, XYBitmap, 0, /* dpth, fmt, offset */ + (char *) calloc ((w+8) / 8, h), /* data */ + w, h, 8, 0); /* w, h, pad, bpl */ + /* Geez, what kinda goofy bit order is this?? */ + for (x = 0; x < w; x++) + for (y = h-1; y >= 0; y--) + XPutPixel (fp->image, x, y, flag_bits[i++]); +} + +#endif /* !STANDALONE */ + + +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)]; + + make_flag_bits(mi); + + fp->width = MI_WIN_WIDTH(mi); + fp->height = MI_WIN_HEIGHT(mi); + + 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->initialized) { + fp->initialized = True; + if (!(fp->cache = XCreatePixmap(display, MI_WINDOW(mi), + MAXW(fp), MAXH(fp), MI_WIN_DEPTH(mi)))) +#ifdef STANDALONE + exit(-1); +#else /* !STANDALONE */ + error("%s: catastrophe memoire\n"); +#endif /* !STANDALONE */ + } + XSetForeground(display, MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + XFillRectangle(display, fp->cache, MI_GC(mi), + 0, 0, MAXW(fp), MAXH(fp)); + /* don't want any exposure events from XCopyArea */ + XSetGraphicsExposures(display, MI_GC(mi), 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); + + XClearWindow(display, MI_WINDOW(mi)); +} + +void +draw_flag(ModeInfo * mi) +{ + Display *display = MI_DISPLAY(mi); + Window window = MI_WINDOW(mi); + flagstruct *fp = &flags[MI_SCREEN(mi)]; + + if (fp->width <= MAXW(fp) || fp->height <= MAXH(fp)) { + fp->size = MININITSIZE; + /* fp->pointsize = MINPOINTSIZE; */ + XCopyArea(display, fp->cache, window, MI_GC(mi), + 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, MI_GC(mi), + 0, 0, MAXW(fp), MAXH(fp), fp->x_flag, fp->y_flag); + } + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + XFillRectangle(display, fp->cache, MI_GC(mi), + 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++) + { + if (flags[screen].cache) + XFreePixmap(MI_DISPLAY(mi), flags[screen].cache); + if (flags[screen].image) + XDestroyImage(flags[screen].image); + } + (void) free((void *) flags); + flags = NULL; + } +} + +void +refresh_flag(ModeInfo * mi) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/flag.man b/hacks/flag.man new file mode 100644 index 00000000..897a1f25 --- /dev/null +++ b/hacks/flag.man @@ -0,0 +1,88 @@ +.TH XScreenSaver 1 "24-May-97" "X Version 11" +.SH NAME +flag - draws a waving flag, containing text or an image +.SH SYNOPSIS +.B flag +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-size \fIinteger\fP] [\-text \fIstring\fP] [\-font \fIfont\fP] [\-bitmap \fIxbm-file\fP] + +.SH DESCRIPTION +The \fIflag\fP program draws a waving flag that contains text or a bitmap. +.SH OPTIONS +.I flag +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-size \fIinteger\fP +How large the pixels in the flag should be, from 1 to 8. +If this is a negative number, the pixel size is chosen randomly +from the range 1 to -size. Default -7. +.TP 8 +.B \-text \fItext\fP +The text to display in the flag. Multiple lines of text are allowed; +the lines will be displayed centered atop one another. Default: none. +If the text is the magic string \fI"(default)"\fP, then the text used +will be the local machine name; a newline; and the local OS version. +.TP 8 +.B \-bitmap \fIxbm-file\fP +The bitmap to display in the flag; this must be an XBM file (color XPMs +are not allowed.) Default: none. If the bitmap is the magic +string \fI"(default)"\fP, then the bitmap used will be a charming +little picture of J. R. "Bob" Dobbs. + +If neither \fI\-text\fP nor \fI\-bitmap\fP are specified, then either +the builtin text or the builtin bitmap will be chosen randomly. +.TP 8 +.B \-font \fIfont\fP +The font in which to draw the text; the default is +"-*-helvetica-bold-r-*-240-*". +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1996 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. + +.SH AUTHOR +Charles Vidal , 1996. + +Ability to run standalone or with \fIxscreensaver\fP, and the \-text +and \-bitmap options, added by Jamie Zawinski , 24-May-97. diff --git a/hacks/flame.c b/hacks/flame.c new file mode 100644 index 00000000..6b243f59 --- /dev/null +++ b/hacks/flame.c @@ -0,0 +1,409 @@ +/* xscreensaver, Copyright (c) 1993, 1995, 1996 + * 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. + */ + +/* This file was ported from xlock for use in xscreensaver (and standalone) + * by jwz on 18-Oct-93. (And again, 11-May-97.) Original copyright reads: + * + * static char sccsid[] = "@(#)flame.c 1.4 91/09/27 XLOCK"; + * + * flame.c - recursive fractal cosmic flames. + * + * 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. + * + * Comments and additions should be sent to the author: + * + * naughton@eng.sun.com + * + * Patrick J. Naughton + * MS 21-14 + * Sun Laboritories, Inc. + * 2550 Garcia Ave + * Mountain View, CA 94043 + * + * Revision History: + * 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). + */ + +#include +#include "screenhack.h" + +#define POINT_BUFFER_SIZE 10 +#define MAXLEV 4 +#define MAXKINDS 10 + +static double f[2][3][MAXLEV]; /* three non-homogeneous transforms */ +static int max_total; +static int max_levels; +static int max_points; +static int cur_level; +static int variation; +static int snum; +static int anum; +static int num_points; +static int total_points; +static int pixcol; +static int ncolors; +static XColor *colors; +static XPoint points [POINT_BUFFER_SIZE]; +static GC gc; + +static int delay, delay2; +static int width, height; + +static short +halfrandom (int mv) +{ + static short lasthalf = 0; + unsigned long r; + + if (lasthalf) + { + r = lasthalf; + lasthalf = 0; + } + else + { + r = random (); + lasthalf = r >> 16; + } + return (r % mv); +} + +static void +init_flame (Display *dpy, Window window) +{ + XGCValues gcv; + XWindowAttributes xgwa; + Colormap cmap; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + cmap = xgwa.colormap; + + max_points = get_integer_resource ("iterations", "Integer"); + if (max_points <= 0) max_points = 100; + + max_levels = max_points; + + max_total = get_integer_resource ("points", "Integer"); + if (max_total <= 0) max_total = 10000; + + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + delay2 = get_integer_resource ("delay2", "Integer"); + if (delay2 < 0) delay2 = 0; + + variation = random() % MAXKINDS; + + if (mono_p) + ncolors = 0; + else + { + ncolors = get_integer_resource ("colors", "Integer"); + if (ncolors <= 0) ncolors = 128; + colors = (XColor *) malloc ((ncolors+1) * sizeof (*colors)); + make_smooth_colormap (dpy, xgwa.visual, xgwa.colormap, colors, &ncolors, + True, 0, True); + if (ncolors <= 2) + mono_p = True, ncolors = 0; + } + + gcv.foreground = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + gcv.background = get_pixel_resource ("background", "Background", dpy, cmap); + + if (! mono_p) + { + pixcol = halfrandom (ncolors); + gcv.foreground = (colors [pixcol].pixel); + } + + gc = XCreateGC (dpy, window, GCForeground | GCBackground, &gcv); +} + +static int +recurse (double x, double y, int l, Display *dpy, Window win) +{ + int xp, yp, i; + double nx, ny; + + if (l == max_levels) + { + total_points++; + if (total_points > max_total) /* how long each fractal runs */ + return 0; + + if (x > -1.0 && x < 1.0 && y > -1.0 && y < 1.0) + { + xp = points[num_points].x = (int) ((width / 2) * (x + 1.0)); + yp = points[num_points].y = (int) ((height / 2) * (y + 1.0)); + num_points++; + if (num_points >= POINT_BUFFER_SIZE) + { + XDrawPoints (dpy, win, gc, points, num_points, CoordModeOrigin); + num_points = 0; + /* if (delay) usleep (delay); */ + /* XSync (dpy, True); */ + } + } + } + else + { + for (i = 0; i < snum; i++) + { + + /* Scale back when values get very large. Spot sez: + "I think this happens on HPUX. I think it's non-IEEE + to generate an exception instead of a silent NaN." + */ + if ((abs(x) > 1.0E5) || (abs(y) > 1.0E5)) + x = x / y; + + nx = f[0][0][i] * x + f[0][1][i] * y + f[0][2][i]; + ny = f[1][0][i] * x + f[1][1][i] * y + f[1][2][i]; + if (i < anum) + { + switch (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; + double 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 (nx, ny, l + 1, dpy, win)) + return 0; + } + } + return 1; +} + + +static void +flame (Display *dpy, Window window) +{ + int i, j, k; + static int alt = 0; + + if (!(cur_level++ % max_levels)) + { + if (delay2) usleep (delay2); + XClearWindow (dpy, window); + alt = !alt; + + variation = random() % MAXKINDS; + } + else + { + if (ncolors > 2) + { + XSetForeground (dpy, gc, colors [pixcol].pixel); + if (--pixcol < 0) + pixcol = ncolors - 1; + } + } + + /* number of functions */ + snum = 2 + (cur_level % (MAXLEV - 1)); + + /* how many of them are of alternate form */ + if (alt) + anum = 0; + else + anum = halfrandom (snum) + 2; + + /* 6 coefs per function */ + for (k = 0; k < snum; k++) + { + for (i = 0; i < 2; i++) + for (j = 0; j < 3; j++) + f[i][j][k] = ((double) (random() & 1023) / 512.0 - 1.0); + } + num_points = 0; + total_points = 0; + (void) recurse (0.0, 0.0, 0, dpy, window); + XDrawPoints (dpy, window, gc, points, num_points, CoordModeOrigin); + XSync (dpy, True); + if (delay) usleep (delay); +} + + +#ifdef __hpux +/* I don't understand why this is necessary, but I'm told that this program + does nothing at all on HP-sUX without it. + */ +#undef random +#undef srandom +#include +int matherr(x) + register struct exception *x; +{ + if (x->type == PLOSS) return 1; + else return 0; +} +#endif /* __hpux */ + + + +char *progclass = "Flame"; + +char *defaults [] = { + "Flame.background: black", /* to placate SGI */ + "Flame.foreground: white", + "*colors: 64", + "*iterations: 25", + "*delay: 50000", + "*delay2: 2000000", + "*points: 10000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-colors", ".colors", XrmoptionSepArg, 0 }, + { "-iterations", ".iterations", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { "-points", ".points", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_flame (dpy, window); + while (1) + flame (dpy, window); +} diff --git a/hacks/flame.man b/hacks/flame.man new file mode 100644 index 00000000..5c3f7b66 --- /dev/null +++ b/hacks/flame.man @@ -0,0 +1,70 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +flame - draw weird cosmic fractals +.SH SYNOPSIS +.B flame +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-colors \fIinteger\fP] [\-iterations \fIinteger\fP] [\-points \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-delay2 \fImicroseconds\fP] +.SH DESCRIPTION +The \fIflame\fP program generates colorful fractal displays. +.SH OPTIONS +.I flame +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-colors \fIinteger\fP +How many colors should be used (if possible). Default 64. +.TP 8 +.B \-iterations \fIinteger\fP +How many fractals to generate. Default 25. +.TP 8 +.B \-points \fIinteger\fP +How many pixels to draw for each fractal. Default 10000. +.TP 8 +.B \-delay \fImicroseconds\fP +How long we should wait between drawing each fractal. Default 50000, +or about 1/20th second. +.TP 8 +.B \-delay2 \fImicroseconds\fP +How long we should wait before clearing the screen when each run ends. +Default 2000000, or two seconds. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Scott Graves , 06-Jun-91.n + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 18-Oct-93. diff --git a/hacks/forest.c b/hacks/forest.c new file mode 100644 index 00000000..54fe8073 --- /dev/null +++ b/hacks/forest.c @@ -0,0 +1,211 @@ +/* -*- Mode: C; tab-width: 4 -*- + * forest.c --- draw a fractal forest. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)forest.c 4.03 97/05/10 xlockmore"; +#endif + +/* Copyright (c) 1995 Pascal Pensa + * + * Original idea : Guillaume Ramey + * + * 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 "*count: 100 \n" \ + "*cycles: 200 \n" \ + "*delay: 400000 \n" \ + "*ncolors: 100 \n" +# define UNIFORM_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include "erase.h" +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt forest_opts = { + 0, NULL, 0, NULL, NULL }; + + +#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_WIN_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_WIN_WIDTH(mi); + fp->height = MI_WIN_HEIGHT(mi); + fp->time = 0; + + fp->ntrees = MI_BATCHCOUNT(mi); + if (fp->ntrees < -MINTREES) + fp->ntrees = NRAND(-fp->ntrees - MINTREES + 1) + MINTREES; + else if (fp->ntrees < MINTREES) + fp->ntrees = MINTREES; + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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; + + 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_WIN_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)) { +#ifdef STANDALONE + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif /* STANDALONE */ + init_forest(mi); + } +} + +void +release_forest(ModeInfo * mi) +{ + if (forests != NULL) { + (void) free((void *) forests); + forests = NULL; + } +} + +void +refresh_forest(ModeInfo * mi) +{ + foreststruct *fp = &forests[MI_SCREEN(mi)]; + + if (fp->time < fp->ntrees) + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + else + init_forest(mi); +} diff --git a/hacks/forest.man b/hacks/forest.man new file mode 100644 index 00000000..a584cf7b --- /dev/null +++ b/hacks/forest.man @@ -0,0 +1,63 @@ +.TH XScreenSaver 1 "27-May-97" "X Version 11" +.SH NAME +forest - draws a fractal forest +.SH SYNOPSIS +.B forest +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIforest\fP program draws a fractal forest. +.SH OPTIONS +.I forest +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 100. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1995 by Pascal Pensa. + +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. +.SH AUTHOR +Pascal Pensa , 1995. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 27-May-97. diff --git a/hacks/galaxy.c b/hacks/galaxy.c new file mode 100644 index 00000000..0a8694bf --- /dev/null +++ b/hacks/galaxy.c @@ -0,0 +1,469 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* galaxy --- spinning galaxies */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)galaxy.c 4.04 97/07/28 xlockmore"; +#endif + +/* Originally done by Uli Siegmund 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 + * + * + * 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@netscape.com: turned into a standalone program. + * 18-Apr-97: Memory leak fixed by Tom Schmidt + * 07-Apr-97: Modified by Dave Mitchell + * 23-Oct-94: Modified by David Bagley + * 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 + * + */ + +#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" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +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 = { 2, opts, 1, vars, desc }; + + +#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 8 + /* Colors for stars start here */ +#define COLORSTEP (NUMCOLORS/COLORBASE) /* 8 colors per galaxy */ + +#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 = 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_BATCHCOUNT(mi) < -MINGALAXIES) + free_galaxies(gp); + gp->ngalaxies = MI_BATCHCOUNT(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; + + gt->galcol = NRAND(COLORBASE - 2); + if (gt->galcol > 1) + gt->galcol += 2; /* Mult 8; 16..31 no green stars */ + /* 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 = >->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; + } + } + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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_WIN_WIDTH(mi); + gp->clip.bottom = MI_WIN_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 */ + + for (i = 0; i < gp->ngalaxies; ++i) { + Galaxy *gt = &gp->galaxies[i]; + + for (j = 0; j < gp->galaxies[i].nstars; ++j) { + Star *st = >->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) COLORSTEP) + st->color = COLORSTEP * gt->galcol + COLORSTEP - 1; + else + st->color = COLORSTEP * gt->galcol + ((int) d) % COLORSTEP; +#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_WIN_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) > 2) +#ifdef NO_VELOCITY_COLORING + XSetForeground(display, gc, MI_PIXEL(mi, COLORSTEP * gt->galcol)); +#else + XSetForeground(display, gc, MI_PIXEL(mi, st->color)); +#endif + else + XSetForeground(display, gc, MI_WIN_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) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/galaxy.man b/hacks/galaxy.man new file mode 100644 index 00000000..8a4fe4c5 --- /dev/null +++ b/hacks/galaxy.man @@ -0,0 +1,83 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +galaxy - draws spinning galaxies +.SH SYNOPSIS +.B galaxy +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] [\-size \fIinteger\fP] [\-trail] [\-no\-trail] + +.SH DESCRIPTION +The \fIgalaxy\fP program draws spinning galaxies. +.SH OPTIONS +.I galaxy +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-size \fIinteger\fP + +.TP 8 +.B \-trail +.TP 8 +.B \-no\-trail + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1994 by Hubert Feyrer. + +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. +.SH AUTHOR +Original Amiga version by Uli Siegmund + for EGS in Cluster. + +Ported from Cluster/EGS to C/Intuition by Harald Backert. + +Ported to X11 and xlockmore by +Hubert Feyrer , 30-Sep-94. + +Modified by David Bagley , 23-Oct-94. + +Modified by Dave Mitchell , 7-Apr-97. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/glx/Makefile.in b/hacks/glx/Makefile.in new file mode 100644 index 00000000..686223b0 --- /dev/null +++ b/hacks/glx/Makefile.in @@ -0,0 +1,365 @@ +# hacks/glx/Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# the `../../configure' script generates `hacks/glx/Makefile' from this file. + +@SET_MAKE@ +.SUFFIXES: +.SUFFIXES: .c .o + +srcdir = @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 -DUSE_GL @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_LIBS = $(LIBS) $(X_LIBS) $(X_PRE_LIBS) @GL_LIBS@ @HACK_LIBS@ \ + -lXt -lX11 -lXext $(X_EXTRA_LIBS) -lm + +HACK_SRC = $(srcdir)/.. +HACK_BIN = .. +UTILS_SRC = $(HACK_SRC)/../utils +UTILS_BIN = $(HACK_BIN)/../utils + +INCLUDES = -I$(srcdir) -I$(UTILS_SRC) -I$(HACK_SRC) \ + -I$(HACK_SRC)/.. @INCLUDES@ + +UTIL_SRCS = $(UTILS_SRC)/colors.c $(UTILS_SRC)/hsv.c \ + $(UTILS_SRC)/resources.c $(UTILS_SRC)/usleep.c \ + $(UTILS_SRC)/visual.c $(UTILS_SRC)/yarandom.c +UTIL_OBJS = $(UTILS_SRC)/colors.o $(UTILS_SRC)/hsv.o \ + $(UTILS_SRC)/resources.o $(UTILS_SRC)/usleep.o \ + $(UTILS_SRC)/visual.o $(UTILS_SRC)/yarandom.o + +SRCS = buildlwo.c cage.c gears.c moebius.c morph3d.c \ + pipeobjs.c pipes.c rubik.c s1_1.c s1_2.c s1_3.c s1_4.c \ + s1_5.c s1_6.c s1_b.c sproingies.c sproingiewrap.c stairs.c \ + superquadrics.c xlock-gl.c + +OBJS = buildlwo.o cage.o gears.o moebius.o morph3d.o \ + pipeobjs.o pipes.o rubik.o s1_1.o s1_2.o s1_3.o s1_4.o \ + s1_5.o s1_6.o s1_b.o sproingies.o sproingiewrap.o stairs.o \ + superquadrics.o xlock-gl.o + +GL_EXES = cage gears moebius pipes sproingies stairs superquadrics \ + morph3d rubik +EXES = @GL_EXES@ + +HACK_OBJS = screenhack-gl.o xlock-gl.o $(HACK_BIN)/xlockmore.o \ + $(UTILS_BIN)/resources.o $(UTILS_BIN)/visual.o \ + $(UTILS_BIN)/usleep.o $(UTILS_BIN)/yarandom.o \ + $(UTILS_BIN)/hsv.o $(UTILS_BIN)/colors.o + +HDRS = buildlwo.h e_textures.h +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) + + +# 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)/colors.o: $(UTILS_SRC)/colors.c +$(UTILS_BIN)/hsv.o: $(UTILS_SRC)/hsv.c +$(UTILS_BIN)/resources.o: $(UTILS_SRC)/resources.c +$(UTILS_BIN)/usleep.o: $(UTILS_SRC)/usleep.c +$(UTILS_BIN)/visual.o: $(UTILS_SRC)/visual.c +$(UTILS_BIN)/yarandom.o: $(UTILS_SRC)/yarandom.c + +$(UTIL_OBJS): + cd $(UTILS_BIN) ; \ + $(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" + +$(HACK_BIN)/xlockmore.o: $(HACK_SRC)/xlockmore.c + cd $(HACK_BIN) ; $(MAKE) $(@F) CC="$(CC)" CFLAGS="$(CFLAGS)" + + +# How we build object files in this directory. +.c.o: + $(CC) -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) $< + +# These hacks use a slightly-differently-compiled variant of screenhack.c. +# This is how to make the the other .o file from it. +# +screenhack-gl.o: $(HACK_SRC)/screenhack.c + $(CC) -o $@ -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) \ + -DXLOCKMORE -DUSE_GL $(HACK_SRC)/screenhack.c + +CC_HACK = $(CC) $(LDFLAGS) + +cage: cage.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +gears: gears.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +moebius: moebius.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +pipes: pipes.o $(HACK_OBJS) pipeobjs.o buildlwo.o + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) pipeobjs.o buildlwo.o \ + $(HACK_LIBS) + +superquadrics: superquadrics.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +morph3d: morph3d.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +rubik: rubik.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +stairs: stairs.o $(HACK_OBJS) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS) + +SPROINGIES = sproingiewrap.o buildlwo.o \ + s1_1.o s1_2.o s1_3.o s1_4.o s1_5.o s1_6.o s1_b.o +sproingies: sproingies.o $(HACK_OBJS) $(SPROINGIES) + $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(SPROINGIES) $(HACK_LIBS) + + +############################################################################## +# +# DO NOT DELETE: updated by make distdepend + +buildlwo.o: $(srcdir)/buildlwo.h +cage.o: $(HACK_SRC)/xlockmore.h +cage.o: $(HACK_SRC)/../config.h +cage.o: $(HACK_SRC)/xlockmoreI.h +cage.o: $(HACK_SRC)/screenhack.h +cage.o: $(UTILS_SRC)/yarandom.h +cage.o: $(UTILS_SRC)/usleep.h +cage.o: $(UTILS_SRC)/resources.h +cage.o: $(UTILS_SRC)/hsv.h +cage.o: $(UTILS_SRC)/colors.h +cage.o: $(UTILS_SRC)/grabscreen.h +cage.o: $(UTILS_SRC)/visual.h +cage.o: $(srcdir)/e_textures.h +gears.o: $(HACK_SRC)/xlockmore.h +gears.o: $(HACK_SRC)/../config.h +gears.o: $(HACK_SRC)/xlockmoreI.h +gears.o: $(HACK_SRC)/screenhack.h +gears.o: $(UTILS_SRC)/yarandom.h +gears.o: $(UTILS_SRC)/usleep.h +gears.o: $(UTILS_SRC)/resources.h +gears.o: $(UTILS_SRC)/hsv.h +gears.o: $(UTILS_SRC)/colors.h +gears.o: $(UTILS_SRC)/grabscreen.h +gears.o: $(UTILS_SRC)/visual.h +moebius.o: $(HACK_SRC)/xlockmore.h +moebius.o: $(HACK_SRC)/../config.h +moebius.o: $(HACK_SRC)/xlockmoreI.h +moebius.o: $(HACK_SRC)/screenhack.h +moebius.o: $(UTILS_SRC)/yarandom.h +moebius.o: $(UTILS_SRC)/usleep.h +moebius.o: $(UTILS_SRC)/resources.h +moebius.o: $(UTILS_SRC)/hsv.h +moebius.o: $(UTILS_SRC)/colors.h +moebius.o: $(UTILS_SRC)/grabscreen.h +moebius.o: $(UTILS_SRC)/visual.h +moebius.o: $(srcdir)/e_textures.h +morph3d.o: $(HACK_SRC)/xlockmore.h +morph3d.o: $(HACK_SRC)/../config.h +morph3d.o: $(HACK_SRC)/xlockmoreI.h +morph3d.o: $(HACK_SRC)/screenhack.h +morph3d.o: $(UTILS_SRC)/yarandom.h +morph3d.o: $(UTILS_SRC)/usleep.h +morph3d.o: $(UTILS_SRC)/resources.h +morph3d.o: $(UTILS_SRC)/hsv.h +morph3d.o: $(UTILS_SRC)/colors.h +morph3d.o: $(UTILS_SRC)/grabscreen.h +morph3d.o: $(UTILS_SRC)/visual.h +pipeobjs.o: $(srcdir)/buildlwo.h +pipes.o: $(HACK_SRC)/xlockmore.h +pipes.o: $(HACK_SRC)/../config.h +pipes.o: $(HACK_SRC)/xlockmoreI.h +pipes.o: $(HACK_SRC)/screenhack.h +pipes.o: $(UTILS_SRC)/yarandom.h +pipes.o: $(UTILS_SRC)/usleep.h +pipes.o: $(UTILS_SRC)/resources.h +pipes.o: $(UTILS_SRC)/hsv.h +pipes.o: $(UTILS_SRC)/colors.h +pipes.o: $(UTILS_SRC)/grabscreen.h +pipes.o: $(UTILS_SRC)/visual.h +pipes.o: $(srcdir)/buildlwo.h +rubik.o: $(HACK_SRC)/xlockmore.h +rubik.o: $(HACK_SRC)/../config.h +rubik.o: $(HACK_SRC)/xlockmoreI.h +rubik.o: $(HACK_SRC)/screenhack.h +rubik.o: $(UTILS_SRC)/yarandom.h +rubik.o: $(UTILS_SRC)/usleep.h +rubik.o: $(UTILS_SRC)/resources.h +rubik.o: $(UTILS_SRC)/hsv.h +rubik.o: $(UTILS_SRC)/colors.h +rubik.o: $(UTILS_SRC)/grabscreen.h +rubik.o: $(UTILS_SRC)/visual.h +s1_1.o: $(srcdir)/buildlwo.h +s1_2.o: $(srcdir)/buildlwo.h +s1_3.o: $(srcdir)/buildlwo.h +s1_4.o: $(srcdir)/buildlwo.h +s1_5.o: $(srcdir)/buildlwo.h +s1_6.o: $(srcdir)/buildlwo.h +s1_b.o: $(srcdir)/buildlwo.h +sproingies.o: $(HACK_SRC)/xlockmoreI.h +sproingies.o: $(HACK_SRC)/screenhack.h +sproingies.o: $(HACK_SRC)/../config.h +sproingies.o: $(UTILS_SRC)/yarandom.h +sproingies.o: $(UTILS_SRC)/usleep.h +sproingies.o: $(UTILS_SRC)/resources.h +sproingies.o: $(UTILS_SRC)/hsv.h +sproingies.o: $(UTILS_SRC)/colors.h +sproingies.o: $(UTILS_SRC)/grabscreen.h +sproingies.o: $(UTILS_SRC)/visual.h +sproingies.o: $(srcdir)/buildlwo.h +sproingiewrap.o: $(HACK_SRC)/xlockmore.h +sproingiewrap.o: $(HACK_SRC)/../config.h +sproingiewrap.o: $(HACK_SRC)/xlockmoreI.h +sproingiewrap.o: $(HACK_SRC)/screenhack.h +sproingiewrap.o: $(UTILS_SRC)/yarandom.h +sproingiewrap.o: $(UTILS_SRC)/usleep.h +sproingiewrap.o: $(UTILS_SRC)/resources.h +sproingiewrap.o: $(UTILS_SRC)/hsv.h +sproingiewrap.o: $(UTILS_SRC)/colors.h +sproingiewrap.o: $(UTILS_SRC)/grabscreen.h +sproingiewrap.o: $(UTILS_SRC)/visual.h +stairs.o: $(HACK_SRC)/xlockmore.h +stairs.o: $(HACK_SRC)/../config.h +stairs.o: $(HACK_SRC)/xlockmoreI.h +stairs.o: $(HACK_SRC)/screenhack.h +stairs.o: $(UTILS_SRC)/yarandom.h +stairs.o: $(UTILS_SRC)/usleep.h +stairs.o: $(UTILS_SRC)/resources.h +stairs.o: $(UTILS_SRC)/hsv.h +stairs.o: $(UTILS_SRC)/colors.h +stairs.o: $(UTILS_SRC)/grabscreen.h +stairs.o: $(UTILS_SRC)/visual.h +stairs.o: $(srcdir)/e_textures.h +superquadrics.o: $(HACK_SRC)/xlockmore.h +superquadrics.o: $(HACK_SRC)/../config.h +superquadrics.o: $(HACK_SRC)/xlockmoreI.h +superquadrics.o: $(HACK_SRC)/screenhack.h +superquadrics.o: $(UTILS_SRC)/yarandom.h +superquadrics.o: $(UTILS_SRC)/usleep.h +superquadrics.o: $(UTILS_SRC)/resources.h +superquadrics.o: $(UTILS_SRC)/hsv.h +superquadrics.o: $(UTILS_SRC)/colors.h +superquadrics.o: $(UTILS_SRC)/grabscreen.h +superquadrics.o: $(UTILS_SRC)/visual.h +xlock-gl.o: $(HACK_SRC)/screenhack.h +xlock-gl.o: $(HACK_SRC)/../config.h +xlock-gl.o: $(UTILS_SRC)/yarandom.h +xlock-gl.o: $(UTILS_SRC)/usleep.h +xlock-gl.o: $(UTILS_SRC)/resources.h +xlock-gl.o: $(UTILS_SRC)/hsv.h +xlock-gl.o: $(UTILS_SRC)/colors.h +xlock-gl.o: $(UTILS_SRC)/grabscreen.h +xlock-gl.o: $(UTILS_SRC)/visual.h +xlock-gl.o: $(HACK_SRC)/xlockmoreI.h + diff --git a/hacks/glx/README b/hacks/glx/README new file mode 100644 index 00000000..682fa3c9 --- /dev/null +++ b/hacks/glx/README @@ -0,0 +1,10 @@ + +This directory contains various graphics hacks that requre OpenGL. These are +independent from the xscreensaver program (in the ../../driver/ directory) +but some of them use the utility functions found in the ../../utils/ directory. + +If you have compilation problems, check the parameters in ../../config.h. + +If you're looking for a free implementation of the OpenGL library, check +out . For general OpenGL info, +see . diff --git a/hacks/glx/buildlwo.c b/hacks/glx/buildlwo.c new file mode 100644 index 00000000..f405730d --- /dev/null +++ b/hacks/glx/buildlwo.c @@ -0,0 +1,101 @@ + +#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.early.com/~emackey/lw2ogl/ + * + * by Ed Mackey, 4/19/97 + * + */ + +#ifndef STANDALONE +#include "xlock.h" +#endif + +#ifdef USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#include +#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/hacks/glx/buildlwo.h b/hacks/glx/buildlwo.h new file mode 100644 index 00000000..fd9f027e --- /dev/null +++ b/hacks/glx/buildlwo.h @@ -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/hacks/glx/cage.c b/hacks/glx/cage.c new file mode 100644 index 00000000..10edcbf7 --- /dev/null +++ b/hacks/glx/cage.c @@ -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 addresses are + * vianna@cat.cbpf.br + * and + * 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 + +#ifdef STANDALONE +# define PROGCLASS "Cage" +# define HACK_INIT init_cage +# define HACK_DRAW draw_cage +# define cage_opts xlockmore_opts +# define DEFAULTS "*cycles: 1 \n" \ + "*delay: 1000 \n" \ + "*wireframe: False \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ + +#endif /* !STANDALONE */ + +#ifdef USE_GL + + +#include +#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, "", + "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_WIN_WIDTH(mi), MI_WIN_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); + + 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_WIN_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/hacks/glx/e_textures.h b/hacks/glx/e_textures.h new file mode 100644 index 00000000..7f9457e3 --- /dev/null +++ b/hacks/glx/e_textures.h @@ -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/hacks/glx/gears.c b/hacks/glx/gears.c new file mode 100644 index 00000000..a0847ff1 --- /dev/null +++ b/hacks/glx/gears.c @@ -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 + * 1996: "written" by Danny Sung + * Based on 3-D gear wheels by Brian Paul which is in the public domain. + * + * Brian Paul + */ + +/*- + * 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 + +#ifdef STANDALONE +# define PROGCLASS "Gears" +# define HACK_INIT init_gears +# define HACK_DRAW draw_gears +# define gears_opts xlockmore_opts +# define DEFAULTS "*count: 1 \n" \ + "*cycles: 2 \n" \ + "*delay: 100 \n" \ + "*wireframe: False \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +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, 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_WIN_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_WIN_IS_WIREFRAME(mi); + int mono = MI_WIN_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_WIN_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_WIN_WIDTH(mi), MI_WIN_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_BATCHCOUNT(mi) ? MI_BATCHCOUNT(mi) : 1; + + 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/hacks/glx/moebius.c b/hacks/glx/moebius.c new file mode 100644 index 00000000..3fd933c7 --- /dev/null +++ b/hacks/glx/moebius.c @@ -0,0 +1,711 @@ +/* -*- 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 addresses are + * vianna@cat.cbpf.br + * and + * 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 + +#ifdef STANDALONE +# define PROGCLASS "Moebius" +# define HACK_INIT init_moebius +# define HACK_DRAW draw_moebius +# define moebius_opts xlockmore_opts +# define DEFAULTS "*cycles: 1 \n" \ + "*delay: 1000 \n" \ + "*wireframe: False \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ + +#endif /* !STANDALONE */ + +#ifdef USE_GL + + +#include +#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 = +{4, opts, 2, 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, 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_WIN_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_WIN_WIDTH(mi), MI_WIN_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); + + 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_WIN_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/hacks/glx/morph3d.c b/hacks/glx/morph3d.c new file mode 100644 index 00000000..41aa301d --- /dev/null +++ b/hacks/glx/morph3d.c @@ -0,0 +1,890 @@ +/* -*- 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. 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 addresses are + * vianna@cat.cbpf.br + * and + * 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 + +#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 */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +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, 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; TiMaterialColor[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_WIN_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_WIN_WIDTH(mi), MI_WIN_HEIGHT(mi)); + mp->object = MI_BATCHCOUNT(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); + + 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_WIN_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/hacks/glx/pipeobjs.c b/hacks/glx/pipeobjs.c new file mode 100644 index 00000000..e89f7009 --- /dev/null +++ b/hacks/glx/pipeobjs.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of pipeobjs.c */ diff --git a/hacks/glx/pipes.c b/hacks/glx/pipes.c new file mode 100644 index 00000000..8ee15389 --- /dev/null +++ b/hacks/glx/pipes.c @@ -0,0 +1,1036 @@ +/* -*- 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 are + * + * vianna@cat.cbpf.br + * and + * 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 + * 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 + +#ifdef STANDALONE +# define PROGCLASS "Pipes" +# define HACK_INIT init_pipes +# define HACK_DRAW draw_pipes +# define pipes_opts xlockmore_opts +# define DEFAULTS "*delay: 100 \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 */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +#include +#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 = +{7, opts, 4, 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, 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_WIN_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_WIN_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_WIN_WIDTH(mi), MI_WIN_HEIGHT(mi)); + pp->initial_rotation = -10.0; + pinit(mi, 1); + + if (factory > 0) { + pp->valve = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_BigValve); + pp->bolts = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_Bolts3D); + pp->betweenbolts = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_PipeBetweenBolts); + + pp->elbowbolts = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_ElbowBolts); + pp->elbowcoins = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_ElbowCoins); + + pp->guagehead = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_GuageHead); + pp->guageface = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_GuageFace); + pp->guagedial = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_GuageDial); + pp->guageconnector = BuildLWO(MI_WIN_IS_WIREFRAME(mi), &LWO_GuageConnector); + } + /* else they are all 0, thanks to calloc(). */ + + if (MI_BATCHCOUNT(mi) < 1 || MI_BATCHCOUNT(mi) > NofSysTypes + 1) { + pp->system_type = NRAND(NofSysTypes) + 1; + } else { + pp->system_type = MI_BATCHCOUNT(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; + + 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_WIN_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/hacks/glx/rubik.c b/hacks/glx/rubik.c new file mode 100644 index 00000000..d52dda15 --- /dev/null +++ b/hacks/glx/rubik.c @@ -0,0 +1,1812 @@ +/* -*- 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.07 97/11/24 xlockmore"; + +#endif + +#undef DEBUG_LISTS +#undef LMN + +/*- + * 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 a 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 addresses are + * vianna@cat.cbpf.br + * and + * m-vianna@usa.net + * + * Marcelo F. Vianna (Jul-31-1997) + * + * Revision History: + * 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) | rp->faces[N][X+AVSIZE*Y]= + * | | rp->cubeLoc[N][X+AVSIZE*Y]= + * | | + * | 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 + +#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 */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +#define DEF_HIDESHUFFLING "False" + +static Bool hideshuffling; + +static XrmOptionDescRec opts[] = +{ + {"-hideshuffling", ".rubik.hideshuffling", XrmoptionNoArg, (caddr_t) "on"}, + {"+hideshuffling", ".rubik.hideshuffling", XrmoptionNoArg, (caddr_t) "off"} +}; + +static argtype vars[] = +{ + {(caddr_t *) & hideshuffling, "hideshuffling", "Hideshuffling", DEF_HIDESHUFFLING, t_Bool} +}; + +static OptionStruct desc[] = +{ + {"-/+hideshuffling", "turn on/off hidden shuffle phase"} +}; + +ModeSpecOpt rubik_opts = +{2, opts, 1, vars, desc}; + +#ifdef USE_MODULES +ModStruct rubik_description = +{"rubik", "init_rubik", "draw_rubik", "release_rubik", + "draw_rubik", "change_rubik", NULL, &rubik_opts, + 1000, -30, 5, -6, 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 +#ifdef LMN /* LxMxN not completed yet... */ +#define MAXSIZEX (rp->sizex) +#define MAXSIZEY (rp->sizey) +#define MAXSIZEZ (rp->sizez) +#define AVSIZE (rp->avsize) +#define MAXSIZE (rp->maxsize) +#define AVSIZESQ (rp->avsizeSq) +#define MAXSIZESQ (rp->maxsizeSq) +#else +#define MAXSIZEX (rp->size) +#define MAXSIZEY (rp->size) +#define MAXSIZEZ (rp->size) +#define AVSIZE (rp->size) +#define MAXSIZE (rp->size) +#define AVSIZESQ (rp->sizeSq) +#define MAXSIZESQ (rp->sizeSq) +#endif +#define MAXSIZEXY (MAXSIZEX*MAXSIZEY) +#define MAXSIZEZY (MAXSIZEZ*MAXSIZEY) +#define MAXSIZEXZ (MAXSIZEX*MAXSIZEZ) +#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 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 MAXSIZE + +#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). + * Beware.. using this for NxNxN makes some assumptions that referenced + * cubes are along the diagonal top-left to bottom-right. + * 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, LEFT}, + {0, RIGHT, BOTTOM}, + {0, TOP, RIGHT}, + {1, RIGHT, BOTTOM}, + {0, LEFT, TOP} +}; + +typedef struct { + GLint WindH, WindW; + GLfloat step; + RubikMove *moves; + int storedmoves; + int shufflingmoves; +#ifdef LMN /* Under construction */ + int sizex, sizey, sizez; + int avsize, maxsize; + int avsizeSq, maxsizeSq; +#else + int size, sizeSq; +#endif + int action; + int done; + GLfloat anglestep; + RubikLoc *cubeLoc[MAXFACES]; + RubikLoc *rowLoc[MAXORIENT]; + RubikMove movement; + GLfloat rotatestep; + 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; + +#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 +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_WIN_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(); + } +} + + +static RubikSlice +convertMove(rubikstruct * rp, RubikMove move) +{ + RubikSlice slice; + RubikLoc plane; + + plane = rotateSlice[(int) move.face][move.direction % 2]; + slice.face = plane.face; + slice.rotation = plane.rotation; + if (slice.rotation == CW) /* I just know this to be true... */ + slice.depth = AVSIZESQ - 1 - move.position; + else + slice.depth = move.position; + slice.depth = slice.depth / AVSIZE; + /* If slice.depth = 0 then face 0, face 1, or face 2 moves */ + if (move.direction / 2) + slice.rotation = (plane.rotation == CW) ? CCW : CW; + return slice; +} + +/* 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 { + slice = convertMove(rp, rp->movement); + } + 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; + + if (dir == TOP || dir == BOTTOM) + for (g = 0; g < size; g++) + rp->rowLoc[orient][g] = + rp->cubeLoc[face][g * size + h]; + else /* dir == RIGHT || dir == LEFT */ + for (g = 0; g < size; g++) + rp->rowLoc[orient][g] = + rp->cubeLoc[face][h * size + 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; + + if (dir == TOP || dir == BOTTOM) { + for (g = 0; g < size; g++) { + position = g * size + 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 * size + 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; + RubikLoc *faceLoc = NULL; + + if ((faceLoc = (RubikLoc *) malloc(AVSIZESQ * sizeof (RubikLoc))) == NULL) + (void) fprintf(stderr, + "Could not allocate memory for rubik face position info\n"); + /* Read Face */ + for (position = 0; position < AVSIZESQ; position++) + faceLoc[position] = rp->cubeLoc[face][position]; + /* Write Face */ + for (position = 0; position < AVSIZESQ; position++) { + i = position % AVSIZE; + j = position / AVSIZE; + rp->cubeLoc[face][position] = (direction == CW) ? + faceLoc[(AVSIZE - i - 1) * AVSIZE + j] : + faceLoc[i * AVSIZE + AVSIZE - j - 1]; + rp->cubeLoc[face][position].rotation = + (rp->cubeLoc[face][position].rotation + direction - MAXORIENT) % + MAXORIENT; + /* DrawSquare(face, position); */ + } + if (faceLoc != NULL) + (void) free((void *) faceLoc); +} + +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; + + if (direction == CW || direction == CCW) { + direction = (direction == CCW) ? + (rotateToRow[face].direction + 2) % MAXORIENT : + rotateToRow[face].direction; + i = j = (rotateToRow[face].sideFace == RIGHT || + rotateToRow[face].sideFace == BOTTOM) ? AVSIZE - 1 : 0; + face = rotateToRow[face].face; + position = j * AVSIZE + i; + } + i = position % AVSIZE; + j = position / AVSIZE; + h = (direction == TOP || direction == BOTTOM) ? i : j; + /* rotate sides CW or CCW */ + if (h == AVSIZE - 1) { + newDirection = (direction == TOP || direction == BOTTOM) ? + TOP : RIGHT; + 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 (direction == TOP || direction == RIGHT) + rotateFace(rp, rowToRotate[face][newDirection], CCW); + else /* direction == BOTTOM || direction == LEFT */ + rotateFace(rp, rowToRotate[face][newDirection], CW); + } + /* Slide rows */ + readRC(rp, face, direction, h, 0, AVSIZE); + for (k = 1; k <= MAXORIENT; k++) { + 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 = AVSIZE - 1 - h; + reverse = False; + } else { /* newDirection == RIGHT || newDirection == LEFT */ + newH = h; + reverse = True; + } + break; + case BOTTOM: + newH = AVSIZE - 1 - h; + reverse = True; + break; + case LEFT: + if (newDirection == TOP || newDirection == BOTTOM) { + newH = h; + reverse = True; + } else { /* newDirection == RIGHT || newDirection == LEFT */ + newH = AVSIZE - 1 - h; + reverse = False; + } + break; + default: + (void) printf("moveRubik: rotate %d\n", rotate); + } + if (k != MAXORIENT) + readRC(rp, newFace, newDirection, newH, k, AVSIZE); + rotateRC(rp, rotate, k - 1, AVSIZE); + if (reverse == True) + reverseRC(rp, k - 1, AVSIZE); + writeRC(rp, newFace, newDirection, newH, k - 1, AVSIZE); + face = newFace; + direction = newDirection; + h = newH; + } +} + +#ifdef DEBUG +void +printCube(rubikstruct * rp) +{ + int face, position; + + for (face = 0; face < MAXFACES; face++) { + for (position = 0; position < AVSIZESQ; position++) { + (void) printf("%d %d ", rp->cubeLoc[face][position].face, + rp->cubeLoc[face][position].rotation); + if (!((position + 1) % AVSIZE)) + (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; + + slice1 = convertMove(rp, move1); + slice2 = convertMove(rp, move2); + 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; + + AVSIZE = MI_SIZE(mi); + if (AVSIZE < -MINSIZE) + AVSIZE = NRAND(-AVSIZE - MINSIZE + 1) + MINSIZE; + else if (AVSIZE < MINSIZE) + AVSIZE = MINSIZE; + /* Let me waste a little space for the moment */ + /* Future cube to be LxMxN and not just NxNxN, but not done yet */ + AVSIZESQ = AVSIZE * AVSIZE; +#ifdef LMN + MAXSIZEX = AVSIZE; + MAXSIZEY = AVSIZE; + MAXSIZEZ = AVSIZE; + MAXSIZE = AVSIZE; + MAXSIZESQ = AVSIZESQ; +#endif + + for (face = 0; face < MAXFACES; face++) { + if (rp->cubeLoc[face] != NULL) + (void) free((void *) rp->cubeLoc[face]); + if ((rp->cubeLoc[face] = + (RubikLoc *) malloc(AVSIZESQ * sizeof (RubikLoc))) == NULL) + (void) fprintf(stderr, + "Could not allocate memory for rubik cube position info\n"); + for (position = 0; position < AVSIZESQ; 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]); + if ((rp->rowLoc[i] = + (RubikLoc *) malloc(AVSIZE * sizeof (RubikLoc))) == NULL) + (void) fprintf(stderr, + "Could not allocate memory for rubik row position info\n"); + } + rp->storedmoves = MI_BATCHCOUNT(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 */ + /* + * Randomize position along diagonal, each plane gets an equal chance. + * This trick will only work for NxNxN cubes + * draw_cube DEPENDS on that they are chosen this way. + */ + move.position = NRAND(AVSIZE) * (AVSIZE + 1); + + + condition = 1; + + if (i > 0) /* avoid immediate undoing moves */ + if (compare_moves(rp, move, rp->moves[i - 1], True)) + 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->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); + + if ((rp->glx_context = init_GL(mi)) != NULL) { + + reshape(mi, MI_WIN_WIDTH(mi), MI_WIN_HEIGHT(mi)); + objects = glGenLists(1); + pinit(mi); + } else { + MI_CLEARWINDOW(mi); + } +} + +void +draw_rubik(ModeInfo * mi) +{ + rubikstruct *rp = &rubik[MI_SCREEN(mi)]; + Display *display = MI_DISPLAY(mi); + Window window = MI_WINDOW(mi); + + 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); + + if (!MI_WIN_IS_ICONIC(mi)) { + 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); + + 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 { + rp->rotatestep += rp->anglestep; + if (rp->rotatestep > 90) { + 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 { + rp->rotatestep += rp->anglestep; + if (rp->rotatestep > 90) { + evalmovement(mi, rp->movement); + rp->storedmoves--; + rp->movement.face = NO_FACE; + } + } + } + } + + draw_cube(mi); + + glPopMatrix(); + + glFlush(); + + glXSwapBuffers(display, window); + + 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/hacks/glx/s1_1.c b/hacks/glx/s1_1.c new file mode 100644 index 00000000..61dd91fe --- /dev/null +++ b/hacks/glx/s1_1.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_1.c */ diff --git a/hacks/glx/s1_2.c b/hacks/glx/s1_2.c new file mode 100644 index 00000000..bb7a35bd --- /dev/null +++ b/hacks/glx/s1_2.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_2.c */ diff --git a/hacks/glx/s1_3.c b/hacks/glx/s1_3.c new file mode 100644 index 00000000..1e6f868a --- /dev/null +++ b/hacks/glx/s1_3.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_3.c */ diff --git a/hacks/glx/s1_4.c b/hacks/glx/s1_4.c new file mode 100644 index 00000000..1b3406db --- /dev/null +++ b/hacks/glx/s1_4.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_4.c */ diff --git a/hacks/glx/s1_5.c b/hacks/glx/s1_5.c new file mode 100644 index 00000000..53cd0bfb --- /dev/null +++ b/hacks/glx/s1_5.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_5.c */ diff --git a/hacks/glx/s1_6.c b/hacks/glx/s1_6.c new file mode 100644 index 00000000..fb9c60e0 --- /dev/null +++ b/hacks/glx/s1_6.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_6.c */ diff --git a/hacks/glx/s1_b.c b/hacks/glx/s1_b.c new file mode 100644 index 00000000..8510d916 --- /dev/null +++ b/hacks/glx/s1_b.c @@ -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 USE_GL + +#ifdef STANDALONE +#include +#endif +#include +#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 /* USE_GL */ + +/* End of s1_b.c */ diff --git a/hacks/glx/sproingies.c b/hacks/glx/sproingies.c new file mode 100644 index 00000000..aa790456 --- /dev/null +++ b/hacks/glx/sproingies.c @@ -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 USE_GL + +#include +#include +#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/hacks/glx/sproingiewrap.c b/hacks/glx/sproingiewrap.c new file mode 100644 index 00000000..ad11a1b7 --- /dev/null +++ b/hacks/glx/sproingiewrap.c @@ -0,0 +1,244 @@ +/* -*- 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 */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +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, 1.0, "", + "Shows Sproingies! Nontoxic. Safe for pets and small children", 0, NULL}; + +#endif + +#define MINSIZE 32 + +#include +#include + +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 batchcount = MI_BATCHCOUNT(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_WIN_IS_MONO(mi) ? 1 : 0); + sp->window = window; + if ((sp->glx_context = init_GL(mi)) != NULL) { + + if ((cycles & 1) || MI_WIN_IS_WIREFRAME(mi)) + wfmode = 1; + grnd = (cycles >> 1); + if (grnd > 2) + grnd = 2; + + mspr = batchcount; + 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_WIN_WIDTH(mi); + h = MI_WIN_HEIGHT(mi); + } else if (size < MINSIZE) { + w = MINSIZE; + h = MINSIZE; + } else { + w = (size > MI_WIN_WIDTH(mi)) ? MI_WIN_WIDTH(mi) : size; + h = (size > MI_WIN_HEIGHT(mi)) ? MI_WIN_HEIGHT(mi) : size; + } + + glViewport((MI_WIN_WIDTH(mi) - w) / 2, (MI_WIN_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); + + 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/hacks/glx/stairs.c b/hacks/glx/stairs.c new file mode 100644 index 00000000..5896e195 --- /dev/null +++ b/hacks/glx/stairs.c @@ -0,0 +1,495 @@ +/* -*- 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 addresses are + * vianna@cat.cbpf.br + * and + * 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. +z * + * In real OpenGL, PseudoColor DO NOT support texture map (as far as I know). + */ + +#include + +#ifdef STANDALONE +# define PROGCLASS "Stairs" +# define HACK_INIT init_stairs +# define HACK_DRAW draw_stairs +# define stairs_opts xlockmore_opts +# define DEFAULTS "*cycles: 1 \n" \ + "*delay: 200000 \n" \ + "*wireframe: False \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ + +#endif /* !STANDALONE */ + +#ifdef USE_GL + +#include +#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, 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(stairsstruct * sp, 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_degree(stairsstruct * sp, GLfloat w, GLfloat h , GLfloat t) +{ + draw_block(sp, w, h, t); +} + +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_degree(sp, 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_degree(sp, 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_degree(sp, 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_degree(sp, 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 >= 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(ModeInfo * mi) +{ +/* stairsstruct *sp = &stairs[MI_SCREEN(mi)];*/ + + 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_WIN_WIDTH(mi), MI_WIN_HEIGHT(mi)); + glDrawBuffer(GL_BACK); + if (!glIsList(objects)) + objects = glGenLists(1); + pinit(mi); + } 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); + + 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_WIN_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(mi); +} + +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/hacks/glx/superquadrics.c b/hacks/glx/superquadrics.c new file mode 100644 index 00000000..8e2a7636 --- /dev/null +++ b/hacks/glx/superquadrics.c @@ -0,0 +1,778 @@ +/* -*- 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 + +#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 */ +#endif /* !STANDALONE */ + +#ifdef USE_GL + +/*- + * 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 = +{1, opts, 1, 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, 1.0, "", + "Shows 3D mathematical shapes", 0, NULL}; + +#endif + +#include + +#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_WIN_IS_MONO(mi) ? 1 : 0); + + if ((sp->glx_context = init_GL(mi)) != NULL) { + + InitSuperquadrics(MI_WIN_IS_WIREFRAME(mi), 0, + MI_BATCHCOUNT(mi), MI_CYCLES(mi), spinspeed, sp); + ReshapeSuperquadrics(MI_WIN_WIDTH(mi), MI_WIN_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); + + 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/hacks/glx/xlock-gl.c b/hacks/glx/xlock-gl.c new file mode 100644 index 00000000..d8cfd7a6 --- /dev/null +++ b/hacks/glx/xlock-gl.c @@ -0,0 +1,180 @@ +/* xlock-gc.c --- xscreensaver compatibility layer for xlockmore GL modules. + * xscreensaver, Copyright (c) 1997, 1998 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. + * + * This file, along with xlockmore.h, make it possible to compile an xlockmore + * GL module into a standalone program, and thus use it with xscreensaver. + * By Jamie Zawinski on 31-May-97. + */ + +#include +#include "screenhack.h" +#include "xlockmoreI.h" + +#include +#include + +/* Gag -- we use this to turn X errors from glXCreateContext() into + something that will actually make sense to the user. + */ +static XErrorHandler orig_ehandler = 0; +static Bool got_error = 0; + +static int +BadValue_ehandler (Display *dpy, XErrorEvent *error) +{ + if (error->error_code == BadValue) + { + got_error = True; + return 0; + } + else + return orig_ehandler (dpy, error); +} + + +GLXContext * +init_GL(ModeInfo * mi) +{ + Display *dpy = mi->dpy; + Window window = mi->window; + Screen *screen = mi->xgwa.screen; + Visual *visual = mi->xgwa.visual; + GLXContext glx_context = 0; + XVisualInfo vi_in, *vi_out; + int out_count; + + vi_in.screen = screen_number (screen); + vi_in.visualid = XVisualIDFromVisual (visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + + { + XSync (dpy, False); + orig_ehandler = XSetErrorHandler (BadValue_ehandler); + glx_context = glXCreateContext (dpy, vi_out, 0, GL_TRUE); + XSync (dpy, False); + XSetErrorHandler (orig_ehandler); + if (got_error) + glx_context = 0; + } + + XFree((char *) vi_out); + + if (!glx_context) + { + fprintf(stderr, "%s: couldn't create GL context for visual 0x%x.\n", + progname, (unsigned int) XVisualIDFromVisual (visual)); + exit(1); + } + + glXMakeCurrent (dpy, window, glx_context); + + { + GLboolean rgba_mode = 0; + glGetBooleanv(GL_RGBA_MODE, &rgba_mode); + if (!rgba_mode) + { + glIndexi (WhitePixelOfScreen (screen)); + glClearIndex (BlackPixelOfScreen (screen)); + } + } + + /* GLXContext is already a pointer type. + Why this function returns a pointer to a pointer, I have no idea... + */ + { + GLXContext *ptr = (GLXContext *) malloc(sizeof(GLXContext)); + *ptr = glx_context; + return ptr; + } +} + + +Visual * +get_gl_visual (Screen *screen, char *name, char *class) +{ + char *string = get_string_resource (name, class); + XVisualInfo *vi = 0; + Bool done_once = False; + + AGAIN: + if (!string || !*string || + !strcmp (string, "best") || + !strcmp (string, "color") || + !strcmp (string, "default")) + { + Display *dpy = DisplayOfScreen (screen); + int screen_num = screen_number (screen); + int attrs[20]; + int i = 0; + Bool dbuf_p = !get_boolean_resource ("noBuffer", "NoBuffer"); + + done_once = True; + + attrs[i++] = GLX_RGBA; + attrs[i++] = GLX_RED_SIZE; attrs[i++] = 1; + attrs[i++] = GLX_GREEN_SIZE; attrs[i++] = 1; + attrs[i++] = GLX_BLUE_SIZE; attrs[i++] = 1; + attrs[i++] = GLX_DEPTH_SIZE; attrs[i++] = 1; + if (dbuf_p) + attrs[i++] = GLX_DOUBLEBUFFER; + attrs[i++] = 0; + + vi = glXChooseVisual (dpy, screen_num, attrs); + if (vi) goto DONE; + + /* Try without double-buffering. */ + attrs[i - 1] = 0; + vi = glXChooseVisual (dpy, screen_num, attrs); + if (vi) goto DONE; + + /* Try mono. */ + i = 0; + if (dbuf_p) + attrs[i++] = GLX_DOUBLEBUFFER; + attrs[i++] = 0; + vi = glXChooseVisual (dpy, screen_num, attrs); + if (vi) goto DONE; + + /* Try mono without double-buffering. */ + attrs[0] = 0; + vi = glXChooseVisual (dpy, screen_num, attrs); + } + + DONE: + { + Visual *v; + if (vi) + { + v = vi->visual; + XFree (vi); + } + else + { + v = get_visual (screen, string, False, True); + if (!v) + { + if (done_once) + v = DefaultVisualOfScreen (screen); + else + { + free (string); + string = 0; + goto AGAIN; + } + } + } + + free (string); + return v; + } +} diff --git a/hacks/goop.c b/hacks/goop.c new file mode 100644 index 00000000..079ebc61 --- /dev/null +++ b/hacks/goop.c @@ -0,0 +1,534 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +#include +#include "screenhack.h" +#include "spline.h" +#include "alpha.h" + + +/* 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... + */ + + +#define SCALE 10000 /* fixed-point math, for sub-pixel motion */ +#define DEF_COUNT 12 /* When planes and count are 0, how many blobs. */ + + +#define RAND(n) ((long) ((random() & 0x7fffffff) % ((long) (n)))) +#define RANDSIGN() ((random() & 1) ? 1 : -1) + +struct blob { + 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 *spline; +}; + +struct layer { + int nblobs; + struct blob **blobs; + Pixmap pixmap; + unsigned long pixel; + GC gc; +}; + +enum goop_mode { + transparent, + opaque, + xor, + outline +}; + +struct goop { + enum goop_mode mode; + int width, height; + int nlayers; + struct layer **layers; + unsigned long background; + Pixmap pixmap; + GC pixmap_gc; + GC window_gc; +}; + + +static struct blob * +make_blob (int maxx, int maxy, int size) +{ + struct blob *b = (struct blob *) calloc(1, sizeof(*b)); + int i; + int 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 = get_float_resource ("torque", "Torque"); + b->elasticity = SCALE * get_float_resource ("elasticity", "Elasticity"); + b->max_velocity = SCALE * get_float_resource ("maxVelocity", "MaxVelocity"); + + b->x = RAND(maxx); + b->y = RAND(maxy); + + b->dx = RAND(b->max_velocity) * RANDSIGN(); + b->dy = RAND(b->max_velocity) * RANDSIGN(); + b->th = frand(M_PI+M_PI) * RANDSIGN(); + b->npoints = (random() % 5) + 5; + + b->spline = make_spline (b->npoints); + b->r = (long *) malloc (sizeof(*b->r) * b->npoints); + for (i = 0; i < b->npoints; i++) + b->r[i] = ((random() % mid) + (mid/2)) * RANDSIGN(); + return b; +} + +static void +throb_blob (struct 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 + ra * cos (i * frac + th); + y = b->y + ra * sin (i * frac + th); + + b->spline->control_x[i] = x / SCALE; + b->spline->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 += (RAND(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 (! (random() % 50)) + r = -r; + + b->r[i] = r; + } +} + +static void +move_blob (struct 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 (! (random() % 10)) + { + b->dx += (RAND(b->max_velocity/2) * RANDSIGN()); + b->dy += (RAND(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 : frand(b->torque)); + 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 (! (random() % 100)) + b->th *= -1; +} + +static void +draw_blob (Display *dpy, Drawable drawable, GC gc, struct blob *b, + Bool fill_p) +{ + compute_closed_spline (b->spline); +#ifdef DEBUG + { + int i; + for (i = 0; i < b->npoints; i++) + XDrawLine (dpy, drawable, gc, b->x/SCALE, b->y/SCALE, + b->spline->control_x[i], b->spline->control_y[i]); + } +#else + if (fill_p) + XFillPolygon (dpy, drawable, gc, b->spline->points, b->spline->n_points, + Nonconvex, CoordModeOrigin); + else +#endif + XDrawLines (dpy, drawable, gc, b->spline->points, b->spline->n_points, + CoordModeOrigin); +} + + +static struct layer * +make_layer (Display *dpy, Window window, int width, int height, int nblobs) +{ + int i; + struct layer *layer = (struct layer *) calloc(1, sizeof(*layer)); + int blob_min, blob_max; + XGCValues gcv; + layer->nblobs = nblobs; + + layer->blobs = (struct blob **) malloc(sizeof(*layer->blobs)*layer->nblobs); + + blob_max = (width < height ? width : height) / 2; + blob_min = (blob_max * 2) / 3; + for (i = 0; i < layer->nblobs; i++) + layer->blobs[i] = make_blob (width, height, + (random() % (blob_max-blob_min)) + blob_min); + + layer->pixmap = XCreatePixmap (dpy, window, width, height, 1); + layer->gc = XCreateGC (dpy, layer->pixmap, 0, &gcv); + + return layer; +} + +static void +draw_layer_plane (Display *dpy, struct layer *layer, int width, int height) +{ + int i; + XSetForeground (dpy, layer->gc, 1L); + XFillRectangle (dpy, layer->pixmap, layer->gc, 0, 0, width, height); + XSetForeground (dpy, layer->gc, 0L); + for (i = 0; i < layer->nblobs; i++) + { + throb_blob (layer->blobs[i]); + move_blob (layer->blobs[i], width, height); + draw_blob (dpy, layer->pixmap, layer->gc, layer->blobs[i], True); + } +} + + +static void +draw_layer_blobs (Display *dpy, Drawable drawable, GC gc, + struct layer *layer, int width, int height, + Bool fill_p) +{ + int i; + for (i = 0; i < layer->nblobs; i++) + { + throb_blob (layer->blobs[i]); + move_blob (layer->blobs[i], width, height); + draw_blob (dpy, drawable, gc, layer->blobs[i], fill_p); + } +} + + +static struct goop * +make_goop (Display *dpy, Window window, Colormap cmap, + int width, int height, long depth) +{ + int i; + struct goop *goop = (struct goop *) calloc(1, sizeof(*goop)); + XGCValues gcv; + int nblobs = get_integer_resource ("count", "Count"); + + unsigned long *plane_masks = 0; + unsigned long base_pixel = 0; + + goop->mode = (get_boolean_resource("xor", "Xor") + ? xor + : (get_boolean_resource("transparent", "Transparent") + ? transparent + : opaque)); + + goop->width = width; + goop->height = height; + + + goop->nlayers = get_integer_resource ("planes", "Planes"); + if (goop->nlayers <= 0) + goop->nlayers = (random() % (depth-2)) + 2; + goop->layers = (struct layer **) malloc(sizeof(*goop->layers)*goop->nlayers); + + + if (mono_p && goop->mode == transparent) + goop->mode = opaque; + + /* Try to allocate some color planes before committing to nlayers. + */ + if (goop->mode == transparent) + { + Bool additive_p = get_boolean_resource ("additive", "Additive"); + int nplanes = goop->nlayers; + allocate_alpha_colors (dpy, cmap, &nplanes, additive_p, &plane_masks, + &base_pixel); + if (nplanes > 1) + goop->nlayers = nplanes; + else + { + fprintf (stderr, + "%s: couldn't allocate any color planes; turning transparency off.\n", + progname); + goop->mode = opaque; + } + } + + { + int lblobs[32]; + int total = DEF_COUNT; + memset (lblobs, 0, sizeof(lblobs)); + if (nblobs <= 0) + while (total) + for (i = 0; total && i < goop->nlayers; i++) + lblobs[i]++, total--; + for (i = 0; i < goop->nlayers; i++) + goop->layers[i] = make_layer (dpy, window, width, height, + (nblobs > 0 ? nblobs : lblobs[i])); + } + + if (goop->mode == transparent && plane_masks) + { + for (i = 0; i < goop->nlayers; i++) + goop->layers[i]->pixel = base_pixel | plane_masks[i]; + goop->background = base_pixel; + } + if (plane_masks) + free (plane_masks); + + if (goop->mode != transparent) + { + XColor color; + color.flags = DoRed|DoGreen|DoBlue; + + goop->background = + get_pixel_resource ("background", "Background", dpy,cmap); + + for (i = 0; i < goop->nlayers; i++) + { + int H = random() % 360; /* range 0-360 */ + double S = ((double) (random()%70) + 30)/100.0; /* range 30%-100% */ + double V = ((double) (random()%34) + 66)/100.0; /* range 66%-100% */ + hsv_to_rgb (H, S, V, &color.red, &color.green, &color.blue); + if (XAllocColor (dpy, cmap, &color)) + goop->layers[i]->pixel = color.pixel; + else + goop->layers[i]->pixel = + WhitePixelOfScreen(DefaultScreenOfDisplay(dpy)); + } + } + + goop->pixmap = XCreatePixmap (dpy, window, width, height, + (goop->mode == xor ? 1L : depth)); + + gcv.background = goop->background; + gcv.foreground = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + gcv.line_width = get_integer_resource ("thickness","Thickness"); + goop->pixmap_gc = XCreateGC (dpy, goop->pixmap, GCLineWidth, &gcv); + goop->window_gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + + return goop; +} + +static struct goop * +init_goop (Display *dpy, Window window) +{ + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + + return make_goop (dpy, window, xgwa.colormap, + xgwa.width, xgwa.height, xgwa.depth); +} + +static void +run_goop (Display *dpy, Window window, struct goop *goop) +{ + int i; + + switch (goop->mode) + { + case transparent: + + for (i = 0; i < goop->nlayers; i++) + draw_layer_plane (dpy, goop->layers[i], goop->width, goop->height); + + XSetForeground (dpy, goop->pixmap_gc, goop->background); + XSetPlaneMask (dpy, goop->pixmap_gc, AllPlanes); + XFillRectangle (dpy, goop->pixmap, goop->pixmap_gc, 0, 0, + goop->width, goop->height); + XSetForeground (dpy, goop->pixmap_gc, ~0L); + for (i = 0; i < goop->nlayers; i++) + { + XSetPlaneMask (dpy, goop->pixmap_gc, goop->layers[i]->pixel); +/* + XSetForeground (dpy, goop->pixmap_gc, ~0L); + XFillRectangle (dpy, goop->pixmap, goop->pixmap_gc, 0, 0, + goop->width, goop->height); + XSetForeground (dpy, goop->pixmap_gc, 0L); + */ + draw_layer_blobs (dpy, goop->pixmap, goop->pixmap_gc, + goop->layers[i], goop->width, goop->height, + True); + } + XCopyArea (dpy, goop->pixmap, window, goop->window_gc, 0, 0, + goop->width, goop->height, 0, 0); + break; + + case xor: + XSetFunction (dpy, goop->pixmap_gc, GXcopy); + XSetForeground (dpy, goop->pixmap_gc, 0); + XFillRectangle (dpy, goop->pixmap, goop->pixmap_gc, 0, 0, + goop->width, goop->height); + XSetFunction (dpy, goop->pixmap_gc, GXxor); + XSetForeground (dpy, goop->pixmap_gc, 1); + for (i = 0; i < goop->nlayers; i++) + draw_layer_blobs (dpy, goop->pixmap, goop->pixmap_gc, + goop->layers[i], goop->width, goop->height, + (goop->mode != outline)); + XCopyPlane (dpy, goop->pixmap, window, goop->window_gc, 0, 0, + goop->width, goop->height, 0, 0, 1L); + break; + + case opaque: + case outline: + XSetForeground (dpy, goop->pixmap_gc, goop->background); + XFillRectangle (dpy, goop->pixmap, goop->pixmap_gc, 0, 0, + goop->width, goop->height); + for (i = 0; i < goop->nlayers; i++) + { + XSetForeground (dpy, goop->pixmap_gc, goop->layers[i]->pixel); + draw_layer_blobs (dpy, goop->pixmap, goop->pixmap_gc, + goop->layers[i], goop->width, goop->height, + (goop->mode != outline)); + } + XCopyArea (dpy, goop->pixmap, window, goop->window_gc, 0, 0, + goop->width, goop->height, 0, 0); + break; + + default: + abort (); + break; + } +} + + +char *progclass = "Goop"; + +char *defaults [] = { + "Goop.background: black", /* to placate SGI */ + "Goop.foreground: white", + "*delay: 12000", + "*transparent: true", + "*additive: true", + "*xor: false", + "*count: 0", + "*planes: 0", + "*thickness: 5", + "*torque: 0.0075", + "*elasticity: 1.8", + "*maxVelocity: 1.2", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-count", ".count", XrmoptionSepArg, 0 }, + { "-planes", ".planes", XrmoptionSepArg, 0 }, + { "-transparent", ".transparent", XrmoptionNoArg, "True" }, + { "-non-transparent", ".transparent", XrmoptionNoArg, "False" }, + { "-additive", ".additive", XrmoptionNoArg, "True" }, + { "-subtractive", ".additive", XrmoptionNoArg, "false" }, + { "-xor", ".xor", XrmoptionNoArg, "true" }, + { "-no-xor", ".xor", XrmoptionNoArg, "false" }, + { "-thickness", ".thickness", XrmoptionSepArg, 0 }, + { "-torque", ".torque", XrmoptionSepArg, 0 }, + { "-elasticity", ".elasticity", XrmoptionSepArg, 0 }, + { "-max-velocity", ".maxVelocity", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + struct goop *g = init_goop (dpy, window); + int delay = get_integer_resource ("delay", "Integer"); + while (1) + { + run_goop (dpy, window, g); + XSync (dpy, True); + if (delay) usleep (delay); + } +} diff --git a/hacks/goop.man b/hacks/goop.man new file mode 100644 index 00000000..e7f4c3da --- /dev/null +++ b/hacks/goop.man @@ -0,0 +1,81 @@ +.TH XScreenSaver 1 "11-Jun-97" "X Version 11" +.SH NAME +goop - squishy transparent oil and bubble screenhack +.SH SYNOPSIS +.B goop +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-transparent] [\-non\-transparent] [\-additive] [\-subtractive] [\-xor] [\-no\-xor] +.SH DESCRIPTION +The \fIgoop\fP program draws a simulation of bubbles in layers of +overlapping multicolored translucent fluid. +.SH OPTIONS +.I goop +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-count \fIinteger\fP +How many bubbles to draw per layer. Default: random. +.TP 8 +.B \-layers \fIinteger\fP +How many layers to draw. Default: random, based on screen depth. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 100000, or about 1/10th second. +.TP 8 +.B \-transparent +If \fI\-layers\fP is greater than 1, then each layer will be drawn in one +color, and when they overlap, the colors will be mixed. This only works +on \fBPseudoColor\fP displays. This is the default. +.TP 8 +.B \-non\-transparent +Turns off \fI\-transparent\fP. +.TP 8 +.B \-additive +If \fI\-transparent\fP is specified, then this option means that the colors +will be mixed using an additive color model, as if the blobs were projected +light. This is the default. +.TP 8 +.B \-subtractive +If \fI\-transparent\fP is specified, then this option means that the +colors will be mixed using a subtractive color model, as if the blobs were +translucent filters. +.TP 8 +.B \-xor +Draw with xor instead of the other color tricks. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 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. +.SH AUTHOR +Jamie Zawinski , 11-Jun-97. diff --git a/hacks/grav.c b/hacks/grav.c new file mode 100644 index 00000000..528bb1b9 --- /dev/null +++ b/hacks/grav.c @@ -0,0 +1,322 @@ +/* -*- Mode: C; tab-width: 4 -*- + * grav --- simulation of a planetary system. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)grav.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1993 Greg Bowering + * + * 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@netscape.com: turned into a standalone program. + * 11-Jul-94: color version + * 06-Oct-93: by Greg Bowering + */ + +#ifdef STANDALONE +# define PROGCLASS "Grav" +# define HACK_INIT init_grav +# define HACK_DRAW draw_grav +# define grav_opts xlockmore_opts +# define DEFAULTS "*count: 12 \n" \ + "*delay: 10000 \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 */ + +#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))) + +#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 = { 4, opts, 2, vars, desc }; + +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_WIN_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_WIN_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_WIN_WIDTH(mi); + gp->height = MI_WIN_HEIGHT(mi); + + gp->sr = STARRADIUS; + + gp->nplanets = MI_BATCHCOUNT(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)); + + XClearWindow(display, MI_WINDOW(mi)); + + if (MI_NPIXELS(mi) > 2) + gp->starcolor = MI_PIXEL(mi, NRAND(MI_NPIXELS(mi))); + else + gp->starcolor = MI_WIN_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; + + /* Mask centrepoint */ + XSetForeground(display, gc, MI_WIN_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) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/grav.man b/hacks/grav.man new file mode 100644 index 00000000..2a53938d --- /dev/null +++ b/hacks/grav.man @@ -0,0 +1,74 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +grav - draws a simple orbital simulation +.SH SYNOPSIS +.B grav +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-count \fIinteger\fP] [\-decay] [\-no\-decay] [\-trail] [\-no\-trail] + +.SH DESCRIPTION +The \fIgrav\fP program draws a simple orbital simulation +.SH OPTIONS +.I grav +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors are chosen randomly. +.TP 8 +.B \-count \fIinteger\fP +Default 12. +.TP 8 +.B \-decay +.TP 8 +.B \-no-\decay +Whether orbits should decay. + +.TP 8 +.B \-trail +.TP 8 +.B \-no\-trail +Whether the objects should leave trails behind them (makes it look vaguely +like a cloud-chamber. + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1993 by Greg Bowering. + +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. +.SH AUTHOR +Greg Bowering , 1993. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/greynetic.c b/hacks/greynetic.c new file mode 100644 index 00000000..c3f5fbaf --- /dev/null +++ b/hacks/greynetic.c @@ -0,0 +1,182 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +#include "screenhack.h" + +#define NBITS 12 + +#ifndef VMS +# include +# include +# include +# include +# include +# include +# include +# include +# include +# include +# include +# include +#else /* VMS */ +# include "sys$common:[decw$include.bitmaps]stipple.xbm" +# include "sys$common:[decw$include.bitmaps]cross_weave.xbm" +# include "sys$common:[decw$include.bitmaps]dimple1.xbm" +# include "sys$common:[decw$include.bitmaps]dimple3.xbm" +# include "sys$common:[decw$include.bitmaps]flipped_gray.xbm" +# include "sys$common:[decw$include.bitmaps]gray1.xbm" +# include "sys$common:[decw$include.bitmaps]gray3.xbm" +# include "sys$common:[decw$include.bitmaps]hlines2.xbm" +# include "sys$common:[decw$include.bitmaps]light_gray.xbm" +# include "sys$common:[decw$include.bitmaps]root_weave.xbm" +# include "sys$common:[decw$include.bitmaps]vlines2.xbm" +# include "sys$common:[decw$include.bitmaps]vlines3.xbm" +#endif /* VMS */ + +static Pixmap pixmaps [NBITS]; +static GC gc; +static int delay; +static unsigned long fg, bg, pixels [512]; +static int npixels; + +static void +init_greynetic (Display *dpy, Window window) +{ + int i; + XGCValues gcv; + XWindowAttributes xgwa; + Colormap cmap; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + npixels = 0; + gcv.foreground= fg= get_pixel_resource("foreground","Foreground", dpy, cmap); + gcv.background= bg= get_pixel_resource("background","Background", dpy, cmap); + gcv.fill_style= FillOpaqueStippled; + gc = XCreateGC (dpy, window, GCForeground|GCBackground|GCFillStyle, &gcv); + + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + + i = 0; +#define BITS(n,w,h) \ + pixmaps [i++] = XCreatePixmapFromBitmapData (dpy, window, n, w, h, 1, 0, 1) + + BITS (stipple_bits, stipple_width, stipple_height); + BITS (cross_weave_bits, cross_weave_width, cross_weave_height); + BITS (dimple1_bits, dimple1_width, dimple1_height); + BITS (dimple3_bits, dimple3_width, dimple3_height); + BITS (flipped_gray_bits, flipped_gray_width, flipped_gray_height); + BITS (gray1_bits, gray1_width, gray1_height); + BITS (gray3_bits, gray3_width, gray3_height); + BITS (hlines2_bits, hlines2_width, hlines2_height); + BITS (light_gray_bits, light_gray_width, light_gray_height); + BITS (root_weave_bits, root_weave_width, root_weave_height); + BITS (vlines2_bits, vlines2_width, vlines2_height); + BITS (vlines3_bits, vlines3_width, vlines3_height); +} + +static void +greynetic (Display *dpy, Window window) +{ + static int tick = 500, xlim, ylim; + static Colormap cmap; + int x, y, w, h, i; + XGCValues gcv; + if (tick++ == 500) + { + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + tick = 0; + xlim = xgwa.width; + ylim = xgwa.height; + cmap = xgwa.colormap; + } + for (i = 0; i < 10; i++) /* minimize area, but don't try too hard */ + { + w = 50 + random () % (xlim - 50); + h = 50 + random () % (ylim - 50); + if (w + h < xlim && w + h < ylim) + break; + } + x = random () % (xlim - w); + y = random () % (ylim - h); + gcv.stipple = pixmaps [random () % NBITS]; + if (mono_p) + { + MONO: + if (random () & 1) + gcv.foreground = fg, gcv.background = bg; + else + gcv.foreground = bg, gcv.background = fg; + } + else + { + XColor fgc, bgc; + if (npixels == sizeof (pixels) / sizeof (unsigned long)) + goto REUSE; + fgc.flags = bgc.flags = DoRed|DoGreen|DoBlue; + fgc.red = random (); + fgc.green = random (); + fgc.blue = random (); + bgc.red = random (); + bgc.green = random (); + bgc.blue = random (); + if (! XAllocColor (dpy, cmap, &fgc)) + goto REUSE; + pixels [npixels++] = fgc.pixel; + gcv.foreground = fgc.pixel; + if (! XAllocColor (dpy, cmap, &bgc)) + goto REUSE; + pixels [npixels++] = bgc.pixel; + gcv.background = bgc.pixel; + goto DONE; + REUSE: + if (npixels <= 0) + { + mono_p = 1; + goto MONO; + } + gcv.foreground = pixels [random () % npixels]; + gcv.background = pixels [random () % npixels]; + DONE: + ; + } + XChangeGC (dpy, gc, GCStipple|GCForeground|GCBackground, &gcv); + XFillRectangle (dpy, window, gc, x, y, w, h); + XSync (dpy, True); +} + + +char *progclass = "Greynetic"; + +char *defaults [] = { + "Greynetic.background: black", /* to placate SGI */ + "Greynetic.foreground: white", + "*delay: 0", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_greynetic (dpy, window); + while (1) + { + greynetic (dpy, window); + if (delay) usleep (delay); + } +} diff --git a/hacks/greynetic.man b/hacks/greynetic.man new file mode 100644 index 00000000..86381123 --- /dev/null +++ b/hacks/greynetic.man @@ -0,0 +1,52 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +greynetic - draw random stippled/color rectangles +.SH SYNOPSIS +.B greynetic +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-delay \fIusecs\fP] +.SH DESCRIPTION +The \fIgreynetic\fP program draws random rectangles. +.SH OPTIONS +.I greynetic +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fImicroseconds\fP +Slow it down. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. diff --git a/hacks/halo.c b/hacks/halo.c new file mode 100644 index 00000000..470a9e90 --- /dev/null +++ b/hacks/halo.c @@ -0,0 +1,450 @@ +/* xscreensaver, Copyright (c) 1993, 1995, 1996, 1997 + * 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. + */ + +/* I wanted to lay down new circles with TV:ALU-ADD instead of TV:ALU-XOR, + but X doesn't support arithmetic combinations of pixmaps!! What losers. + I suppose I could crank out the 2's compliment math by hand, but that's + a real drag... + + This would probably look good with shapes other than circles as well. + + */ + +#include "screenhack.h" +#include + +struct circle { + int x, y, radius; + int increment; + int dx, dy; +}; + +static enum color_mode { + seuss_mode, ramp_mode, random_mode +} cmode; + + +static struct circle *circles; +static int count, global_count; +static Pixmap pixmap, buffer; +static int width, height, global_inc; +static int delay, delay2, cycle_delay; +static unsigned long fg_pixel, bg_pixel; +static GC draw_gc, erase_gc, copy_gc, merge_gc; +static Bool anim_p; +static Colormap cmap; + +static int ncolors; +static XColor *colors; +static Bool cycle_p; +static int fg_index; +static int bg_index; + + +#define min(x,y) ((x)<(y)?(x):(y)) +#define max(x,y) ((x)>(y)?(x):(y)) + +static void +init_circles_1 (Display *dpy, Window window) +{ + int i; + count = (global_count ? global_count + : (3 + (random () % max (1, (min (width, height) / 50))) + + (random () % max (1, (min (width, height) / 50))))); + circles = (struct circle *) malloc (count * sizeof (struct circle)); + for (i = 0; i < count; i++) + { + circles [i].x = 10 + random () % (width - 20); + circles [i].y = 10 + random () % (height - 20); + if (global_inc) + circles [i].increment = global_inc; + else + { /* prefer smaller increments to larger ones */ + int j = 8; + int inc = ((random()%j) + (random()%j) + (random()%j)) - ((j*3)/2); + if (inc < 0) inc = -inc + 3; + circles [i].increment = inc + 3; + } + circles [i].radius = random () % circles [i].increment; + circles [i].dx = ((random () % 3) - 1) * (1 + random () % 5); + circles [i].dy = ((random () % 3) - 1) * (1 + random () % 5); + } +} + +static void +init_circles (Display *dpy, Window window) +{ + XGCValues gcv; + XWindowAttributes xgwa; + char *mode_str = 0; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + global_count = get_integer_resource ("count", "Integer"); + if (global_count < 0) global_count = 0; + global_inc = get_integer_resource ("increment", "Integer"); + if (global_inc < 0) global_inc = 0; + anim_p = get_boolean_resource ("animate", "Boolean"); + delay = get_integer_resource ("delay", "Integer"); + delay2 = get_integer_resource ("delay2", "Integer") * 1000000; + cycle_delay = get_integer_resource ("cycleDelay", "Integer"); + mode_str = get_string_resource ("colorMode", "ColorMode"); + if (! mode_str) cmode = random_mode; + else if (!strcmp (mode_str, "seuss")) cmode = seuss_mode; + else if (!strcmp (mode_str, "ramp")) cmode = ramp_mode; + else if (!strcmp (mode_str, "random")) cmode = random_mode; + else { + fprintf (stderr, + "%s: colorMode must be seuss, ramp, or random, not \"%s\"\n", + progname, mode_str); + exit (1); + } + + if (mono_p) cmode = seuss_mode; + if (cmode == random_mode) + cmode = ((random()&3) == 1) ? ramp_mode : seuss_mode; + + if (cmode == ramp_mode) + anim_p = False; /* This combo doesn't work right... */ + + ncolors = get_integer_resource ("colors", "Colors"); + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + + if (mono_p) + colors = 0; + else + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + + cycle_p = mono_p ? False : get_boolean_resource ("cycle", "Cycle"); + + + if (mono_p) + ; + else if (random() % (cmode == seuss_mode ? 2 : 10)) + make_uniform_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, &cycle_p, True); + else + make_smooth_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, &cycle_p, True); + + if (ncolors <= 2) mono_p = True; + if (mono_p) cycle_p = False; + if (mono_p) cmode = seuss_mode; + + if (mono_p) + { + fg_pixel = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + bg_pixel = get_pixel_resource ("background", "Background", dpy, cmap); + } + else + { + fg_index = 0; + bg_index = ncolors / 4; + if (fg_index == bg_index) bg_index++; + fg_pixel = colors[fg_index].pixel; + bg_pixel = colors[bg_index].pixel; + } + + width = max (50, xgwa.width); + height = max (50, xgwa.height); + +#ifdef DEBUG + width/=2; height/=2; +#endif + + pixmap = XCreatePixmap (dpy, window, width, height, 1); + if (cmode == seuss_mode) + buffer = XCreatePixmap (dpy, window, width, height, 1); + else + buffer = 0; + + gcv.foreground = 1; + gcv.background = 0; + draw_gc = XCreateGC (dpy, pixmap, GCForeground | GCBackground, &gcv); + gcv.foreground = 0; + erase_gc = XCreateGC (dpy, pixmap, GCForeground, &gcv); + gcv.foreground = fg_pixel; + gcv.background = bg_pixel; + copy_gc = XCreateGC (dpy, window, GCForeground | GCBackground, &gcv); + + if (cmode == seuss_mode) + { + gcv.foreground = 1; + gcv.background = 0; + gcv.function = GXxor; + merge_gc = XCreateGC (dpy, pixmap, + GCForeground | GCBackground | GCFunction, &gcv); + } + else + { + gcv.foreground = fg_pixel; + gcv.background = bg_pixel; + gcv.function = GXcopy; + merge_gc = XCreateGC (dpy, window, + GCForeground | GCBackground | GCFunction, &gcv); + } + + init_circles_1 (dpy, window); + XClearWindow (dpy, window); + if (buffer) XFillRectangle (dpy, buffer, erase_gc, 0, 0, width, height); +} + +static void +run_circles (Display *dpy, Window window) +{ + int i; + static int iterations = 0; + static int oiterations = 0; + static Bool first_time_p = True; + Bool done = False; + Bool inhibit_sleep = False; + XFillRectangle (dpy, pixmap, erase_gc, 0, 0, width, height); + for (i = 0; i < count; i++) + { + int radius = circles [i].radius; + int inc = circles [i].increment; + + if (! (iterations & 1)) /* never stop on an odd number of iterations */ + ; + else if (radius == 0) /* eschew inf */ + ; + else if (radius < 0) /* stop when the circles are points */ + done = True; + else /* stop when the circles fill the window */ + { + /* Probably there's a simpler way to ask the musical question, + "is this square completely enclosed by this circle," but I've + forgotten too much trig to know it... (That's not really the + right question anyway, but the right question is too hard.) */ + double x1 = ((double) (-circles [i].x)) / ((double) radius); + double y1 = ((double) (-circles [i].y)) / ((double) radius); + double x2 = ((double) (width - circles [i].x)) / ((double) radius); + double y2 = ((double) (height - circles [i].y)) / ((double) radius); + x1 *= x1; x2 *= x2; y1 *= y1; y2 *= y2; + if ((x1 + y1) < 1 && (x2 + y2) < 1 && (x1 + y2) < 1 && (x2 + y1) < 1) + done = True; + } + + if (radius > 0 && + (cmode == seuss_mode || /* drawing all circles, or */ + circles [0].increment < 0)) /* on the way back in */ + { + XFillArc (dpy, + (cmode == seuss_mode ? pixmap : window), + (cmode == seuss_mode ? draw_gc : merge_gc), + circles [i].x - radius, circles [i].y - radius, + radius * 2, radius * 2, 0, 360*64); + } + circles [i].radius += inc; + } + + if (cycle_p && cmode != seuss_mode) + { + struct timeval now; + static struct timeval then = { 0, }; + unsigned long diff; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; + gettimeofday(&now, &tzp); +#else + gettimeofday(&now); +#endif + diff = (((now.tv_sec - then.tv_sec) * 1000000) + + (now.tv_usec - then.tv_usec)); + if (diff > cycle_delay) + { + rotate_colors (dpy, cmap, colors, ncolors, 1); + then = now; + } + } + + if (anim_p && !first_time_p) + inhibit_sleep = !done; + + if (done) + { + if (anim_p) + { + first_time_p = False; + for (i = 0; i < count; i++) + { + circles [i].x += circles [i].dx; + circles [i].y += circles [i].dy; + circles [i].radius %= circles [i].increment; + if (circles [i].x < 0 || circles [i].x >= width) + { + circles [i].dx = -circles [i].dx; + circles [i].x += (2 * circles [i].dx); + } + if (circles [i].y < 0 || circles [i].y >= height) + { + circles [i].dy = -circles [i].dy; + circles [i].y += (2 * circles [i].dy); + } + } + } + else if (circles [0].increment < 0) + { + /* We've zoomed out and the screen is blank -- re-pick the + center points, and shift the colors. + */ + free (circles); + init_circles_1 (dpy, window); + if (! mono_p) + { + fg_index = (fg_index + 1) % ncolors; + bg_index = (fg_index + (ncolors/2)) % ncolors; + XSetForeground (dpy, copy_gc, colors [fg_index].pixel); + XSetBackground (dpy, copy_gc, colors [bg_index].pixel); + } + } +#if 1 + /* Sometimes go out from the inside instead of the outside */ + else if ((random () % 10) == 0) + { +# if 0 + if (! mono_p) + { + unsigned long swap = fg_index; + fg_index = bg_index; + bg_index = swap; + XSetForeground (dpy, copy_gc, colors [fg_index].pixel); + XSetBackground (dpy, copy_gc, colors [bg_index].pixel); + } +# endif + iterations = 0; /* ick */ + for (i = 0; i < count; i++) + circles [i].radius %= circles [i].increment; + } +#endif + else + { + oiterations = iterations; + for (i = 0; i < count; i++) + { + circles [i].increment = -circles [i].increment; + circles [i].radius += (2 * circles [i].increment); + } + } + } + + if (buffer) + XCopyPlane (dpy, pixmap, buffer, merge_gc, 0, 0, width, height, 0, 0, 1); + else if (cmode != seuss_mode) + { + + if (!mono_p) + { + fg_index++; + bg_index++; + if (fg_index >= ncolors) fg_index = 0; + if (bg_index >= ncolors) bg_index = 0; + XSetForeground (dpy, merge_gc, colors [fg_index].pixel); + } + + if (circles [0].increment >= 0) + inhibit_sleep = True; + else if (done && cmode == seuss_mode) + XFillRectangle (dpy, window, merge_gc, 0, 0, width, height); + } + else + XCopyPlane (dpy, pixmap, window, merge_gc, 0, 0, width, height, 0, 0, 1); + + /* buffer is only used in seuss-mode or anim-mode */ + if (buffer && (anim_p + ? (done || (first_time_p && (iterations & 1))) + : (iterations & 1))) + { + XCopyPlane (dpy, buffer, window, copy_gc, 0, 0, width, height, 0, 0, 1); + XSync (dpy, True); + if (anim_p && done) + XFillRectangle (dpy, buffer, erase_gc, 0, 0, width, height); + } + +#ifdef DEBUG + XCopyPlane (dpy, pixmap, window, copy_gc, 0,0,width,height,width,height, 1); + if (buffer) + XCopyPlane (dpy, buffer, window, copy_gc, 0,0,width,height,0,height, 1); + XSync (dpy, True); +#endif + + if (done) + iterations = 0; + else + iterations++; + + if (delay && !inhibit_sleep) + { + static Bool really_first_p = True; + int direction = 1; + int d = delay; + if (done && cycle_p && cmode != seuss_mode && !really_first_p) + { + d = delay2; + if (! (random() % 10)) + direction = -1; + } + if (done) + really_first_p = False; + + XSync(dpy, False); + + if (cycle_p && cycle_delay) + { + int i = 0; + while (i < d) + { + rotate_colors (dpy, cmap, colors, ncolors, direction); + usleep(cycle_delay); + i += cycle_delay; + } + } + else + usleep (d); + } +} + + +char *progclass = "Halo"; + +char *defaults [] = { + "Halo.background: black", /* to placate SGI */ + "Halo.foreground: white", + "*colorMode: random", + "*colors: 100", + "*cycle: true", + "*count: 0", + "*delay: 100000", + "*delay2: 20", + "*cycleDelay: 100000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-count", ".count", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-cycle-delay", ".cycleDelay", XrmoptionSepArg, 0 }, + { "-animate", ".animate", XrmoptionNoArg, "True" }, + { "-mode", ".colorMode", XrmoptionSepArg, 0 }, + { "-colors", ".colors", XrmoptionSepArg, 0 }, + { "-cycle", ".cycle", XrmoptionNoArg, "True" }, + { "-no-cycle", ".cycle", XrmoptionNoArg, "False" }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_circles (dpy, window); + while (1) + run_circles (dpy, window); +} diff --git a/hacks/halo.man b/hacks/halo.man new file mode 100644 index 00000000..0d3d4e01 --- /dev/null +++ b/hacks/halo.man @@ -0,0 +1,80 @@ +.TH XScreenSaver 1 "12-Jun-97" "X Version 11" +.SH NAME +halo - draw circular patterns +.SH SYNOPSIS +.B halo +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-count \fIint\fP] [\-delay \fIusecs\fP] [\-mode seuss | ramp | random ] [\-animate] [\-colors \fIinteger\fP] [\-cycle] [\-no\-cycle] [\-cycle\-delay \fIusecs\fP] +.SH DESCRIPTION +The \fIhalo\fP program draws cool patterns based on circles. +.SH OPTIONS +.I halo +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-count \fIinteger\fP +How many circles to draw. Default 0, meaning random. +.TP 8 +.B \-mode "seuss | ramp | random" +In \fIseuss\fP mode, alternating striped curves will be drawn. + +In \fIramp\fP mode, a color ramp will be drawn. + +\fIrandom\fP means pick the mode randomly. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 100000, or about 0.1 second. +.TP 8 +.B \-colors \fIinteger\fP +How many colors to use. Default 100. +.TP 8 +.B \-animate +If specified, then the centerpoints of the circles will bounce around. +Otherwise, the circles will be drawn once, erased, and a new set of +circles will be drawn. +.TP 8 +.B \-cycle +.TP 8 +.B \-no\-cycle +Whether to do colormap cycling. Default is to cycle. +.TP 8 +.B \-cycle\-delay +Number of microseconds between shifts of the colormap; default 100000, +or 1/10th second. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1993 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. +.SH AUTHOR +Jamie Zawinski , 6-jul-93. diff --git a/hacks/helix.c b/hacks/helix.c new file mode 100644 index 00000000..1fe62e47 --- /dev/null +++ b/hacks/helix.c @@ -0,0 +1,303 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +/* Algorithm from a Mac program by Chris Tate, written in 1988 or so. */ + +/* 18-Sep-97: Johannes Keukelaar (johannes@nada.kth.se): Improved screen + * eraser. + * 10-May-97: merged ellipse code by Dan Stromberg + * as found in xlockmore 4.03a10. + * 1992: jwz created. + */ + +#include +#include "screenhack.h" +#include "erase.h" + +static double sins [360]; +static double coss [360]; + +static GC draw_gc; +static unsigned int default_fg_pixel; +static int sleep_time; + +static void +init_helix (Display *dpy, Window window) +{ + int i; + XGCValues gcv; + XWindowAttributes xgwa; + Colormap cmap; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + gcv.foreground = default_fg_pixel = + get_pixel_resource ("foreground", "Foreground", dpy, cmap); + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = get_pixel_resource ("background", "Background", dpy, cmap); + + for (i = 0; i < 360; i++) + { + sins [i] = sin ((((double) i) / 180.0) * M_PI); + coss [i] = cos ((((double) i) / 180.0) * M_PI); + } +} + +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 (Display *dpy, Window window, + int radius1, int radius2, int d_angle, + int factor1, int factor2, int factor3, int factor4) +{ + XWindowAttributes xgwa; + int width, height; + int xmid, ymid; + int x1, y1, x2, y2, angle, limit; + int i; + + XClearWindow (dpy, window); + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + + xmid = width / 2; + ymid = height / 2; + x1 = xmid; + y1 = ymid + radius2; + x2 = xmid; + y2 = ymid + radius1; + angle = 0; + limit = 1 + (360 / gcd (360, d_angle)); + + for (i = 0; i < limit; i++) + { + int tmp; +#define pmod(x,y) (tmp=((x) % (y)), (tmp >= 0 ? tmp : (tmp + (y)))) + + x1 = xmid + (((double) radius1) * sins [pmod ((angle * factor1), 360)]); + y1 = ymid + (((double) radius2) * coss [pmod ((angle * factor2), 360)]); + XDrawLine (dpy, window, draw_gc, x1, y1, x2, y2); + x2 = xmid + (((double) radius2) * sins [pmod ((angle * factor3), 360)]); + y2 = ymid + (((double) radius1) * coss [pmod ((angle * factor4), 360)]); + + XDrawLine (dpy, window, draw_gc, x1, y1, x2, y2); + angle += d_angle; + XFlush (dpy); + } +} + +static void +trig (Display *dpy, Window window, + int d_angle, int factor1, int factor2, + int offset, int d_angle_offset, int dir, int density) +{ + XWindowAttributes xgwa; + int width, height; + int xmid, ymid; + int x1, y1, x2, y2; + int tmp, angle; + Colormap cmap; + + XClearWindow (dpy, window); + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + width = xgwa.width; + height = xgwa.height; + + xmid = width / 2; + ymid = height / 2; + + while (d_angle >= -360 && d_angle <= 360) + { + angle = d_angle + d_angle_offset; + x1 = (sins [pmod(angle * factor1, 360)] * xmid) + xmid; + y1 = (coss [pmod(angle * factor1, 360)] * ymid) + ymid; + x2 = (sins [pmod(angle * factor2 + offset, 360)] * xmid) + xmid; + y2 = (coss [pmod(angle * factor2 + offset, 360)] * ymid) + ymid; + XDrawLine(dpy, window, draw_gc, x1, y1, x2, y2); + tmp = (int) 360 / (2 * density * factor1 * factor2); + if (tmp == 0) /* Do not want it getting stuck... */ + tmp = 1; /* Would not need if floating point */ + d_angle += dir * tmp; + } +} + +#define min(a,b) ((a)<(b)?(a):(b)) + +static void +random_helix (Display *dpy, Window window, XColor *color, Bool *got_color) +{ + Colormap cmap; + int width, height; + int radius, radius1, radius2, d_angle, factor1, factor2, factor3, factor4; + double divisor; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + cmap = xgwa.colormap; + + radius = min (width, height) / 2; + + d_angle = 0; + factor1 = 2; + factor2 = 2; + factor3 = 2; + factor4 = 2; + + divisor = ((frand (3.0) + 1) * (((random() & 1) * 2) - 1)); + + if ((random () & 1) == 0) + { + radius1 = radius; + radius2 = radius / divisor; + } + else + { + radius2 = radius; + radius1 = radius / divisor; + } + + while (gcd (360, d_angle) >= 2) + d_angle = random () % 360; + +#define random_factor() \ + (((random() % 7) ? ((random() & 1) + 1) : 3) \ + * (((random() & 1) * 2) - 1)) + + while (gcd (gcd (gcd (factor1, factor2), factor3), factor4) != 1) + { + factor1 = random_factor (); + factor2 = random_factor (); + factor3 = random_factor (); + factor4 = random_factor (); + } + + if (mono_p) + XSetForeground (dpy, draw_gc, default_fg_pixel); + else + { + hsv_to_rgb (random () % 360, frand (1.0), frand (0.5) + 0.5, + &color->red, &color->green, &color->blue); + if ((*got_color = XAllocColor (dpy, cmap, color))) + XSetForeground (dpy, draw_gc, color->pixel); + else + XSetForeground (dpy, draw_gc, default_fg_pixel); + } + helix (dpy, window, radius1, radius2, d_angle, + factor1, factor2, factor3, factor4); +} + +static void +random_trig (Display *dpy, Window window, XColor *color, Bool *got_color) +{ + Colormap cmap; + int width, height; + int radius, d_angle, factor1, factor2; + int offset, d_angle_offset, dir, density; + + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + cmap = xgwa.colormap; + + radius = min (width, height) / 2; + + d_angle = 0; + factor1 = (random() % 8) + 1; + do { + factor2 = (random() % 8) + 1; + } while (factor1 == factor2); + + dir = (random() & 1) ? 1 : -1; + d_angle_offset = random() % 360; + offset = ((random() % ((360 / 4) - 1)) + 1) / 4; + density = 1 << ((random() % 4) + 4); /* Higher density, higher angles */ + + if (mono_p) + XSetForeground (dpy, draw_gc, default_fg_pixel); + else + { + hsv_to_rgb (random () % 360, frand (1.0), frand (0.5) + 0.5, + &color->red, &color->green, &color->blue); + if ((*got_color = XAllocColor (dpy, cmap, color))) + XSetForeground (dpy, draw_gc, color->pixel); + else + XSetForeground (dpy, draw_gc, default_fg_pixel); + } + trig (dpy, window, d_angle, factor1, factor2, + offset, d_angle_offset, dir, density); +} + +static void +random_helix_or_trig (Display *dpy, Window window) +{ + Bool free_color = False; + XColor color; + int width, height; + XWindowAttributes xgwa; + Colormap cmap; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + cmap = xgwa.colormap; + + if (random() & 1) + random_helix(dpy, window, &color, &free_color); + else + random_trig(dpy, window, &color, &free_color); + + XSync (dpy, True); + sleep ( sleep_time ); + + erase_full_window(dpy, window); + + if (free_color) XFreeColors (dpy, cmap, &color.pixel, 1, 0); + XSync (dpy, True); + sleep (1); +} + + +char *progclass = "Helix"; + +char *defaults [] = { + "Helix.background: black", /* to placate SGI */ + "*delay: 5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0 }, +}; +int options_size = (sizeof (options) / sizeof (options[0])); + +void +screenhack (Display *dpy, Window window) +{ + sleep_time = get_integer_resource("delay", "Integer"); + init_helix (dpy, window); + while (1) + random_helix_or_trig (dpy, window); +} diff --git a/hacks/helix.man b/hacks/helix.man new file mode 100644 index 00000000..abc0a827 --- /dev/null +++ b/hacks/helix.man @@ -0,0 +1,63 @@ +.TH XScreenSaver 1 "18-sep-97" "X Version 11" +.SH NAME +helix - draw helical string-art patterns +.SH SYNOPSIS +.B helix +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-erase\-speed \fIusecs\fP] [\-erase\-mode \fIinteger\fP] [\-delay \fIseconds\fP] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIhelix\fP program draws interesting patterns composed of line segments +in random colors. +.SH OPTIONS +.I helix +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-erase\-speed \fIusecs\fP +This controls the speed at which the screen will be erased. Lower numbers +erase faster. +.TP 8 +.B \-erase\-mode \fIinteger\fP +This sets the erase mode. Mode \-1 chooses a random mode each time. There +are currently 6 modes defined (0\-5). +.TP 8 +.B \-delay \fIseconds\fP +This sets the number of seconds that the helix will be on the screen. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. +Screen eraser improved by Johannes Keukelaar , + 18-sep-97. diff --git a/hacks/hopalong.c b/hacks/hopalong.c new file mode 100644 index 00000000..cb663ac3 --- /dev/null +++ b/hacks/hopalong.c @@ -0,0 +1,260 @@ +/* -*- Mode: C; tab-width: 4 -*- + * hop --- real plane fractals. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)hop.c 4.02 97/04/01 xlockmore"; +#endif + +/* 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. + * + * Revision History: + * Changes of David Bagley + * 10-May-97: jwz@netscape.com: ported from xlockmore 4.03a10 to be a + * standalone program and thus usable with xscreensaver + * (I threw away my 1992 port and started over.) + * 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 sine hop + * + * (12-Aug-92: jwz@lucid.com: made xlock version run standalone.) + * + * Changes of Patrick J. Naughton + * 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. + */ + +#ifdef STANDALONE +# define PROGCLASS "Hopalong" +# define HACK_INIT init_hop +# define HACK_DRAW draw_hop +# define HACK_FREE release_hop +# define hop_opts xlockmore_opts +# define DEFAULTS "*count: 1000 \n" \ + "*cycles: 2500 \n" \ + "*delay: 10000 \n" \ + "*ncolors: 200 \n" +# define SMOOTH_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include "erase.h" +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +static Bool jong; +static Bool sine; + +#define DEF_JONG "False" +#define DEF_SINE "False" + +static XrmOptionDescRec opts[] = +{ + {"-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 *) & jong, "jong", "Jong", DEF_JONG, t_Bool}, + {(caddr_t *) & sine, "sine", "Sine", DEF_SINE, t_Bool} +}; +static OptionStruct desc[] = +{ + {"-/+jong", "turn on/off jong format"}, + {"-/+sine", "turn on/off sine format"} +}; + +ModeSpecOpt hop_opts = { 4, opts, 2, vars, desc }; + + +#define SQRT 0 +#define JONG 1 +#define SINE 2 +#ifdef OFFENDING +#define OPS 2 /* Sine might be too close to a Swastika for some... */ +#else +#define OPS 3 +#endif + +typedef struct { + int centerx; + int centery; /* center of the screen */ + double a; + double b; + double c; + double d; + double i; + double j; /* hopalong parameters */ + int inc; + int pix; + int op; + int count; + int bufsize; +} hopstruct; + +static hopstruct *hops = NULL; +static XPoint *pointBuffer = 0; /* pointer for XDrawPoints */ + +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_WIN_WIDTH(mi) / 2; + hp->centery = MI_WIN_HEIGHT(mi) / 2; + /* Make the other operations less common since they are less interesting */ + if (MI_WIN_IS_FULLRANDOM(mi)) { + hp->op = NRAND(OPS+2); /* jwz: make the others a bit more likely. */ + if (hp->op >= OPS) + hp->op = SQRT; + } else { + hp->op = SQRT; + if (jong) + hp->op = JONG; + else if (sine) + hp->op = SINE; + } + switch (hp->op) { + case SQRT: + range = sqrt((double) hp->centerx * hp->centerx + + (double) hp->centery * hp->centery) / (10.0 + NRAND(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() & 1) + hp->c = 0.0; + break; + case JONG: + hp->a = (LRAND() / MAXRAND) * 2.0 * M_PI - M_PI; + hp->b = (LRAND() / MAXRAND) * 2.0 * M_PI - M_PI; + hp->c = (LRAND() / MAXRAND) * 2.0 * M_PI - M_PI; + hp->d = (LRAND() / MAXRAND) * 2.0 * M_PI - M_PI; + break; + case SINE: + hp->a = M_PI + ((LRAND() / MAXRAND) * 2.0 - 1.0) * 0.7; + break; + } + if (MI_NPIXELS(mi) > 2) + hp->pix = NRAND(MI_NPIXELS(mi)); + hp->i = hp->j = 0.0; + hp->inc = (int) ((LRAND() / MAXRAND) * 200) - 100; + hp->bufsize = MI_BATCHCOUNT(mi); + + if (!pointBuffer) + pointBuffer = (XPoint *) malloc(hp->bufsize * sizeof (XPoint)); + + XClearWindow(display, MI_WINDOW(mi)); + + XSetForeground(display, gc, MI_WIN_WHITE_PIXEL(mi)); + hp->count = 0; +} + + +void +draw_hop(ModeInfo * mi) +{ + hopstruct *hp = &hops[MI_SCREEN(mi)]; + double oldj, oldi; + XPoint *xp = pointBuffer; + int k = hp->bufsize; + + 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 SQRT: + 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 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: + 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), + pointBuffer, hp->bufsize, CoordModeOrigin); + if (++hp->count > MI_CYCLES(mi)) { +#ifdef STANDALONE + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif /* STANDALONE */ + init_hop(mi); + } +} + +void +release_hop(ModeInfo * mi) +{ + if (hops != NULL) { + (void) free((void *) hops); + hops = NULL; + } + if (pointBuffer) { + (void) free((void *) pointBuffer); + pointBuffer = NULL; + } +} + +void +refresh_hop(ModeInfo * mi) +{ + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); +} diff --git a/hacks/hopalong.man b/hacks/hopalong.man new file mode 100644 index 00000000..bbb15be0 --- /dev/null +++ b/hacks/hopalong.man @@ -0,0 +1,78 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +hopalong - draw real plane fractals +.SH SYNOPSIS +.B hopalong +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] [\-jong] [\-no\-jong] [\-jong] [\-no\-sine] + +.SH DESCRIPTION +The \fIhopalong\fP program generates real plane fractals as described in +the September 1986 issue of Scientific American. +.SH OPTIONS +.I hopalong +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP +How long to run each batch. Default 2500 pixels. +.TP 8 +.B \-count \fIinteger\fP +How many pixels should be drawn before a color change. Default 1000. +.TP 8 +.B \-jong \fIinteger\fP +.TP 8 +.B \-no\-jong \fIinteger\fP +Whether to use the Jong format (default is to choose randomly.) + +.TP 8 +.B \-sine \fIinteger\fP +.TP 8 +.B \-no\-sine \fIinteger\fP +Whether to use the Sine format (default is to choose randomly.) + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Patrick J. Naughton , 23-mar-88. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 13-aug-92, and again on 10-May-97. diff --git a/hacks/hypercube.c b/hacks/hypercube.c new file mode 100644 index 00000000..04b1560a --- /dev/null +++ b/hacks/hypercube.c @@ -0,0 +1,328 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996 + * 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. + * + * This code derived from TI Explorer Lisp code by Joe Keane, Fritz Mueller, + * and Jamie Zawinski. + */ + +#include +#include "screenhack.h" + +static Display *dpy; +static Window window; +static GC color0, color1, color2, color3, color4, color5, color6, color7; +static GC black; + +static int delay; + +static int observer_z; +static int x_offset, y_offset; +static int unit_pixels; + +struct point_state { + int old_x, old_y; + int new_x, new_y; + Bool same_p; +}; + +static void +move_line (struct point_state *state0, struct point_state *state1, GC gc) +{ + if (state0->same_p && state1->same_p) + return; + if (mono_p) + { + XDrawLine (dpy, window, black, + state0->old_x, state0->old_y, state1->old_x, state1->old_y); + XDrawLine (dpy, window, gc, + state0->new_x, state0->new_y, state1->new_x, state1->new_y); + } + else + { + XSegment segments [2]; + segments [0].x1 = state0->old_x; segments [0].y1 = state0->old_y; + segments [0].x2 = state1->old_x; segments [0].y2 = state1->old_y; + segments [1].x1 = state0->new_x; segments [1].y1 = state0->new_y; + segments [1].x2 = state1->new_x; segments [1].y2 = state1->new_y; + XDrawSegments (dpy, window, gc, segments, 2); + } +} + +static void +hyper (double xy, double xz, double yz, double xw, double yw, double zw) +{ + double cos_xy = cos (xy), sin_xy = sin (xy); + double cos_xz = cos (xz), sin_xz = sin (xz); + double cos_yz = cos (yz), sin_yz = sin (yz); + double cos_xw = cos (xw), sin_xw = sin (xw); + double cos_yw = cos (yw), sin_yw = sin (yw); + double cos_zw = cos (zw), sin_zw = sin (zw); + + double ax = 1.0, ay = 0.0, az = 0.0, aw = 0.0; + double bx = 0.0, by = 1.0, bz = 0.0, bw = 0.0; + double cx = 0.0, cy = 0.0, cz = 1.0, cw = 0.0; + double dx = 0.0, dy = 0.0, dz = 0.0, dw = 1.0; + + double _tmp0_, _tmp1_; + + struct point_state points [16]; + memset (points, 0, sizeof (points)); + +#define mmmm (&points[0]) +#define mmmp (&points[1]) +#define mmpm (&points[2]) +#define mmpp (&points[3]) +#define mpmm (&points[4]) +#define mpmp (&points[5]) +#define mppm (&points[6]) +#define mppp (&points[7]) +#define pmmm (&points[8]) +#define pmmp (&points[9]) +#define pmpm (&points[10]) +#define pmpp (&points[11]) +#define ppmm (&points[12]) +#define ppmp (&points[13]) +#define pppm (&points[14]) +#define pppp (&points[15]) + + while (1) + { + double temp_mult; + +#define compute(a,b,c,d,point_state) \ + temp_mult = (unit_pixels / (((a*az) + (b*bz) + (c*cz) + (d*dz) + \ + (a*aw) + (b*bw) + (c*cw) + (d*dw)) \ + - observer_z)); \ + point_state->old_x = point_state->new_x; \ + point_state->old_y = point_state->new_y; \ + point_state->new_x = ((((a*ax) + (b*bx) + (c*cx) + (d*dx)) * temp_mult) \ + + x_offset); \ + point_state->new_y = ((((a*ay) + (b*by) + (c*cy) + (d*dy)) * temp_mult) \ + + y_offset); \ + point_state->same_p = (point_state->old_x == point_state->new_x && \ + point_state->old_y == point_state->new_y); + + compute (-1, -1, -1, -1, mmmm); + compute (-1, -1, -1, 1, mmmp); + compute (-1, -1, 1, -1, mmpm); + compute (-1, -1, 1, 1, mmpp); + compute (-1, 1, -1, -1, mpmm); + compute (-1, 1, -1, 1, mpmp); + compute (-1, 1, 1, -1, mppm); + compute (-1, 1, 1, 1, mppp); + compute ( 1, -1, -1, -1, pmmm); + compute ( 1, -1, -1, 1, pmmp); + compute ( 1, -1, 1, -1, pmpm); + compute ( 1, -1, 1, 1, pmpp); + compute ( 1, 1, -1, -1, ppmm); + compute ( 1, 1, -1, 1, ppmp); + compute ( 1, 1, 1, -1, pppm); + compute ( 1, 1, 1, 1, pppp); + + move_line (mmmm, mmmp, color0); + move_line (mmmm, mmpm, color0); + move_line (mmpm, mmpp, color0); + move_line (mmmp, mmpp, color0); + + move_line (pmmm, pmmp, color1); + move_line (pmmm, pmpm, color1); + move_line (pmpm, pmpp, color1); + move_line (pmmp, pmpp, color1); + + move_line (mpmm, mpmp, color2); + move_line (mpmm, mppm, color2); + move_line (mppm, mppp, color2); + move_line (mpmp, mppp, color2); + + move_line (mmpp, mppp, color3); + move_line (mmpp, pmpp, color3); + move_line (pmpp, pppp, color3); + move_line (mppp, pppp, color3); + + move_line (mmmm, mpmm, color4); + move_line (mmmm, pmmm, color4); + move_line (mpmm, ppmm, color4); + move_line (pmmm, ppmm, color4); + + move_line (mmmp, mpmp, color5); + move_line (mmmp, pmmp, color5); + move_line (pmmp, ppmp, color5); + move_line (mpmp, ppmp, color5); + + move_line (mmpm, mppm, color6); + move_line (mmpm, pmpm, color6); + move_line (pmpm, pppm, color6); + move_line (mppm, pppm, color6); + + move_line (ppmm, ppmp, color7); + move_line (ppmm, pppm, color7); + move_line (pppm, pppp, color7); + move_line (ppmp, pppp, color7); + + /* If you get error messages about the following forms, and you think you're + using an ANSI C conforming compiler, then you're mistaken. Possibly you're + mixing an ANSI compiler with a non-ANSI preprocessor, or vice versa. + Regardless, your system is broken; it's not a bug in this program. + */ +#if defined(__STDC__) || defined(__ANSI_CPP__) +# define rotate(name,dim0,dim1,cos,sin) \ + _tmp0_ = ((name##dim0 * cos) + (name##dim1 * sin)); \ + _tmp1_ = ((name##dim1 * cos) - (name##dim0 * sin)); \ + name##dim0 = _tmp0_; \ + name##dim1 = _tmp1_; + +# define rotates(dim0,dim1) \ + if (sin_##dim0##dim1 != 0) { \ + rotate(a, dim0, dim1, cos_##dim0##dim1, sin_##dim0##dim1); \ + rotate(b, dim0, dim1, cos_##dim0##dim1, sin_##dim0##dim1); \ + rotate(c, dim0, dim1, cos_##dim0##dim1, sin_##dim0##dim1); \ + rotate(d, dim0, dim1, cos_##dim0##dim1, sin_##dim0##dim1); \ + } + +#else /* !__STDC__, courtesy of Andreas Luik */ +# define rotate(name,dim0,dim1,cos,sin) \ + _tmp0_ = ((name/**/dim0 * cos) + (name/**/dim1 * sin)); \ + _tmp1_ = ((name/**/dim1 * cos) - (name/**/dim0 * sin)); \ + name/**/dim0 = _tmp0_; \ + name/**/dim1 = _tmp1_; + +# define rotates(dim0,dim1) \ + if (sin_/**/dim0/**/dim1 != 0) { \ + rotate(a,dim0,dim1,cos_/**/dim0/**/dim1,sin_/**/dim0/**/dim1); \ + rotate(b,dim0,dim1,cos_/**/dim0/**/dim1,sin_/**/dim0/**/dim1); \ + rotate(c,dim0,dim1,cos_/**/dim0/**/dim1,sin_/**/dim0/**/dim1); \ + rotate(d,dim0,dim1,cos_/**/dim0/**/dim1,sin_/**/dim0/**/dim1); \ + } +#endif /* !__STDC__ */ + + rotates (x,y); + rotates (x,z); + rotates (y,z); + rotates (x,w); + rotates (y,w); + rotates (z,w); + + XSync (dpy, True); + if (delay) usleep (delay); + } +} + + +char *progclass = "Hypercube"; + +char *defaults [] = { + "Hypercube.background: black", /* to placate SGI */ + "Hypercube.foreground: white", + "*color0: red", + "*color1: orange", + "*color2: yellow", + "*color3: white", + "*color4: green", + "*color5: cyan", + "*color6: dodgerblue", + "*color7: magenta", + + "*xw: 0.000", + "*xy: 0.010", + "*xz: 0.005", + "*yw: 0.010", + "*yz: 0.000", + "*zw: 0.000", + + "*observer-z: 5", + "*delay: 30000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-color0", ".color0", XrmoptionSepArg, 0 }, + { "-color1", ".color1", XrmoptionSepArg, 0 }, + { "-color2", ".color2", XrmoptionSepArg, 0 }, + { "-color3", ".color3", XrmoptionSepArg, 0 }, + { "-color4", ".color4", XrmoptionSepArg, 0 }, + { "-color5", ".color5", XrmoptionSepArg, 0 }, + { "-color6", ".color6", XrmoptionSepArg, 0 }, + { "-color7", ".color7", XrmoptionSepArg, 0 }, + + { "-xw", ".xw", XrmoptionSepArg, 0 }, + { "-xy", ".xy", XrmoptionSepArg, 0 }, + { "-xz", ".xz", XrmoptionSepArg, 0 }, + { "-yw", ".yw", XrmoptionSepArg, 0 }, + { "-yz", ".yz", XrmoptionSepArg, 0 }, + { "-zw", ".zw", XrmoptionSepArg, 0 }, + + { "-observer-z", ".observer-z", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *d, Window w) +{ + XGCValues gcv; + XWindowAttributes xgwa; + Colormap cmap; + double xy, xz, yz, xw, yw, zw; + unsigned long bg; + + dpy = d; + window = w; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + + x_offset = xgwa.width / 2; + y_offset = xgwa.height / 2; + unit_pixels = xgwa.width < xgwa.height ? xgwa.width : xgwa.height; + + xy = get_float_resource ("xy", "Float"); + xz = get_float_resource ("xz", "Float"); + yz = get_float_resource ("yz", "Float"); + xw = get_float_resource ("xw", "Float"); + yw = get_float_resource ("yw", "Float"); + zw = get_float_resource ("zw", "Float"); + + observer_z = get_integer_resource ("observer-z", "Integer"); + + delay = get_integer_resource ("delay", "Integer"); + + bg = get_pixel_resource ("background", "Background", dpy, cmap); + + if (mono_p) + { + gcv.function = GXcopy; + gcv.foreground = bg; + black = XCreateGC (dpy, window, GCForeground|GCFunction, &gcv); + gcv.foreground = get_pixel_resource ("foreground", "Foreground", + dpy, cmap); + color0 = color1 = color2 = color3 = color4 = color5 = color6 = color7 = + XCreateGC (dpy, window, GCForeground|GCFunction, &gcv); + } + else + { + black = 0; + gcv.function = GXxor; +#define make_gc(color,name) \ + gcv.foreground = bg ^ get_pixel_resource ((name), "Foreground", \ + dpy, cmap); \ + color = XCreateGC (dpy, window, GCForeground|GCFunction, &gcv) + + make_gc (color0,"color0"); + make_gc (color1,"color1"); + make_gc (color2,"color2"); + make_gc (color3,"color3"); + make_gc (color4,"color4"); + make_gc (color5,"color5"); + make_gc (color6,"color6"); + make_gc (color7,"color7"); + } + + hyper (xy, xz, yz, xw, yw, zw); +} diff --git a/hacks/hypercube.man b/hacks/hypercube.man new file mode 100644 index 00000000..daa66899 --- /dev/null +++ b/hacks/hypercube.man @@ -0,0 +1,93 @@ +.TH XScreenSaver 1 "6-dec-92" "X Version 11" +.SH NAME +hypercube - 2d projection of a 4d object +.SH SYNOPSIS +.B hypercube +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-color[0-7] \fIcolor\fP] [\-xy \fIfloat\fP] [\-xz \fIfloat\fP] [\-yz \fIfloat\fP] [\-xw \fIfloat\fP] [\-yw \fIfloat\fP] [\-zw \fIfloat\fP] [\-observer-z \fIint\fP] [\-delay \fIusecs\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIhypercube\fP program displays a wireframe projection of a hypercube +which is rotating at user-specified rates around any or all of its four axes. +.SH OPTIONS +.I hypercube +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 100000, or about 1/10th second. +.TP 8 +.B \-observer-z \fIint\fP +How far away the observer is from the center of the cube (the cube is one +unit per side.) Default 5. +.TP 8 +.B \-color0 \fIcolor\fP +.TP 8 +.B \-color1 \fIcolor\fP +.TP 8 +.B \-color2 \fIcolor\fP +.TP 8 +.B \-color3 \fIcolor\fP +.TP 8 +.B \-color4 \fIcolor\fP +.TP 8 +.B \-color5 \fIcolor\fP +.TP 8 +.B \-color6 \fIcolor\fP +.TP 8 +.B \-color7 \fIcolor\fP +The colors used to draw the line segments bordering the eight faces of +the cube. Some of the faces have only two of their border-lines drawn in +the specified color, and some have all four. +.TP 8 +.B \-xw \fIfloat\fP +.TP 8 +.B \-xy \fIfloat\fP +.TP 8 +.B \-xz \fIfloat\fP +.TP 8 +.B \-yw \fIfloat\fP +.TP 8 +.B \-yz \fIfloat\fP +.TP 8 +.B \-zw \fIfloat\fP +The amount that the cube should be rotated around the specified axis at +each frame of the animation, expressed in radians. These should be small +floating-point values (less than 0.05 works best.) Default: xy=0.01, +xz=0.005, yw=0.01. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 6-dec-92. diff --git a/hacks/ifs.c b/hacks/ifs.c new file mode 100644 index 00000000..7e55af51 --- /dev/null +++ b/hacks/ifs.c @@ -0,0 +1,478 @@ +/* -*- Mode: C; tab-width: 4 -*- + * ifs --- Modified iterated functions system. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)ifs.c 4.02 97/04/01 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@netscape.com: 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: 20000 \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 */ + +ModeSpecOpt ifs_opts = { + 0, NULL, 0, NULL, NULL }; + +/*****************************************************/ +/*****************************************************/ + +typedef float DBL; +typedef short int F_PT; + +/* typedef float F_PT; */ + +/*****************************************************/ + +#define FIX 12 +#define UNIT ( 1<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) +{ + 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->Max_Pt) { + free(Fractal->Buffer1); + free(Fractal->Buffer2); + } + 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)); + if (Fractal->Buffer1 == NULL) + goto Abort; + Fractal->Buffer2 = (XPoint *) calloc(Fractal->Max_Pt, sizeof (XPoint)); + if (Fractal->Buffer2 == NULL) + goto Abort; + + Fractal->Speed = 6; + Fractal->Width = MI_WIN_WIDTH(mi); + Fractal->Height = MI_WIN_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); + + Fractal->dbuf = XCreatePixmap(MI_DISPLAY(mi), MI_WINDOW(mi), + Fractal->Width, Fractal->Height, 1); + if (Fractal->dbuf) + { + XGCValues gcv; + gcv.foreground = 0; + gcv.background = 0; + gcv.function = GXcopy; + Fractal->dbuf_gc = XCreateGC(MI_DISPLAY(mi), Fractal->dbuf, + GCForeground|GCBackground|GCFunction, + &gcv); + XFillRectangle(MI_DISPLAY(mi), Fractal->dbuf, + Fractal->dbuf_gc, 0,0, Fractal->Width, Fractal->Height); + + XSetBackground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + XSetFunction(MI_DISPLAY(mi), MI_GC(mi), GXcopy); + } + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + return; + + Abort: + if (Fractal->Buffer1 != NULL) + free(Fractal->Buffer1); + if (Fractal->Buffer2 != NULL) + free(Fractal->Buffer2); + Fractal->Buffer1 = NULL; + Fractal->Buffer2 = NULL; + Fractal->Max_Pt = 0; + return; +} + + +/***************************************************************/ + +#ifndef __GNUC__ +# 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(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 = Lx + (x * Lx / (UNIT * 2)); + Buf->y = Ly - (y * Ly / (UNIT * 2)); + Buf++; + Cur_Pt++; + + if (D && ((x - xo) >> 4) && ((y - yo) >> 4)) { + D--; + Trace(x, y); + D++; + } + } +} + +static void +Draw_Fractal(FRACTAL * F) +{ + 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; + Lx = F->Lx; + Ly = F->Ly; + D = F->Depth; + 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(x, y); + } + } + + /* Erase previous */ + + if (F->Cur_Pt) { + XSetForeground(display, gc, MI_WIN_BLACK_PIXEL(The_MI)); + if (F->dbuf) /* jwz */ + { + 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 (Max_Colors < 2) + XSetForeground(display, gc, MI_WIN_WHITE_PIXEL(The_MI)); + else + XSetForeground(display, gc, MI_PIXEL(The_MI, F->Col % Max_Colors)); + 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; + DBL u, uu, v, vv, u0, u1, u2, u3; + SIMI *S, *S1, *S2, *S3, *S4; + + The_MI = mi; + display = MI_DISPLAY(mi); + window = MI_WINDOW(mi); + gc = MI_GC(mi); + Max_Colors = MI_NPIXELS(mi); + + F = &Root[MI_SCREEN(mi)]; + + 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; + } + + Draw_Fractal(F); + + 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 i; + + if (Root == NULL) + return; + + for (i = 0; i < MI_NUM_SCREENS(mi); ++i) { + if (Root[i].Buffer1 != NULL) + free(Root[i].Buffer1); + if (Root[i].Buffer2 != NULL) + free(Root[i].Buffer2); + if (Root[i].dbuf) + XFreePixmap(MI_DISPLAY(mi), Root[i].dbuf); + if (Root[i].dbuf_gc) + XFreeGC(MI_DISPLAY(mi), Root[i].dbuf_gc); + } + free(Root); + Root = NULL; +} diff --git a/hacks/ifs.man b/hacks/ifs.man new file mode 100644 index 00000000..39e12d15 --- /dev/null +++ b/hacks/ifs.man @@ -0,0 +1,59 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +ifs - draws spinning, colliding iterated-function-system images +.SH SYNOPSIS +.B ifs +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] + +.SH DESCRIPTION +The \fIifs\fP program draws spinning, colliding iterated-function-system images. +.SH OPTIONS +.I ifs +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors used cycle through the hue, making N stops around +the color wheel. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1997 by Massimino Pascal. + +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. +.SH AUTHOR +Massimino Pascal , 1997. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/images/bob.xbm b/hacks/images/bob.xbm new file mode 100644 index 00000000..f44adda4 --- /dev/null +++ b/hacks/images/bob.xbm @@ -0,0 +1,43 @@ +#define bob_width 61 +#define bob_height 75 +static unsigned char bob_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/hacks/images/bubbles/blood.pov b/hacks/images/bubbles/blood.pov new file mode 100644 index 00000000..8166f4ea --- /dev/null +++ b/hacks/images/bubbles/blood.pov @@ -0,0 +1,24 @@ +#include "colors.inc" +#include "shapes.inc" +#include "textures.inc" + +/* The following make the field of view as wide as it is high + * Thus, you should have the -W and -H command line options + * equal to each other. */ +camera { + location <5.8, 0, 0> + up <0, 1, 0> + right <1, 0, 0> + look_at <0, 0, 0> +} + +sphere { + <0,0,0>, 2.5 + texture { Blood_Marble + scale <2, 2, 2> + rotate <0, 20, 0> } + finish { Dull } +} + +light_source {<6, 1, 0> color White} +/* light_source {<6.1, 1, 0> color White} */ diff --git a/hacks/images/bubbles/blood1.xpm b/hacks/images/bubbles/blood1.xpm new file mode 100644 index 00000000..c76131a6 --- /dev/null +++ b/hacks/images/bubbles/blood1.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char *blood1[] = { +/* width height ncolors chars_per_pixel */ +"10 10 57 2", +/* colors */ +"`` c None", +"`a c #250000", +"`b c #415050", +"`c c #013232", +"`d c #000606", +"`e c #0E2E2E", +"`f c #60C0C0", +"`g c #002020", +"`h c #102222", +"`i c #4D5454", +"`j c #043737", +"`k c #000505", +"`l c #65A0A0", +"`m c #7ED6D6", +"`n c #196969", +"`o c #0C4545", +"`p c #642525", +"`q c #385C5C", +"`r c #002525", +"`s c #6D8686", +"`t c #354F4F", +"`u c #5A7D7D", +"`v c #030A0A", +"`w c #001E1E", +"`x c #71B1B1", +"`y c #274E4E", +"`z c #287373", +"a` c #0D1A1A", +"aa c #053333", +"ab c #001717", +"ac c #374343", +"ad c #000303", +"ae c #070000", +"af c #537272", +"ag c #520B0B", +"ah c #0C3636", +"ai c #297D7D", +"aj c #AF5C5C", +"ak c #003737", +"al c #010000", +"am c #042727", +"an c #0C3C3C", +"ao c #000202", +"ap c #042020", +"aq c #419A9A", +"ar c #420707", +"as c #064949", +"at c #071212", +"au c #1D4F4F", +"av c #154747", +"aw c #000101", +"ax c #264747", +"ay c #002828", +"az c #000707", +"b` c #364949", +"ba c #001414", +"bb c #002121", +/* pixels */ +"```````k`aamaeal````", +"````arahauai`nag`c``", +"``aw`o`zaqafajaxam`r", +"``akav`q`f`m`lb`anay", +"```dahac`u`x`s`t`hab", +"```aat`y`b`iaqai`ebb", +"```gaaah`p`yava``jba", +"````ad`c`vasaaap````", +"``````aeaz`waoae````", +"````````````````````" +}; diff --git a/hacks/images/bubbles/blood10.xpm b/hacks/images/bubbles/blood10.xpm new file mode 100644 index 00000000..7f948fb0 --- /dev/null +++ b/hacks/images/bubbles/blood10.xpm @@ -0,0 +1,257 @@ +/* XPM */ +static char *blood10[] = { +/* width height ncolors chars_per_pixel */ +"60 60 190 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #010404", +"`j c #013232", +"`k c #3C9090", +"`l c #251A1A", +"`m c #095454", +"`n c #190101", +"`o c #70D0D0", +"`p c #000606", +"`q c #003434", +"`r c #0E2E2E", +"`s c #001313", +"`t c #115555", +"`u c #213030", +"`v c #60C0C0", +"`w c #0F0404", +"`x c #002020", +"`y c #165D5D", +"`z c #636A6A", +"a` c #072A2A", +"aa c #445C5C", +"ab c #6C7676", +"ac c #000C0C", +"ad c #549393", +"ae c #001919", +"af c #102222", +"ag c #4D5454", +"ah c #002626", +"ai c #163535", +"aj c #043737", +"ak c #4F6363", +"al c #000505", +"am c #65A0A0", +"an c #052E2E", +"ao c #041616", +"ap c #044444", +"aq c #76C1C1", +"ar c #7ED6D6", +"as c #001212", +"at c #196969", +"au c #385656", +"av c #0C4545", +"aw c #767F7F", +"ax c #642525", +"ay c #360505", +"az c gray28", +"b` c #5FB4B4", +"ba c #002C2C", +"bb c #0E2626", +"bc c #8C9B9B", +"bd c #000B0B", +"be c #030404", +"bf c #001818", +"bg c #944040", +"bh c #280404", +"bi c #0A0E0E", +"bj c #385C5C", +"bk c #002525", +"bl c #6D8686", +"bm c #407E7E", +"bn c #000404", +"bo c #354F4F", +"bp c #739999", +"bq c #001111", +"br c #5A7D7D", +"bs c #347272", +"bt c #030A0A", +"bu c #5AABAB", +"bv c #010808", +"bw c #001E1E", +"bx c #6E3B3B", +"by c #71B1B1", +"bz c #183C3C", +"c` c #274E4E", +"ca c #266464", +"cb c #000A0A", +"cc c #287373", +"cd c #0D1A1A", +"ce c #2B3E3E", +"cf c #053333", +"cg c #121515", +"ch c #270C0C", +"ci c #001717", +"cj c #253838", +"ck c #418888", +"cl c #374343", +"cm c #013C3C", +"cn c #040707", +"co c #031D1D", +"cp c #192C2C", +"cq c #000303", +"cr c #070000", +"cs c #164040", +"ct c #537272", +"cu c #5B8787", +"cv c #120E0E", +"cw c #032A2A", +"cx c #520B0B", +"cy c #001010", +"cz c #062323", +"d` c #435555", +"da c #0C3636", +"db c #8EAFAF", +"dc c #282A2A", +"dd c #001D1D", +"de c #0C1515", +"df c #515C5C", +"dg c #1B5555", +"dh c #297D7D", +"di c #002A2A", +"dj c #2B3030", +"dk c #4F3939", +"dl c #AF5C5C", +"dm c #000909", +"dn c #003737", +"do c #010000", +"dp c #001616", +"dq c #042727", +"dr c #0C3C3C", +"ds c #030F0F", +"dt c #010D0D", +"du c #002323", +"dv c #074E4E", +"dw c #0C4949", +"dx c #295555", +"dy c #5E7272", +"dz c #011A1A", +"e` c #000202", +"ea c #55A1A1", +"eb c #000F0F", +"ec c #176464", +"ed c #042020", +"ee c #0F0000", +"ef c #001C1C", +"eg c #8A5B5B", +"eh c #419A9A", +"ei c #000808", +"ej c #205C5C", +"ek c #420707", +"el c #064949", +"em c #041919", +"en c #0C5C5C", +"eo c #001515", +"ep c #071212", +"eq c #1D4F4F", +"er c #171B1B", +"es c #154747", +"et c #2D8686", +"eu c #031B1B", +"ev c #000101", +"ew c #3C1B1B", +"ex c #286A6A", +"ey c #044040", +"ez c #000E0E", +"f` c #264747", +"fa c #0F4E4E", +"fb c #0D1E1E", +"fc c #396A6A", +"fd c #001B1B", +"fe c gray14", +"ff c #0C4141", +"fg c #031414", +"fh c #011212", +"fi c #172121", +"fj c #002828", +"fk c #060D0D", +"fl c #063B3B", +"fm c #2B5C5C", +"fn c #645C5C", +"fo c #000707", +"fp c #343A3A", +"fq c #396363", +"fr c #182525", +"fs c #364949", +"ft c #001414", +"fu c #467373", +"fv c #AA7979", +"fw c #506969", +"fx c #022323", +"fy c #002121", +"fz c #1C7171", +"g` c #213E3E", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````ebac`eefahahdi`jahdpe`aleb``````````````````````````````````````````````", +"``````````````````````````````````````````fodmftev`eacebeobw`x`sfodmfj`qan`jdudi````````````````````````````````````````", +"````````````````````````````````````du`p``cqdzdufydiebezeobq`ibvevdpbkek`ncr`dchdiefbw``````````````````````````````````", +"`````````````````````````````````xe`ebalft`qcmapcpeydnfjbfdsdsbtcofxfjcmcmdrek`ndocr`b`eci``````````````````````````````", +"``````````````````````````````bqebcbalftdicmff`n`davdvapeyajdqbtedajbh`wcr`hcmcmcmaydo`d`bdi````````````````````````````", +"````````````````````````````e``e`palaediapaicmfleldv`m`melcfa`btanenaydvdvel`jbwfx`q`bdn`ncrbheo````````````````````````", +"````````````````````````bd`e`easftae`jelapananflel`men`mfffbbidaencxdrcdepfkcnbtbedsfyfd`x`bfjbwei``````````````````````", +"``````````````````````bneofj`bac`pfg`japcfdqa`da`men`tffffaf`rfsecffcvfbdadwffcfczfgcnbteveo`xeb`ecq````````````````````", +"````````````````````cbdidn`q`qdudtfgcza`a`dadadrdwfa`aerfrcpecax`ybzercsavfaen`manczemfkbtbqftbqale`cq``````````````````", +"``````````````````ebbh`nchdnapeycofkbibicd`raififraiaiaiesejfcfzeqfrcseq`t`yatcxenavajeddsfg`bdidpebcyeo````````````````", +"````````````````cyan`nfrekeebhewcfa`dadacg`aficpeqdgcaeqejcadhdhdxfeg`ecatatcaewecdkcx`mcffgbtdp`jdmfybbcr``````````````", +"``````````````ciee`b`bfrapcwcfek`mfp`f`taifrbzejdxcaexdxdxccbmdhc`djc`exejatbj`fbo`tecek`medemfhcwdnbqchchdd````````````", +"``````````````eecycydncmcodsanekeqch`fatececcaexexccbsbsbsetdketbofpfmfmexcaccew`fececchendra`dscfcmdibdchef````````````", +"`````````````dbqe`dm`bcofgepflchcxdkfzaxagdhexcabsbsbmckehbxeg`kfqclaubsetetdhetbxaxew`faxavdqfkcwelapdpbwbwcb``````````", +"``````````bqdpbdfdaldsdsaoa`ffecbofz`ydhewfwdhbjfcbmckadazehckfuaaazfcckfnbx`kbmetazfzatatffdecncwapap`qaleecifo````````", +"``````````cdcbbqbwfhcncnczff`m`ycafzfzetfwbxetbmfuckehdlbuadbrctfwagbmehcubgbr`kfudhca`y`y`adeepczflewcmdiebchbw````````", +"````````ftduevbf`iedfgczav`fc`bobjfzccdhetbxeh`kehehbpegbucuctctdffwaddldlehbgehetexf`g`csfrcgfbdqflbheeeyddbk`d`e``````", +"````````cy`xale`fy`jajcxcvekew`laxccdhbs`kegazadadbufvbuamcu`zdycucub`dlfvbxbgehbsbof`fe`hercgbbdaeyel`wcmdi``crbw``````", +"````````cvdieobkdn`wbhesenecatdkaxbxetetehadbgbubudl`vam`cbl`zblam`v`vbydlbgbl`kbjfpdjdc`hfrerbbffeldc`n`l`b`sbacg``````", +"``````eodo`qahch`delbzce`t`tdgccewdcbxfpazbxegam`vdlb`byambpblabby`oaq`v`vawbuckclbjfmcecjcper`affdvekfebheydudpfycr````", +"``````cd`d`adnekekbzdjcv`f`ydgfzbsfudy`zbgdldlbcdbdl`oaqambpblabbpby`v`v`vdldlckazfqfqfmf`g`frfrdw`mewel`wcrdievdp`n````", +"``````bwee`dcmee`dbhekcxdk`ydgejfmexbs`keheab``v`vdlfv`oaqaqbybpawbpbpbybub``vadaa`gfcfmdxf`cp`aavdvdvel`hayahe`ezdu````", +"````bqfday`ddnfebhek`mfaescsg`g`cjclbjfuckadbu`v`vdbfvfvararar`obyawaw`camameacuak`gfsbof`g`fierdrfadrelap`qfjalcbddeb``", +"`````eae`ddnayapekeldabbfberfrcjcefsauaackeaeab`byaq`odbfvfvdbaraqbpabawblcudyakdfaaaufpdjfecper`adadrcfajbadn`eacefem``", +"````fofy`bbaaycpelancdbiaffr`hg`djfpbod`bmeabuamambybyaqararfvdb`obybpaw`z`zfndfakfcfqcldj`ubzfrcgcddrcfdq`bcmdu```xcv``", +"````bnbfbwefdncrdranbiafaifrficjdjfsboazfuadeaam`c`cbpbpbyaqarawarbybpbpab`zdyfwfwfubjboce`h`ufrafdefbedfxdq`bfyev`xdz``", +"````ebfoaccbbwapapdqbidreserfifef`bjauazfucuadam`cblblbpbpbyarfvfv`oaqambl`z`zfwfufuaufpcj`ucjcperafbifkco`bdueocbdpdp``", +"````cibnbde`dteyela`dedwesfierg`dxaucl`gfubrcucublabblblbpbpaqarfv`o`oby`c`zfwfwaaazfpfpceg`bzaiafbbcdcnfx`bfd`se`dmbf``", +"````ftfofdfy`papapdqep`rdaaifi`hcececl`gaaakctdybr`zabawabbpbyarfvfv`obybl`zakagd`aabofpcj`u`ucpafcdepbtdscwcidp``cqfy``", +"````bfasfyefev`japembibbbbfificjdcfpfsaud`agagdffn`zababblbpby`ofvbcbyambr`zakdfaafcaufscj`uerfrafdeepepemdnbabw`s`ebf``", +"````bfcyefftcbey`jdsdecdafercpg`f`ceclcl`gaaakctfn`zdy`zbl`cbyaqeg`obuamcubrbrfubmbsbjdxcjg`fierfbcdepepan`qdn`bfjfyfo``", +"````bw`sac`eahayfhfkepdedecgaig`c`dxfsfpauaaakfwfwdydydy`z`zblam`veg`vbyeaadckckehetexf`cj`hercgcdbicncodqcmdnereecrfo``", +"````cibfe`ei`b`qbeemepbidecgcseqeqexdxfpaud``gdfctbrctcudy`zdybr`cb`fndleg`cblabbg`ketfmg`cpercgdeepcndsed`q`b`dbkdu`s``", +"````fo`n`edzdn`bbvaoeubifbcdaidgdgcadxdjboboclaaakfwfwctctdfdffwbradawegawbgdkbxdkbxaxfzeqfrcgdebbczaobtedciduee`x`x`n``", +"````dmee`p`x`dbadtdsedemep`raicsesdgc`dcfsbofsd``gd`agagagdfagdffwctbmckehegegbxbxewdhatcsficgfb`rczcobebtacfyeefycieb``", +"``````eealfj`n`beodtcoedbi`affescscsg`fecefsfpfp`g`gd`d`d`agagagaaaaaafqbmbmetetaxax`gejcserbbdrfla`cobtdmbqbkdq`sbq````", +"``````asas`ser`qbfbvdsemfkfbdrfaesbzcp`h`udjdjclbjbjfqfqaa`gazazazclclaubjfcexcacafzaxdg`rcddrdweleydq`i`ifo`bahacdz````", +"``````acez`eahee`jacbtfgcocfffdwesesbzfrfefedccedxbofqfcfcfcauclclfpfpclfsfmdxc`eqfzecbzcv`rdvdcfecpfxftdmcy`bahbfac````", +"````````bdcifd`bchdufgaocfeleldwdwesaifrcpfe`hf`cafmexbsfcbsfqfscefsf`djcef`dxeqdgercscdcddrewbhfedrcwfte`ezdi`ddo``````", +"````````evacfyafan`j`xdqcfdrdv`mavdrdaaicscpbzdgcaccccexcaexexf`cjc`cedccjf`dgecdk`t`acvbbffayekapbabwfoe`e`fyfyfo``````", +"`````````pei`xdi`j`j`b`jcfajelapda`rdadacs`tatataxewazexc`c`c`cjfecj`u`hes`y`ydxcgfacdbicfdvbhewajcwftdmei``ft`edt``````", +"````````````ezdd`b`bbb`layeyeyapcfa`drfffa`f`fecbodx`fcaeqg`g`g`frfifrbz`y`ydkcxcedwcdcdfl`w`najfjaecbdmeifoevcq````````", +"````````````e`eodzchee`ncfeeekapana`a`ffavch`tesc`ax`lecesaibzaicpfifiesc``fceeq`mdabia`flfedadqaeezeicbefdzezei````````", +"````````````al``e`ef`bba`d`n`dcmdqdqanajelcvdwavencx`f`fescsaibzaibb`ravfpcxcjcxelanfkczcwfl`jcidmbdcy`xcv`dbi``````````", +"``````````````ev``eveobf`jcrbhfrajananapayela`bbdrfafacxfp`t`tfaavdrff`tewaycvcxflfkaocodq`jduftezbdftcgftee````````````", +"``````````````evcqbnalcyeo`b`qayaybhfebhapaja`deczffffg`g`dvchdvdvdwdwcvbzcncnekancncofjfxdufycieibf`xeedpal````````````", +"````````````````bnevevbdcqbq`xbafr`j`jflancoemfkbtdqczana`flelekcxchekflcfelcneydqbeedbk`xdzez`p``asbwefcq``````````````", +"``````````````````e`bn````cq`e`eftdzdpddfgbtbecncnbefgaoepedcfajflflcwcoedajflcfdpcyfydzacdmbneidmbweffo````````````````", +"````````````````````cbfoacezbnale`e`acfobde``p`pbebebtbecnfgemdseuaocodqdqdqahdp`pcidpcbevcq``fobdasdo``````````````````", +"```````````````````````ebqaecifdaccq`pcqaleodubwdddpfgbvdzcwbkfgbt`pfgco`xfdcicbdmddci````al`pdmevcb````````````````````", +"`````````````````````````e`n`naecieb`e`ecbebbfaedzbwbqdm`sbw`bbkcy`idmcibfeoebeicift`pezeodz`sfgev``````````````````````", +"``````````````````````````btbqepbwbfdpdpcbcqfodmac`sfobdaseo`xahae`sfo`pacfoevbdbne``eaecv`wee``````````````````````````", +"````````````````````````````````bneocr`nddbqcycyfocbevbnebdzbwduahbwbf`ee`cqe`dm`sbwcrdpciez````````````````````````````", +"````````````````````````````````evcqfobqefcvdzcieb```p``alfoeoftdddpdm``dmeicybfeecyezdsfo``````````````````````````````", +"````````````````````````````````````aleve`alacdzeecveo`sbdcbbqbqal``bneveibqciaebqdo`p``````````````````````````````````", +"``````````````````````````````````````````cqevcbasbiepcvdpebdmcbal`eei`pcqevcbal````````````````````````````````````````", +"````````````````````````````````````````````````eb`pbneidmbdcyeeeecycncrcr``````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood11.xpm b/hacks/images/bubbles/blood11.xpm new file mode 100644 index 00000000..b6daa933 --- /dev/null +++ b/hacks/images/bubbles/blood11.xpm @@ -0,0 +1,269 @@ +/* XPM */ +static char *blood11[] = { +/* width height ncolors chars_per_pixel */ +"72 72 190 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #010404", +"`j c #013232", +"`k c #3C9090", +"`l c #251A1A", +"`m c #095454", +"`n c #190101", +"`o c #70D0D0", +"`p c #000606", +"`q c #003434", +"`r c #0E2E2E", +"`s c #001313", +"`t c #115555", +"`u c #213030", +"`v c #60C0C0", +"`w c #0F0404", +"`x c #002020", +"`y c #165D5D", +"`z c #636A6A", +"a` c #072A2A", +"aa c #445C5C", +"ab c #6C7676", +"ac c #000C0C", +"ad c #549393", +"ae c #001919", +"af c #102222", +"ag c #4D5454", +"ah c #002626", +"ai c #163535", +"aj c #043737", +"ak c #4F6363", +"al c #000505", +"am c #65A0A0", +"an c #052E2E", +"ao c #041616", +"ap c #044444", +"aq c #76C1C1", +"ar c #7ED6D6", +"as c #001212", +"at c #196969", +"au c #385656", +"av c #0C4545", +"aw c #767F7F", +"ax c #642525", +"ay c #360505", +"az c gray28", +"b` c #5FB4B4", +"ba c #002C2C", +"bb c #0E2626", +"bc c #8C9B9B", +"bd c #000B0B", +"be c #030404", +"bf c #001818", +"bg c #944040", +"bh c #280404", +"bi c #0A0E0E", +"bj c #385C5C", +"bk c #002525", +"bl c #6D8686", +"bm c #407E7E", +"bn c #000404", +"bo c #354F4F", +"bp c #739999", +"bq c #001111", +"br c #5A7D7D", +"bs c #347272", +"bt c #030A0A", +"bu c #5AABAB", +"bv c #010808", +"bw c #001E1E", +"bx c #6E3B3B", +"by c #71B1B1", +"bz c #183C3C", +"c` c #274E4E", +"ca c #266464", +"cb c #000A0A", +"cc c #287373", +"cd c #0D1A1A", +"ce c #2B3E3E", +"cf c #053333", +"cg c #121515", +"ch c #270C0C", +"ci c #001717", +"cj c #253838", +"ck c #418888", +"cl c #374343", +"cm c #013C3C", +"cn c #040707", +"co c #031D1D", +"cp c #192C2C", +"cq c #000303", +"cr c #070000", +"cs c #164040", +"ct c #537272", +"cu c #5B8787", +"cv c #120E0E", +"cw c #032A2A", +"cx c #520B0B", +"cy c #001010", +"cz c #062323", +"d` c #435555", +"da c #0C3636", +"db c #8EAFAF", +"dc c #282A2A", +"dd c #001D1D", +"de c #0C1515", +"df c #515C5C", +"dg c #1B5555", +"dh c #297D7D", +"di c #002A2A", +"dj c #2B3030", +"dk c #4F3939", +"dl c #AF5C5C", +"dm c #000909", +"dn c #003737", +"do c #010000", +"dp c #001616", +"dq c #042727", +"dr c #0C3C3C", +"ds c #030F0F", +"dt c #010D0D", +"du c #002323", +"dv c #074E4E", +"dw c #0C4949", +"dx c #295555", +"dy c #5E7272", +"dz c #011A1A", +"e` c #000202", +"ea c #55A1A1", +"eb c #000F0F", +"ec c #176464", +"ed c #042020", +"ee c #0F0000", +"ef c #001C1C", +"eg c #8A5B5B", +"eh c #419A9A", +"ei c #000808", +"ej c #205C5C", +"ek c #420707", +"el c #064949", +"em c #041919", +"en c #0C5C5C", +"eo c #001515", +"ep c #071212", +"eq c #1D4F4F", +"er c #171B1B", +"es c #154747", +"et c #2D8686", +"eu c #031B1B", +"ev c #000101", +"ew c #3C1B1B", +"ex c #286A6A", +"ey c #044040", +"ez c #000E0E", +"f` c #264747", +"fa c #0F4E4E", +"fb c #0D1E1E", +"fc c #396A6A", +"fd c #001B1B", +"fe c gray14", +"ff c #0C4141", +"fg c #031414", +"fh c #011212", +"fi c #172121", +"fj c #002828", +"fk c #060D0D", +"fl c #063B3B", +"fm c #2B5C5C", +"fn c #645C5C", +"fo c #000707", +"fp c #343A3A", +"fq c #396363", +"fr c #182525", +"fs c #364949", +"ft c #001414", +"fu c #467373", +"fv c #AA7979", +"fw c #506969", +"fx c #022323", +"fy c #002121", +"fz c #1C7171", +"g` c #213E3E", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````ftcb`p`eacftasasace`cq````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````cqcqe`foeb`s`x`b`b`bahdpebcqezezasfdcv````````````````````````````````````````````````````", +"````````````````````````````````````````````````cqevbdal`pdpfycifdbfcyezas`sezevdp`qdodo`nafdibkah``````````````````````````````````````````````", +"````````````````````````````````````````````ei``ei`pbwdi`xfjbadz`sfhacacbddtbdbddufjapcrayee`day`jfydd``````````````````````````````````````````", +"````````````````````````````````````````cyeoeibnft`jdncmaiffeydnbacofgdsdsdsfgfyahdicmcmeyfeay`ndo`d`laedz``````````````````````````````````````", +"````````````````````````````````````ddbdebalcqbfdidnelaycrbhdcelapeyajanfxcnaoaneyayay`d`delapey`h`ddocr`qbkah``````````````````````````````````", +"``````````````````````````````````cqeoebcqe`aedidn`u`ueyapcj`mdv`mdveyfldqbtedajesekdcewdvap`jbkfjdn`qdndodnbh`n````````````````````````````````", +"``````````````````````````````foalcbbde`ebci`bey`hapancfcfey`mewen`mdafbdebidrenekdvcfczdqanembtbtfxduahdicmcm`qfydp````````````````````````````", +"````````````````````````````cbeidzdzfoasdpdq`qdveldqczajeydven`mdwavdrfbcdffceewdwbbbideczcoeufgbtbedzdzcbebbkfjbwbfei``````````````````````````", +"````````````````````````````cyah`bahcybdbtdqajeycfa`an`ravenen`tffda`rcgdrfsatfa`acdbbdadwdvffajdqemdscnbtcq`sftaee`dme`````````````````````````", +"````````````````````````cbdu`rdndndndufhbtcodqana`cfdrdaavfafaaificgfraiecewecfa`aafcsesdwenen`manededcndtdtbqci`sfo`pe`cq``````````````````````", +"``````````````````````ez`b`n`ddndncmajcocnfkembicd`rda`raffifrcpcpcpesdgfzfz`ycserbzeq`t`tendk`f`mdra`cocndsaoah`bbwcqcyebas````````````````````", +"````````````````````cy`baychayapekekdvajczfbbbbbcvafaieraieqeqeqeqdgcacafcdhejg``hf`ejececat`fch`fchfp`mapaocnfgeddifdfofyfyed``````````````````", +"``````````````````eo`bbh`jchayayapey`welffenenaverfieraieqeqejexdxc`fmexetfwfmg``uc`exatatfzax`lateneccvenflcofgdseu`qfdezer`nfy````````````````", +"```````````````````ndifd`jcpcmahedancxenf`chc``tesbzg`dgcacaccccfmdxfmdhbgetfmcjdjdxexcacafzbx`fdk`t`tekew`manaocnbw`qcmfdduaydi````````````````", +"````````````````cgciebdpdncmfxdsemflcvcechchdkfzfzatexexcaccccbsbsbsbm`kdk`kfcfpclfmcaexcaexdhewewfzat`f`fendrcfbefxcmey`jbn`bfdci``````````````", +"``````````````fyefeidmas`bedfgaoemavchch`ffzfzewagdhcccaexbsbsbmbm`kehdkeg`kbsbofsbjbsetetdhdhfqbxax`f`l`ffpava`aoedaj`hapbwe`anacfo````````````", +"``````````````dieifofdacfhbtdscoandwfpdkcaececagfebxdhfcfqbsbmckehbgbxehckfufc`g`gfcbm`kegbxetetdhaafqfzatejavcdepeucfelap`jbq`xdieb````````````", +"````````````efezfofyaedtbtcnfka`fffa`tatfmecfzdfdfbxetbmfcfcckeh`cazeaadckfufwaaaabmehbxbgbg`ketbmdhfzecec`y`rdebiemcfap`hcm`be``qdias``````````", +"````````````czcbeibw`ibfbtfkcfelenecfsdkfzfzccetckdk`kbmckck`keadldleacuctbrctagfwadbuegehbxckbretdhcaeqdgdg`adebifba`flbhekfefybq`n`d``````````", +"```````````efy`pasaceffxcoa`elcxchecboaxfzccccdhetbgbxehehadeadlfvb`adbrdy`zdfctbrbuegbgblbxab`ketexc`cj`ucpficdfba`aneydc`new`jaebk`nbf````````", +"``````````effy`edmefdqajeyaycncxayewew`fccdhdhdh`kbrbgeaadadb`dlbuam`ccu`zdycucuea`vdldlbxbgcu`kbsbocedj`ucpficgfb`rfleldv`dap`bah`peecd````````", +"````````eieedifdcydnapaybh`mf`enecatdkaxbxdhet`kehehazaweab`dlbyamam`cab`zblamb``v`vbydldldleackbjfpfpdc`h`hfrerfbdadrdvdcbeekcmdieibafb`n``````", +"````````aeee`jah`b`dek`ucsg`en`t`t`yd`fedcaxbxbxbxazbgdlb`bpdl`vambyam`cblabam`vdbaq`vbybpbpeafuclaubjcecj`ucpfi`adaav`mekekekaydndzdzbwfx``````", +"````````cgcr`q`q`lcrfedvg`cv`fec`tdgfzbxaxaxbgegbgbgagdl`vbcdl`vbybybpbpblabbpby`v`o`vb`fvdlbubmazbjfcfmf`g`cjfrfrdafa`mewelbhcrdaddcqcied``````", +"```````nbk`dcrcm`leebhewcxekay`yeqeqatccccdh`kcuawbub`by`vbcegfv`oaqbybybpawabbpbyby`vb``vdlbpckd`d`fcfqdxdxf`cpfi`rav`m`melek`day`xevfoducv````", +"``````ci`xayeednay`d`nbhcxg`en`tdgdgeqc`dxfqbsckadadea`v`v`ofvabdbar`o`obybybpawbl`camamamb`bucuaaazbjfqdxdxf``ufiaifa`meldv`hapeybwcqdmfyco````", +"``````aebwayay`q`dcp`ncj`mfaffbzaig`cjcjcebobjfuckadeab`b``v`ofvfvarararararaqbpawawbl`camamadctakd`clbofsf`cjfier`affavflapapaj`jdudmebeffd````", +"```````sahaydncmdaewfeapdabbafcger`hcjcjceauauaackeaeabub`byaq`oarbcfvfvdbar`obyblabawblblbrctakdfaabjclfpdjfecpfifibbdadrajajan`j`q`eacbffd````", +"````bd`efja``bdafeewelanfbdecvfrfi`ug`cjdjfs`gaabmeabuamamambybyaq`oarfvawdbaraqbpblab`z`zfndfdfakfwfqaudjdc`ucjfrercgbbffajedcw`jdn`xcqefbwez``", +"````foacciahdu`j`n`hapanepde`a`aerfecjdjfpfpcl`gfuadbubuam`cbpbpbpaqaqararfvaraqbpbpbpab`z`zakakakfufqbjcldj`u`uaificdde`randqcw`b`qbk`pftefeo``", +"````acbdebas`sahdnekapczbi`adaaierfe`hcjboaud`azfucuadamam`c`cbpbpbpbybyarfvdbarbybybpbl`zdydyctfufubjaucedj`h`uaifrcgcdbiaoeddq`bdudzcqacbfft``", +"````aeeve`fo`pfd`b`dapczdedrfaaifi`h`hc`fmau`g`gfucuad`c`cblblblbpbpbpbyardbawaraqaqby`cdy`zakfwfwfcbjclfpcjcjcjbzfrfb`abifkemcw`jfddpcqe``sci``", +"````eebnbdez`pdmcwbhapdqdeavdwbzerfig`dxdxfscld`fubrcucucuababawblblbpbyaqardbfv`o`oby`c`z`zfwfwagazclfpcececjcjbz`afbbbfbcnaoan`beoase`ev`seo``", +"`````ncbbqeffyevahayeyczep`rdaaicpfi`hcecefpbo`gaaakfwdydybr`zabababawbpby`odbfvaq`obybldyakakagd`aaaucldjcj`u`ucp`afbfbepfkcnedbaftdpcqe`ac`s``", +"````crbddpfybwfofxaycfeubibb`rbbfifr`udcdjclaud`aadfagak`z`z`zababblblbpby`ofvfv`obyambrdydfagagaafcaubocedj`herfiafdebibifkdsdq`qdibw`sbqe`dp``", +"````eeeidpfd`scqfybhcwepepfbafafercpg`g`cefpfsclazagakfwfwfn`zababab`camby`ofvfv`vbuamcubrctctfufubsfqfmf`cjg`cperaffbdedefkedcf`qdndifydudmbf``", +"````eeeiezftftebdndnfkbtaocddeaferaig`c`f`cefsfp`gaaakctfwdfdydy`z`zabbl`cby`veg`vb`b`eaadcubmbmckbmfcdxcecj`uficgcgfbbifkemfxdn`qcm`q`bdobfbd``", +"````fkftftfo`pfyeeahbefgepepbicgercsesf`fmfmfsfpauaad`dfakctdydybrdy`z`zbl`cbu`vfnfvdlb`eaad`k`kck`kdhcaf`cjfrerercvdebifkfgco`jcm`qayaydi`xfo``", +"````acfdeoeidmahfifxbtemepcncdcvafesdgeqcacac`fpboau`gd`akctbrctbrbrdyfn`zbrcuea`vfndlfnbgadbgbgbxfnetccc`g`cpercgcvdedecncnfg`b`bdi`nahducrdm``", +"``````cveocydzbacmcobtemeucncdfbafcsdgdgcaejc`djbobocl`gaafwfwfwctctfwdfdfakbrcueadlegegabbxbxbxdkbxaxaxejesfrcgcgfbbbczaofgaodzbwaheefybwdz````", +"``````fdbwcbbwficmdpe`aoedembi`a`aaicsesdgeqf`djfsbofs`gaad`aaagdfdfdfdfagdffwctbmckehehabbgegbgbgdcdhfcejcsficgdebbanczcodsdsebebah`nfyfyeo````", +"``````ez`xevahdo`qbwdtcncoczepfbdaffcsbzesf`g`dccefsfsclfpazazaz`gagagagagagakakakakfuck`k`kckfuaxaxagfzejbzercd`rdacfczcodtbvbv`sahafcidzbf````", +"``````cb`n`pfyaydnbkebbtaoedepep`rfffaescsai`ufecjcefpfpfsbjbjfqaaaad`d``g`g`g`g`g`gaufqbsbsbsccdhdhewateqcpcg`adreleycfedbtbvbvdp`bbacy`s`w````", +"````````ddbdcb`b`d`bft`ibtembtem`rdadwesesbzcp`h`hdcdcfpbobjbjfqfcfcbjd`azclfsclfpclbobofmcafmfmejateweccsafbbffdvelelflfxbtalaleobhdudm`n``````", +"````````ei`p`ebw`lerdidtbvdsdsandaffdwdwesesaififefefedjc`dxbobjfcbsfcfcaufsclfpfpfpfpcldxfmdxc`eqatdkes`rcdda`mcxbzelaibkbfdte`bfcvfjdpae``````", +"````````cb`eciefah`ndnfdfgaocwapeldvdwdwdwaiaifrcpfefecjdxcafmexbsbsfcbsfqbodjfsfscedjcecedxeqeqdg`f`t`rcgfbdrg``newaieycwcievalascg`d`ne```````", +"``````````e``ebw`bdoaydiddfxcwap`udvdvdwdrdaaiaibzcp`ug`ejcaccccccexexexexc`djc`c`cjdccjg`eqdgecfsecbzcdcdbbdrekbhekfl`bddezdmevcqdu`dfd````````", +"``````````al`pfybk`n`b`qdi`b`jflapeleldada`rdaaicseseq`yatexaxagcccafmdxfmf`dccjf``u`hg`dgej`yecew`y`acdcd`rav`nekapanahaealalevfofdase`````````", +"````````````aldpbwdi`bba`q`qdncmajapeyajcfa`dadres`ydkew`lewewaxfzejg`g`g`g``hfe`uer`ues`y`ycl`l`f`t`abicdeybhdcayey`bahebfodmfoeveial``````````", +"````````````fobdeffy`d`j`lee`n`nayapapcfananffavfa`fcx`tecdxecew`f`yesbzcsbzcpfrercpbz`y`yf`ewf`eqdwbbepa`ey`n`wajfjfycydmbdeiac`e`pfo``````````", +"``````````````evcbftbwcz`d`ddnbhbhayapana`ana`ffavew`tdwfaf`dk`lfsdgbzaibzaicpfierfres`y`fchenf``mdrcdcocfflaicp`bfdbqbddmcbbfbkdzac````````````", +"``````````````cqbneial`x`bdifiaydobhcmcwczananajelch`mavfa`tcx`fcg`tcsbzaibzai`rbbaiav`tcvfpdcewelcfepemdqcwfl`qfyac`p`ecybw`n`naeee````````````", +"```````````````````pe`alaebwdieedobhcmajcwcwcfapewewdaa`daavfafadjek`tfafafaavdrdrff`mdjchchcxeweyemdsemeddq`jfyfdcyac`e`sfjbwbwee``````````````", +"````````````````````ale`fo`sft`j`q`deeficmey`lcnekeyajedfbdadwav`mchdjchekfafaavavdwewcvcvek`wekcfdsemeddqfxdifyfdciacciddcoaeas````````````````", +"``````````````````e`evevfoezdmbqfyah`q`day`rbhayeyancwepfkedcfdaffeldrffewchdvdvg`djdceyelcnbhaicwbeaocwfxfy`xbfacfoalaebweebf``````````````````", +"````````````````````bne```foe`bnebbwdu`jbaah`b`bfxemdsbedscnemeuedczdqajapfeay`wbzapana`flewfeeyfx`idpah`xciezcbevcqfoas`naobn``````````````````", +"``````````````````````cqfo``e`ev`paceiacdpbfcydzfhbtbebebebebedsfgdsfkemdqananajanczededcfcmcmcwfhezfydzcifofoe``pev`sbwepei````````````````````", +"````````````````````````cbeicbacaccqalbnevdmacfobde``pbv`pbebebtcnbebtaoembtememaocodqdqahcwfyfh`peodzezalevcqe`eialcbeodo``````````````````````", +"``````````````````````````accyeoftbfdzac``eibdbn`pfhddbwdddzfgdsbvdsbwbadqfgbv`idtdzedfxbwdzeodmcbfdfdacale`e```aleibnac````````````````````````", +"`````````````````````````````eci`n`xciftbdei`pdmbdbddzbkfdef`x`sbdebciducwdudpac`pbddpfddzbfbdalebdzcycqdmcyaeasftacbn``````````````````````````", +"``````````````````````````````btcrcrddefaecibqbqe`eiasfteb`sdpeb`idmeoefahfyeodt`i`iebci`eace``sac`pe`bddpbffddo`w``````````````````````````````", +"``````````````````````````````````cbeb`nbwddddbfezdm`pacfodmbdbnevcb`sdpdzahduefascbfoe`bnbnale`bn`pasdz`nef`nas````````````````````````````````", +"````````````````````````````````````alevcbaeeedobwdpcyftcydmeie```ei`sdd`xbkahfjfdeodme`bn`pcbezdpefdoaeezdocb``````````````````````````````````", +"````````````````````````````````````````cq``bdbqefcrdzci`s`e``focqcqbncbeoftfdefcyei``eidmbdftefeeasasbqcb``````````````````````````````````````", +"````````````````````````````````````````````e```al`pbdddee`xddasebacbdbdasebfoe`evbnev`pebbfemciebcyez``````````````````````````````````````````", +"````````````````````````````````````````````````evevevalbqdzeeeebwdpezezcbcydmaldmeibncqevdmasfkbn``````````````````````````````````````````````", +"``````````````````````````````````````````````````````accqbdebcyeoeedpbqbqasezdmbdbdezacale`````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````cncbev``evbndmaccrdocb````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood2.xpm b/hacks/images/bubbles/blood2.xpm new file mode 100644 index 00000000..e2529854 --- /dev/null +++ b/hacks/images/bubbles/blood2.xpm @@ -0,0 +1,100 @@ +/* XPM */ +static char *blood2[] = { +/* width height ncolors chars_per_pixel */ +"12 12 81 2", +/* colors */ +"`` c None", +"`a c #002E2E", +"`b c #250000", +"`c c #000D0D", +"`d c #212A2A", +"`e c #000606", +"`f c #213030", +"`g c #636A6A", +"`h c #072A2A", +"`i c #445C5C", +"`j c #4D5454", +"`k c #163535", +"`l c #000505", +"`m c #052E2E", +"`n c #041616", +"`o c #044444", +"`p c #76C1C1", +"`q c #0C4545", +"`r c #767F7F", +"`s c #002C2C", +"`t c #000B0B", +"`u c #030404", +"`v c #280404", +"`w c #385C5C", +"`x c #354F4F", +"`y c #001111", +"`z c #347272", +"a` c #6E3B3B", +"aa c #71B1B1", +"ab c #000A0A", +"ac c #270C0C", +"ad c #001717", +"ae c #253838", +"af c #418888", +"ag c #013C3C", +"ah c #192C2C", +"ai c #000303", +"aj c #164040", +"ak c #032A2A", +"al c #520B0B", +"am c #001010", +"an c #435555", +"ao c #0C3636", +"ap c #8EAFAF", +"aq c #282A2A", +"ar c #515C5C", +"as c #1B5555", +"at c #002A2A", +"au c #2B3030", +"av c #4F3939", +"aw c #AF5C5C", +"ax c #003737", +"ay c #010000", +"az c #001616", +"b` c #042727", +"ba c #0C3C3C", +"bb c #030F0F", +"bc c #002323", +"bd c #0C4949", +"be c #011A1A", +"bf c #176464", +"bg c #0F0000", +"bh c #001C1C", +"bi c #8A5B5B", +"bj c #419A9A", +"bk c #064949", +"bl c #041919", +"bm c #001515", +"bn c #071212", +"bo c #031B1B", +"bp c #044040", +"bq c #0F4E4E", +"br c gray14", +"bs c #031414", +"bt c #063B3B", +"bu c #2B5C5C", +"bv c #396363", +"bw c #182525", +"bx c #001414", +"by c #506969", +"bz c #002121", +/* pixels */ +"````````bxbpbbagay``````", +"````abbc`hbqbfaj`m`yai``", +"`````aac`j`zbi`za``q`o``", +"``at`vavbjaw`gaa`wbwaq`s", +"``axaoaeaf`pap`rarbrba`c", +"``bzbn`d`i`gaaaaan`fbnaz", +"``beboas`xbyarbiavbw`nbg", +"``adbsbdahbubvauasbaak`b", +"`````aagbkal`k`qbkbtam``", +"````ab`l`t`ublb``eaiay``", +"````````bh``bm``bg``````", +"````````````````````````" +}; diff --git a/hacks/images/bubbles/blood3.xpm b/hacks/images/bubbles/blood3.xpm new file mode 100644 index 00000000..81fd4d4e --- /dev/null +++ b/hacks/images/bubbles/blood3.xpm @@ -0,0 +1,122 @@ +/* XPM */ +static char *blood3[] = { +/* width height ncolors chars_per_pixel */ +"14 14 101 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #250000", +"`c c #5D1616", +"`d c #415050", +"`e c #010404", +"`f c #3C9090", +"`g c #251A1A", +"`h c #095454", +"`i c #190101", +"`j c #70D0D0", +"`k c #000606", +"`l c #60C0C0", +"`m c #165D5D", +"`n c #636A6A", +"`o c #072A2A", +"`p c #6C7676", +"`q c #000C0C", +"`r c #102222", +"`s c #4D5454", +"`t c #163535", +"`u c #043737", +"`v c #4F6363", +"`w c #044444", +"`x c #76C1C1", +"`y c #001212", +"`z c #0C4545", +"a` c #767F7F", +"aa c #642525", +"ab c #360505", +"ac c #000B0B", +"ad c #385C5C", +"ae c #6D8686", +"af c #000404", +"ag c #001111", +"ah c #030A0A", +"ai c #5AABAB", +"aj c #001E1E", +"ak c #6E3B3B", +"al c #71B1B1", +"am c #274E4E", +"an c #0D1A1A", +"ao c #2B3E3E", +"ap c #053333", +"aq c #121515", +"ar c #270C0C", +"as c #418888", +"at c #374343", +"au c #013C3C", +"av c #040707", +"aw c #031D1D", +"ax c #192C2C", +"ay c #000303", +"az c #070000", +"b` c #164040", +"ba c #537272", +"bb c #120E0E", +"bc c #001010", +"bd c #062323", +"be c #282A2A", +"bf c #0C1515", +"bg c #515C5C", +"bh c #1B5555", +"bi c #002A2A", +"bj c #2B3030", +"bk c #4F3939", +"bl c #000909", +"bm c #003737", +"bn c #010000", +"bo c #001616", +"bp c #042727", +"bq c #030F0F", +"br c #074E4E", +"bs c #0C4949", +"bt c #011A1A", +"bu c #55A1A1", +"bv c #000F0F", +"bw c #042020", +"bx c #419A9A", +"by c #064949", +"bz c #1D4F4F", +"c` c #2D8686", +"ca c #000101", +"cb c #286A6A", +"cc c #044040", +"cd c #001B1B", +"ce c #0C4141", +"cf c #031414", +"cg c #011212", +"ch c #172121", +"ci c #002828", +"cj c #2B5C5C", +"ck c #000707", +"cl c #343A3A", +"cm c #182525", +"cn c #364949", +"co c #AA7979", +"cp c #506969", +"cq c #002121", +"cr c #1C7171", +"cs c #213E3E", +/* pixels */ +"``````````cqcqagbiab````````", +"``````ajawbd`h`ranbdcfbc````", +"`````bbmaochcbc`cjaaarcf`b``", +"`````e`zcr`fbxbaas`fbhbfcc``", +"``bnby`mbjak`lae`jbuam`abebt", +"``ar`wcmataialcoa`bgatchbw`k", +"``bt`u`tclcp`pal`x`vclaxavck", +"``blahbbcb`dba`n`sbkcbaqbqci", +"``afcgbdb`beadcnatcjbzbrck`q", +"`````occ`o`c`gcsaxarbfaubl``", +"````caciazapcebbbsabci`yaw``", +"``````btafcdbobpbvbl``ag````", +"``````````acbv`yay`i````````", +"````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood4.xpm b/hacks/images/bubbles/blood4.xpm new file mode 100644 index 00000000..d4f3ced9 --- /dev/null +++ b/hacks/images/bubbles/blood4.xpm @@ -0,0 +1,171 @@ +/* XPM */ +static char *blood4[] = { +/* width height ncolors chars_per_pixel */ +"20 20 144 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #013232", +"`j c #095454", +"`k c #70D0D0", +"`l c #000606", +"`m c #0E2E2E", +"`n c #001313", +"`o c #115555", +"`p c #213030", +"`q c #60C0C0", +"`r c #002020", +"`s c #445C5C", +"`t c #6C7676", +"`u c #000C0C", +"`v c #549393", +"`w c #102222", +"`x c #4D5454", +"`y c #002626", +"`z c #163535", +"a` c #043737", +"aa c #4F6363", +"ab c #000505", +"ac c #65A0A0", +"ad c #052E2E", +"ae c #044444", +"af c #7ED6D6", +"ag c #001212", +"ah c #196969", +"ai c #385656", +"aj c #0C4545", +"ak c #767F7F", +"al c #642525", +"am c #002C2C", +"an c #0E2626", +"ao c #030404", +"ap c #001818", +"aq c #0A0E0E", +"ar c #385C5C", +"as c #002525", +"at c #6D8686", +"au c #000404", +"av c #354F4F", +"aw c #739999", +"ax c #001111", +"ay c #5A7D7D", +"az c #347272", +"b` c #030A0A", +"ba c #010808", +"bb c #001E1E", +"bc c #6E3B3B", +"bd c #71B1B1", +"be c #183C3C", +"bf c #274E4E", +"bg c #000A0A", +"bh c #287373", +"bi c #0D1A1A", +"bj c #053333", +"bk c #270C0C", +"bl c #001717", +"bm c #253838", +"bn c #418888", +"bo c #374343", +"bp c #013C3C", +"bq c #040707", +"br c #031D1D", +"bs c #192C2C", +"bt c #000303", +"bu c #070000", +"bv c #164040", +"bw c #537272", +"bx c #5B8787", +"by c #120E0E", +"bz c #032A2A", +"c` c #520B0B", +"ca c #0C3636", +"cb c #001D1D", +"cc c #0C1515", +"cd c #297D7D", +"ce c #002A2A", +"cf c #AF5C5C", +"cg c #000909", +"ch c #003737", +"ci c #010000", +"cj c #001616", +"ck c #042727", +"cl c #0C3C3C", +"cm c #030F0F", +"cn c #002323", +"co c #074E4E", +"cp c #0C4949", +"cq c #295555", +"cr c #5E7272", +"cs c #011A1A", +"ct c #000202", +"cu c #55A1A1", +"cv c #000F0F", +"cw c #176464", +"cx c #042020", +"cy c #0F0000", +"cz c #001C1C", +"d` c #8A5B5B", +"da c #419A9A", +"db c #420707", +"dc c #064949", +"dd c #0C5C5C", +"de c #001515", +"df c #071212", +"dg c #1D4F4F", +"dh c #154747", +"di c #2D8686", +"dj c #000101", +"dk c #3C1B1B", +"dl c #286A6A", +"dm c #044040", +"dn c #000E0E", +"do c #264747", +"dp c #396A6A", +"dq c #001B1B", +"dr c gray14", +"ds c #0C4141", +"dt c #031414", +"du c #172121", +"dv c #002828", +"dw c #060D0D", +"dx c #063B3B", +"dy c #2B5C5C", +"dz c #000707", +"e` c #343A3A", +"ea c #182525", +"eb c #364949", +"ec c #001414", +"ed c #AA7979", +"ee c #506969", +"ef c #002121", +"eg c #1C7171", +"eh c #213E3E", +/* pixels */ +"``````````````dzdjcv`rcgadce````````````", +"``````````axabbp`daecka`bubpcice````````", +"````````de`u`ick`jds`mdscabjbqde`e``````", +"``````addbdkca`adgdgcddrahdkc`dt`ian````", +"`````dcgdtbkegcdazbnd`bodididkajbzcjbg``", +"````djcxajavbhbcdad`bweecfdadoeackcyas``", +"``de`ydc`obhbcbc`qbdat`k`qbndybsdsdrcnbu", +"``dqchdbdhehar`v`qedafakacbxebehcldcdvcb", +"``apchad`zbmav`v`cawafbd`teear`h`wcx`b`r", +"``dz`lckca`hboaaayakbdedat`xav`p`wb`blbt", +"```n`ydwcceheb`seecratd`cubndl`hbibrchbu", +"``cy`dcmdfbvbfav`g`x`xbwdabccddu`maoefbl", +"```u`y`ubrcpbedrcqdpaie`ebbfcw`mdrec`b`u", +"`````r`ibjaeca`oaldlbfbmdhcqbicoa`cgec``", +"````abcz`dbpadbydd`f`zane`c`dwdxcg`raq``", +"``````djbtam`ibrb`addcbkbjdmcxcs``cz````", +"````````axdq`ldecbbaas`l`rbgblabdj``````", +"````````````buaxdzaubbbbctcgbudn````````", +"``````````````btagbycg`ebtab````````````", +"````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood5.xpm b/hacks/images/bubbles/blood5.xpm new file mode 100644 index 00000000..76f2471d --- /dev/null +++ b/hacks/images/bubbles/blood5.xpm @@ -0,0 +1,201 @@ +/* XPM */ +static char *blood5[] = { +/* width height ncolors chars_per_pixel */ +"24 24 170 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #013232", +"`j c #3C9090", +"`k c #251A1A", +"`l c #095454", +"`m c #190101", +"`n c #000606", +"`o c #003434", +"`p c #0E2E2E", +"`q c #001313", +"`r c #115555", +"`s c #213030", +"`t c #60C0C0", +"`u c #0F0404", +"`v c #002020", +"`w c #165D5D", +"`x c #636A6A", +"`y c #072A2A", +"`z c #445C5C", +"a` c #6C7676", +"aa c #000C0C", +"ab c #001919", +"ac c #102222", +"ad c #4D5454", +"ae c #002626", +"af c #163535", +"ag c #4F6363", +"ah c #000505", +"ai c #65A0A0", +"aj c #052E2E", +"ak c #041616", +"al c #044444", +"am c #76C1C1", +"an c #7ED6D6", +"ao c #196969", +"ap c #385656", +"aq c #0C4545", +"ar c #767F7F", +"as c #642525", +"at c #360505", +"au c #5FB4B4", +"av c #002C2C", +"aw c #8C9B9B", +"ax c #000B0B", +"ay c #030404", +"az c #001818", +"b` c #280404", +"ba c #0A0E0E", +"bb c #385C5C", +"bc c #002525", +"bd c #407E7E", +"be c #354F4F", +"bf c #739999", +"bg c #001111", +"bh c #5A7D7D", +"bi c #347272", +"bj c #030A0A", +"bk c #5AABAB", +"bl c #010808", +"bm c #001E1E", +"bn c #6E3B3B", +"bo c #71B1B1", +"bp c #274E4E", +"bq c #266464", +"br c #000A0A", +"bs c #2B3E3E", +"bt c #053333", +"bu c #121515", +"bv c #270C0C", +"bw c #001717", +"bx c #253838", +"by c #418888", +"bz c #374343", +"c` c #013C3C", +"ca c #040707", +"cb c #031D1D", +"cc c #192C2C", +"cd c #000303", +"ce c #070000", +"cf c #164040", +"cg c #537272", +"ch c #5B8787", +"ci c #120E0E", +"cj c #032A2A", +"ck c #520B0B", +"cl c #001010", +"cm c #062323", +"cn c #435555", +"co c #0C3636", +"cp c #8EAFAF", +"cq c #282A2A", +"cr c #001D1D", +"cs c #0C1515", +"ct c #515C5C", +"cu c #1B5555", +"cv c #297D7D", +"cw c #002A2A", +"cx c #2B3030", +"cy c #4F3939", +"cz c #AF5C5C", +"d` c #000909", +"da c #003737", +"db c #010000", +"dc c #001616", +"dd c #042727", +"de c #0C3C3C", +"df c #030F0F", +"dg c #010D0D", +"dh c #002323", +"di c #074E4E", +"dj c #0C4949", +"dk c #295555", +"dl c #5E7272", +"dm c #011A1A", +"dn c #000202", +"do c #000F0F", +"dp c #176464", +"dq c #042020", +"dr c #0F0000", +"ds c #001C1C", +"dt c #8A5B5B", +"du c #419A9A", +"dv c #000808", +"dw c #205C5C", +"dx c #420707", +"dy c #064949", +"dz c #041919", +"e` c #0C5C5C", +"ea c #001515", +"eb c #071212", +"ec c #1D4F4F", +"ed c #171B1B", +"ee c #154747", +"ef c #2D8686", +"eg c #031B1B", +"eh c #000101", +"ei c #3C1B1B", +"ej c #286A6A", +"ek c #044040", +"el c #000E0E", +"em c #264747", +"en c #0F4E4E", +"eo c #0D1E1E", +"ep c #001B1B", +"eq c gray14", +"er c #031414", +"es c #172121", +"et c #060D0D", +"eu c #063B3B", +"ev c #2B5C5C", +"ew c #000707", +"ex c #343A3A", +"ey c #396363", +"ez c #182525", +"f` c #364949", +"fa c #001414", +"fb c #467373", +"fc c #AA7979", +"fd c #506969", +"fe c #002121", +"ff c #1C7171", +"fg c #213E3E", +/* pixels */ +"``````````````````cdew`v`bdoelci````````````````", +"``````````````eafac`ekcbdffec`eqdbab````````````", +"``````````ewaxbw`hbt`l`lcse`btajbjaec`dc````````", +"````````brdadhcb`ycoenbudpencfe`ajcabgewcd``````", +"``````ea`iat`ue`edafdwbpeffgejffaocicbegelfe````", +"``````dv`bakbvffadbqbi`jdtbebicvbn`kaqdqalaj````", +"````cmbmbjdyf`ffbybd`jczcgadbkbnefec`aeob`fe`d``", +"````cwdab`e`cycvduarczai`xauboczbbcqezcocqc`av``", +"```mcedrck`waocvarbodtambfbf`tczcneyem`p`l`dehci", +"```qdaeicobubxapbybkamawcpboarbhctbzeqesdeaj`eep", +"``ax`qdxbaaf`hapfbai`cbfananbfdlfbap`hezbadddmaz", +"``brfeatebaf`hex`zdl`xa`bofcboagcnbz`s`aebdqdcaa", +"``dvfadaakacfgbs`gcgdl`x`cdtauchbydk`sbuetda`oaz", +"``cidmcbegeocudwbe`gfdcgctchdtbncyasezeoakdmdrdm", +"``brfebcakebenafbxexbb`z`g`gapbicvaobudydqblav`u", +"````bw`meraldjafccbxevbieyf`cxdkcu`pdeeicjah`d``", +"````ahcw`oc`ek`yeeeieidwfgeq`s`w`fbab`ekdoewah``", +"``````dv`batc`ajdyaqck`raf`paqexdydzeuaacl`m````", +"``````dnewbg`o`pekebbtdyeidicqcacjcj`vewbm``````", +"````````braaahd`axblayaydzdzddcj`nelcdahdb``````", +"``````````bjcrbwdnfadcd`aedgdoaaaaaxep``````````", +"````````````````dsbw``cdeads``axdrbg````````````", +"``````````````````aadodrbgd`eldn````````````````", +"````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood6.xpm b/hacks/images/bubbles/blood6.xpm new file mode 100644 index 00000000..50a6c220 --- /dev/null +++ b/hacks/images/bubbles/blood6.xpm @@ -0,0 +1,220 @@ +/* XPM */ +static char *blood6[] = { +/* width height ncolors chars_per_pixel */ +"30 30 183 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #010404", +"`j c #013232", +"`k c #3C9090", +"`l c #251A1A", +"`m c #095454", +"`n c #190101", +"`o c #70D0D0", +"`p c #000606", +"`q c #003434", +"`r c #0E2E2E", +"`s c #001313", +"`t c #115555", +"`u c #213030", +"`v c #60C0C0", +"`w c #0F0404", +"`x c #002020", +"`y c #165D5D", +"`z c #636A6A", +"a` c #072A2A", +"aa c #445C5C", +"ab c #6C7676", +"ac c #000C0C", +"ad c #549393", +"ae c #001919", +"af c #102222", +"ag c #4D5454", +"ah c #002626", +"ai c #163535", +"aj c #043737", +"ak c #4F6363", +"al c #000505", +"am c #65A0A0", +"an c #052E2E", +"ao c #041616", +"ap c #044444", +"aq c #76C1C1", +"ar c #7ED6D6", +"as c #001212", +"at c #196969", +"au c #385656", +"av c #0C4545", +"aw c #767F7F", +"ax c #642525", +"ay c #360505", +"az c gray28", +"b` c #000B0B", +"ba c #030404", +"bb c #001818", +"bc c #944040", +"bd c #280404", +"be c #0A0E0E", +"bf c #385C5C", +"bg c #002525", +"bh c #6D8686", +"bi c #407E7E", +"bj c #000404", +"bk c #354F4F", +"bl c #739999", +"bm c #001111", +"bn c #5A7D7D", +"bo c #347272", +"bp c #030A0A", +"bq c #5AABAB", +"br c #001E1E", +"bs c #6E3B3B", +"bt c #71B1B1", +"bu c #183C3C", +"bv c #274E4E", +"bw c #266464", +"bx c #000A0A", +"by c #287373", +"bz c #0D1A1A", +"c` c #2B3E3E", +"ca c #053333", +"cb c #121515", +"cc c #270C0C", +"cd c #001717", +"ce c #253838", +"cf c #418888", +"cg c #374343", +"ch c #013C3C", +"ci c #040707", +"cj c #031D1D", +"ck c #192C2C", +"cl c #000303", +"cm c #070000", +"cn c #164040", +"co c #537272", +"cp c #5B8787", +"cq c #120E0E", +"cr c #032A2A", +"cs c #520B0B", +"ct c #001010", +"cu c #062323", +"cv c #435555", +"cw c #0C3636", +"cx c #8EAFAF", +"cy c #282A2A", +"cz c #001D1D", +"d` c #0C1515", +"da c #515C5C", +"db c #1B5555", +"dc c #297D7D", +"dd c #002A2A", +"de c #2B3030", +"df c #4F3939", +"dg c #AF5C5C", +"dh c #000909", +"di c #003737", +"dj c #010000", +"dk c #001616", +"dl c #042727", +"dm c #0C3C3C", +"dn c #030F0F", +"do c #010D0D", +"dp c #002323", +"dq c #074E4E", +"dr c #0C4949", +"ds c #295555", +"dt c #5E7272", +"du c #011A1A", +"dv c #000202", +"dw c #55A1A1", +"dx c #000F0F", +"dy c #176464", +"dz c #042020", +"e` c #0F0000", +"ea c #001C1C", +"eb c #8A5B5B", +"ec c #419A9A", +"ed c #000808", +"ee c #205C5C", +"ef c #420707", +"eg c #064949", +"eh c #041919", +"ei c #0C5C5C", +"ej c #001515", +"ek c #071212", +"el c #1D4F4F", +"em c #171B1B", +"en c #154747", +"eo c #2D8686", +"ep c #031B1B", +"eq c #000101", +"er c #3C1B1B", +"es c #286A6A", +"et c #044040", +"eu c #000E0E", +"ev c #264747", +"ew c #0F4E4E", +"ex c #0D1E1E", +"ey c #396A6A", +"ez c #001B1B", +"f` c gray14", +"fa c #0C4141", +"fb c #031414", +"fc c #172121", +"fd c #002828", +"fe c #060D0D", +"ff c #063B3B", +"fg c #2B5C5C", +"fh c #645C5C", +"fi c #000707", +"fj c #343A3A", +"fk c #396363", +"fl c #182525", +"fm c #364949", +"fn c #001414", +"fo c #467373", +"fp c #AA7979", +"fq c #506969", +"fr c #002121", +"fs c #1C7171", +"ft c #213E3E", +/* pixels */ +"````````````````````````dx`eahddahdvdx``````````````````````", +"``````````````````dp``dufrdxej`ieqbg`n`dddbr````````````````", +"````````````````dxalddfa`ddqetdldzbdcmchchdj`b``````````````", +"````````````b``efn`japanegeifabeeidmekcibafr`xfded``````````", +"``````````bxdi`qdocua`cwdr`afldy`yemaveianehbpfnalcl````````", +"````````ct`nefbdcacwcbfcelbweedcdsftatbwdycscabp`jfrcm``````", +"````````ctdicjanel`fdybwesbobodfbkfgesby`fdyeia`caddcc``````", +"``````dkezdnaofabk`yerdceycfazcfaaeyfh`keofsatd`crapalcd````", +"````fneq`ifbavbvbfbyeoececblbqcodaaddgbceoevcncbdlbdetbg`e``", +"````cqejdibdeiataxeoecbcbq`v`c`zam`vdgbhbfde`hemfacy`l`scb``", +"`````ddiefde`fdbbodtbcdgcx`oambhbl`v`vdgazfkevfldrer`wdddk``", +"``bmaydibd`menftcebfcfbq`vfpararbtawamdwakfmevfcdmdmapfdbxdx", +"``fi`bayegbzaf`hdebkbibqambtarfp`obl`zfhakfkdebucbdmdlch``cq", +"``dxacbrapbeenfcevaufoad`cbhblarfpaqbh`zfoauceceembecjdpbxdk", +"``fnez`papekcwfcc`cgaacobnababbtfp`obhakcvbkce`uafekdncd``fr", +"``bbeabx`jd`afckevcg`gakfhdtbhbtebbqcpbnbibfcefcexekandifdfi", +"``cddv`bbaekd`cneldsau`gcocodtdt`cfhebbhbceoftemd`cidz`bbg`s", +"``dh`p`ddodzekaienbvfmfm`gagagagfqbiecebbsdccncb`rcjbpfrfrdx", +"````asembbdnfedmenck`udebffkaaazazcgbfesbwax`rdmegdl`i`bac``", +"````b`ezccfbcaegdraick`hbweseyfkc`evc`dsdbcnbzerf`crdvdddj``", +"`````p`x`j`bcaegcwcwcnataxazbvbvf``uen`ycbbzcabdajfnedfndo``", +"``````dvdue`caefana`av`tbv`lenbuckfcbvc``mbeffcwaeedeaeu````", +"``````````ej`jbdajanaya`dmewfj`tavfaercqffaodldpeufnfn``````", +"````````bjeqcl`xfl`janehbpcua`egcsefcacidldz`xeu``brcl``````", +"``````````bxacbjdvacb``pbabpciehepcjdlah`pdkeq``b`dj````````", +"`````````````e`ncd`ebxbbdubm`s`bctdhbbdxcd`pej`seq``````````", +"````````````````bjcmczctfieqdxbrahbbdvdv`scmcd``````````````", +"``````````````````aldvace`ejb`bmalbjedcdbm`p````````````````", +"````````````````````````dxbjdhcte`cicm``````````````````````", +"````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood7.xpm b/hacks/images/bubbles/blood7.xpm new file mode 100644 index 00000000..81a71ca0 --- /dev/null +++ b/hacks/images/bubbles/blood7.xpm @@ -0,0 +1,228 @@ +/* XPM */ +static char *blood7[] = { +/* width height ncolors chars_per_pixel */ +"36 36 185 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #013232", +"`j c #3C9090", +"`k c #251A1A", +"`l c #095454", +"`m c #190101", +"`n c #70D0D0", +"`o c #000606", +"`p c #003434", +"`q c #0E2E2E", +"`r c #001313", +"`s c #115555", +"`t c #213030", +"`u c #60C0C0", +"`v c #0F0404", +"`w c #002020", +"`x c #165D5D", +"`y c #636A6A", +"`z c #072A2A", +"a` c #445C5C", +"aa c #6C7676", +"ab c #000C0C", +"ac c #549393", +"ad c #001919", +"ae c #102222", +"af c #4D5454", +"ag c #002626", +"ah c #163535", +"ai c #043737", +"aj c #4F6363", +"ak c #000505", +"al c #65A0A0", +"am c #052E2E", +"an c #041616", +"ao c #044444", +"ap c #76C1C1", +"aq c #7ED6D6", +"ar c #001212", +"as c #196969", +"at c #385656", +"au c #0C4545", +"av c #767F7F", +"aw c #642525", +"ax c #360505", +"ay c gray28", +"az c #5FB4B4", +"b` c #002C2C", +"ba c #0E2626", +"bb c #000B0B", +"bc c #030404", +"bd c #001818", +"be c #944040", +"bf c #280404", +"bg c #0A0E0E", +"bh c #385C5C", +"bi c #002525", +"bj c #6D8686", +"bk c #407E7E", +"bl c #000404", +"bm c #354F4F", +"bn c #739999", +"bo c #001111", +"bp c #5A7D7D", +"bq c #347272", +"br c #030A0A", +"bs c #5AABAB", +"bt c #010808", +"bu c #001E1E", +"bv c #6E3B3B", +"bw c #71B1B1", +"bx c #183C3C", +"by c #274E4E", +"bz c #266464", +"c` c #000A0A", +"ca c #287373", +"cb c #0D1A1A", +"cc c #2B3E3E", +"cd c #053333", +"ce c #121515", +"cf c #270C0C", +"cg c #001717", +"ch c #253838", +"ci c #418888", +"cj c #374343", +"ck c #013C3C", +"cl c #040707", +"cm c #031D1D", +"cn c #192C2C", +"co c #000303", +"cp c #164040", +"cq c #537272", +"cr c #120E0E", +"cs c #032A2A", +"ct c #520B0B", +"cu c #001010", +"cv c #062323", +"cw c #435555", +"cx c #0C3636", +"cy c #8EAFAF", +"cz c #282A2A", +"d` c #001D1D", +"da c #0C1515", +"db c #515C5C", +"dc c #1B5555", +"dd c #297D7D", +"de c #002A2A", +"df c #2B3030", +"dg c #4F3939", +"dh c #AF5C5C", +"di c #000909", +"dj c #003737", +"dk c #010000", +"dl c #001616", +"dm c #042727", +"dn c #0C3C3C", +"do c #030F0F", +"dp c #010D0D", +"dq c #002323", +"dr c #074E4E", +"ds c #0C4949", +"dt c #295555", +"du c #5E7272", +"dv c #011A1A", +"dw c #000202", +"dx c #55A1A1", +"dy c #000F0F", +"dz c #176464", +"e` c #042020", +"ea c #0F0000", +"eb c #001C1C", +"ec c #8A5B5B", +"ed c #419A9A", +"ee c #000808", +"ef c #205C5C", +"eg c #420707", +"eh c #064949", +"ei c #041919", +"ej c #0C5C5C", +"ek c #001515", +"el c #071212", +"em c #1D4F4F", +"en c #171B1B", +"eo c #154747", +"ep c #2D8686", +"eq c #031B1B", +"er c #000101", +"es c #3C1B1B", +"et c #286A6A", +"eu c #044040", +"ev c #000E0E", +"ew c #264747", +"ex c #0F4E4E", +"ey c #0D1E1E", +"ez c #396A6A", +"f` c #001B1B", +"fa c gray14", +"fb c #0C4141", +"fc c #031414", +"fd c #172121", +"fe c #002828", +"ff c #060D0D", +"fg c #063B3B", +"fh c #2B5C5C", +"fi c #645C5C", +"fj c #000707", +"fk c #343A3A", +"fl c #396363", +"fm c #182525", +"fn c #364949", +"fo c #001414", +"fp c #467373", +"fq c #AA7979", +"fr c #506969", +"fs c #022323", +"ft c #002121", +"fu c #1C7171", +"fv c #213E3E", +/* pixels */ +"````````````````````````````````c``efoardw``````````````````````````````", +"````````````````````````cobb`oftf`cuarevdldk`mdeag``````````````````````", +"````````````````````cueefodjaheub`fcdofcagckeuaxdk`kdv``````````````````", +"``````````````````ekcoaddj`tao`l`leudme`eoczdr`ife`pdkbf````````````````", +"``````````````c`dvfjdl`pehcveuejdsdncbccdsbgcveqbrdvc`bibuee````````````", +"````````````c``qdjdqbrdm`zdnauexfdfmdzdz`acpdsejame`dpbo`r`oco``````````", +"``````````cuaxaxegdrcvbacrahahemembzezef`hefdz`f`ffkaocle`f`fte`````````", +"``````````de`icke`ctewbyeofvbzcafhfhbefhdfetbzbvdg`sesamcl`pf`ax````````", +"````````ebdi`bfceicf`ffuafcaetbqbkedecbqfnbqepddbv`f`fauanaiaodwab``````", +"``````ebfjadbrfffb`sfhfudbepezci`cdxcifra`edbe`jbkfudz`qbgcd`h`b`par````", +"``````ftarebcmehcfbmfucaepbveddxfqacdudbbpecbjaaepby`tfdeyamczesad`m````", +"````eedecuaobfewdzdgbvepedaydxdhal`c`yal`ubwdhdxbhfk`hfmeydnczegdeb``m``", +"````ce`p`kfafv`f`sfuawbebeaf`udhbwbnbjbn`u`ufqbsayezewchfmexesbfcxcoe```", +"`````weaax`mctejdcemdtbqacdx`ufqcy`nbwbnbjalalbsa`bhdtewfdexeh`heucoft``", +"````agdjcxfacxaeenchccatcidxazapaqfqcy`nbjavbjcqdbbhfkfafdbadnai`i`ebd``", +"``fjcgdq`maoel`aenchfkcjfpbsalbnbnapaqaqbnbn`yajajflcj`tahcb`qdm`bbifoek", +"``addw`o`baodaexfd`hfh`gfpac`cbjbnbnaqavapbwduajfrbhfkchbxeybgei`idldwcg", +"```mboftageuelcxcn`hccbma`frdu`yaaavbwcyapbwduajcwatdf`tcneyelclb`dldw`r", +"``eadl`rftcselaeenfvccfnayajfr`yaa`cbwfq`ualbpcqfpflewfveneydae``pdedqbd", +"``fffo`oeabcelbgeneofhfnatcwajdubp`ybjbsfidhdx`jciddewfmendaffcmckaxdefj", +"````ekdvckbreqcbaedcbzbybmcja`frcqfrdbbpdxecaabvdgaweffmcebaananbueabu``", +"`````wag`pdpcmelcxcpeofvccfnfkay`gafafajajfp`jciawafefen`qcdcmbt`raedv``", +"````d`c``dfobrbr`qdseocn`hczbmbhezbhayfnfkbmfhfhefescpbadrehfsakekdq`m``", +"````c`cgagdjfccsehdsdsahcnfadtfhbqezfldffndfccemdc`scedn`mahcserar`ddw``", +"```````obi`bde`iaoehcxcxcpemasawcafhfhczew`hdc`xes`acbauegamadakfjar````", +"``````fjeb`d`k`maxaoamfbexctdzdz`feocpcnenbx`xesemba`z`maiftdiee`efj````", +"````````blak`bfddkckcvameh`lexctcecpahahbaaucrczeheldmfgft`ocu`mad``````", +"``````````akfjfo`peack`kegaieyds`ldfegexauescr`vcdeidmdef`abd`ad````````", +"``````````bl``dwdydqb``bfsdodoeie`dmaoaxbxamfgfafsdl`weverfj`mbl````````", +"````````````c`c`abakerabbb`o`obcclbreieiandmagft`odvakcoeec`dk``````````", +"```````````````e`mcgbb`obbdvf``wbbcgcsdl`odldvbbdycudiadfobl````````````", +"``````````````````dybud`ev`ofjbber`rdvdqarfjblakblar`m`m````````````````", +"````````````````````cobbebdv`r``coblekf`cu``difoeaarc```````````````````", +"````````````````````````ererboeabuevc`didiblerarbl``````````````````````", +"````````````````````````````````c```blabdk``````````````````````````````", +"````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood8.xpm b/hacks/images/bubbles/blood8.xpm new file mode 100644 index 00000000..050b6e28 --- /dev/null +++ b/hacks/images/bubbles/blood8.xpm @@ -0,0 +1,241 @@ +/* XPM */ +static char *blood8[] = { +/* width height ncolors chars_per_pixel */ +"44 44 190 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #010404", +"`j c #013232", +"`k c #3C9090", +"`l c #251A1A", +"`m c #095454", +"`n c #190101", +"`o c #70D0D0", +"`p c #000606", +"`q c #003434", +"`r c #0E2E2E", +"`s c #001313", +"`t c #115555", +"`u c #213030", +"`v c #60C0C0", +"`w c #0F0404", +"`x c #002020", +"`y c #165D5D", +"`z c #636A6A", +"a` c #072A2A", +"aa c #445C5C", +"ab c #6C7676", +"ac c #000C0C", +"ad c #549393", +"ae c #001919", +"af c #102222", +"ag c #4D5454", +"ah c #002626", +"ai c #163535", +"aj c #043737", +"ak c #4F6363", +"al c #000505", +"am c #65A0A0", +"an c #052E2E", +"ao c #041616", +"ap c #044444", +"aq c #76C1C1", +"ar c #7ED6D6", +"as c #001212", +"at c #196969", +"au c #385656", +"av c #0C4545", +"aw c #767F7F", +"ax c #642525", +"ay c #360505", +"az c gray28", +"b` c #5FB4B4", +"ba c #002C2C", +"bb c #0E2626", +"bc c #8C9B9B", +"bd c #000B0B", +"be c #030404", +"bf c #001818", +"bg c #944040", +"bh c #280404", +"bi c #0A0E0E", +"bj c #385C5C", +"bk c #002525", +"bl c #6D8686", +"bm c #407E7E", +"bn c #000404", +"bo c #354F4F", +"bp c #739999", +"bq c #001111", +"br c #5A7D7D", +"bs c #347272", +"bt c #030A0A", +"bu c #5AABAB", +"bv c #010808", +"bw c #001E1E", +"bx c #6E3B3B", +"by c #71B1B1", +"bz c #183C3C", +"c` c #274E4E", +"ca c #266464", +"cb c #000A0A", +"cc c #287373", +"cd c #0D1A1A", +"ce c #2B3E3E", +"cf c #053333", +"cg c #121515", +"ch c #270C0C", +"ci c #001717", +"cj c #253838", +"ck c #418888", +"cl c #374343", +"cm c #013C3C", +"cn c #040707", +"co c #031D1D", +"cp c #192C2C", +"cq c #000303", +"cr c #070000", +"cs c #164040", +"ct c #537272", +"cu c #5B8787", +"cv c #120E0E", +"cw c #032A2A", +"cx c #520B0B", +"cy c #001010", +"cz c #062323", +"d` c #435555", +"da c #0C3636", +"db c #8EAFAF", +"dc c #282A2A", +"dd c #001D1D", +"de c #0C1515", +"df c #515C5C", +"dg c #1B5555", +"dh c #297D7D", +"di c #002A2A", +"dj c #2B3030", +"dk c #4F3939", +"dl c #AF5C5C", +"dm c #000909", +"dn c #003737", +"do c #010000", +"dp c #001616", +"dq c #042727", +"dr c #0C3C3C", +"ds c #030F0F", +"dt c #010D0D", +"du c #002323", +"dv c #074E4E", +"dw c #0C4949", +"dx c #295555", +"dy c #5E7272", +"dz c #011A1A", +"e` c #000202", +"ea c #55A1A1", +"eb c #000F0F", +"ec c #176464", +"ed c #042020", +"ee c #0F0000", +"ef c #001C1C", +"eg c #8A5B5B", +"eh c #419A9A", +"ei c #000808", +"ej c #205C5C", +"ek c #420707", +"el c #064949", +"em c #041919", +"en c #0C5C5C", +"eo c #001515", +"ep c #071212", +"eq c #1D4F4F", +"er c #171B1B", +"es c #154747", +"et c #2D8686", +"eu c #031B1B", +"ev c #000101", +"ew c #3C1B1B", +"ex c #286A6A", +"ey c #044040", +"ez c #000E0E", +"f` c #264747", +"fa c #0F4E4E", +"fb c #0D1E1E", +"fc c #396A6A", +"fd c #001B1B", +"fe c gray14", +"ff c #0C4141", +"fg c #031414", +"fh c #011212", +"fi c #172121", +"fj c #002828", +"fk c #060D0D", +"fl c #063B3B", +"fm c #2B5C5C", +"fn c #645C5C", +"fo c #000707", +"fp c #343A3A", +"fq c #396363", +"fr c #182525", +"fs c #364949", +"ft c #001414", +"fu c #467373", +"fv c #AA7979", +"fw c #506969", +"fx c #022323", +"fy c #002121", +"fz c #1C7171", +"g` c #213E3E", +/* pixels */ +"````````````````````````````````````````````ac``````````````````````````````````````````", +"`````````````````````````````````peie`bnbddidicicqae`xbwcg``````````````````````````````", +"````````````````````````````cqcqddfydieoezebfoezbqahee`n`n`rbw``````````````````````````", +"`````````````````````````pcbac`jap`nekapcweuaofhanapffekekdocr`dfd``````````````````````", +"````````````````````ev`sal`pdieleleyel`m`mfla`emelbhdjelajfydn`jdo`ncd``````````````````", +"``````````````````eveoezeobaelajdqfldv`mdw`rde`mcx`rfkemepdscncocbdidueo````````````````", +"````````````````fo`bdndd`idqcfa`drdr`tfa`acgesatesfbdafadvfledfkbvacftbnev``````````````", +"``````````````fj`dcmcmcmdsfkbibbdaaffrcpaidgccecaics`t`tdxfpffa`cnfg`baebqac````````````", +"````````````ch`dcp`ddvcxcfdwfferercsejexc`caetex`uf`atfzaz`fenchdvemdsahcy`bcg``````````", +"``````````dzef`xeycoedewench`yesdgcaexccfmbsbxfcdjdxcacafcew`ydkenajdsdqcmezchef````````", +"``````````dzalfybwaodqch`ffz`fbscccabsbmckbgegbmclbjetetdhbxax`l`favczdqai`bacft````````", +"````````crbdbwdtbtcodrenaxejaadcdhfqfu`kbgehckfwd`fucufp`ketaaatatdabiedapcmbwaf`s``````", +"````````fteoevfgemelfpclfzfzdh`z`k`k`kbudladbrctdfadazehbr`kccc`eq`adeczaj`ncpei`d``````", +"``````eoftfoahajekekcv`ldhdhdhehbxadeadlea`c`zbrcub`fnbxabbmbocj`uercg`rapcxeydiahdu````", +"```````dahdiewayes`mecdkaxbxckegazbudl`vam`cab`c`oaqfvdlbufqfsfp`hfrfidrdvcnek`qacbk````", +"````dd`ndnayewcjcvcl`tfzbxbg`zbgegb`eg`obybpblawby`v`vdlblaafqfqf`g`fidr`mdj`n`lacdp`n``", +"````fy`day`d`wayewecdgdgdxfcckehbu`vfvab`oaqbybpaw`cambubufu`gfqc`f`frdr`mdvfefeebbdfy``", +"````ci`ddn`lbhdvdr`acpcjceaufcadeab``odbfvfvdb`obpawbl`ccuakaafpce`ufr`adafleybadzebdd``", +"````dp`j`j`heldqdeaferg`djbod`adbuambybyaqarawarbyblab`zdfdffcbjdj`uaicgfbfled`jbaevbw``", +"`````scibwdrelembbaier`uf`auazbradam`cbpbpbyarfvaqbpbl`zdyctfubjce`hbzfrdeemczcwduevbw``", +"````cq``bddnelepavbzfi`udxboazbrad`cblblbpbpaqbcaraqam`zfwfwaaclfpg`bzfr`acnco`jftalci``", +"``eefofddp`jeyao`raifi`hf`fp`gakctdyababawblbyaraw`oam`zakagaafsdj`ucp`afbepbt`beoe`al`p", +"````ezbw`efjajfkbbfberg`cecl`gazdfak`zababbpbydbdlbycudyfwakfcauceg`erafdeepeddn`bfdac``", +"````cbbqevchdtepcdfbfrg`c`fsfpd`akct`zdy`zab`cb`eg`vbuadckckckfmcjcpcgcgbifkfxdndnafbk``", +"````fd`p`scmcnepfkcv`rdgejfmfpau`gakbrctcu`zdycueafndlegbgbgfudhf`cpcgdedefkao`j`bah`d``", +"````eeacahdn`iembibbbbesejdxdjboclaaakakfwdfdffwcueablabbgbxaxdkdgficgbba`cobfftbafyeo``", +"````fdever`bdscnedepdrcscsg`dcf`clfp`gazd`agagaaakaafuck`kbgaxfzeqer`adadqaobt`s`jeodp``", +"````ezebbk`deobeemaodafafaai`hdjdjfsbjfqfcaaazazclclaufqfmfmfzatbzafavelflfhalaceedmfk``", +"``````ezefa``qdscncfffdwesbzfifefef`dxfqbsfcfqfpclfpfpc`dxeqboescgdacx`u`ledalaschef````", +"````````fdcwer`xbkfldw`mffdaaiaiaiejexccexexexcjc`cj`uf`dgat`yafcdffayfe`baefocqfy`s````", +"````````cbbk`bdn`jflapapda`rdr`tfsaxewaxcaf`g``u`h`hbz`yeccgfadebbewbhcmfjeidmbn`e``````", +"``````````dzfjereebhekapcfa`av`tf``tdk`lecbzcscpfrcpeqc``fenfffkcfekcmfyebcqacasfo``````", +"``````````e`e`ahdiay`ncmfxa`ajdcfadwfp`fdgcsaiai`a`r`tchdjesanfgcwflcwcbacaeeedd````````", +"````````````bnfobq`jee`ndnajewewanfbavdwekcvewdwffdwcxaycnapdsemah`bbw`sasdueo`e````````", +"``````````````ev`ecbbw`jchdn`hanczcnczanfldaescxbzayflelcnflbeahfybwacaldp`ncb``````````", +"``````````````cb``e`bdcbcibffddtbebebeepepaoancffldqeuajeyfyebbwftei`pbnbwee````````````", +"````````````````ezcy`sace`cb`p`pbqdpdsbebteudqbedteudqbkfde`aebqal``bn``bd``````````````", +"``````````````````fh`naecybdcb`eaeciddfhdtdzdiddfocbaeci`edmae`pcyfdft`p````````````````", +"````````````````````btdpbwefcidmalfocy`pbdftefbkbfeialbnale`bnbf`nepdm``````````````````", +"````````````````````````cqebcvfycibqeibn```ebwbkbkaccqalebeoeebq````````````````````````", +"``````````````````````````````bnbdcvdeftebbdasbdevbncqcydzasbq``````````````````````````", +"````````````````````````````````ei`pbqft`nbqbdac`eacdmcqev``````````````````````````````", +"````````````````````````````````````````````e```````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blood9.xpm b/hacks/images/bubbles/blood9.xpm new file mode 100644 index 00000000..e6efa9e2 --- /dev/null +++ b/hacks/images/bubbles/blood9.xpm @@ -0,0 +1,247 @@ +/* XPM */ +static char *blood9[] = { +/* width height ncolors chars_per_pixel */ +"50 50 190 2", +/* colors */ +"`` c None", +"`a c #102A2A", +"`b c #002E2E", +"`c c #689494", +"`d c #250000", +"`e c #000D0D", +"`f c #5D1616", +"`g c #415050", +"`h c #212A2A", +"`i c #010404", +"`j c #013232", +"`k c #3C9090", +"`l c #251A1A", +"`m c #095454", +"`n c #190101", +"`o c #70D0D0", +"`p c #000606", +"`q c #003434", +"`r c #0E2E2E", +"`s c #001313", +"`t c #115555", +"`u c #213030", +"`v c #60C0C0", +"`w c #0F0404", +"`x c #002020", +"`y c #165D5D", +"`z c #636A6A", +"a` c #072A2A", +"aa c #445C5C", +"ab c #6C7676", +"ac c #000C0C", +"ad c #549393", +"ae c #001919", +"af c #102222", +"ag c #4D5454", +"ah c #002626", +"ai c #163535", +"aj c #043737", +"ak c #4F6363", +"al c #000505", +"am c #65A0A0", +"an c #052E2E", +"ao c #041616", +"ap c #044444", +"aq c #76C1C1", +"ar c #7ED6D6", +"as c #001212", +"at c #196969", +"au c #385656", +"av c #0C4545", +"aw c #767F7F", +"ax c #642525", +"ay c #360505", +"az c gray28", +"b` c #5FB4B4", +"ba c #002C2C", +"bb c #0E2626", +"bc c #8C9B9B", +"bd c #000B0B", +"be c #030404", +"bf c #001818", +"bg c #944040", +"bh c #280404", +"bi c #0A0E0E", +"bj c #385C5C", +"bk c #002525", +"bl c #6D8686", +"bm c #407E7E", +"bn c #000404", +"bo c #354F4F", +"bp c #739999", +"bq c #001111", +"br c #5A7D7D", +"bs c #347272", +"bt c #030A0A", +"bu c #5AABAB", +"bv c #010808", +"bw c #001E1E", +"bx c #6E3B3B", +"by c #71B1B1", +"bz c #183C3C", +"c` c #274E4E", +"ca c #266464", +"cb c #000A0A", +"cc c #287373", +"cd c #0D1A1A", +"ce c #2B3E3E", +"cf c #053333", +"cg c #121515", +"ch c #270C0C", +"ci c #001717", +"cj c #253838", +"ck c #418888", +"cl c #374343", +"cm c #013C3C", +"cn c #040707", +"co c #031D1D", +"cp c #192C2C", +"cq c #000303", +"cr c #070000", +"cs c #164040", +"ct c #537272", +"cu c #5B8787", +"cv c #120E0E", +"cw c #032A2A", +"cx c #520B0B", +"cy c #001010", +"cz c #062323", +"d` c #435555", +"da c #0C3636", +"db c #8EAFAF", +"dc c #282A2A", +"dd c #001D1D", +"de c #0C1515", +"df c #515C5C", +"dg c #1B5555", +"dh c #297D7D", +"di c #002A2A", +"dj c #2B3030", +"dk c #4F3939", +"dl c #AF5C5C", +"dm c #000909", +"dn c #003737", +"do c #010000", +"dp c #001616", +"dq c #042727", +"dr c #0C3C3C", +"ds c #030F0F", +"dt c #010D0D", +"du c #002323", +"dv c #074E4E", +"dw c #0C4949", +"dx c #295555", +"dy c #5E7272", +"dz c #011A1A", +"e` c #000202", +"ea c #55A1A1", +"eb c #000F0F", +"ec c #176464", +"ed c #042020", +"ee c #0F0000", +"ef c #001C1C", +"eg c #8A5B5B", +"eh c #419A9A", +"ei c #000808", +"ej c #205C5C", +"ek c #420707", +"el c #064949", +"em c #041919", +"en c #0C5C5C", +"eo c #001515", +"ep c #071212", +"eq c #1D4F4F", +"er c #171B1B", +"es c #154747", +"et c #2D8686", +"eu c #031B1B", +"ev c #000101", +"ew c #3C1B1B", +"ex c #286A6A", +"ey c #044040", +"ez c #000E0E", +"f` c #264747", +"fa c #0F4E4E", +"fb c #0D1E1E", +"fc c #396A6A", +"fd c #001B1B", +"fe c gray14", +"ff c #0C4141", +"fg c #031414", +"fh c #011212", +"fi c #172121", +"fj c #002828", +"fk c #060D0D", +"fl c #063B3B", +"fm c #2B5C5C", +"fn c #645C5C", +"fo c #000707", +"fp c #343A3A", +"fq c #396363", +"fr c #182525", +"fs c #364949", +"ft c #001414", +"fu c #467373", +"fv c #AA7979", +"fw c #506969", +"fx c #022323", +"fy c #002121", +"fz c #1C7171", +"g` c #213E3E", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````bnbnbddpfjdn`bahfdcq`pebfj````````````````````````````````````", +"````````````````````````````````bnfocqftbwdddpeobqbddmfofyaydoaydnahbk``````````````````````````````", +"````````````````````````````fd`seibw`q`qapcmahdzfgfgbtfh`x`qcmflcheecrbwah``````````````````````````", +"````````````````````````dmdmezalfd`bapek`ddvelapajdqdscwdvaycravcm`j`rdoayahdd``````````````````````", +"```````````````````````pftevevdzdn`heyajey`m`m`manczaoel`wapeyeyfxfh`bah`qfibhah````````````````````", +"````````````````````bnfd`xezeo`jdvcfeddadvenavav`rcd`tfpdabicdczcoepbedzez`sahdzbq``````````````````", +"``````````````````cbdi`qdifhdsancfa`drdafa`tbzafcgesej`tfbdaff`mdvfledfgbtbtcycifo``````````````````", +"````````````````du`naydncmfxcnaobibbdr`aerfrcpcpeqdhatesfres`t`tdkdgdra`btfhbwdicyezei``````````````", +"``````````````fbcr`rekeeayapdqda`rcg`afreqejejdxcadhccg``uejatfzaxclc`cx`mcodtfg`jev`bbk````````````", +"````````````bw`jdzchcmdqeyg`ceekfaaibzdgejcccadxbsfnbsceceexejfzaxew`teccxelaocn`bdnevbh`x``````````", +"```````````s`xfofjdnfhfgdvewayewdkatexexccbsbsbm`kfpckfsbofqccexdhewdkaz`fenflbtajap`xfdbqcb````````", +"``````````fyacdpdzdsfgdqen`fatecagaxdhfmfcck`kbleg`kfud`d`bs`kfnetdhbs`gateca`fkcweldnebay`e````````", +"````````bqdmaeftbtbecofffaecfzatakaxetbmfcckbubxehbrctakfw`kegdk`ketetatecfacdbidqapap`jdmercq``````", +"`````````nevbfeoeueuavcxec`ffzccdh`k`z`keheadlb`cuctctdfbrbldlcuad`kccf`g`cscgfbdqflayekfybk`n``````", +"``````alfj`pftfjflbhayekcxewccdhet`kbgehadbpb`am`cfnbrcububpdlbxadbmboce`ucpcgafdaelewapdibncrdz````", +"``````dzbbddey`dayesenecatewewbmckabbxamb`dlb`am`cab`c`vdbbyfvdleafqclcedc`hfibbff`m`w`dcmaedu`d````", +"``````bhay`qay`hcscvf``t`ybxaxbxegbgagfv`vfvbybybpblawby`v`v`vdlbuaabjfcf`cjcpfrdw`mewek`dahfoah````", +"````efczeecm`n`wekcx`f`tdgexexbmeheabu`vaqegdbaqaqbpbpawambyb``vb`fu`gfcfmdx`ufrff`mdveweedievdddz``", +"````bfer`ddnapbhfa`mesbzg`cjcebjfuckeab``vdbfvarararaqbpawblamamadfw`gfsboc``herdrdwapeldnfje`aeef``", +"````cy`nfi`dai`uflfbcder`uceceauaaadeabubyaq`oarfvbcarbyblabblbrfwdfaabjfpdc`ufiafdaflanbadnbd`sdz``", +"`````pbw`beyekeyczbi`afr`ucjfpcld`cubuamambpbyaqardbaraqbp`c`z`zdfdffufqcldc`ucpcdfbcfeddqdnbwbdbw``", +"````al`e`sah`napep`acsfifecjauauazbradam`cblbpbpbyarawarbybpab`zfwctfubjfpdj`haifbcdepcocwah`saleo``", +"````e`ei`pfh`leybiffeser`hc`fmfs`gbmadcublabblblbpaqardbaqaq`c`zfwfwd`clfpcecjbzaf`afkemanbwcy``eo``", +"`````edzdd`pekflep`rdacpfecjcecl`gakfwdybr`zababbpbyarfv`obyblfnakagaabodjcj`ucpaffbepbefjcidpbnas``", +"````cbdzaee`eyanfkbbafercpcjcjfs`g`gdfdffn`zabblbpby`ofv`vambrfwakaafcauf`cj`ufiafepfkaodn`j`xdz`p``", +"````cbaseo`sayfkfkcdcdcgbzc`f`fsfpd`akctdfdy`z`zblambyegb`b`adcubmbmbmfqf``ucpcgcdbifkfxdndn`b`dcy``", +"````aecbe``b`jcnaobicvereseqcadxfpbjd`dfctbrbrbr`zbr`cb`fnegbueaehehbmdhc``ufierdebicnaocm`qcrdudd``", +"````dzei`s`qdibtaocnfbfbfadgcadxdjbocld`fwfwctctdfakdycub`agegbxbxbxbxaxcabzercgfbedfgfgddfyaybwde``", +"````asbdbf`ddu`icocoep`rbzcsdgc`djfsfs`g`gagagagagagdfctfuckehegegbgdjdhecaicgcd`redcobtezfybhfyae``", +"````foaeddeedidsbeedbi`ravesbzcjfececefpaud`aad`d``gd`aad`aabsbmdhfnbxaxdg`afbdreyanfg`pezbkahasfk``", +"``````dd`p`j`qft`iemepa`dresesaifedcdccebjbjfcfcbjfsclclclfsbofmfmejcaboescgdadvcsflfgal``erfdae````", +"``````alftdddo`jdscndqapavfaesbzfife`hcjfmdxbsbsfcfqclclcldjcedxdxeqat`tbbbb`mekaicpfxdmaccwfyfd````", +"``````cb`pfyerayddfxajdcdwdwdraiaiai`uf`caccexexexexcef`c`dccjf`dgatec`rde`rcsbhap`jfddmcqfy`n`p````", +"````````bn`xcz`b`j`jcfflelfldadadafa`yataxewccejc`c`cj`hcjfees`yeccx`ycddeff`wayajahdmcbcqftbd``````", +"````````foacdddo`j`d`nfeapajandaav`tch`yejdx`fejg`g``ufrerbz`y`ychf`facdczelbhajfxfheialcbbnac``````", +"`````````````edzererdnbeaycfa`a`dadwf`av`y`fcxeqaiaiaifiercsc`chf`djdacnanfldafjcyaccbbwfyac````````", +"``````````evbn``ciduchcrayajdqanapcxdrdadw`tcedjfaavavdrdadwdjchewesczemfxcwcwbffoebbwcodo``````````", +"``````````````bne``sci`jay`ncpdrbhapajema`avdway`maydwdwavcxekaycneydscofjahfydz`ebfbkefbd``````````", +"``````````````evevbdcq`sbkdn`q`jajdqcobtbta`a`a`cfelchewcheycfewekajbeedduddasei``eocrbd````````````", +"````````````````cb``e`bndmdmeoftaedtbebecncnaodsaodqanajanedfxajajcoezfydpalev`pacbwee``````````````", +"```````````````````e`ecycyeievacal`iebfhfgbvbedscodqbedtfhfxahahbfevbfft``e`e`evev`e````````````````", +"````````````````````ft`nefbfdmbndmcbfdfyddbwezcyfyfjdzezdm`sefaecb`paeebalebas`scq``````````````````", +"``````````````````````do`wbwfdftft``eiacezeobnezeodufyftdmfocybd`pcbbndmciembicb````````````````````", +"````````````````````````dme``scrcvaecyasfocb``bdbfbwdubkaeebe`cqalebfdcrcycrcb``````````````````````", +"``````````````````````````````cqacdpbwcibqe`cqalfoasbqaseibndmacci`ncyebdm``````````````````````````", +"````````````````````````````````cqe```ez`n`nciftac`ebqfofoe`evcb`wasal``````````````````````````````", +"```````````````````````````````````````ecq`ebqeofgeo`sbdbdbqcbbn````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue.pov b/hacks/images/bubbles/blue.pov new file mode 100644 index 00000000..86d1ff8d --- /dev/null +++ b/hacks/images/bubbles/blue.pov @@ -0,0 +1,22 @@ +#include "colors.inc" +#include "shapes.inc" +#include "textures.inc" + +/* The following make the field of view as wide as it is high + * Thus, you should have the -W and -H command line options + * equal to each other. */ +camera { + location <5.8, 0, 0> + up <0, 1, 0> + right <1, 0, 0> + look_at <0, 0, 0> +} + +sphere { + <0,0,0>, 2.5 + texture { Blue_Agate + scale <0.7, 0.7, 0.7> } + finish { phong 1 } +} + +light_source {<6, 1, 0> color White} diff --git a/hacks/images/bubbles/blue1.xpm b/hacks/images/bubbles/blue1.xpm new file mode 100644 index 00000000..49ff0128 --- /dev/null +++ b/hacks/images/bubbles/blue1.xpm @@ -0,0 +1,63 @@ +/* XPM */ +static char *blue1[] = { +/* width height ncolors chars_per_pixel */ +"10 10 46 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #2E2E4E", +"`c c #1D1D30", +"`d c #1B1B2E", +"`e c #0C0C12", +"`f c #0A0A10", +"`g c #17172A", +"`h c #25253E", +"`i c #12121E", +"`j c #20202F", +"`k c #141423", +"`l c #2F2F4E", +"`m c #1A1A2C", +"`n c #333355", +"`o c #1D1D2B", +"`p c #282843", +"`q c #303051", +"`r c #111122", +"`s c #161620", +"`t c #0A0A14", +"`u c #25253F", +"`v c #2B2B48", +"`w c #2F2F4F", +"`x c #101020", +"`y c #18182B", +"`z c #353558", +"a` c #15151E", +"aa c #191925", +"ab c #13131F", +"ac c #0D0D19", +"ad c #151524", +"ae c #343456", +"af c #1F1F34", +"ag c #0C0C14", +"ah c #0A0A12", +"ai c #494967", +"aj c #23233B", +"ak c #0C0C17", +"al c #292944", +"am c #121223", +"an c #BCBCD7", +"ao c #1A1A2E", +"ap c #0B0B15", +"aq c #262640", +"ar c #171724", +/* pixels */ +"```````s`uaj`u`t````", +"````ac`a`w`l`waqaa``", +"```m`p`x`nae`n`waj`t", +"``a``o`w`dan`z`q`yaf", +"``ap`g`l`naiam`lal`k", +"``ak`h`v`bao`b`v`h`s", +"``ab`iaral`r`j`uafab", +"````ad`c`sab`s`cag``", +"```````eadahad`f````", +"````````````````````" +}; diff --git a/hacks/images/bubbles/blue10.xpm b/hacks/images/bubbles/blue10.xpm new file mode 100644 index 00000000..9d6b2789 --- /dev/null +++ b/hacks/images/bubbles/blue10.xpm @@ -0,0 +1,240 @@ +/* XPM */ +static char *blue10[] = { +/* width height ncolors chars_per_pixel */ +"60 60 173 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #1B1B2B", +"`c c #282845", +"`d c #191929", +"`e c #323252", +"`f c #303050", +"`g c #111121", +"`h c #2E2E4E", +"`i c #0F0F1F", +"`j c #1D1D30", +"`k c #1B1B2E", +"`l c #0C0C12", +"`m c #0A0A10", +"`n c #17172A", +"`o c #212137", +"`p c #767691", +"`q c #1F1F35", +"`r c #2F2F48", +"`s c #101019", +"`t c #0E0E17", +"`u c #272740", +"`v c #181824", +"`w c #25253E", +"`x c #12121E", +"`y c #10101C", +"`z c #20202F", +"a` c #0E0E1A", +"aa c #2B2B47", +"ab c #0C0C18", +"ac c #292945", +"ad c #161625", +"ae c #141423", +"af c #242436", +"ag c #313150", +"ah c #121221", +"ai c #2F2F4E", +"aj c #2D2D4C", +"ak c #2B2B4A", +"al c #1A1A2C", +"am c #5C5C7A", +"an c #161628", +"ao c #333355", +"ap c #07070C", +"aq c #313153", +"ar c #05050A", +"as c #0D0D15", +"at c #07070F", +"au c #24243C", +"av c #202038", +"aw c #0D0D18", +"ax c #1D1D2B", +"ay c #0B0B16", +"az c #282843", +"b` c #262641", +"ba c #232334", +"bb c #11111F", +"bc c #0F0F1D", +"bd c #2C2C4A", +"be c #3C3C5D", +"bf c #2A2A48", +"bg c #1B1B2C", +"bh c #19192A", +"bi c #151526", +"bj c #131324", +"bk c #303051", +"bl c #111122", +"bm c #1F1F33", +"bn c #19192D", +"bo c #08080F", +"bp c #161620", +"bq c #23233A", +"br c #212138", +"bs c #0E0E18", +"bt c #0A0A14", +"bu c #272741", +"bv c #25253F", +"bw c #23233D", +"bx c #12121F", +"by c #10101D", +"bz c #202030", +"c` c #0E0E1B", +"ca c #1E1E2E", +"cb c #2B2B48", +"cc c #0C0C19", +"cd c #292946", +"ce c #181828", +"cf c #28283B", +"cg c #262639", +"ch c #2F2F4F", +"ci c #101020", +"cj c #1C1C2F", +"ck c #2A2A40", +"cl c #18182B", +"cm c #353558", +"cn c #09090F", +"co c #333356", +"cp c #07070D", +"cq c #15151E", +"cr c #202036", +"cs c #1C1C32", +"ct c #090912", +"cu c #191925", +"cv c #26263F", +"cw c #24243D", +"cx c #22223B", +"cy c #13131F", +"cz c #11111D", +"d` c #0F0F1B", +"da c #0D0D19", +"db c #2A2A46", +"dc c #262642", +"dd c #171726", +"de c #151524", +"df c #131322", +"dg c #111120", +"dh c #2E2E4D", +"di c #0F0F1E", +"dj c #1D1D2F", +"dk c #343456", +"dl c #08080D", +"dm c #151527", +"dn c #06060B", +"do c #1F1F34", +"dp c #1B1B30", +"dq c #0C0C14", +"dr c #0A0A12", +"ds c #494967", +"dt c #23233B", +"du c white", +"dv c #14141F", +"dw c #212139", +"dx c #1E1E2C", +"dy c #2B2B46", +"dz c #0C0C17", +"e` c #292944", +"ea c #0A0A15", +"eb c #262637", +"ec c #141422", +"ed c #2D2D4B", +"ee c #0E0E1C", +"ef c #1A1A2B", +"eg c #373758", +"eh c #181829", +"ei c #161627", +"ej c #333354", +"ek c #141425", +"el c #313152", +"em c #121223", +"en c #222236", +"eo c #030307", +"ep c #BCBCD7", +"eq c #1E1E32", +"er c #1C1C30", +"es c #1A1A2E", +"et c #0B0B12", +"eu c #18182C", +"ev c #28283F", +"ew c #090910", +"ex c #222239", +"ey c #202037", +"ez c #11111B", +"f` c #1E1E35", +"fa c #0F0F19", +"fb c #0D0D17", +"fc c #0B0B15", +"fd c #1B1B28", +"fe c #090913", +"ff c #262640", +"fg c #171724", +"fh c #151522", +"fi c #212131", +"fj c #2C2C49", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````dn`tdvahbhdebhbhecehawbs`x``````````````````````````````````````````````", +"```````````````````````````````````````````yaweffcerbpbpeqbmbmbbaneiahay`kcedqfh````````````````````````````````````````", +"````````````````````````````````````cpddeffcbbbsbpbpbrexexal`kabdgdfabaway`v`jcjbt`tcz``````````````````````````````````", +"````````````````````````````````dnddaler`kbpfdexbqaucw`nccdac``wcccucwfdcueqcrcreq`kbsddar``````````````````````````````", +"``````````````````````````````dqefcjbpdzexcuau`wbvekdt`gciekdtbiaxbubuffbvbcandoexfgbtdvbiez````````````````````````````", +"``````````````````````````drdzbgeqcldfbcbxdjdxbuazazcibcax`dci`qffb`biazazbuff`wcwbqc`bpeqbgcecz````````````````````````", +"````````````````````````fcehfedzcrabbyalexbuaze`dbdfdidicbaxdfbuavdffidbdbe`azbuffc``qfhcreq`xbhec``````````````````````", +"``````````````````````cz`yalahfgbqahdabjazacdbaacbfjbdauede`edciblcbenfjcbaadbac`zexdxcwbqbpanaybhec````````````````````", +"````````````````````boezayclbidtexeedididbaacbbdededajdhdhdhdhdhdtesajededbdcbfiae`ndxff`wdtaldadrbhas``````````````````", +"```````````````````tbherc``ndtdteeeeby`zcbfjedajdhdy`abnbvbzebebciavcwebdhajbierahah`qdxcu`wdtal`kdzbhcp````````````````", +"````````````````bxeh`yawdadtcuclazac`acbbdeddh`hch`n`ncschdcaicsdmdmcif`ch`hdhfjdidiffbyahdx`wczcubmbsczbx``````````````", +"``````````````asddbxbtcsda`wcsekac`acbbdajdhaich`favcicif`cgaq`jcb`navdm`fchaiekesbjeeesbmazffbcc``oeqbgctcn````````````", +"``````````````ctez`j`dexfgcvbccw`acbbdbzdhch`fbkelfidpbleycfejcfdc`ndpbnelbkfiesbdbnfiexdt`ubucv`kexcr`jefde````````````", +"````````````cyehdz`ybrbycsbubqeecbbdajdhch`fbkelaq`eafazakafaobnbheyeucscbelbacsb`badffidf`zdxbu`wdabrcufcctcy``````````", +"```````````matdv`jcrehczbbazaccsfjeddhai`fbabz`eejejblchbkeuekcjcoaoaoaiej`eclemfifienafbiaaacazekccexcrdfctaddl````````", +"``````````cydzfcehbrclclcae`dxbueddh`i`qbdbdbjaiaobnesembj`jdkdkdkdkedaoaoejbkcsbjchaidhedcbdbe`exfdaubrawbtfccy````````", +"````````asezalayaydaahanaz`udganbvcici`gf`dmajbnao`jazekavdkdkdkcgbjbn`naoemancdbj`fchdhedbdaabcdtffcwexcrehbtad`m``````", +"````````bxbofebbbierdw`kazdbcaemcidtdc`nelbvblaocobfeualcfcmcmazbmcmemebclbidmaibjbkchaidhbd`bbrahbu`wdt`ocjfece`l``````", +"````````fhbhbtdzbybcclahe``afj`icsazblfiafdhancodkeuazcmcmcmcmcmcfejcfdkdkbj`n`naqel`faidhedaxcie`bucvfdexdodfbhfh``````", +"``````bobxehayabda`jdaexaxaabdeudpbvf`bv`a`ccfcockbjf`ckbebebebecfalcmdkdkcocdbj`eel`fchdhedahbcdxc`fhcwexcrayalbobo````", +"```````xddbcay`yfhbidgc`eecifiajfidcdmcidmfiaocoalekf`eq`eagdsdsdsbeegcmdkcoclcw`eelbkch`hajdwee`nc`by`wbqcr`va`ddbo````", +"``````dfehfeanfheidgekaz`zbldmaj`hcaajeubn`haodkbj`kexcfegamam`pamdsbeegcmdkaocxbjelbkch`hajbv`qclfd`wbcdt`oeqbhdedf````", +"````etcybhaycqfhbhcsfdazaxcadiaj`hchchdm`gajdmdk`kagbeds`p`pepep`pamdsbecmdkao`neuelbkch`hajblahclca`kbndtbrdocqdrecet``", +"````bsfcbhd`dobrbrczbmazcacb`qca`hchbkeldmf`andkdkej`ramepduduepep`pambecmdkaoelblciebch`hajandtdibuekcccubrdoerctdebs``", +"`````sfheifbdzfddfexdxazdbcbeuazfich`felbhblbidkanbmeg`pepdududuep`pambeegdkao`cavavblekdhaj`zclerbcdiciecbrcudvezat`s``", +"`````yad`d`jaybrczcsby`zdbca`bdp`gef`felelavcgcobnbzam`pepdududuep`pambeegcoclchcddmdpcw`zeddidweedpc`aney`vbsdzez`sbs``", +"````ezadcq`jdobrdtdfcvby`kahcwemajcwbabkelcsf`aocseq`ram`pepepepep`pdsbebmcbesbnbkci`nazfiedfjaafieec`dfahbr`vfcbhezfb``", +"````ezadbherdo`odtbqffbb`nahcicicdbwbz`felbvavejcb`kdsds`p`p`pep`pamdsen`nancldpcici`cbafiedcb`aacexdmczdt`obbaebbec`y``", +"````ez`tbhdzfc`obqcwffah`nciekerehfiai`fcsanek`eaoekef`rdsbedsamamdsbe`nem`eaqelbabaaidhedcaddaxe`axc`cubq`oaecjdzewdn``", +"`````yct`xfcbtcrexaucvbuekeeesf`crdh`hbibv`ffiaq`eekbh`jcg`e`rdsbeegcmekblbaelbk`fch`hdhedfjaadbazbuda`vexcrabadct`sfa``", +"`````sfh`sahaydzexdt`wffazdteebcbaeddh`gcibdbkelcxbjevdkaiejeqegcmdkejcgcsekbk`fchaidhedbdcb`aaccabbcwcuexcr`jbsehfhet``", +"````cneccedrbyczbrbqcwffbu`nazemddbdajebcwci`fbk`qbnafaicbdweiejej`eelelahbjfichaidhajbdfjcadbazax`v`na`brdoahcqceasas``", +"````arboddctekdgbpexau`wbucrerffbifjedajdfcieb`fahf`ek`f`h`gaaelelelelbk`fey`qaidhajedfjcbdbacazbu`wdadj`obmez`x`sctfb``", +"````eodqaddffeay`jexdt`wfffdeeexdicbbdedajcs`haibz`q`gemb`bjbkbkchdb`f`fchaicx`iajedbdcb`aac`zbuffcyei`ncreqa`dzdzasdq``", +"````arcnfhdrdzalbp`oexau`w`qdm`qax`acbfjedcsafdh`hdp`hcieubdes`fchchchai`hdhdhdififjcb`aace`axfd`wdgbiabay`jbpfccpezap``", +"``````dqecctawaydzcrexdtbcccahfde`db`acbahdieiajdhdhdh`heiemf`aiai`hdhdhdhajeddmciee`adbe`azbucvcwbhaybbancjef`ydr`m````", +"``````arbxadehaydzcj`ofhcreiee`zaze`ac`aercidibdedajajdhdhdmcbdhdhdhajajexbgcsdwciahace`azbucv`wdtcrayawfccqbhctbsas````", +"``````arezfhddaefcaycr`obbekbndfbuazfdacaccsdpciazfi`uededey`ifiededbdbdfjdfdicxaxeebububuax`wauex`oayaycjalddboezcp````", +"````````fadqadbofcbteqcrdf`ndf`wcvbuazbididibjf`ahcafjfjfjfidbeifjfjfjcbcbaa`ddbacazdpdaexbxaucsbrcrbhdebg`dadetfa``````", +"````````ctasfhdqd`fc`vdoekay`vau`wcvbuc`eebc`z`zdb`a`acbcb`beeahcbcb`a`adb`zace`azbu`wdtccdaabbccrcqa`deefddfhfbap``````", +"````````eofacyadawctbgeq`xeifdbqaucyfgeedabuazaze`acacdbfiddblbleedbacac`zb``zbudfffbvczdg`neqc`docja`ezceadcydnap``````", +"``````````dqdqecctctczcjeqeafgbrexexc`ccciffbubuazazazdddf`qesercsazazazfdcx`gbbaubccwdt`vcualaleqcjfcezeiecezdq````````", +"``````````eobs`xctdrctbgeraeeacrbrexabbicz`wcvffffbubudf`zaneecebqbububudxfddx`wcwaudtexbrcrah`jerbgctecfhcpbsar````````", +"````````````bofaezdeecbhdvfeaw`vcr`ocjaya`cucw`w`wcvcvccerdfei`w`jffcvcv`w`wcwaudtexex`ocrdoeafcbgcqdzdrasareo``````````", +"``````````````dq`ycpbs`sbhanbs`kef`qcrayd`exdtdtaucwcwer`ndfccbc`w`wcwcwaudtdtexex`ocr`qahekczdqbh`ybocpdnar````````````", +"``````````````apasezcydeddfhcta`eaeqdoawaebbfgcuexbqababf`ek`kaudtdtdtbqexexexdafgcrdofcdfeialdzddcycp`tapap````````````", +"````````````````bo`tbobodeezfedfa`cj`jeqayeiaybnbpbrbydzeifhcydjexexexbrbp`ocrdzdoeq`jdd`yfcfafcdqcyezdldl``````````````", +"``````````````````cn`tezcyatctddbhal`kcj`jbsayal`qddbba``y`o`o`ocrcrcrcr`qdoaybt`jcj`kalfebofbcpctez`teo````````````````", +"````````````````````ewfbdqdqcpfhddehefalcqdrehefeq`ya``vdododododobmeqeqeqcqfabpcqalef`sdebxbxbocpfbew``````````````````", +"``````````````````````dndq`s`xdffhaddd`tctecczbpcjdzdzdv`jdveh`j`j`j`jbpalfcbgalcyeh`satdrfcbsdnascn````````````````````", +"````````````````````````ardlfafbcpfbbtbo`yctbhbhasa``sbg`k`k`k`k`kbgbgalefbhbhceetdfbodfdr`metdrcp``````````````````````", +"``````````````````````````dndrewfadnboecfhadeidddrdzfcbhbhbhezbhbhbh`dehceddeiboctctdndqdndneoap````````````````````````", +"``````````````````````````````boewdq`lez`xcyecfhdeadfcbsecctdrdd`sdqadaddefheccybo`y`mareoar````````````````````````````", +"````````````````````````````````apaparfbfa`ycz`xcyetcpcpcpatdqec`sececcycy`xdnasfadrdleoar``````````````````````````````", +"````````````````````````````````````eoarbocnfbfafaasdrarfcbobsczczczez`yfafafbdqdreoar``````````````````````````````````", +"``````````````````````````````````````````apbodretcncndqarar`mbsasfbasdqcndreoap````````````````````````````````````````", +"````````````````````````````````````````````````apdneoeoeoarbocncnboapdnap``````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue11.xpm b/hacks/images/bubbles/blue11.xpm new file mode 100644 index 00000000..c39e4f1c --- /dev/null +++ b/hacks/images/bubbles/blue11.xpm @@ -0,0 +1,254 @@ +/* XPM */ +static char *blue11[] = { +/* width height ncolors chars_per_pixel */ +"72 72 175 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #1B1B2B", +"`c c #282845", +"`d c #191929", +"`e c #323252", +"`f c #303050", +"`g c #111121", +"`h c #2E2E4E", +"`i c #0F0F1F", +"`j c #1D1D30", +"`k c #1B1B2E", +"`l c #0C0C12", +"`m c #0A0A10", +"`n c #17172A", +"`o c #212137", +"`p c #767691", +"`q c #1F1F35", +"`r c #2F2F48", +"`s c #101019", +"`t c #0E0E17", +"`u c #272740", +"`v c #181824", +"`w c #25253E", +"`x c #21213A", +"`y c #12121E", +"`z c #10101C", +"a` c #20202F", +"aa c #0E0E1A", +"ab c #2B2B47", +"ac c #0C0C18", +"ad c #292945", +"ae c #161625", +"af c #141423", +"ag c #242436", +"ah c #313150", +"ai c #121221", +"aj c #2F2F4E", +"ak c #2D2D4C", +"al c #2B2B4A", +"am c #1A1A2C", +"an c #5C5C7A", +"ao c #161628", +"ap c #333355", +"aq c #07070C", +"ar c #313153", +"as c #05050A", +"at c #0D0D15", +"au c #07070F", +"av c #24243C", +"aw c #202038", +"ax c #0D0D18", +"ay c #1D1D2B", +"az c #0B0B16", +"b` c #282843", +"ba c #262641", +"bb c #232334", +"bc c #11111F", +"bd c #0F0F1D", +"be c #2C2C4A", +"bf c #3C3C5D", +"bg c #2A2A48", +"bh c #1B1B2C", +"bi c #19192A", +"bj c #151526", +"bk c #131324", +"bl c #303051", +"bm c #111122", +"bn c #1F1F33", +"bo c #19192D", +"bp c #08080F", +"bq c #161620", +"br c #23233A", +"bs c #212138", +"bt c #0E0E18", +"bu c #0A0A14", +"bv c #272741", +"bw c #25253F", +"bx c #23233D", +"by c #12121F", +"bz c #10101D", +"c` c #202030", +"ca c #0E0E1B", +"cb c #1E1E2E", +"cc c #2B2B48", +"cd c #0C0C19", +"ce c #292946", +"cf c #181828", +"cg c #28283B", +"ch c #262639", +"ci c #2F2F4F", +"cj c #101020", +"ck c #1C1C2F", +"cl c #2A2A40", +"cm c #18182B", +"cn c #353558", +"co c #09090F", +"cp c #333356", +"cq c #07070D", +"cr c #15151E", +"cs c #202036", +"ct c #1C1C32", +"cu c #090912", +"cv c #191925", +"cw c #26263F", +"cx c #24243D", +"cy c #22223B", +"cz c #13131F", +"d` c #11111D", +"da c #0F0F1B", +"db c #0D0D19", +"dc c #2A2A46", +"dd c #262642", +"de c #171726", +"df c #151524", +"dg c #131322", +"dh c #111120", +"di c #2E2E4D", +"dj c #0F0F1E", +"dk c #1D1D2F", +"dl c #343456", +"dm c #08080D", +"dn c #151527", +"do c #06060B", +"dp c #1F1F34", +"dq c #1B1B30", +"dr c #0C0C14", +"ds c #0A0A12", +"dt c #494967", +"du c #23233B", +"dv c white", +"dw c #14141F", +"dx c #212139", +"dy c #1E1E2C", +"dz c #2B2B46", +"e` c #0C0C17", +"ea c #292944", +"eb c #0A0A15", +"ec c #262637", +"ed c #141422", +"ee c #2D2D4B", +"ef c #0E0E1C", +"eg c #1A1A2B", +"eh c #373758", +"ei c #181829", +"ej c #161627", +"ek c #333354", +"el c #141425", +"em c #313152", +"en c #121223", +"eo c #222236", +"ep c #030307", +"eq c #BCBCD7", +"er c #1E1E32", +"es c #1C1C30", +"et c #1A1A2E", +"eu c #0B0B12", +"ev c #18182C", +"ew c #28283F", +"ex c #090910", +"ey c #222239", +"ez c #202037", +"f` c #11111B", +"fa c #1E1E35", +"fb c #0F0F19", +"fc c #0D0D17", +"fd c #0B0B15", +"fe c #1B1B28", +"ff c #090913", +"fg c #262640", +"fh c #171724", +"fi c #151522", +"fj c #212131", +"fk c #2E2E4B", +"fl c #2C2C49", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````bpcudf`tdeded`aedfdrau````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````cqd`e`fdbh`kckck`yesesckckbzbiegaobped````````````````````````````````````````````````````", +"`````````````````````````````````````````````````ydeeidack`jficv`vdecscsdbazaccmaadgaf`jckdacuf`ed``````````````````````````````````````````````", +"````````````````````````````````````````````ae`dbhfdcmaoczcs`oeyeyeyfee`bzamazaaesacbiazczbnerckdgdfae``````````````````````````````````````````", +"````````````````````````````````````````ds`ybh`j`k`vbq`yeyduavavbddbcadbca`wdhaabravfedudpej`ocseraabubiau``````````````````````````````````````", +"````````````````````````````````````btcfbh`jfbaa`oeycvav`w`wamezaidgdbbjbselfebvbvfgcw`w`wcmbzet`o`vaaffbhde`t``````````````````````````````````", +"``````````````````````````````````dregckerdbaaeyfiaccxcwbvbvfeb`cabcbz`qduaielamdfcab`bvbvfeeyfhduey`yejerckcfej````````````````````````````````", +"``````````````````````````````bpdgbh`jdpfedbelctd`aedyb`b`eaaf`qbdbj`aaybnctelcxbvayadeab`b`bvfg`wfeetaadwdp`jbccfcz````````````````````````````", +"````````````````````````````fccuaxazda`o`odbcabja`b`b`addc`afj`adjbjfl`devbw`ndg`aafab`adcadb`b`bvcxcaey`o`o`qaobheied``````````````````````````", +"``````````````````````````ed`zfb`vesbhdudxelcmaib`addc`accflbebeeeeeeebbeeeeao`idjbebeflcc`adccbdecsdxbwcxdu`vaie`e``dfi````````````````````````", +"````````````````````````bpcufibier`qduaiaielaiefdc`accflbeeeeeakdidididididibjao`nakeeeebeflcca`af`kbdbvfi`wductazebaa`dat``````````````````````", +"``````````````````````auei`kbcfb`jdudbdbcacjcjdeccflbeeeakdia`faevenaoeab`brajcxbeawdidiakfldjaodhefdjfedhfe`w`oesdb`z`keids````````````````````", +"````````````````````czcfbhaxcsaidufecacxdgad`accfleeakdidiajam`ncjaodncjboevelcydqet`xajdidibhevbk`i`qbddecmfg`wfe`kbq`de``zcz``````````````````", +"``````````````````atdeamca`jazcacx`vbzb`ad`accbeeeakdiajci`fajcybxccctcmagbhawet`gbkbw`fciajdib`bkdjcjdjefb`bvcw`bdbbsdp`jamcud`````````````````", +"```````````````````tbibi`jacd`cxdycabcad`accbeeedidiajci`fcievcjbmbmee`e`e`ebgaw`gfaccbl`fci`wawfab`bkboevaib`bv`wboaa`obnesbi`s````````````````", +"````````````````cqeiff`vcsey`v`waidhbwayccbeeedi`hci`f`fememeablbmbmembrekbbetdqaoctevbiem`faocjdqfaelevezbv`bbnbv`wcseycsbq`kdaed``````````````", +"```````````````zcuegbuaxbsbzaofgeoa`efavfleedidici`fblemem`e`ech`hbmenchap`jagbednbmctccememccbabaagbjaw`dela`cbbvfgfe`jbsdpbuamat`m````````````", +"``````````````atbiffercsctavcsbvb`cbetflbeakdiaj`fbbdnem`eekek`n`nfab`cmelcmcpapapapcgek`eemciajeldkageaa`cbabadb`bvaieleycsbqbdd`fi````````````", +"````````````dsedame`debs`qaidbb`adfjbwbeeediajb`fa`hejc`ekekagevfaceaoecdldldlcpcpapapekek`edd`nbjciajdieecbccdcadbzduesdubs`qaae`de`y``````````", +"````````````fibtffebcmesdbezfeb`adelet`dbhcteldnbmencebmekapdncyenevctagdldldleldn`jamapcgbbevcidn`fci`hdieeflabadeyedfeaveyfh`kaicufi``````````", +"``````````drdeamfdejazaidb`nb`eaaybwbabmen`ncy`cecalenceapcpdndndqetfacncncnecdnecbockcgagb`bketfadzciajdieebecccjduayfg`wdubsbqdeeide`t````````", +"``````````eddefdcabdazducsbdb`ad`wejcjendqb`babbembgawelapcpbe`ecscncncncncnclcncgbmfkclbkcybmbaaobl`fcidiakbebbfacjb`bv`waveycs`je`cfed````````", +"`````````mcqbiffamazaicmcmeyb`dcccfl`icjdxfacjecagemdqapcpdlevccagcncncncncncncgcnecdldlch`haofjarem`fciajdieecbawcbb`bvcwaveycsckaibifbfd``````", +"`````````y`sdsazazer`jetdb`kerdcccbedubmdcbv`nfaenbkelapcpamelbwelehcgbfbfbfbfaocgcndldlcp`jaoee`eembl`fa`dieedgelbdeaefdycxbr`obqfdamde`y``````", +"````````dgcfdabudgacdkcsdbcjej`nb`beakbhevel`nbkaodncgcpdlenevbkb``rclahdtdtbfbf`rcncndldlcpaodnagembl`fcidiakdgbodqdgetefavdubs`qacbycfdg``````", +"``````btfdeiaafd`zaxd`cm`wet`nctbddjakdicmdi`n`genawapcpdlenelcmeyahahdtdtanandtbfbfcndldlcpdnbmcgembl`fcidiakezbdfgdgfebzfiaveycsbqe`f`fi`m````", +"```````zcqbiffbjerdbduca`qb`adaidcceakdicicjbxdubmarcmcpdlcmbvewdzandt`panananandtbfehcndlcpewdnbmemem`fcidiakcjaiefdhayer`qaveycserbqcuae`l````", +"```````ybpbidadw`jeydgdbfeb``wefbb`nakdiciagccejenctcecpdlcsehehehan`peqeqeq`p`pandtbfcndlcpagbxboecbl`fcidiakdgcfdueyayeserbyeycsercrcud``y````", +"``````by`tcuda`v`oey`naybnb`ad`wea`icbdici`fblemdnaoenekdlclekcl`p`peqdvdveqeqeq`pdtbfehdlcpcgbwbmcydk`fcidiakdjbaef`netelcacaey`obnesazbpby````", +"````asczdeaebubq`vdwef`qfeb`ad`acccyevejci`fblemaoen`hapdlcmerdtan`pdvdvdvdvdveq`panbfehdlapewevet`xb`fjagdiakegbkefdxaidgbkbjey`obhes`tbtczeu``", +"````atfbdee``jeb`ofeejfaay`dad`acc`qbkbkeaciblemfjbwbgapdzdleranan`pdvdvdvdvdveq`panbfehdlapcmcycybmbvcyetdiak`bduezdncmdhdbesey`oafbie``tfbat``", +"`````td`de`t`jcr`oeydkdbcffeayayfjdcdj`xet`g`fememendnapdib`csehdt`peqdvdvdveqeq`pdtbfehdlbkblakawfa`gbadgdieebedgefbdbodh`wdhax`oebdsatf`d``t``", +"````btbydeamesbncseyavayfgdebvaicj`n`nctaddx`fblem`nbmekec`famcgan`peqeqeqeqeq`pandtbfckenbmbmdncicjcjctawc`eeflccdccw`g`g`ndbdacsaxckcudefbds``", +"````btbpdeamckercseydufefgcb`n`gefcjdjadetcyci`fagad`gb`apce`kbf`rdtan`p`p`p`pandtbf`j`abkekenejelcj`cabdiakbeflabdceabodhbddueycsbidgegbpcqas``", +"`````md``scre`bccseydu`wfgaiduefcjdgesdgew`hci`fctbmcj`eekagelbibbbfdtbfdtanandtbfbf`netcm`eemembbeceo`hdieecb`db`adb`bccaaydueyazebckcucudsdm``", +"````eucqf`f`fffddbbsbrcxcwbvendhdncmbvfjakdiaj`gcicx`nem`eekaocmbn`e`rch`rbfdtbfehcnenboctemembl`fciajdiakeeflbrdcadb`bvcacabrbsfbdfaxcraeexeu``", +"````asdr`sfbaie`bd`oeyav`wfga`cacjcjaicbb`didicccjbwaiemembmenbbdlbhfkajcgbfehcndlapbbbwdnembl`fciajdidieebeccabdceab`fe`ncvey`ocvbubtbi`se`dr``", +"````dscqae`dbudsebaaeydu`wfgbvcfeyezefdgbeakdieecjbmamblbbdnevbbfkc`cybxaodldlapek`eemb`enc``fcici`hdiakbeflccdcadb`dhdectbyey`odpdbe``daecqco``", +"````epd`dfcfdgebdbebeyducxbwbvb`aebobk`gbeeeakagfgelb``fblelbgdnemenfa`xej`e`e`eemem`ffjccdg`waj`hdiakeebecc`udceab`dyay`kaceycserafamcf`tdreu``", +"````dof`eddefdejaiam`oeyav`wfgbva`dudccjccbeeeakejbk`ici`fddenbwfaevcjdgememememewblbl`f`fbxfa`hdiakeebeccabdcadb`bvfgcvdjfe`o`qerd`at`scqcqas``", +"``````fbbpdedgdebibz`veyducxbwbvbwcaeyefccflbeeeakbeaoajcibh`qcjelcjbxeiblblblec`f`f`fcicicb`gecakeebeflccdcaddya`bvbwboejesbhdp`je`e`dscqfb````", +"``````btcuaecufdfcelcsbseyav`wfgdjfgbv`d`accflbeeebjeedi`hajajawbmbmfacjen`f`fciciciciaj`hdidneleebeflcc`aadeaayayfgavdhbjbjeleresbjfdau`tbt````", +"``````atf`ficufdaabu`ycseyducxdyejfeafeadc`accccfjetfaakdidiecagcbfaevbkctfjciajaj`hdididiakelbkflcbcc`adceab`bvfg`wcvdbdbazd`buckf`dgd``yat````", +"``````ds`leddeedfdbuazcs`ofedacd`qbnfeb`eadc`accb`djbveeeeakdididiavdq`ib`didididididiakeeeebj`gdjfafjdceab`bvfgcw`wdueyazdhelaobhbiaefd`zds````", +"````````asczdff``tckdf`vcscvazacducdfebvb`eaaddcceetcyezbjeeeeeeakakc`aoakdiakakakeeeeee`dccctdxaocjdheab`bvbvcw`wavbrbhdbe`ckbiamcfdr`zfb``````", +"````````dod``yde`ybjbcbt`q`ocve`dhcxaibvbvb`cbayducydxdqbmctbbfjbeeeeecxdjeleeeebebebeflccceaicya`a`cj`qfjfeay`wavduey`oebbudgbhbidefdd`do``````", +"````````bp`sdraecfdafcejercsaiazesca`wcwfgbva`dudjefefcyctaicbccflflbefjdcbobeflflccccccabfjdyadadb`bo`nbo`wbyaocm`v`ocsbid`ckegcfaeeu`sep``````", +"``````````fc`zeddedacuffbqdpczcaerduav`wcwfgbhcjdqdgbzay`day`aabccccccdgefdxccccccab`a`adcfjadeab`b`dyeddbdbbzbzdbczcsbqelffam`ddeedf`fc````````", +"``````````ep`satdfcubdcuaferdpaz`odpduav`wbwdgdbaib`b`eaadaddcdcdcdcaydhefdxdjdcdcdcdcay`gelbhb`bvbvfgcvbs`kbd`jaibddpbubhaxbidedfczdseu````````", +"````````````fcdoedafejcudg`jercmesbseyducdcmctcabdbvbvb`b`b`eaeaadayfjbocjbdfaafadeaeaa`cmbdbvcfbjai`wedczda`jbze`fier`jaidrcfaeedd`co``````````", +"````````````as`lbycqdabpbick`jdweb`v`oeyfhdhbidbdbcwfgbvbvbvb`b`bcbkbzeybjefbddyb`b`b`ay`kbjbcbdbifiavdubrey`obtesdw`jcfe`dscufibyfbds``````````", +"``````````````ateuczdfbpcuamck`jbi`ycs`oey`zacdgcz`w`wcwfgfgbvbvcbaiaiaocadhfeaybvbvbv`obhdy`d`wcxavdueyey`ocsctbce`ckcfbudacufdfdco````````````", +"``````````````asbtd`bpededbiamcmbubj`vcscsbsdbcaaacvcx`w`w`wcwcwdyeyeldgejcmfefgfgcwcw`w`w`wcxavdubreybscscsdpbze`crambue`bybydoaqas````````````", +"````````````````eufb`y`sfdf`bifdaxbhacerdpcsfiazcabrduduavcxcx`wbycs`qdgbzbjed`w`w`wcxcxavdudubreybs`ocsdpbtaidbe`ambidfaubyeufdaq``````````````", +"``````````````````drfbdscqaedebideffaabuerdpfdbzaicafecfbrdudufhfhdpacbscsavavavavavdudubreyey`zbqcscsdpbubzbudwamcrdedsfd`ycqep````````````````", +"``````````````````dmat`zdobyaedefdcudgfbcr`jeraxeldb`kdbczeyeyazbjbd`vfielca`vbrbreyeybnbs`o`oebcvdperbqffacdgfcdr`saeed`s`zaqep````````````````", +"````````````````````coatdo`yeddfczbpde`d`kck`jer`v`zaibdescs`bamdbercvfi`veyeybsbs`ocvcscscsebazerer`jckdgfddrf`aue`dr`y`zatep``````````````````", +"``````````````````````exat`s`ydsbtcufibiegbh`kck`jaxbzaieldpbheiacbjcscscscscscscscs`qdpdpfh`jbt`jck`kbhegcuejfcdse`bp`satbp````````````````````", +"````````````````````````exdr`ldoaucqfidecfbiegbhcrcfao`y`jer`zebazdpdpdpdpdpdpdpbnerereregf`debqcrbhegbibzdfbybtcqcq`tatex``````````````````````", +"``````````````````````````coaqatf`byeddfaedeeibidgcubyfdckckfdbuff`j`jf`eicf`j`j`j`j`jaacadrbhf`e`bieibpaieucuexdododmco````````````````````````", +"````````````````````````````epeubtcq`yczbp`sbpbpdsfdaeegambheiff`sckckckckckckck`k`kf`buamegbi`dcfdedfdse`bpdofccqcodm``````````````````````````", +"``````````````````````````````aqeuatdocqfbds`tdfaededecfeiaacucregamamamamamamamegegbibieicfdedsbtdsbpbpcqbt`lasasaq````````````````````````````", +"``````````````````````````````````coepcqbpcq`yczedfidfaedeaecubpdeeieif`cucueieicfcfdededeaeatbpbybpdobpfdasdoep````````````````````````````````", +"````````````````````````````````````epaqasdofbf``ybyczedfifidfcucubpcubpeufificu`saedf`sfiedczdrcudo`mascq`maq``````````````````````````````````", +"````````````````````````````````````````epasdr`tfb`zf``ybyczeubpdscqaubtdred`tedededczczbyds`meufb`tasbpep``````````````````````````````````````", +"````````````````````````````````````````````asepaqdocofbfb`zfbbtdobpcq`zbt`y`y`yd`d`f``zfbfb`tateuepaq``````````````````````````````````````````", +"````````````````````````````````````````````````dodoepeudrat`tdodseudoas`mfbfbfbfbbt`tatdreudsdoaq``````````````````````````````````````````````", +"``````````````````````````````````````````````````````aqasepepasepcoasepexdrdreueuds`mepdoaq````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````epepepepepdoaqaqasepaq````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue2.xpm b/hacks/images/bubbles/blue2.xpm new file mode 100644 index 00000000..94152167 --- /dev/null +++ b/hacks/images/bubbles/blue2.xpm @@ -0,0 +1,89 @@ +/* XPM */ +static char *blue2[] = { +/* width height ncolors chars_per_pixel */ +"12 12 70 2", +/* colors */ +"`` c None", +"`a c #323252", +"`b c #303050", +"`c c #0F0F1F", +"`d c #1B1B2E", +"`e c #17172A", +"`f c #1F1F35", +"`g c #181824", +"`h c #25253E", +"`i c #10101C", +"`j c #20202F", +"`k c #0E0E1A", +"`l c #292945", +"`m c #141423", +"`n c #242436", +"`o c #2D2D4C", +"`p c #333355", +"`q c #313153", +"`r c #0D0D15", +"`s c #24243C", +"`t c #262641", +"`u c #232334", +"`v c #3C3C5D", +"`w c #19192A", +"`x c #303051", +"`y c #111122", +"`z c #1F1F33", +"a` c #08080F", +"aa c #212138", +"ab c #12121F", +"ac c #0E0E1B", +"ad c #1E1E2E", +"ae c #2B2B48", +"af c #2F2F4F", +"ag c #1C1C2F", +"ah c #18182B", +"ai c #353558", +"aj c #15151E", +"ak c #1C1C32", +"al c #26263F", +"am c #13131F", +"an c #0F0F1B", +"ao c #2A2A46", +"ap c #131322", +"aq c #2E2E4D", +"ar c #0F0F1E", +"as c #343456", +"at c #151527", +"au c #1F1F34", +"av c #0C0C14", +"aw c #494967", +"ax c #23233B", +"ay c white", +"az c #0C0C17", +"b` c #141422", +"ba c #2D2D4B", +"bb c #0E0E1C", +"bc c #161627", +"bd c #333354", +"be c #141425", +"bf c #1E1E32", +"bg c #1C1C30", +"bh c #0B0B12", +"bi c #18182C", +"bj c #090910", +"bk c #222239", +"bl c #0F0F19", +"bm c #1B1B28", +"bn c #262640", +"bo c #151522", +/* pixels */ +"`````````d`sacbmbf``````", +"````a`axaobaaqba`max`r``", +"````aabbaf`a`pak`t`jaa``", +"```wah`c`nbiaias`qbaal`w", +"``an`zadatbday`v`y`obebg", +"``azbnbgakbeaw`e`uadacag", +"``apaxbk`o`f`x`b`o`lbcaz", +"``avbf`haradaoae`lab`wbh", +"````b``g`kalbcalaxauaz``", +"````bjboaj`iaubfajabbj``", +"````````blbhavambl``````", +"````````````````````````" +}; diff --git a/hacks/images/bubbles/blue3.xpm b/hacks/images/bubbles/blue3.xpm new file mode 100644 index 00000000..b38a8d44 --- /dev/null +++ b/hacks/images/bubbles/blue3.xpm @@ -0,0 +1,103 @@ +/* XPM */ +static char *blue3[] = { +/* width height ncolors chars_per_pixel */ +"14 14 82 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #282845", +"`c c #111121", +"`d c #2E2E4E", +"`e c #1B1B2E", +"`f c #0A0A10", +"`g c #17172A", +"`h c #101019", +"`i c #181824", +"`j c #21213A", +"`k c #10101C", +"`l c #20202F", +"`m c #0C0C18", +"`n c #161628", +"`o c #07070F", +"`p c #24243C", +"`q c #0B0B16", +"`r c #282843", +"`s c #11111F", +"`t c #0F0F1D", +"`u c #1B1B2C", +"`v c #19192A", +"`w c #151526", +"`x c #303051", +"`y c #111122", +"`z c #19192D", +"a` c #23233A", +"aa c #212138", +"ab c #0E0E18", +"ac c #0A0A14", +"ad c #272741", +"ae c #23233D", +"af c #202030", +"ag c #1E1E2E", +"ah c #2B2B48", +"ai c #181828", +"aj c #28283B", +"ak c #2F2F4F", +"al c #2D2D4D", +"am c #1C1C2F", +"an c #18182B", +"ao c #353558", +"ap c #15151E", +"aq c #191925", +"ar c #24243D", +"as c #13131F", +"at c #11111D", +"au c #0D0D19", +"av c #262642", +"aw c #151524", +"ax c #2E2E4D", +"ay c #343456", +"az c #06060B", +"b` c #0C0C14", +"ba c #494967", +"bb c #23233B", +"bc c white", +"bd c #0C0C17", +"be c #292944", +"bf c #0A0A15", +"bg c #2D2D4B", +"bh c #0E0E1C", +"bi c #1A1A2B", +"bj c #373758", +"bk c #181829", +"bl c #161627", +"bm c #141425", +"bn c #313152", +"bo c #121223", +"bp c #1E1E32", +"bq c #1C1C30", +"br c #18182C", +"bs c #222239", +"bt c #11111B", +"bu c #1E1E35", +"bv c #0F0F19", +"bw c #0D0D17", +"bx c #0B0B15", +"by c #1B1B28", +"bz c #262640", +"c` c #2C2C49", +/* pixels */ +"``````````awbsau`mbp````````", +"``````bdbhbe`wbu`lbe`p`w````", +"`````var`aaxbmbn`caxbr`tb```", +"````aqbeblbr`baybnboax`lat``", +"``ai`pbq`g`ubmbaao`yak`g`pai", +"```s`tahakalbabcbaajafbr`tbw", +"``ap`p`cagav`vbabjbnax`l`i`n", +"``aiaaadc``d`jbn`x`cc`adai`h", +"``as`e`n`r`zagbzbgae`r`pacbx", +"````as`qanad`r`n`rag`pbf`h``", +"````bvbkbpbqaubba`byabbtbv``", +"``````azaw`sauabambi`o`f````", +"``````````abbw`katab````````", +"````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue4.xpm b/hacks/images/bubbles/blue4.xpm new file mode 100644 index 00000000..bb0843d0 --- /dev/null +++ b/hacks/images/bubbles/blue4.xpm @@ -0,0 +1,157 @@ +/* XPM */ +static char *blue4[] = { +/* width height ncolors chars_per_pixel */ +"20 20 130 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #282845", +"`c c #323252", +"`d c #303050", +"`e c #111121", +"`f c #2E2E4E", +"`g c #0F0F1F", +"`h c #1D1D30", +"`i c #1B1B2E", +"`j c #0C0C12", +"`k c #0A0A10", +"`l c #17172A", +"`m c #212137", +"`n c #767691", +"`o c #1F1F35", +"`p c #2F2F48", +"`q c #101019", +"`r c #0E0E17", +"`s c #181824", +"`t c #25253E", +"`u c #12121E", +"`v c #10101C", +"`w c #20202F", +"`x c #0E0E1A", +"`y c #0C0C18", +"`z c #292945", +"a` c #161625", +"aa c #141423", +"ab c #121221", +"ac c #2F2F4E", +"ad c #2D2D4C", +"ae c #1A1A2C", +"af c #5C5C7A", +"ag c #161628", +"ah c #333355", +"ai c #07070C", +"aj c #313153", +"ak c #05050A", +"al c #0D0D15", +"am c #24243C", +"an c #202038", +"ao c #1D1D2B", +"ap c #0B0B16", +"aq c #282843", +"ar c #11111F", +"as c #2C2C4A", +"at c #3C3C5D", +"au c #1B1B2C", +"av c #19192A", +"aw c #131324", +"ax c #303051", +"ay c #111122", +"az c #1F1F33", +"b` c #19192D", +"ba c #08080F", +"bb c #161620", +"bc c #23233A", +"bd c #0E0E18", +"be c #0A0A14", +"bf c #272741", +"bg c #25253F", +"bh c #10101D", +"bi c #1E1E2E", +"bj c #2B2B48", +"bk c #0C0C19", +"bl c #292946", +"bm c #2F2F4F", +"bn c #101020", +"bo c #1C1C2F", +"bp c #2A2A40", +"bq c #18182B", +"br c #353558", +"bs c #09090F", +"bt c #07070D", +"bu c #15151E", +"bv c #1C1C32", +"bw c #090912", +"bx c #191925", +"by c #24243D", +"bz c #22223B", +"c` c #13131F", +"ca c #11111D", +"cb c #0D0D19", +"cc c #2A2A46", +"cd c #171726", +"ce c #151524", +"cf c #131322", +"cg c #0F0F1E", +"ch c #343456", +"ci c #08080D", +"cj c #151527", +"ck c #1F1F34", +"cl c #1B1B30", +"cm c #0C0C14", +"cn c #0A0A12", +"co c #494967", +"cp c #23233B", +"cq c white", +"cr c #14141F", +"cs c #1E1E2C", +"ct c #0C0C17", +"cu c #292944", +"cv c #141422", +"cw c #2D2D4B", +"cx c #0E0E1C", +"cy c #373758", +"cz c #181829", +"d` c #161627", +"da c #141425", +"db c #313152", +"dc c #121223", +"dd c #030307", +"de c #BCBCD7", +"df c #1C1C30", +"dg c #1A1A2E", +"dh c #0B0B12", +"di c #18182C", +"dj c #090910", +"dk c #222239", +"dl c #202037", +"dm c #11111B", +"dn c #1E1E35", +"do c #0D0D17", +"dp c #0B0B15", +"dq c #1B1B28", +"dr c #262640", +"ds c #171724", +"dt c #151522", +"du c #2C2C49", +/* pixels */ +"```````````````vdpbbazd``idt````````````", +"``````````cmbbbxbg`ecpbfbgckbedm````````", +"`````````vdscb`zbjamcwbjbj`zcsbbav``````", +"``````czcbbq`acwbmbvaccjbmdudrcsbxca````", +"````c``vbvcxad`dajaqahdlbjbvcf`w`tbxc```", +"````aecbaqagbncjahdachawahblbmascpdkbe``", +"``baap`haodidn`bbpbpataechaw`dcwcsbyapba", +"``c`bubvaoadbmad`icodeafbr`laxadbqb`ckcv", +"``a`apbvcccl`danb``ncq`ncybmclcwcxagbd`q", +"```rdpby`ldfacagah`pcocodcdbacbicubxaadj", +"``cvbhbcbfdcadbn`oacd``cabbmadbiao`xabal", +"``bsct`m`t`objbv`fbndgbm`fcgbjcu`t`ybbdm", +"``akcdaparcfdqbvaqcw`gcwdubzbfaodkapcdbt", +"````c`bw`ubcdsbfcuccaycc`wbfbg`lckdmc```", +"````bacecr`sbobx`tbkd`dr`tamdkckaucndd``", +"```````rcecf`hd`bbctc`dkbbct`hdpcmci````", +"````````cmcfcdcvbocrcz`haeae`qdpal``````", +"``````````ba`jc`cebdcncmcec``kak````````", +"``````````````aidhcm`kdobsai````````````", +"````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue5.xpm b/hacks/images/bubbles/blue5.xpm new file mode 100644 index 00000000..e337885f --- /dev/null +++ b/hacks/images/bubbles/blue5.xpm @@ -0,0 +1,170 @@ +/* XPM */ +static char *blue5[] = { +/* width height ncolors chars_per_pixel */ +"24 24 139 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #323252", +"`c c #303050", +"`d c #111121", +"`e c #2E2E4E", +"`f c #0F0F1F", +"`g c #1D1D30", +"`h c #1B1B2E", +"`i c #0C0C12", +"`j c #0A0A10", +"`k c #17172A", +"`l c #212137", +"`m c #767691", +"`n c #1F1F35", +"`o c #101019", +"`p c #181824", +"`q c #25253E", +"`r c #12121E", +"`s c #10101C", +"`t c #20202F", +"`u c #0E0E1A", +"`v c #292945", +"`w c #161625", +"`x c #141423", +"`y c #242436", +"`z c #313150", +"a` c #121221", +"aa c #2F2F4E", +"ab c #2D2D4C", +"ac c #1A1A2C", +"ad c #161628", +"ae c #333355", +"af c #07070C", +"ag c #313153", +"ah c #05050A", +"ai c #0D0D15", +"aj c #24243C", +"ak c #202038", +"al c #0D0D18", +"am c #1D1D2B", +"an c #0B0B16", +"ao c #282843", +"ap c #262641", +"aq c #232334", +"ar c #0F0F1D", +"as c #2C2C4A", +"at c #3C3C5D", +"au c #19192A", +"av c #151526", +"aw c #131324", +"ax c #303051", +"ay c #111122", +"az c #1F1F33", +"b` c #08080F", +"ba c #161620", +"bb c #23233A", +"bc c #212138", +"bd c #0E0E18", +"be c #0A0A14", +"bf c #272741", +"bg c #25253F", +"bh c #12121F", +"bi c #10101D", +"bj c #202030", +"bk c #0E0E1B", +"bl c #1E1E2E", +"bm c #2B2B48", +"bn c #0C0C19", +"bo c #181828", +"bp c #28283B", +"bq c #2F2F4F", +"br c #101020", +"bs c #1C1C2F", +"bt c #18182B", +"bu c #353558", +"bv c #09090F", +"bw c #333356", +"bx c #07070D", +"by c #15151E", +"bz c #202036", +"c` c #1C1C32", +"ca c #090912", +"cb c #191925", +"cc c #26263F", +"cd c #24243D", +"ce c #22223B", +"cf c #13131F", +"cg c #11111D", +"ch c #0F0F1B", +"ci c #0D0D19", +"cj c #2A2A46", +"ck c #171726", +"cl c #131322", +"cm c #111120", +"cn c #2E2E4D", +"co c #0F0F1E", +"cp c #343456", +"cq c #08080D", +"cr c #151527", +"cs c #06060B", +"ct c #1F1F34", +"cu c #0C0C14", +"cv c #0A0A12", +"cw c #494967", +"cx c #23233B", +"cy c white", +"cz c #0C0C17", +"d` c #292944", +"da c #0A0A15", +"db c #262637", +"dc c #141422", +"dd c #2D2D4B", +"de c #0E0E1C", +"df c #1A1A2B", +"dg c #161627", +"dh c #333354", +"di c #141425", +"dj c #313152", +"dk c #121223", +"dl c #030307", +"dm c #BCBCD7", +"dn c #1E1E32", +"do c #1C1C30", +"dp c #1A1A2E", +"dq c #0B0B12", +"dr c #18182C", +"ds c #090910", +"dt c #222239", +"du c #11111B", +"dv c #1E1E35", +"dw c #0F0F19", +"dx c #0D0D17", +"dy c #0B0B15", +"dz c #1B1B28", +"e` c #262640", +"ea c #151522", +"eb c #212131", +"ec c #2C2C49", +/* pixels */ +"``````````````````bxdybsdobsdfdc````````````````", +"```````````````r`h`rajcibk`udzdgdnau````````````", +"``````````b``gcicgao`xavazcd`vao`q`u`gcf````````", +"````````b`aucxdicjecddcncnadddec`xbfcxdaai``````", +"``````aibkbkbi`addaaaabm`ydpbgaaawcobfci`gcg````", +"``````dfbce`deddbqdj`bayaeasc`djapak`te`bcac````", +"````eadaciaodpc`ayaycrdrcpdiacaqcr`eecdtaj`hea``", +"````auanbtcj`fdv`yaedrbububpcp`eagbqddblccbzau``", +"``bd`ual`qc`abcndkbwdi`zcwcwbubwbp`cabe`bidtcz`j", +"``bhchdtaz`qbl`ccrdhdh`mcydmatbway`cabdedidtdobh", +"``cg`gdtboamco`ddjaebz`mcydmatawakapdddecmalcvcg", +"``cgczdte`dedo`ec``bdiatcwcw`k`baq`ebl`vbkdtbscv", +"``bxbe`u`qbodeabbraxdrbjadaedjbjbqabbmaoc``lczbx", +"``dwclbicxbfdtecabaa`nbraxdb`cblabec`vbfdgctczdw", +"``cvckbe`lbndzcjaoddcnajaocncnddcocjbf`qanad`wcv", +"````cuchdnan`qbfcocebleccjecbmeb`v`kbh`paudfdq``", +"````dx`xclbtdtbtaraod`ambr`xd`aravdc`geaa``wbv``", +"``````cgdcbt`pbc`u`qccdtdge`cc`qcxbcctbyczcs````", +"``````cqcsckcl`gdicidtardibbdt`lcbbacl`o`odl````", +"````````dscseaauby`r`sctctctdndubyaubhbxds``````", +"``````````afcscv`wbocaacacacaubobdb``iaf````````", +"``````````````ahdw`rdqbxcudccfcvdwb`````````````", +"``````````````````afdlbvdsdq`jaf````````````````", +"````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue6.xpm b/hacks/images/bubbles/blue6.xpm new file mode 100644 index 00000000..f70bb6c9 --- /dev/null +++ b/hacks/images/bubbles/blue6.xpm @@ -0,0 +1,195 @@ +/* XPM */ +static char *blue6[] = { +/* width height ncolors chars_per_pixel */ +"30 30 158 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #191929", +"`c c #323252", +"`d c #303050", +"`e c #111121", +"`f c #2E2E4E", +"`g c #1D1D30", +"`h c #1B1B2E", +"`i c #0C0C12", +"`j c #0A0A10", +"`k c #17172A", +"`l c #212137", +"`m c #767691", +"`n c #1F1F35", +"`o c #2F2F48", +"`p c #101019", +"`q c #181824", +"`r c #25253E", +"`s c #12121E", +"`t c #10101C", +"`u c #20202F", +"`v c #0E0E1A", +"`w c #2B2B47", +"`x c #0C0C18", +"`y c #292945", +"`z c #161625", +"a` c #141423", +"aa c #242436", +"ab c #121221", +"ac c #2F2F4E", +"ad c #2D2D4C", +"ae c #1A1A2C", +"af c #5C5C7A", +"ag c #161628", +"ah c #333355", +"ai c #07070C", +"aj c #313153", +"ak c #05050A", +"al c #0D0D15", +"am c #07070F", +"an c #24243C", +"ao c #202038", +"ap c #0D0D18", +"aq c #1D1D2B", +"ar c #0B0B16", +"as c #282843", +"at c #232334", +"au c #11111F", +"av c #0F0F1D", +"aw c #2C2C4A", +"ax c #3C3C5D", +"ay c #1B1B2C", +"az c #19192A", +"b` c #151526", +"ba c #131324", +"bb c #303051", +"bc c #111122", +"bd c #1F1F33", +"be c #19192D", +"bf c #08080F", +"bg c #161620", +"bh c #23233A", +"bi c #212138", +"bj c #0E0E18", +"bk c #0A0A14", +"bl c #272741", +"bm c #25253F", +"bn c #12121F", +"bo c #10101D", +"bp c #202030", +"bq c #0E0E1B", +"br c #1E1E2E", +"bs c #2B2B48", +"bt c #0C0C19", +"bu c #181828", +"bv c #28283B", +"bw c #262639", +"bx c #2F2F4F", +"by c #101020", +"bz c #18182B", +"c` c #353558", +"ca c #09090F", +"cb c #333356", +"cc c #07070D", +"cd c #15151E", +"ce c #202036", +"cf c #1C1C32", +"cg c #090912", +"ch c #191925", +"ci c #26263F", +"cj c #24243D", +"ck c #22223B", +"cl c #13131F", +"cm c #11111D", +"cn c #0F0F1B", +"co c #0D0D19", +"cp c #2A2A46", +"cq c #262642", +"cr c #171726", +"cs c #151524", +"ct c #131322", +"cu c #111120", +"cv c #2E2E4D", +"cw c #0F0F1E", +"cx c #343456", +"cy c #08080D", +"cz c #151527", +"d` c #06060B", +"da c #1F1F34", +"db c #1B1B30", +"dc c #0C0C14", +"dd c #0A0A12", +"de c #494967", +"df c #23233B", +"dg c white", +"dh c #14141F", +"di c #212139", +"dj c #1E1E2C", +"dk c #0C0C17", +"dl c #292944", +"dm c #0A0A15", +"dn c #262637", +"do c #141422", +"dp c #2D2D4B", +"dq c #0E0E1C", +"dr c #1A1A2B", +"ds c #373758", +"dt c #181829", +"du c #161627", +"dv c #333354", +"dw c #141425", +"dx c #313152", +"dy c #121223", +"dz c #222236", +"e` c #030307", +"ea c #BCBCD7", +"eb c #1E1E32", +"ec c #1C1C30", +"ed c #1A1A2E", +"ee c #0B0B12", +"ef c #18182C", +"eg c #28283F", +"eh c #090910", +"ei c #222239", +"ej c #202037", +"ek c #11111B", +"el c #1E1E35", +"em c #0F0F19", +"en c #0D0D17", +"eo c #0B0B15", +"ep c #1B1B28", +"eq c #090913", +"er c #262640", +"es c #171724", +"et c #151522", +"eu c #212131", +"ev c #2C2C49", +/* pixels */ +"````````````````````````d`dhazazdoap`s``````````````````````", +"``````````````````ccdraubgbiei`hcu`xar`gbkcm````````````````", +"````````````````drbgeianbmdfbydfaqblbmageibkb```````````````", +"````````````eoeqceboeiascpcwbsctaoeucpaser`nce`sdo``````````", +"``````````bfarb`eicwcpbsdpadcvcvdfaddpbsa`dj`raeddal````````", +"````````bn`tcochas`aawcvbx`kbxacczbybxcvcwerab`rchbjbn``````", +"````````ek`besav`aawcv`ddxdbejdvcqdbdxeuaweudfbl`hcedr``````", +"``````am`gdtau`yevcv`dbpdvbcbbdwcbahdvbzeudzb``ydweict`z````", +"````alaearabascubmbyeladahasaocxbwbeahagbabxdp`wdfcjcebk`j``", +"````etbkbobzdlevcfbcaaagcxasc`c`bvbvcx`kaj`dcvaqdlcieictet``", +"````craretcudqeueuczczahaeel`cdededscxbz`cbb`fdi`kbobh`qcr``", +"``eeazcdazepaqcw`fbx`ecz`hax`mea`mdec`ahefbb`fbcbz`hdfdaddee", +"```pdudkctdjcpefeu`dazb`agdseadgeaafdsahaobccv`ueccwdochek`p", +"``ekcddadfci`hcjadatdxelcf`o`meaeadebdedbb`keueveubqab`qazen", +"``ekazeobher`kdwdtaccfdwahdrdedeafaxdyajatacdpcrdlbqbha`dkd`", +"```p`parei`rasdqatcvbybbckegacebc`dvcfbbbxcvaw`abrcjei`gdtee", +"``akcrdwbganblecb`dpctdnabdw`f`wdxdx`d`ncvdpbs`yblco`lek`pen", +"``aketdkbgei`rczaqbsdpaa`f`fefedbxbx`fcveubs`yaq`rb`arbgccai", +"````bndtdk`lcedqas`yeccwdpadcvbscvadeicfby`yascidfareoazbj``", +"````em`zeoebctctciascwbaabevevcpevevbs`b`ydbeianbiazay`zem``", +"````e`clapay`sepanescoasdl`yeubcdq`y`u`uctbmcuebda`vbuclai``", +"``````bjcgcgecdmbi`xcmcierbl`udqbhbldjdjcjdfbiabeccgetbj````", +"`````````tbjazbjdrcecndfancj`kbt`rcjandfeiceabcmazbfd```````", +"````````bfbfcseq`v`gararbgboducleieibgceda`g`temdcekcy``````", +"``````````ehdccccrdrcddteb`vdadadaebebemcddrcsbncceh````````", +"````````````akemccbk`tazal`p`h`h`haydrazeebfddeecc``````````", +"````````````````eh`i`sdocseododd`p`zcsdobf`je```````````````", +"``````````````````e`bfenemddeobjcmekemenddak````````````````", +"````````````````````````aie`e`bfcaaiai``````````````````````", +"````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue7.xpm b/hacks/images/bubbles/blue7.xpm new file mode 100644 index 00000000..6f4ee485 --- /dev/null +++ b/hacks/images/bubbles/blue7.xpm @@ -0,0 +1,212 @@ +/* XPM */ +static char *blue7[] = { +/* width height ncolors chars_per_pixel */ +"36 36 169 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #1B1B2B", +"`c c #191929", +"`d c #323252", +"`e c #303050", +"`f c #111121", +"`g c #2E2E4E", +"`h c #0F0F1F", +"`i c #1D1D30", +"`j c #1B1B2E", +"`k c #0C0C12", +"`l c #0A0A10", +"`m c #17172A", +"`n c #212137", +"`o c #767691", +"`p c #1F1F35", +"`q c #2F2F48", +"`r c #101019", +"`s c #0E0E17", +"`t c #272740", +"`u c #181824", +"`v c #25253E", +"`w c #21213A", +"`x c #12121E", +"`y c #10101C", +"`z c #20202F", +"a` c #0E0E1A", +"aa c #2B2B47", +"ab c #0C0C18", +"ac c #292945", +"ad c #161625", +"ae c #141423", +"af c #242436", +"ag c #121221", +"ah c #2F2F4E", +"ai c #2D2D4C", +"aj c #1A1A2C", +"ak c #5C5C7A", +"al c #161628", +"am c #333355", +"an c #07070C", +"ao c #313153", +"ap c #05050A", +"aq c #0D0D15", +"ar c #07070F", +"as c #24243C", +"at c #202038", +"au c #0D0D18", +"av c #1D1D2B", +"aw c #0B0B16", +"ax c #282843", +"ay c #262641", +"az c #232334", +"b` c #11111F", +"ba c #0F0F1D", +"bb c #2C2C4A", +"bc c #3C3C5D", +"bd c #2A2A48", +"be c #1B1B2C", +"bf c #19192A", +"bg c #151526", +"bh c #131324", +"bi c #303051", +"bj c #111122", +"bk c #1F1F33", +"bl c #19192D", +"bm c #08080F", +"bn c #161620", +"bo c #23233A", +"bp c #212138", +"bq c #0E0E18", +"br c #0A0A14", +"bs c #272741", +"bt c #25253F", +"bu c #23233D", +"bv c #12121F", +"bw c #10101D", +"bx c #202030", +"by c #0E0E1B", +"bz c #1E1E2E", +"c` c #2B2B48", +"ca c #292946", +"cb c #181828", +"cc c #28283B", +"cd c #262639", +"ce c #2F2F4F", +"cf c #101020", +"cg c #1C1C2F", +"ch c #2A2A40", +"ci c #18182B", +"cj c #353558", +"ck c #09090F", +"cl c #333356", +"cm c #07070D", +"cn c #15151E", +"co c #202036", +"cp c #1C1C32", +"cq c #090912", +"cr c #191925", +"cs c #26263F", +"ct c #24243D", +"cu c #22223B", +"cv c #13131F", +"cw c #11111D", +"cx c #0F0F1B", +"cy c #0D0D19", +"cz c #2A2A46", +"d` c #262642", +"da c #171726", +"db c #151524", +"dc c #131322", +"dd c #111120", +"de c #2E2E4D", +"df c #0F0F1E", +"dg c #1D1D2F", +"dh c #343456", +"di c #08080D", +"dj c #151527", +"dk c #06060B", +"dl c #1F1F34", +"dm c #1B1B30", +"dn c #0C0C14", +"do c #0A0A12", +"dp c #494967", +"dq c #23233B", +"dr c white", +"ds c #212139", +"dt c #1E1E2C", +"du c #2B2B46", +"dv c #0C0C17", +"dw c #292944", +"dx c #0A0A15", +"dy c #262637", +"dz c #141422", +"e` c #2D2D4B", +"ea c #0E0E1C", +"eb c #1A1A2B", +"ec c #373758", +"ed c #181829", +"ee c #161627", +"ef c #333354", +"eg c #141425", +"eh c #313152", +"ei c #121223", +"ej c #222236", +"ek c #030307", +"el c #BCBCD7", +"em c #1E1E32", +"en c #1C1C30", +"eo c #1A1A2E", +"ep c #0B0B12", +"eq c #18182C", +"er c #28283F", +"es c #090910", +"et c #222239", +"eu c #11111B", +"ev c #1E1E35", +"ew c #0F0F19", +"ex c #0D0D17", +"ey c #0B0B15", +"ez c #1B1B28", +"f` c #090913", +"fa c #262640", +"fb c #171724", +"fc c #151522", +"fd c #212131", +"fe c #2E2E4B", +"ff c #2C2C49", +/* pixels */ +"````````````````````````````````cq`sdaaddn``````````````````````````````", +"`````````````````````````xedcgfc`ucocyaba`aecgcqdz``````````````````````", +"````````````````````dobe`jbnetasbabybyddboezdl`nembrar``````````````````", +"``````````````````ebema`fcctbsezbybwdqegdbaxbsetdq`xemcb````````````````", +"``````````````exaucx`nby`zaxczfddfffeq`m`aaaczaxbsby`n`pbedz````````````", +"````````````bmfcemdqagagczc`bbe`dededebg`me`bbc`aebafcdqawa`aq``````````", +"``````````cvbecodqbydc`affaideajcfdjblegdm`wdebebh`pdafaezbndvcv````````", +"``````````bf`icwdtb``abbdeah`eeqbje``dbd`fc``e`vevbheqax`va`bkbf````````", +"````````cqbrbpalejeaffdecebieh`d`geiamafdjcpehc`aybg`c`zbsezbpbraq``````", +"``````doajda`pcyacbte`aheveeefafevaldhdhclamefd`bgahe`c`acdqdq`pdv`x````", +"``````daeyawcyaxavayeicudyeiamdjdmevcjdydycgafbhevcedebbcfav`vbpdada````", +"`````lbfajagciaxc``hdscfafdmcleqafcjcjcjcjdhcdalao`eahe`ataxcsetcgbfey``", +"````dccxdcdgcyeeaxaieq`malccdheqaxchdpbc`qcjdhalafbiceaibldceadq`pbvdc``", +"````cmf`emdq`pacczaicebubjcidhbsdudpakakdpecdherbjehceaiagddemascobnad``", +"`````scx`n`mbkacdwbzcebidjeidhef`oeldrel`obcdhccbjdgceaiay`megby`nenbm``", +"``aqda`i`neeavacc`bhdwbifdbdduemakdrdrdr`obcdhcicubseoaidqdjdden`nbf`saq", +"``bqdaencoasfabscf`mac`eehbjdyajakelelelakbceibjcecfate`c`cs`fcycocgdado", +"```l`rdvcodqfadqcfenercecpcfefegazdpdpakbc`mciehazejdebzaxaxbydqawcgcqdi", +"``ap`ragbaet`v`zcfagaxdecfageheidhfeccecdhazdjbicedee`c`czax`metcrbq`rdn", +"``ekdbdccyetctbsadbhbbaifaaxbibdehevee`deh`ec``v`gaibb`tdwdt`jetemaj`sep", +"````bmdcbf`udqbtbtetc`bbaialce`pegbubibi`e`ece`faibbc`ac`zbteebe`idvcm``", +"````eucqa``xetcteeaeczc`fdevdedybzeqcpceahdedeegffc`czaxfacrcycwcgdc`x``", +"````apdb`sdbcoawdqezaxaccacubge`aibxaiaiaie``ccpalddaxbs`vbocycgajdnew``", +"````bmdncbexemagen`vfa`zdfeacpbzffbbczbbffc`aadtacblblbvci`nbfcgcbepek``", +"```````rdbbaaedl`ndq`vdcagaxacczczaveadfczcz`fbebsfabpbaagdlbebfdbdo````", +"``````apbvcxbf`idx`nfbbfcyfabsaxb`bwbgbaaxax`jb`bfasbo`nen`idvcqbvdo````", +"````````bqbmdzajbr`ucocya`ct`vcsdtegeeezfacs`vctdqetcodldvajdvbvan``````", +"``````````ewcmdadaa`emeyagezbodqfbabcoasasdqboetbncobrbrajdaeycm````````", +"``````````ckdkdzcvda`j`i`uagen`bcycr`uetbpcrcodxem`idcdnardn`yek````````", +"````````````es`karfccbebcnal`i`yawdldldlbkemebdacnebbwbvcm`ses``````````", +"``````````````ekbq`xbmbmdoadajed`rcgcgcg`jeuajbfcbdbdvdkcmdi````````````", +"``````````````````ekbm`xdzdbdacqdaedcqedcbdadaaqbvdkeydk````````````````", +"````````````````````ekdneweubvepdoardn`sdzcvbv`lewapek``````````````````", +"````````````````````````dkekdn`sdodk`lewew`sdndoan``````````````````````", +"````````````````````````````````ekekdkanek``````````````````````````````", +"````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue8.xpm b/hacks/images/bubbles/blue8.xpm new file mode 100644 index 00000000..d4babc4b --- /dev/null +++ b/hacks/images/bubbles/blue8.xpm @@ -0,0 +1,219 @@ +/* XPM */ +static char *blue8[] = { +/* width height ncolors chars_per_pixel */ +"44 44 168 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #1B1B2B", +"`c c #282845", +"`d c #191929", +"`e c #323252", +"`f c #303050", +"`g c #111121", +"`h c #2E2E4E", +"`i c #1D1D30", +"`j c #1B1B2E", +"`k c #0A0A10", +"`l c #17172A", +"`m c #212137", +"`n c #767691", +"`o c #1F1F35", +"`p c #2F2F48", +"`q c #101019", +"`r c #0E0E17", +"`s c #272740", +"`t c #181824", +"`u c #25253E", +"`v c #21213A", +"`w c #12121E", +"`x c #10101C", +"`y c #20202F", +"`z c #2B2B47", +"a` c #0C0C18", +"aa c #292945", +"ab c #161625", +"ac c #141423", +"ad c #242436", +"ae c #121221", +"af c #2F2F4E", +"ag c #2D2D4C", +"ah c #2B2B4A", +"ai c #1A1A2C", +"aj c #5C5C7A", +"ak c #161628", +"al c #333355", +"am c #07070C", +"an c #05050A", +"ao c #0D0D15", +"ap c #07070F", +"aq c #24243C", +"ar c #202038", +"as c #0D0D18", +"at c #1D1D2B", +"au c #0B0B16", +"av c #282843", +"aw c #262641", +"ax c #232334", +"ay c #11111F", +"az c #0F0F1D", +"b` c #2C2C4A", +"ba c #3C3C5D", +"bb c #2A2A48", +"bc c #1B1B2C", +"bd c #19192A", +"be c #151526", +"bf c #131324", +"bg c #303051", +"bh c #111122", +"bi c #19192D", +"bj c #08080F", +"bk c #161620", +"bl c #23233A", +"bm c #212138", +"bn c #0E0E18", +"bo c #0A0A14", +"bp c #272741", +"bq c #25253F", +"br c #23233D", +"bs c #12121F", +"bt c #10101D", +"bu c #202030", +"bv c #0E0E1B", +"bw c #1E1E2E", +"bx c #2B2B48", +"by c #0C0C19", +"bz c #292946", +"c` c #181828", +"ca c #28283B", +"cb c #262639", +"cc c #2F2F4F", +"cd c #101020", +"ce c #2D2D4D", +"cf c #1C1C2F", +"cg c #2A2A40", +"ch c #18182B", +"ci c #353558", +"cj c #09090F", +"ck c #333356", +"cl c #07070D", +"cm c #15151E", +"cn c #202036", +"co c #1C1C32", +"cp c #090912", +"cq c #191925", +"cr c #26263F", +"cs c #24243D", +"ct c #22223B", +"cu c #13131F", +"cv c #11111D", +"cw c #0F0F1B", +"cx c #0D0D19", +"cy c #2A2A46", +"cz c #262642", +"d` c #171726", +"da c #151524", +"db c #131322", +"dc c #111120", +"dd c #2E2E4D", +"de c #0F0F1E", +"df c #1D1D2F", +"dg c #343456", +"dh c #08080D", +"di c #151527", +"dj c #06060B", +"dk c #1F1F34", +"dl c #1B1B30", +"dm c #0C0C14", +"dn c #0A0A12", +"do c #494967", +"dp c #23233B", +"dq c white", +"dr c #14141F", +"ds c #212139", +"dt c #1E1E2C", +"du c #2B2B46", +"dv c #0C0C17", +"dw c #292944", +"dx c #0A0A15", +"dy c #262637", +"dz c #141422", +"e` c #2D2D4B", +"ea c #0E0E1C", +"eb c #1A1A2B", +"ec c #373758", +"ed c #181829", +"ee c #161627", +"ef c #333354", +"eg c #141425", +"eh c #313152", +"ei c #121223", +"ej c #222236", +"ek c #BCBCD7", +"el c #1E1E32", +"em c #1C1C30", +"en c #1A1A2E", +"eo c #0B0B12", +"ep c #18182C", +"eq c #28283F", +"er c #090910", +"es c #222239", +"et c #202037", +"eu c #11111B", +"ev c #1E1E35", +"ew c #0F0F19", +"ex c #0D0D17", +"ey c #0B0B15", +"ez c #1B1B28", +"f` c #090913", +"fa c #262640", +"fb c #171724", +"fc c #151522", +"fd c #212131", +"fe c #2C2C49", +/* pixels */ +"````````````````````````````````````````````ao``````````````````````````````````````````", +"````````````````````````````````dmbs`wcffb`i`i`i`ieyaicxfc``````````````````````````````", +"````````````````````````````c`euegcwcnbmesa`a`aza`cxcffb`ibo`x``````````````````````````", +"````````````````````````c`cfau`mezdp`uenakaeeadpcr`u`ucxa``mbtcvc```````````````````````", +"````````````````````cvaiel`lezazd`bpavdbbvdbdseaeiayavbpbvcsesa`eleufc``````````````````", +"``````````````````eebeasaubycobpavaa`adic`cyeade`dbw`aaaavbpdbcvesdkdvd`````````````````", +"````````````````bjdvcxeschaqavaa`zbxb`e`agagddbwbfbdb`bx`zaaemdt`uesauf`d```````````````", +"``````````````d`cf`xcfazcx`j`ybxb`agddag`lchej`g`cbxddag`gdieaeaaz`ubeakcmbj````````````", +"````````````dabcdxee`udedw`afee`ddafccaf`ccecobg`lcdejafddaecddedtbp`uchdk`w`q``````````", +"``````````bnebdrcqbccxea`afee`ddcc`fbfbibhep`eaaawczbu`feqeiawbxegavfachbmelebcl````````", +"``````````c`bdcncvezateafee`ddccbgeh`ecbetcaaldfbqegawehdibxad`vae`yavcr`lcnbocv````````", +"````````dzaibkcwcvezaacse`ddccendf`eefbhdddlfeckckalef`ebfardddd`ybxaacseaes`taudz``````", +"`````````xbobv`o`uavdtdcde`g`gawbgalck`vepfddgdg`leldwaketei`fafagfecyeacrdpbkf``r``````", +"``````cuebazbvcdaedw`ybhegbqbudibfalcaahducicicaciegcbakei`lbgccddb`bmavbpcsbmbn`wcu````", +"``````bjf`dx`jchcsaabxbfbrbhbh`cbfckctdgciecececadcidgckdiejeh`ffde`bmaad``uescq`jao````", +"`````kd`dx`ofbenazcddbagbwcdcdawcbdgbrdi`i`pdodobaeccidgb`axeh`fafagbibpevdbdpcna`d`ex``", +"`````w`dbofbeeakavc`cdagafctet`leqdg`cblecajajajajbacidgdwbbeh`fafagawaaatetdpcneudv`w``", +"`````rbdcf`baidtavegdbebafeqcbbhavdg`i`pajekekek`ndobadgad`lai`fafagdpegazcoaz`m`ibodb``", +"````dnbdelelcdeaavcybuevaf`feh`vcodgesba`ndqdqdqekajbadgalbhctbdaxagee`gaebvcv`mel`qdz``", +"`````xcmau`mdfbt`yfdbwegbc`fehejbxdgefdo`ndqdqdq`najbadg`lepev`adye``lctem`jaz`mcfeudn``", +"````fcebel`mdpezatcsdbenbqbzbgbe`lalakcgdo`nekek`ndoadakepbhcdcocde`bxcybv`oez`mbddbbn``", +"``djcpbdeycndpesazeaeaemfdaf`fepaeefbpbdecajdoajdobaefaxehbgdyafagbw`yaaatdsdpcwdbdmcwdj", +"````cwcmbd`jes`ubpdpcoegcyddenepdfehbxaxcgcgcabaecdgarbdeh`fccdde`fecyavezbiescney`rdz``", +"````bnedf`auesaqfaavchazb`agcddidybgcdcacb`aegalef`eaxenfeccddagb`bxaaav`tevesdkbvedcl``", +"````bjd`daau`mdp`ubpatawcrb`age`ch`fcdbhbibeehehehbg`fcfavddagb`bxcyavbp`ua``melcp`qdj``", +"`````xabbdbodfescsfaeaarfdbxb`cyakafak`leieiax`f`fccccaf`lbwb`bx`aaadtfa`j`icv`iasas`x``", +"`````kdzbndvdv`mdpbsbiabaa`abxbxbpddddaxbccddsafaf`hdddd`ycoeg`aaaavfa`ubydbbecfcpbjbn``", +"````djcud`cpdbcnfcayaqezavaa`aazaaaxe`agagcdb`ddagage`ee`oakeaaaavbp`uaqfbcnbtd`eyewdn``", +"```````xda`qeyelcnbv`iatbpavdteacocsdeesb`bueiavb`b`febxcdfdelbvbeezezescnazeybd`q`x````", +"``````dmcud`eydvdkbeeaaq`ufadecdac`y`a`zbx`seaaqbx`z`acyaaavbpatbvbvaz`m`tdvaid`cuan````", +"````````clfccvbt`iaycwescvdebv`yavavdwaaaa`yde`l`yaadwemavabel`uaeakeldk`iaec`fc`x``````", +"````````dm`wap`x`j`icx`mescxbvaqfabpbpavaecodbabavavbpbmaebvcsdpes`mdv`i`j`x`r`wdm``````", +"``````````ewcv`xbdakdx`tcnbmbycwcs`ubqcrbicxeeayfacrbq`ucsdpblbmcndk`i`jdncvcvbn````````", +"``````````er`xex`qbddvbtbk`ocxazesdpaq`ta`by`jcscsaqaqbcescq`m`obecxbcbdcpbsaner````````", +"````````````eobjcveebscwey`ibkeleldceselauezcxcqesesez`mcncuel`idvaydveudz`xan``````````", +"``````````````dm`xaocpabebbccffbasbd`oegazcncncncncn`odkd`drcfbcazdzeybs`xdm````````````", +"````````````````dhbjdm`qd`edebbkd`emdrazelelelelelel`ibocfbofcedee`xdmaneo``````````````", +"``````````````````anbndjerbnbseydnebf`ai`jcfcfcf`jbcaiebbdc``qdmbndv`rdh````````````````", +"````````````````````dhdjdnaodbfcabd`cpc``dbd`rbd`dedc`d`aodzbjdjdmcldh``````````````````", +"````````````````````````anaoewcvbsdbdzeoclap`q`rdafcdzdbcldmewcjer``````````````````````", +"````````````````````````````djdj`reweoexcldjbn`wcveu`xew`rdmdh``````````````````````````", +"````````````````````````````````amcjdndjeoanandmdmdmdnamam``````````````````````````````", +"````````````````````````````````````````````am``````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/blue9.xpm b/hacks/images/bubbles/blue9.xpm new file mode 100644 index 00000000..2026b9b5 --- /dev/null +++ b/hacks/images/bubbles/blue9.xpm @@ -0,0 +1,227 @@ +/* XPM */ +static char *blue9[] = { +/* width height ncolors chars_per_pixel */ +"50 50 170 2", +/* colors */ +"`` c None", +"`a c #2A2A47", +"`b c #1B1B2B", +"`c c #282845", +"`d c #191929", +"`e c #323252", +"`f c #303050", +"`g c #111121", +"`h c #2E2E4E", +"`i c #0F0F1F", +"`j c #1D1D30", +"`k c #1B1B2E", +"`l c #0C0C12", +"`m c #0A0A10", +"`n c #17172A", +"`o c #212137", +"`p c #767691", +"`q c #1F1F35", +"`r c #2F2F48", +"`s c #101019", +"`t c #0E0E17", +"`u c #272740", +"`v c #181824", +"`w c #25253E", +"`x c #21213A", +"`y c #12121E", +"`z c #10101C", +"a` c #20202F", +"aa c #0E0E1A", +"ab c #2B2B47", +"ac c #0C0C18", +"ad c #292945", +"ae c #161625", +"af c #141423", +"ag c #242436", +"ah c #313150", +"ai c #121221", +"aj c #2F2F4E", +"ak c #2D2D4C", +"al c #1A1A2C", +"am c #5C5C7A", +"an c #161628", +"ao c #333355", +"ap c #07070C", +"aq c #313153", +"ar c #05050A", +"as c #0D0D15", +"at c #24243C", +"au c #202038", +"av c #0D0D18", +"aw c #1D1D2B", +"ax c #0B0B16", +"ay c #282843", +"az c #262641", +"b` c #232334", +"ba c #11111F", +"bb c #0F0F1D", +"bc c #2C2C4A", +"bd c #3C3C5D", +"be c #1B1B2C", +"bf c #19192A", +"bg c #151526", +"bh c #131324", +"bi c #303051", +"bj c #111122", +"bk c #1F1F33", +"bl c #19192D", +"bm c #08080F", +"bn c #161620", +"bo c #23233A", +"bp c #212138", +"bq c #0E0E18", +"br c #0A0A14", +"bs c #272741", +"bt c #25253F", +"bu c #23233D", +"bv c #12121F", +"bw c #10101D", +"bx c #202030", +"by c #0E0E1B", +"bz c #1E1E2E", +"c` c #2B2B48", +"ca c #0C0C19", +"cb c #292946", +"cc c #181828", +"cd c #28283B", +"ce c #262639", +"cf c #2F2F4F", +"cg c #101020", +"ch c #1C1C2F", +"ci c #2A2A40", +"cj c #18182B", +"ck c #353558", +"cl c #09090F", +"cm c #333356", +"cn c #07070D", +"co c #15151E", +"cp c #202036", +"cq c #1C1C32", +"cr c #090912", +"cs c #191925", +"ct c #26263F", +"cu c #24243D", +"cv c #22223B", +"cw c #13131F", +"cx c #11111D", +"cy c #0F0F1B", +"cz c #0D0D19", +"d` c #2A2A46", +"da c #262642", +"db c #171726", +"dc c #151524", +"dd c #131322", +"de c #111120", +"df c #2E2E4D", +"dg c #0F0F1E", +"dh c #1D1D2F", +"di c #343456", +"dj c #08080D", +"dk c #151527", +"dl c #06060B", +"dm c #1F1F34", +"dn c #1B1B30", +"do c #0C0C14", +"dp c #0A0A12", +"dq c #494967", +"dr c #23233B", +"ds c white", +"dt c #14141F", +"du c #1E1E2C", +"dv c #2B2B46", +"dw c #0C0C17", +"dx c #292944", +"dy c #0A0A15", +"dz c #262637", +"e` c #141422", +"ea c #2D2D4B", +"eb c #0E0E1C", +"ec c #1A1A2B", +"ed c #373758", +"ee c #181829", +"ef c #161627", +"eg c #333354", +"eh c #141425", +"ei c #313152", +"ej c #121223", +"ek c #222236", +"el c #030307", +"em c #BCBCD7", +"en c #1E1E32", +"eo c #1C1C30", +"ep c #1A1A2E", +"eq c #0B0B12", +"er c #18182C", +"es c #28283F", +"et c #090910", +"eu c #222239", +"ev c #202037", +"ew c #11111B", +"ex c #1E1E35", +"ey c #0F0F19", +"ez c #0D0D17", +"f` c #0B0B15", +"fa c #1B1B28", +"fb c #090913", +"fc c #262640", +"fd c #171724", +"fe c #151522", +"ff c #212131", +"fg c #2C2C49", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````cnddbvalfeewchch`kbbbfcre`````````````````````````````````````", +"````````````````````````````````e`eeaibvendmcp`o`oaxczeoaxbyax`jcydwe```````````````````````````````", +"````````````````````````````e`ewchf`bnaaeudrataicacabyatatfebvaacpen`yewdp``````````````````````````", +"````````````````````````aseechbncpeucs`wbtatefbbcqdrcpfabsfcbtehbaeucpbrchbqew``````````````````````", +"``````````````````````f`al`jdydeacbabwbsaydccucgffa`eheu`wdxaybsfc`watch`y`janfe````````````````````", +"````````````````````cybrbr`oblcz`nbsdxad`aecdkccfgerfgdebzc``aaddxbsdkawfa`odwaaef``````````````````", +"``````````````````bm`k`kbadrddcpayad`ac`bceaeaakdfdfdf`ieheabcc``aadbtbw`wdrdwbybgdb````````````````", +"````````````````ef`kefbgatbyczdrddc`bceadfdzdkanekc`ffexblb`dfeadgdkcgcgbacsateoen`kf```````````````", +"``````````````dcbecjczdrebehad`afgeaakdfcfbudn`cazajepercgeacfdfbxehbbfcawductdrcsenbecr````````````", +"````````````bmbfbfaibb`wefdx`afgeadfajcf`fcgcgbjbxaqbhbtcuan`fcfdxdnbtaibldxbsbkcpcp`jbfet``````````", +"``````````dpccdd`qeu`vbzbbefc`abdfaj`fbiei`ebcejenegdhepeh`g`nbibhbtdkddbsehcgbsfaeu`qchbmdl````````", +"``````````eqcobncpendgaybba`bcdfaj`fb`ei`eb`ehbhau`ndzaoaoch`eeiayerb`a`b`bzd`ayeb`qbpezecfe````````", +"````````ewcrfbchdddefadxaibcakffbeaddkdzegejdk`xehdididicmaoeg`eaydacf`hakbc`adxdgczeucyf`cceq``````", +"````````fealdwacdeefay`d`adk`gcgercqeh`naodkehexdidididkbjanaobjbjex`fcfdfeac`aidrctat`oaxbrfe``````", +"``````eydcbralacehebdx`absercvbcdzdhaycdcmer`jckckckagckeocdb`ayehdkei`f`hakfg`qdhbscueudmfbdbas````", +"``````cwbfbraxen`n`nadc`bc`gd`bjbgcfaycmdiejehckedededcdfgdidiblblffei`feadfboejaddu`wbocpbfbfcw````", +"``````cwbfbrbqboddcgbtayeaefdfbj`n`ncdcmbldkep`r`rdqdqbdceckdicmejdzeibicfdf`bdgebefdbdr`o`jdtfe````", +"`````tcxavdbdwblcpbzaeepaidfdzbudkejagcmbhdkdm`rdqamamambdeddicm`jeieibicfdfcgaiebfadgatbpencraeeq``", +"````ewdbaxcofedebwayawffejdfcfcfepbjdncm`kah`r`p`pem`p`pambdckcmdz`nb`bicfdfef`bcjbzatcseudmeycrew``", +"`````yccbvdmeuehbaaybz`u`nescfbiei`n`ndidvbxdq`pdsdsememamdqeddidxbj`fbxcfdfecazbhbyczaceudmchcr`y``", +"````aseechdycsczbwcpd`c`bhcucf`feidkcucmdicedq`pdsdsdsem`pdqedcmandkcgcgcbdfeaazehbtczbbchavaiewbm``", +"````cneechdmeudhbwawddbzbtcjdn`feiaqbjao`wenam`pdsdsdsemamdqck`nbt`adnbjaidfbcddbscjbgdecscwbw`ydp``", +"````doeechdmbpatbodueobjep`gayddbi`nbjegdaatdqdq`p`pem`pdq`rbucqexcgdkcvddakbcabadbyanatdmbqafcrcn``", +"````cnccbff``odreke``n`g`n`nekaj`fcqbj`eaocqffbddqdqamdqbdb`ej`eeibiagajdfeabzatdxbyeodr`oafbvcrcr``", +"````cn`scrdw`obo`wbsebeb`nbgakdfcqbj`nei`edkceekajcibdbdckagbjb`ei`fcfdfakbcc`d`aybsbgbo`oaxf`dbbm``", +"`````ydbcrbrdmeucufcay`kexayeadf`xcgbhbiadaycdcjfgcjdiaoeg`eaybh`fcf`hdfeafg`aaddudd`jeucpeffedbdl``", +"````ewaecrddaxbpdr`wbsbzepddfgeadfcbev`fcf`xag`abcbf`eeieieibicgbo`hdfeafgc`a`aybs`weubpdmavecaveq``", +"````eyfeczf`dycsbocufcbw`gbbc`bceaefdkajb`anbj`gehbibiag`f`fcfajbhdfeabcc`d`ctayfcanaccpenbacocney``", +"````ase`avdwddcpeuat`wcz`kba`ac`bcd`cqdf`hbcc`cgc`ep`fcfcfaj`hdfbsejbcc``aadayfa`webdmal`jbnbm`yas``", +"````dp`yae`zdydw`ochddcjfaayad`ac`cjbleaakdfdf`hbjepaj`hdfdfakea`dbbbs`aadaybsctcudeeeefbrecbm`ydp``", +"```````zfe`ycrbgcpfd`qbpaibsayadd`bbcueubxeaakakcgbcakakakeabcdecqepdkawaybsct`wdrbpchcjeweeet`z````", +"``````ascwdbdpdpencpbl`ncjfcbsaybgeberbsd`bzbcbcb`ehb`bcbcfgc`bgaiawdxbycueb`vcxeucpczcxecdbcneq````", +"``````elewfeaaf`aadmcjaidr`wctbscgcgebafek`ac`c`ctbbffc`c``a`aawadayayfaddca`ndw`o`ybbbeccfeewdj````", +"`````````tcwaeddax`j`yaleudre`fdebaiayaydxadd`d`dubjcqffd`ada`aybka`fcbtbwcpbbacdmdtcrbfaecwdp``````", +"````````cnbmetcraach`jdy`oeuacbbczccfcbsbsaya`deayblazaeayaydbcqddexcwat`jeu`ybk`jbfcrdoe``zet``````", +"``````````as`yfef`bfcobfcocpbpaibgcs`wbtfcfcbsbwbyczbabsbsfcfcbt`wcudreubpcpbqdcchezaebmcxar````````", +"``````````elbq`t`zeyecaxbbbkcp`oaxbodratcu`w`weubhbwalbt`w`wcuatdrboeu`ocpbkdwbwecdwbmdoarap````````", +"`````````````meyeze`ccbrcrbren`dbwbfbvcsbodrbaaieu`katatdrdrboeueucscpdmbrbff`ecccdobm`ldl``````````", +"``````````````eqeqbmdc`screy`d`jenacac`qbnfdczbg`vcweueueubpbncpacbnen`jeecr`ycrdocw`sel````````````", +"````````````````eqeybm`ze`coecbech`jbwandmbnaxbkcpcpcpcpcp`qdmen`kchchbeec`zf`dodleyeq``````````````", +"``````````````````dlas`y`zaedb`decbnbfbe`jbrbfenenenenenen`j`jdpchf``y`ddpdobvbm`meq````````````````", +"````````````````````elbqarcwdpcxcrdbccalbebefbchch`dchchch`kfbalbfeedbbqcrcneyarap``````````````````", +"``````````````````````djdocncncne`aedbdbccdwbfbfecececbfbfbfeedbdbcxezcncnclarbm````````````````````", +"````````````````````````eldlas`lcxcwe`fedcaedpe`bmdpdbeqefaedcfee`dpbq`mcnelap``````````````````````", +"````````````````````````````elelasey`zcx`ycnbmbm`zcre`e`cwcw`ycx`zeyasdjap``````````````````````````", +"````````````````````````````````dlararas`tcndparareq`z`zey`m`taseqclap``````````````````````````````", +"``````````````````````````````````````apdlelaparelareqeqdpetelap````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass.pov b/hacks/images/bubbles/glass.pov new file mode 100644 index 00000000..c1897714 --- /dev/null +++ b/hacks/images/bubbles/glass.pov @@ -0,0 +1,27 @@ +#include "colors.inc" +#include "shapes.inc" +#include "textures.inc" + +/* The following make the field of view as wide as it is high + * Thus, you should have the -W and -H command line options + * equal to each other. */ +camera { + location <5.8, 0, 0> + up <0, 1, 0> + right <1, 0, 0> + look_at <0, 0, 0> +} + +sphere { + <0,0,0>, 2.5 + texture { Glass + scale <0.7, 0.7, 0.7> + rotate y*clock + normal {bumps 0.4 scale 0.1} + finish { Shiny } +# finish { phong 0.4 } + } +} + +light_source {<6, 7, 0> color White} +light_source {<6.1, 1, 0> color Blue} diff --git a/hacks/images/bubbles/glass1.xpm b/hacks/images/bubbles/glass1.xpm new file mode 100644 index 00000000..7d25395c --- /dev/null +++ b/hacks/images/bubbles/glass1.xpm @@ -0,0 +1,78 @@ +/* XPM */ +static char *glass1[] = { +/* width height ncolors chars_per_pixel */ +"10 10 61 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #29293F", +"`c c #2C2C63", +"`d c #353579", +"`e c #242447", +"`f c #222245", +"`g c #25253E", +"`h c #1C1C3F", +"`i c #2B2B47", +"`j c #252544", +"`k c #222251", +"`l c #323264", +"`m c #212146", +"`n c #37374B", +"`o c #22223D", +"`p c #252536", +"`q c #232337", +"`r c #34346C", +"`s c #303068", +"`t c #26264A", +"`u c #5D5D97", +"`v c #363674", +"`w c #2C2C6A", +"`x c #2E2E5B", +"`y c #242451", +"`z c #343464", +"a` c #3C3C6F", +"aa c #353572", +"ab c #38386B", +"ac c #242454", +"ad c #181831", +"ae c #28285B", +"af c #37377A", +"ag c #20203F", +"ah c #26265C", +"ai c #4C4C60", +"aj c #383874", +"ak c #333379", +"al c #444458", +"am c #272756", +"an c #32326E", +"ao c #30306C", +"ap c #40407F", +"aq c #292944", +"ar c #212150", +"as c #323271", +"at c #2D2D76", +"au c #21213F", +"av c #25255A", +"aw c #35356D", +"ax c #313169", +"ay c #2C2C6E", +"az c #18182C", +"b` c #232344", +"ba c #292961", +"bb c #202037", +"bc c #1C1C33", +"bd c #242452", +"be c #45456F", +"bf c #242455", +/* pixels */ +"``````aibebebeal````", +"`````n`zaw`ua``l`n``", +"```i`xab`wasaj`r`x`q", +"``auaean`daf`vao`c`t", +"```haxahayatakbaaeb`", +"``adbfav`wapao`sam`m", +"``azagaracaaae`k`fbc", +"````bb`ybd`aar`e`o``", +"```````paq`j`b`g````", +"````````````````````" +}; diff --git a/hacks/images/bubbles/glass10.xpm b/hacks/images/bubbles/glass10.xpm new file mode 100644 index 00000000..503f5f1c --- /dev/null +++ b/hacks/images/bubbles/glass10.xpm @@ -0,0 +1,256 @@ +/* XPM */ +static char *glass10[] = { +/* width height ncolors chars_per_pixel */ +"60 60 189 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #353579", +"`p c #272754", +"`q c #414188", +"`r c #20202C", +"`s c #2E2E3D", +"`t c #1C1C28", +"`u c #2E2E68", +"`v c #242447", +"`w c #2C2C66", +"`x c #222245", +"`y c #181824", +"`z c #25253E", +"a` c #161622", +"aa c #B9B9ED", +"ab c #3E3E67", +"ac c #1C1C3F", +"ad c #6767A3", +"ae c #2B2B47", +"af c #272743", +"ag c #222248", +"ah c #292931", +"ai c #29295C", +"aj c #1D1D39", +"ak c #252544", +"al c #1E1E47", +"am c #2B2B61", +"an c #29295F", +"ao c #1F1F3E", +"ap c #2F2F68", +"aq c #2D2D66", +"ar c #30305F", +"as c #2C2C5B", +"at c #11111C", +"au c #262655", +"av c #31316D", +"aw c #4C4C6D", +"ax c #222251", +"ay c #323264", +"az c #2D2D69", +"b` c #33335B", +"ba c #43436E", +"bb c #2B2B67", +"bc c #212146", +"bd c #37374B", +"be c #22223D", +"bf c #252536", +"bg c #1D1D42", +"bh c #2A2A5C", +"bi c #28285A", +"bj c #2B2B53", +"bk c #333372", +"bl c #2F2F6E", +"bm c #2B2B3F", +"bn c #2C2C36", +"bo c #424266", +"bp c #232337", +"bq c #2F2FB0", +"br c #34346C", +"bs c #525265", +"bt c #32326A", +"bu c #1B1B2F", +"bv c #3B3B55", +"bw c #303068", +"bx c #21214C", +"by c #2C2C64", +"bz c #292957", +"c` c #232351", +"ca c #26264A", +"cb c #2F2F60", +"cc c #202044", +"cd c #5D5D97", +"ce c #2B2B5C", +"cf c #363674", +"cg c #3C3C66", +"ch c #252556", +"ci c #30306E", +"cj c #3E3E54", +"ck c #414178", +"cl c #2C2C6A", +"cm c #2F2F4F", +"cn c #25252E", +"co c #27275B", +"cp c #363663", +"cq c #4C4C68", +"cr c #20204A", +"cs c #2E2E5B", +"ct c #29294C", +"cu c #242451", +"cv c #27274A", +"cw c #343464", +"cx c #4F4F64", +"cy c #252548", +"cz c #16162C", +"d` c #292938", +"da c #333384", +"db c #3C3C6F", +"dc c #353572", +"dd c #1E1E37", +"de c #38386B", +"df c #414156", +"dg c #242454", +"dh c #31316E", +"di c #181831", +"dj c #232349", +"dk c #272739", +"dl c #393979", +"dm c #4C4C85", +"dn c #2F2F83", +"do c #28285B", +"dp c #292952", +"dq c #36366C", +"dr c #48486D", +"ds c #23234C", +"dt c #37377A", +"du c #20203F", +"dv c #1E1E3D", +"dw c #26265C", +"dx c #313174", +"dy c #4C4C60", +"dz c #27273F", +"e` c #3C3C78", +"ea c #48485C", +"eb c white", +"ec c #383874", +"ed c #333379", +"ee c #444458", +"ef c #272756", +"eg c #47477C", +"eh c #32326E", +"ei c #1B1B33", +"ej c #1E1E2C", +"ek c #30306C", +"el c #40407F", +"em c #292944", +"en c #212150", +"eo c #23233E", +"ep c #141422", +"eq c #343473", +"er c #323271", +"es c #2D2D76", +"et c #2E2E6D", +"eu c #40406E", +"ev c #21213F", +"ew c #272731", +"ex c #8080BA", +"ey c #23232D", +"ez c #25255A", +"f` c #1B1B39", +"fa c #35356D", +"fb c #191937", +"fc c #262651", +"fd c #313169", +"fe c #2C2C6E", +"ff c #22224D", +"fg c #18182C", +"fh c #373786", +"fi c #2D2D65", +"fj c #232344", +"fk c #2B2B63", +"fl c #292961", +"fm c #27275F", +"fn c #202037", +"fo c #1C1C33", +"fp c #242452", +"fq c #45456F", +"fr c #484868", +"fs c #535380", +"ft c #1F1F43", +"fu c #2C2C5D", +"fv c #3535DD", +"fw c #353573", +"fx c #262657", +"fy c #393963", +"fz c #242455", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````bsbsbsbsbsbsbsbsbsbsbscxbs``````````````````````````````````````````````", +"``````````````````````````````````````````dycxdydycxawawawbsbsbsawcxcxcqdycxcxbs````````````````````````````````````````", +"````````````````````````````````````dyeacxfrawcqawfrawcqcxawcqawawawawawawfrfrcxcqeabs``````````````````````````````````", +"````````````````````````````````dfeadydyawcqawawfrcqawawdrawcqawawfqawcqcqfrawawfrdyeaeadf``````````````````````````````", +"``````````````````````````````eadyeadyfreedrboawfqfqfqdrfqeufqawbaawbabofqeufqdrcqfreeboeadf````````````````````````````", +"``````````````````````````dydffrbocjfrfrdrfrfrfqfqbabofrfqfsbaeubafqfqcgeubafqdrbaabbobobocjeedf````````````````````````", +"````````````````````````dfeeeadffyboeecgeufrfreufqeueueucgbaeubadrdbbacdbaeucgbabocpboboabboeaeebd``````````````````````", +"``````````````````````bdbdcjbd`cfyeefybaabcgfyeubaabdmfseudbdefsaackdbeudebaeudedebocgbofyfycjcjeecj````````````````````", +"````````````````````cjdfabbvb`cg`cfyfyfycgabcgdeckbrfscddecdcddmdmfsabdeeucwcpdbdbcgcgcp`cbvbvcjbvbdcj``````````````````", +"``````````````````bdbddfbv`ccgfyb`cgcgcpfycwdedbdbcdadcdexexckcd`u`uegdedbdbaycpaydecpcpb`bvfybvbdcj`s`s````````````````", +"````````````````dfbdcjbvbd`c`c`cb`cpcwcgdededqayfabrcdexdbcdcdcddeexebbrdbecdedqcwfdaycpcgarb`b`bd`cbd`sbd``````````````", +"```````````````sbdbd`n`ncmcscsarcscwcpdbbtbwbwbtbrfaebexegexaddbdeeceldqbrbrdqbtbkaybt`fbjcscpb`b``ncmctbdbd````````````", +"``````````````aebd`c`ncmcsb`cwayascsdebraybwbrfdbtazdmdeexaddladexckdedmdme`btay`lcbcscwarasfucpb`cmcmae`nbd````````````", +"`````````````saeeo`nbjcmcsarar`paycsbtcb`fbrbtfkfdciecdmdqebcdaacddmece`elbrazfabr`f`wbwbtarbzcsascsarbjbm`kbn``````````", +"``````````ewd`ae`z`c`zbjcsb`cscscwcwbrbravbtecbrfackaadmckexavciexdme`bkfabtapanbr`ffabtfdbtdpcscsbjbjdpbeae`s`s````````", +"``````````ahcm`kcm`bdparaycsay`fcscsfdbrfibwbtbrfdeqcd`qdmelbkeldmexdmeqdce`faerdcapbtbwfa`waucscscvdpdpafcmae`n````````", +"````````cncmaeakcmct`adpcsarcbcbbwdqdeapamdcehcfclbldlbldmeqeradexade`esecelehehdc`ubrbrbtfucsbhcsas`actbecmbpbpey``````", +"````````ejbpeo`vctcv`abzb`ef`ffxfucbbwapbldcdheqetesdlfwdmescfcddmdmdmbkbleldldhaq`ubrfabtcbcsbtcs`pcccycm`veobe`t``````", +"`````````rae`aajevdjdsasas`jbifiapbrbtav`uapclcfdlad`odndnfvdxededexegeceqe`e`cfbybydcbrfmcwcbfdcbbjdjca`bcv`zdd`t``````", +"``````ej`rbu`vcvcv`vcyfcbzefbz`f`uclapfderfeerclerdldlerdada`hedfhe`aacferdtcfciazapfk`ubramcbfuararbzfc`zaeaofo`t`r````", +"``````bpfodibedsdp`jcs`abwbh`lfadccidcecerclet`gfe`hdxdx`hededdt`hdaelcfereterer`wbk`ubtfdbtef`fefcb`paudpbcdiczdi`y````", +"``````ejddddemfcbjefcscs`faycedcececapciazcieqbldterdxdnbqelcdfhfv`h`oe`ererdnetfkfdekfabwbtfubifxfcar`affdpf``yepfo````", +"`````tej`ycyevcuctftbzefdoaiapaqbrbrehfw`udcfwda`oerekfhfhdxdtdaes`hbqfwcferbkehflfkekcffabwfuco`lbzcsbzftbccaevfneja```", +"````atddddem`xaocscsar`pdwdwfibwapbyapeccfdlcf`hdnfmbl`hfhdtdt`hclfvbq`qfhdxbkcfcl`gfkehfa`ufufpamaycsaydjcc`v`vfoepat``", +"````ejfgbucy`vccceaseffdfldgai`ubbfzfdazazcfblereqdt`hdnbq`hedbqfedndndte`dtdtdletfmdhehfkapapbt`mdgfubzacdp`xf`dicz`y``", +"````budddi`x`vevdpcsbzcwfxai`mapfdflfaavblercibkcffhcl`gfvfvfvdadaedclcfcfdteqecdcfkercfav`lbt`famchfdcsbe`bcaczfjbefg``", +"````a`buepccevcrdpbzbzcbfxbifdfififacfekazereretblfe`hfhbqesesdnfh`h`hbq`hfwecdldcerclavecaqaqfifxbhbzbzcv`xfjfodufnat``", +"````atepbufodualfcdp`lauauchfi`lapek`gcicieretfecl`gfhed`hesfm`gfefvfvfvdxbl`oederetfm`wdlfkfxaybzau`d`j`xduf`fgdufga```", +"`````yepddfjacccbz`benamfd`f`mfdbr`mdwcidtcfclfmfebldadneddnesdadadx`hdaededdaclflfmflfmehbyaiaydofuarasftccfjdidiei`t``", +"````a``yczczfbbcbc`bacficucraqfdanfkflaz`oehbbesbldndxfefefeesfvbqbqdnbbdtedciciazaqfkazaz`ubw`laicbas`pdjcccc`advddat``", +"````fo`yddccf`fcalcefucbcufpbi`fbyav`wazbt`ucldxed`hblescldn`hbqdndncl`gazedazazazfw`wekfzanameffucbbzbxbz`jf`fbevbuep``", +"````at`yfbaccy`a`bdsceaiffbzbichfi`manekaq`uclbkcffheletfvesfh`hesdx`qclci`gfkapap`wekapezanfzaifubxeffcfc`bdubufgepat``", +"````a`czdvf`bcdv`bffbzbicrax`fbiezcofifiekbkfk`geredeserbqdndndtadfhazcfblfecl`u`laiflaq`f`lez`ucbdgff`j`bdpccdddiepep``", +"````atczdidvaocy`v`edsbcaxdwbxfzefchameqecdlbl`gazdh`qfhaaadelesfhdaflblbkblerazapfidwbhchaqdobibzalfp`pccbgdveiczepat``", +"````a`epfoczdi`dccac`jaufzcraxaubxdwez`wfkehekbbclbkelaa`obqeleddldafkdmekfm`wfk`wfibwfidobhaiaxef`j`pdsbcacbcaodiddat``", +"``````eifgczevccfbau`jefdgffbhamaxfxezfd`w`l`odl`udcbk`wdneldtegadaaazetdlfmanan`waqfkehfifpbic``p`dbzagftao`vdifbfg````", +"``````a``yfgdv`b`v`ifcbz`b`ibwbtamfxfxfmfxekdhcfby`lciehec`wdlaverapcdecelaz`lby`lfidofiap`mcefxfp`idsagbcagajeicza`````", +"``````ata`czfbdv`vdjceasac`ibiamfian`maifxanazehave`apekehap`uege`ecazcfbkekdwfkfifiauchefbiencuftbcdvfbfof`fbdi`y`y````", +"`````````yczbudvdvdvfbcubgfcaucrbicraxfzchco`wekfke`aqflav`uaa`udm`u`w`uamfzchfmanameffpdgaidgfpaldvaoevf``zfbfgbu``````", +"````````a``tejeif`ajddajdsccbz`pbi`jfpdoanfzanbtai`f`ufkfkdq`lanebexaidcfme`fafiancodgenenbiai`pcracccf`bpddbufg`t``````", +"`````````t`yfgfgbpacaoakdubgbiauffdsenanfidoamaidgcdcoezbtecdc`mdmanbifidoanan`uapfzaxfpfpbhcecr`xbcbgbxddbufoej`t``````", +"```````````t`yfoddaodidv`i`xaleffpc`chfxamchezaichezfmfzanbwanfpcb`famfkanfxfzezcoanbifxc`ffefacbgccacf`ddddej`t````````", +"```````````tcnfobpdvbgdvbgbxftefbibxaiaudofzaxfichanfxfpfxezananfxchdgefezfzfxcuc`crdsfpcubz`jft`eeofcfbfoejfg`r````````", +"````````````eyfgbudiaoajbgdvbecrfpfpff`bffefbwaichchdgdgbhdgbjbidoaicofxfpaicubxds`afpdgas`e`vduag`z`zajdibuey``````````", +"```````````````t`rbuddeodvft`zalbccr`ec``bc`auenfp`jezchfxaidpc`fxdgfpfiamfcdgfxcvcrfcfpalcr`zbeajf`dvajbfey````````````", +"```````````````rbfbpfofbbgdvaffjfjcc`jfxbxfcc``b`bdsbiau`jc`biaibifxfpfcch`afpc``d`d`vdvfjfj`zdvajfbdvbp`tcn````````````", +"````````````````cnfnfnbpfnaoftftdj`ecuftfpaubidgfp`j`bfcfpfc`afpdgc``jfpencuc``b`j`e`vcrevdkdzewbefnfobfej``````````````", +"``````````````````bffnfnajfodvddccftaf`e`b`jdgcuai`jcv`jc`fcdj`jbxcvcvdsdsbxbxdjcr`xbxdjft`z`zddbefnbf`r````````````````", +"````````````````````d`eyewbeduak`zfjemcads`dfp`jdj`b`bcu`jcudgfpefds`bcacacvctct`dagak`xaoddbeeybpfn`r``````````````````", +"``````````````````````eyfnbpdkdz`z`zbmakfj`bag`v`dctctctctem`d`ecvctaeaeafcu`v`ecc`zakafbp`kbpewbfew````````````````````", +"````````````````````````eyeybfbpdk`zemcvcyafemakcvcvaeaeffdjcvcv`j`vae`vemaf`vagcc`z`z`zeodkbfd`ey``````````````````````", +"``````````````````````````cnbnfobe`kbe`kevemdzfj`k`z`b`edjctaeaeemds`eaf`vevdzdjafemd`dk`zbfd`ey````````````````````````", +"``````````````````````````````bncneybf`kbeaf`kememem`kcvafemakaeaeakemem`kdk`z`kbebm`zd`d`ah````````````````````````````", +"````````````````````````````````ahcnewd`dk`z`zaeaf`kaf`k`vemaedzcvakak`z`kdzd`dkdkbmbfbnah``````````````````````````````", +"````````````````````````````````````cncnbf`z`sd``s`k`z`s`zbm`s`kd`d``s`s`k`kd`ahd`bncn``````````````````````````````````", +"``````````````````````````````````````````bnd``s`s`kbnd`d`bfd``kbnbnd`bnd`ewahbn````````````````````````````````````````", +"````````````````````````````````````````````````ahbnahbnd`ewdkbfewahahewbn``````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass11.xpm b/hacks/images/bubbles/glass11.xpm new file mode 100644 index 00000000..0eb808c1 --- /dev/null +++ b/hacks/images/bubbles/glass11.xpm @@ -0,0 +1,268 @@ +/* XPM */ +static char *glass11[] = { +/* width height ncolors chars_per_pixel */ +"72 72 189 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #353579", +"`p c #272754", +"`q c #414188", +"`r c #20202C", +"`s c #2E2E3D", +"`t c #1C1C28", +"`u c #2E2E68", +"`v c #242447", +"`w c #2C2C66", +"`x c #222245", +"`y c #181824", +"`z c #25253E", +"a` c #161622", +"aa c #B9B9ED", +"ab c #3E3E67", +"ac c #1C1C3F", +"ad c #6767A3", +"ae c #2B2B47", +"af c #272743", +"ag c #222248", +"ah c #292931", +"ai c #29295C", +"aj c #1D1D39", +"ak c #252544", +"al c #1E1E47", +"am c #2B2B61", +"an c #29295F", +"ao c #1F1F3E", +"ap c #2F2F68", +"aq c #2D2D66", +"ar c #30305F", +"as c #2C2C5B", +"at c #11111C", +"au c #262655", +"av c #31316D", +"aw c #4C4C6D", +"ax c #222251", +"ay c #323264", +"az c #2D2D69", +"b` c #33335B", +"ba c #43436E", +"bb c #2B2B67", +"bc c #212146", +"bd c #37374B", +"be c #22223D", +"bf c #252536", +"bg c #1D1D42", +"bh c #2A2A5C", +"bi c #28285A", +"bj c #2B2B53", +"bk c #333372", +"bl c #2F2F6E", +"bm c #2B2B3F", +"bn c #2C2C36", +"bo c #424266", +"bp c #232337", +"bq c #2F2FB0", +"br c #34346C", +"bs c #525265", +"bt c #32326A", +"bu c #1B1B2F", +"bv c #3B3B55", +"bw c #303068", +"bx c #21214C", +"by c #2C2C64", +"bz c #292957", +"c` c #232351", +"ca c #26264A", +"cb c #2F2F60", +"cc c #202044", +"cd c #5D5D97", +"ce c #2B2B5C", +"cf c #363674", +"cg c #3C3C66", +"ch c #252556", +"ci c #30306E", +"cj c #3E3E54", +"ck c #414178", +"cl c #2C2C6A", +"cm c #2F2F4F", +"cn c #25252E", +"co c #27275B", +"cp c #363663", +"cq c #4C4C68", +"cr c #20204A", +"cs c #2E2E5B", +"ct c #29294C", +"cu c #242451", +"cv c #27274A", +"cw c #343464", +"cx c #4F4F64", +"cy c #252548", +"cz c #16162C", +"d` c #292938", +"da c #333384", +"db c #3C3C6F", +"dc c #353572", +"dd c #1E1E37", +"de c #38386B", +"df c #414156", +"dg c #242454", +"dh c #31316E", +"di c #181831", +"dj c #232349", +"dk c #272739", +"dl c #393979", +"dm c #4C4C85", +"dn c #2F2F83", +"do c #28285B", +"dp c #292952", +"dq c #36366C", +"dr c #48486D", +"ds c #23234C", +"dt c #37377A", +"du c #20203F", +"dv c #1E1E3D", +"dw c #26265C", +"dx c #313174", +"dy c #4C4C60", +"dz c #27273F", +"e` c #3C3C78", +"ea c #48485C", +"eb c white", +"ec c #383874", +"ed c #333379", +"ee c #444458", +"ef c #272756", +"eg c #47477C", +"eh c #32326E", +"ei c #1B1B33", +"ej c #1E1E2C", +"ek c #30306C", +"el c #40407F", +"em c #292944", +"en c #212150", +"eo c #23233E", +"ep c #141422", +"eq c #343473", +"er c #323271", +"es c #2D2D76", +"et c #2E2E6D", +"eu c #40406E", +"ev c #21213F", +"ew c #272731", +"ex c #8080BA", +"ey c #23232D", +"ez c #25255A", +"f` c #1B1B39", +"fa c #35356D", +"fb c #191937", +"fc c #262651", +"fd c #313169", +"fe c #2C2C6E", +"ff c #22224D", +"fg c #18182C", +"fh c #373786", +"fi c #2D2D65", +"fj c #232344", +"fk c #2B2B63", +"fl c #292961", +"fm c #27275F", +"fn c #202037", +"fo c #1C1C33", +"fp c #242452", +"fq c #45456F", +"fr c #484868", +"fs c #535380", +"ft c #1F1F43", +"fu c #2C2C5D", +"fv c #3535DD", +"fw c #353573", +"fx c #262657", +"fy c #393963", +"fz c #242455", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````bsbsbsbsbsbsdydybsbsea````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````eabsbsdybsbsbsbsbsbscqcxbsbsbsbsbscxdy````````````````````````````````````````````````````", +"````````````````````````````````````````````````dydybsbsdycqcqdycxbsbsfrcqcxdyfrcqcxcxbseacxcxbsbs``````````````````````````````````````````````", +"````````````````````````````````````````````eaeaeafrcqawawawdrdrawcxawawcqcqawawawawawbscqfrfrdycxcxea``````````````````````````````````````````", +"````````````````````````````````````````frdfcxcqawcqcqawawfrcqdrawfrawawcqawawawfqawcqawcqdrawdrfrdycqdycx``````````````````````````````````````", +"````````````````````````````````````eeeaeaeadycqdffrboboawfqfqfqdrdrfqbabadrdrdrdrbobodrdrbaawdrdyfreaeaboeeee``````````````````````````````````", +"``````````````````````````````````eeeefreeeefrbofrfrbofrfqeudrbadrfqdrfqeubabababababafqdreufqfrbafrfreeeeeacjdf````````````````````````````````", +"``````````````````````````````eecjboeebocjboboababboabdrfsfqfqbabobobafqfqawdrfqawbaeueudrdebafrbocgbobobobodfdfcjbd````````````````````````````", +"````````````````````````````dfeeeedfcjbvab`ccgfyeuabboabbabaabdbadeucgdeabbabadbegfqfqfqbaeueueubobob`bocgcgdfeacjcjcj``````````````````````````", +"``````````````````````````cjbddfcjbv`ccgdffycgfqbofyfyabdbeuabfqexbaeueudefqexadckdbbadedebaabdedeeufyboabcpfycjdfdfeecj````````````````````````", +"````````````````````````cjcjdfdfbvb`cg`cfyfyfyfycgabcgdeeudbbregexdbdbadcddmegexeucgdedbdbayfydbdbabcgfycpb`bv`cbvcjdfbdcj``````````````````````", +"``````````````````````bdbdcjbvbvfy`c`cb`cpcgfyfyfycpdededbdeegexdmaaebexckaadm`ucddbdedbdbcwcpcpfddedeb`fyb`bvfycjcmbdcj`s`s````````````````````", +"````````````````````bd`nbvbvbv`ccg`c`ccscpcwcwcgdebrcwbraydqckdbcdegegcdcdade`btdcadbrdqfabrdebrcpbwaycpfyfyb``car`n`nbdcjbnbd``````````````````", +"```````````````````n`s`n`ncj`nb`b`b`b`b`b`arcpdqfabrbrcwaybtbrexadcddbadaae`dedeexaddbdqdebrdedbdededeayb`b`cpb`b`fy`n`c`ncmbdbd````````````````", +"```````````````````n`sbdaecmcmcscscscpcscscpcwfsbwfiaqfdaybtecadexaafsexe`exckdbbtecdedqfdaycpbrekcbcsaycb`icsaycpb`b``ncm`naebd````````````````", +"`````````````````scj`c`ccmctbjcsb`cparasascsdqayaybwecbwbrbrbbe`dee`ebadegcdexadegdbcdade`ecbrbwfk`ffuarcwarcscscscpcscmcmct`nd`bd``````````````", +"```````````````s`saecv`nbjaecmasarar`parcsayfdcb`fbrbtaq`fbtciecdmdbdeebcdebcdebehece`egfabtaqecbrcbazap`fayarcsas`casbjarcmem`n`sbn````````````", +"``````````````ew`s`zcv`nevcmbjcscsbzcscwaydedqbwavfafdfadcdcckadebcke`aaehdhadebe`dcehdcbtbran`fbr`fbrfibtayaybzbjarcsb`bjbjafbm`sae````````````", +"````````````bnaeae`kcmagdjfuaycsb``ffucscsbtbwdcaqfifdfabwave`exaaadcdcddh`oecadcddmfwapdbe`fdaqbrapbtbtfdecaqbhbzarcs`adpcmaf`zcmcncn``````````", +"````````````dz`n`kctcmct`idparcwaybw`farfubrdqbr`ffdfafaecekerdcfeazeleqavdmexaddmelcibkegbrbtbkfa`uehbwfifiambzfxcscs`abjbjakctcmcm`z``````````", +"``````````ey`saf`zafbjcv`befascsfuar`ffdbrde`faq`wdcdcbkerclesdlcfdmcdblfwcdebaddmdldxercdecbkavbkapbrbtfdbt`fcbbwcbbjbzcactaebectfn`zey````````", +"``````````a`bf`zcacvdpcv`icucscsbi`fefbhar`fbr`uekbrekcierdxdxdlcieleqes`odmelelexdmcfere`eldcetaqfibwfadcapcbcscsbtcsfcccakdp`vcv`zfncn````````", +"`````````tbpaecvao`vcccydsbzcsbzffaifiekbwbtbrap`uekbber`odladdteddndnbqdxeqedeqebeleceqdtelelerbyfkavdcfiancwarbtfdcsbjdjfcbjctaebpddbpbf``````", +"````````bf`rfodpevcv`vfjcybz`idpefbhayapetblapfdciblcleqeteqeldldxdxdadadaesdadtadcdcfereqdldcekapap`wflbwayamcbbhcbasasdp`pbjakcvfjfo`y`y``````", +"````````ewdddidvdj`abzagdpcu`p`lbzambwfdbbclehdcerfeetetflfedaedbldxdadndaeddada`qdmcfeqdxdheqblfkap`waqfddq`fdgaycs`pcsefef`afjeveieifo`k``````", +"```````ybfevei`zft`afubzcsas`fam`fbwfaecdcdcdccfetbbblcieretedesed`h`heldm`qdafvdndleceqercledetaqbrapbkfaayfabwbz`fbiascs`p`j`vftf`a`epbu`t````", +"```````y`ybufnaefc`bdpcucs`pfubw`lbwbrdqdcehavfw`wcfcfereqfwercidt`hdae``qdtbqbqeddle`cfdtdxercifk`uavavecbwbw`fbz`m`mefay`jbc`d`aaobua`fg`t````", +"``````epbuddcvfjefca`bdsbzbzbhezbyaqaqbrdqehecdcfddccfeqdaedblazdtfhfhdxdtdnfednfvfvcfdtererdcehfl`wfkbkfafaap`fcefifiasasfudjbc`bcadudda``t````", +"``````a`foeoemak`adparcsarefaidwamapbwapbyazeheccfeccfdxbqesfmblesbqeldtdtbq`g`hfvbq`q`qeqerfweqclbbfmdhbwfa`ufubifxbtarcscb`b`bcv`v`vfgfgbu````", +"````atejfgfgcy`v`bbcfuasef`ffiezchco`uazezezap`uekdlererereqeddadnfvfved`ofvesesbqfvdle`dleddtdlclfmfkerbr`mapfibtbi`lbzfufuccfccvccdvfg`yfoat``", +"`````yfodiaj`v`v`x`bdpcsbzdeamamaxfkaqehfm`wav`ueteretbkbkcffhdxfednfefv`hbqdadxesfedtfwcfdtfwe`dcflcldlbkfdfibtap`fanfpayasao`idpagczfneifg`t``", +"````atfgfofgagccao`abjasbzcbfufxbibtbwfdapecdlavekerblbkeqeqdaesfedafvdndn`hfvfv`hdxeddtdtcffwdlecdhcleqehbkaqaqfkfkco`f`fayafctdjcadiajdv`yfo``", +"````atejbpczaocc`aaldpbzbzfudoen`mbtfiambtbtereretererbletetfeesbq`hfv`g`gdn`hdafhdabqfvbkbkdldlfwerclfkekecaqaqfdfidgef`b`pctccftakfoajfgbua```", +"````ata`befofoft`daldp`p`laubzambi`lby`lehfm`gavciererclfe`g`gfhdtdxed`g`gesfmdnfvfvdndnetdxedblblazfmfmapec`mfzcbarc`bzbxfcaoccftf`fgbcepfgbu``", +"`````y`yevbefjdv`xfpdp`jenbifd`lfufkfdbtazdw`merdtdtci`g`gfebledfhesdnfeesdafvededfvdaed`hdadaclflfmflezfibtbycobwfudgfuarfuds`v`xaodidia`atat``", +"````atfgaobudif`acfp`ebxacfu`fc`fxfdfdan`mdw`gaz`ocfekcletesdndxfecletesdn`h`hfvfhedclfheqfherek`gbyazfm`uaz`ubtamanfucbceaufcccccducaevfoatat``", +"````atfoejfof`fbcc`jcrbheffufualaxamfiancifkbbciehekflcleleqdadxfedn`gbq`hfvesdnblfmflbberedcletazeqazehapfm`w`lfubzcbcsbzcr`jdpacf`ftdvfn`yat``", +"````atfgbufodjfjdudp`afpfu`l`jfcbiefdoapavfkfketazbyazbldxdt`hes`hesdxdx`h`hesdndaet`gazeler`wazdhdhcidhanbxezfzchbibh`p`pfceffffcf`czfodd`yat``", +"````atatczdif``b`v`v`afffu`facfcfubidgfmcoez`lapbbap`gbbedecfhedetdaesesfv`h`qcifhfhdadletfl`wekfianfkcifk`lfkchfl`lbzcrcufc`ift`aaodddda`buat``", +"````at`tdif`dvagcycc`iff`pefcraxfz`fbianezfkap`uehfw`ufl`gcieqcderfh`hdnedeqdcfedmazdldxdl`gazaq`lfmfmdwfi`l`lan`wfdfucrc`fp`b`d`daoddbufnatat``", +"``````fga`f`dvdvcycc`xffdsdscrchezcrfzeffxezfieqecdlbkfebbcidh`qfhfhad`qelfedndadnfkblcfclcierazapaqdwaibhchaqanfxcecealfpef`x`bdvf`eiczfg`y````", +"``````at`yeiczeiajftftac`j`pfpaxalaxefbxfzch`maqfkbkerazclblbkdmdtdaaaedexfvaddafe`udmblflfkazbbazaqfiaqanbiamanaxfpbzds`pfcbcccdvftaoei`yep````", +"``````a`a`didif`f`acbxalfp`pbxax`jcefufzfzfmfmbbfifkfibkdhaveqelexfv`qcddndmcdadfeekdl`hflanfkfm`wfdfkapapbhcuefchcuau`bbz`jacccf``vdidvat`y````", +"``````a`epfoczdv`baoacefbxbzcscr`pfi`fcochchezez`mavekdcecfmfmdmfa`wdlapexcdcddmaabbazes`wfd`lan`maqaibwehapcofiauauau`befalbcdp`ddvfodieiat````", +"````````ata`difbftao`a`bbzfu`bagbzfdbrfiandoaiaifp`wekeqfw`wfkeke`apckaqelecerfkckcdfherer`ufk`wbyaqaidoanamanbzcufx`b`pbgbcbgccagdieiczep``````", +"````````at`yfgf`difbctagbzascrbcefaubififx`lananezdo`mcidhapav`uelcddcecape`dcflfaekbkeqekdwcofkfiapaidgefchbic`ffalftaldvf`bpf`fbdidia`a```````", +"````````at`yczddeiaof`dvfb`jbgccasc`crbhcrfpenchchcoanekeh`we``wfkelececaaek`qcdaqfk`ufiezdgdwfman`lbhenfzfzaifpcealcraoaodueobeajdifg`ya```````", +"``````````a`bueibueiajajddddbcbgalbzfcbh`j`pfpdoaichchavapdodmbtbyad`mfkbydweccfckaielfmbybt`l`mcodwanaxaxenbifxbzdsbxf`ftacfndkajfofgfg````````", +"``````````a``teifgbubeftdvafccbgalamef`j`dbxcofkaqcodo`famdgdeanaidqanape``me`fiaianfk`m`mbwfdapaqfzffenfpc`bhfu`pftagagft`jddddfofofga`````````", +"````````````fg`tbueibpf`dvevfbevbgfpfpcrenbxaxamfiananfkbiaxfpezezfxfkecbwbifzch`mezfiamdocochfi`lcobibibzfpfpbzcufjevccac`efgbubu`tej``````````", +"`````````````tbu`rejf`aodidvdjfcagacbzbhaxdochfxanfzfpbiaichanbychchchbt`lfzbhezcofxaiaichchaufzc`fxch`jdoffenefbgalbgbcbccceiddfo`y`r``````````", +"```````````````rejeifodvdvajacbcccccdgbibxfpdgaufuezfz`manfzanfxaufp`fcodocoezchchenauchfxchefff`jagffbxenbzbi`dftbc`edz`df`buddbudd````````````", +"```````````````y`rbuf`diaoajacbgevevcrfpfpfp`afffffc`faqfxchchfzc`dgfxdgbjfxaiaiancofxfpcodg`bffds`adgbxbzbz`e`v`vftbeev`zajf`ddei`t````````````", +"`````````````````yfoeyfbaj`zajbgevakalbxcccu`e`b`bc`efbic`axaxchfxfpezchbjfcdodochfx`fanbzcuaufxcv`bfp`pef`e`eeoeoaof`f`ajdv`rfn`r``````````````", +"``````````````````cn`rejeidvacdveoak`vccccfffpbibx`ac``jcucu`jfxbifxfpfxfxfxcodgc`aybiai`i`jch`j`a`edjagacbc`x`zfnddajf`eodvey`t````````````````", +"``````````````````eybfej`rejfoaoevcccc`v`xbcc`c`fffpbicubxcucuffc`cu`pfcfpdgbhdoaucu`jcuffbxbx`bcr`efjagbcfjeodkeodkevddfobpcney````````````````", +"````````````````````eyejbpejbpdddvaoaodjbcagbcft`jefchfxbiauc``a`ac`c`fc`afcfccufcenfp`jfffp`jdsfpftcycrbcccdz`zdkbebebfddbf`r``````````````````", +"``````````````````````cnbpeyfofofodudd`eacdjafcr`d`dcufpffef`jca`bff`jfcbxcuc`dsaecv`d`jds`dcy`vag`xagbcfteo`zbpfnbpbfej`r`r````````````````````", +"````````````````````````d`bpddbfbebgak`zfj`z`kdsdsbxffff`bdj`b`b`jcucucudgcueffp`b`bcacacvcvctct`dagcyfjccevddeoeybpd`ej`r``````````````````````", +"``````````````````````````eyddbp`r`k`z`zdzem`kfjfj`b`d`vdjcyctctcactctcv`dcr`bcvctaeaecv`b`jfjdsccakcveoakbedz`zd`ahewah````````````````````````", +"````````````````````````````ewcnbnbndd`kdzfjdzemakemae`zcv`dcaaeaecy`e`acadsag`vaeaecvakaffjcacrbcajfj`zbp`z`kfnewewcn``````````````````````````", +"```````````````````````````````rewbfbp`z`zbedzafcyakembeafctcaak`d`v`acvaeae`dff`dag`baeakfj`zcy`zbm`z`z`k`zbfd`ahcn````````````````````````````", +"```````````````````````````````````sd`eyfnbmeobm`zdz`saf`v`k`kcvbcag`bcvemaeaecvagcyaecvevafaf`zem`zd`dkbmd`bfbf````````````````````````````````", +"````````````````````````````````````ahewfoewbf`k`z`zdz`zafemememcvaf`kdz`vafaeafakemembmbpafdkdkbp`k`zbp`seyah``````````````````````````````````", +"`````````````````````````````````````````sah`zewdk`z`zdzaeaf`kemdzakakaeae`kemakemeo`z`kemdkbfbpdk`kd`d`bn``````````````````````````````````````", +"````````````````````````````````````````````ahbnbf`zd`d``sbm`kdz`sdkdk`sae`k`zbmd``k`sbmdz`kbnah`s`sbn``````````````````````````````````````````", +"````````````````````````````````````````````````bncnbmbnd`dkdkdkdkbm`sbnbnbndzd`d``sbm`sbfd`bnewah``````````````````````````````````````````````", +"``````````````````````````````````````````````````````cnd``s`s`sahd`dkbmbnbn`sbnd`bnbn`newah````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````ahcn`sbnahewbn`sewahbn````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass2.xpm b/hacks/images/bubbles/glass2.xpm new file mode 100644 index 00000000..ee236e5a --- /dev/null +++ b/hacks/images/bubbles/glass2.xpm @@ -0,0 +1,94 @@ +/* XPM */ +static char *glass2[] = { +/* width height ncolors chars_per_pixel */ +"12 12 75 2", +/* colors */ +"`` c None", +"`a c #25254C", +"`b c #23234A", +"`c c #212148", +"`d c #2E2E62", +"`e c #29293F", +"`f c #272754", +"`g c #414188", +"`h c #20202C", +"`i c #2E2E68", +"`j c #242447", +"`k c #25253E", +"`l c #B9B9ED", +"`m c #6767A3", +"`n c #2B2B47", +"`o c #29295C", +"`p c #252544", +"`q c #29295F", +"`r c #1F1F3E", +"`s c #2F2F68", +"`t c #2D2D66", +"`u c #30305F", +"`v c #4C4C6D", +"`w c #2B2B53", +"`x c #2F2F6E", +"`y c #34346C", +"`z c #3B3B55", +"a` c #303068", +"aa c #2C2C64", +"ab c #26264A", +"ac c #5D5D97", +"ad c #363674", +"ae c #3C3C66", +"af c #252556", +"ag c #30306E", +"ah c #3E3E54", +"ai c #2C2C6A", +"aj c #4C4C68", +"ak c #20204A", +"al c #2E2E5B", +"am c #343464", +"an c #16162C", +"ao c #292938", +"ap c #333384", +"aq c #3C3C6F", +"ar c #1E1E37", +"as c #38386B", +"at c #242454", +"au c #31316E", +"av c #181831", +"aw c #232349", +"ax c #272739", +"ay c #23234C", +"az c #37377A", +"b` c #1E1E3D", +"ba c #313174", +"bb c #3C3C78", +"bc c #383874", +"bd c #1B1B33", +"be c #40407F", +"bf c #292944", +"bg c #212150", +"bh c #2D2D76", +"bi c #191937", +"bj c #313169", +"bk c #22224D", +"bl c #18182C", +"bm c #2D2D65", +"bn c #232344", +"bo c #292961", +"bp c #27275F", +"bq c #242452", +"br c #484868", +"bs c #262657", +"bt c #242455", +/* pixels */ +"`````````vajajajbr``````", +"````ahaeae`yacasaq`zah``", +"`````w`f`dagacbb`y`u`u``", +"```naybm`i`mbabcaaamawar", +"``bf`ua`adbpaz`gai`ial`j", +"``bnbgbjaz`xbhapboaa`uav", +"``b`aybtbcaube`x`s`tbqbd", +"``anbiakafbb`l`i`q`o`rbl", +"`````rakbkaf`wbsay`c`k``", +"````ao`pay`aatab`bar`h``", +"````````ax`e`n`kax``````", +"````````````````````````" +}; diff --git a/hacks/images/bubbles/glass3.xpm b/hacks/images/bubbles/glass3.xpm new file mode 100644 index 00000000..e22c86cf --- /dev/null +++ b/hacks/images/bubbles/glass3.xpm @@ -0,0 +1,111 @@ +/* XPM */ +static char *glass3[] = { +/* width height ncolors chars_per_pixel */ +"14 14 90 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #383858", +"`c c #2E2E62", +"`d c #292967", +"`e c #3535A1", +"`f c #272751", +"`g c #23234D", +"`h c #29293F", +"`i c #353579", +"`j c #272754", +"`k c #20202C", +"`l c #2E2E3D", +"`m c #242447", +"`n c #25253E", +"`o c #3E3E67", +"`p c #1C1C3F", +"`q c #6767A3", +"`r c #2B2B47", +"`s c #29295C", +"`t c #2B2B61", +"`u c #29295F", +"`v c #1F1F3E", +"`w c #2F2F68", +"`x c #2D2D66", +"`y c #222251", +"`z c #2D2D69", +"a` c #33335B", +"aa c #37374B", +"ab c #22223D", +"ac c #28285A", +"ad c #2B2B53", +"ae c #2C2C36", +"af c #424266", +"ag c #232337", +"ah c #525265", +"ai c #32326A", +"aj c #1B1B2F", +"ak c #303068", +"al c #232351", +"am c #363674", +"an c #3C3C66", +"ao c #252556", +"ap c #27275B", +"aq c #363663", +"ar c #4C4C68", +"as c #2E2E5B", +"at c #29294C", +"au c #27274A", +"av c #252548", +"aw c #16162C", +"ax c #292938", +"ay c #353572", +"az c #38386B", +"b` c #4C4C85", +"ba c #2F2F83", +"bb c #20203F", +"bc c #313174", +"bd c #333379", +"be c #444458", +"bf c #272756", +"bg c #47477C", +"bh c #32326E", +"bi c #1B1B33", +"bj c #30306C", +"bk c #40407F", +"bl c #23233E", +"bm c #141422", +"bn c #343473", +"bo c #2D2D76", +"bp c #2E2E6D", +"bq c #40406E", +"br c #21213F", +"bs c #8080BA", +"bt c #25255A", +"bu c #1B1B39", +"bv c #35356D", +"bw c #262651", +"bx c #18182C", +"by c #373786", +"bz c #2B2B63", +"c` c #202037", +"ca c #1C1C33", +"cb c #242452", +"cc c #484868", +"cd c #1F1F43", +"ce c #2C2C5D", +"cf c #3535DD", +"cg c #262657", +"ch c #242455", +/* pixels */ +"``````````arccaharcc````````", +"``````bea``obqbqbqanafaa````", +"`````ladaqbv`qbsbgai`ca``b``", +"````a`a`asaib`bhb`bhakasau``", +"``c``j`c`d`dbd`eb`am`wce`aca", +"``bxasaobt`ibdbycf`iay`u`abx", +"``bl`a`t`ubnbdbocfbcbt`cbwbu", +"``bi`fch`sbhbkbabp`z`u`w`gaj", +"``bm`a`a`u`xbjaibgbzcgbf`paw", +"````agbralazap`t`ucbacbbaj``", +"`````kbrcdcbcbcgbw`y`vab`k``", +"``````axbrauatav`r`m`n`n````", +"``````````ax`h`r`nae````````", +"````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass4.xpm b/hacks/images/bubbles/glass4.xpm new file mode 100644 index 00000000..6dc1aad9 --- /dev/null +++ b/hacks/images/bubbles/glass4.xpm @@ -0,0 +1,178 @@ +/* XPM */ +static char *glass4[] = { +/* width height ncolors chars_per_pixel */ +"20 20 151 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #29293F", +"`j c #2C2C63", +"`k c #2A2A61", +"`l c #33334C", +"`m c #353579", +"`n c #272754", +"`o c #20202C", +"`p c #2E2E3D", +"`q c #2E2E68", +"`r c #242447", +"`s c #2C2C66", +"`t c #222245", +"`u c #181824", +"`v c #25253E", +"`w c #B9B9ED", +"`x c #1C1C3F", +"`y c #6767A3", +"`z c #2B2B47", +"a` c #272743", +"aa c #222248", +"ab c #292931", +"ac c #29295C", +"ad c #1D1D39", +"ae c #252544", +"af c #2B2B61", +"ag c #29295F", +"ah c #1F1F3E", +"ai c #2F2F68", +"aj c #2D2D66", +"ak c #30305F", +"al c #2C2C5B", +"am c #11111C", +"an c #262655", +"ao c #31316D", +"ap c #4C4C6D", +"aq c #222251", +"ar c #323264", +"as c #43436E", +"at c #212146", +"au c #37374B", +"av c #22223D", +"aw c #252536", +"ax c #1D1D42", +"ay c #2A2A5C", +"az c #28285A", +"b` c #2B2B53", +"ba c #333372", +"bb c #2F2F6E", +"bc c #2B2B3F", +"bd c #2C2C36", +"be c #232337", +"bf c #34346C", +"bg c #525265", +"bh c #32326A", +"bi c #303068", +"bj c #21214C", +"bk c #2C2C64", +"bl c #292957", +"bm c #232351", +"bn c #26264A", +"bo c #2F2F60", +"bp c #5D5D97", +"bq c #363674", +"br c #3C3C66", +"bs c #252556", +"bt c #30306E", +"bu c #414178", +"bv c #2C2C6A", +"bw c #20204A", +"bx c #2E2E5B", +"by c #29294C", +"bz c #242451", +"c` c #27274A", +"ca c #343464", +"cb c #4F4F64", +"cc c #252548", +"cd c #292938", +"ce c #333384", +"cf c #3C3C6F", +"cg c #353572", +"ch c #1E1E37", +"ci c #38386B", +"cj c #414156", +"ck c #242454", +"cl c #181831", +"cm c #232349", +"cn c #272739", +"co c #4C4C85", +"cp c #2F2F83", +"cq c #28285B", +"cr c #36366C", +"cs c #48486D", +"ct c #23234C", +"cu c #37377A", +"cv c #20203F", +"cw c #26265C", +"cx c #313174", +"cy c #4C4C60", +"cz c #27273F", +"d` c #3C3C78", +"da c #48485C", +"db c #383874", +"dc c #333379", +"dd c #444458", +"de c #272756", +"df c #32326E", +"dg c #1B1B33", +"dh c #1E1E2C", +"di c #30306C", +"dj c #40407F", +"dk c #292944", +"dl c #212150", +"dm c #141422", +"dn c #323271", +"do c #2D2D76", +"dp c #2E2E6D", +"dq c #21213F", +"dr c #8080BA", +"ds c #23232D", +"dt c #25255A", +"du c #35356D", +"dv c #191937", +"dw c #262651", +"dx c #313169", +"dy c #2C2C6E", +"dz c #22224D", +"e` c #18182C", +"ea c #373786", +"eb c #232344", +"ec c #2B2B63", +"ed c #292961", +"ee c #202037", +"ef c #1C1C33", +"eg c #242452", +"eh c #45456F", +"ei c #535380", +"ej c #1F1F43", +"ek c #2C2C5D", +"el c #3535DD", +"em c #262657", +"en c #393963", +"eo c #242455", +/* pixels */ +"``````````````cycyapbgcbcybg````````````", +"``````````dacycsehcsehapehcsddcj````````", +"````````au`cenbraseicibucicibrendd``````", +"``````auau`ccacidudrbpdrcfcrarakau`p````", +"`````p`lbx`nbhbfdxcobpcodjdu`sakalb`bd``", +"`````zbybxbocicgbvbbdn`ydbdfbfekbxbybe``", +"``dh`r`rbl`faidydndn`hd`dnbtecafakdwah`o", +"``dhdqejcqajdfcg`meacu`hbqdfdibi`jblbndh", +"``ch`rbxemaidudnbq`geldcbqdbdn`jafbxbnav", +"``dm`x`bdxdxcwbqdycpdocxdcbvedbkcqalebdg", +"```uccctdzbsag`qbqdpeacxbtaidiagekdwcvdm", +"``dmcl`xeoandtdfbv`wdjcediecbiaydectatch", +"``amdvcm`xaf`kagaodi`qdbbaecanazejdvdv`u", +"````e``xcvandlcqckdtcgagcq`qaqay`tbjef``", +"````dsclaxbwdzdebsckb`acegbjeg`eaaadds``", +"``````eeeeejbzanegdw`abmdl`b`rcnavaw````", +"````````eeczbc`b`dby`dbya``eae`iaw``````", +"``````````bdawa`dkc`aeae`i`i`vab````````", +"``````````````bd`pcdcdbdcdbd````````````", +"````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass5.xpm b/hacks/images/bubbles/glass5.xpm new file mode 100644 index 00000000..72aafe7e --- /dev/null +++ b/hacks/images/bubbles/glass5.xpm @@ -0,0 +1,195 @@ +/* XPM */ +static char *glass5[] = { +/* width height ncolors chars_per_pixel */ +"24 24 164 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #272754", +"`p c #414188", +"`q c #20202C", +"`r c #2E2E3D", +"`s c #1C1C28", +"`t c #2E2E68", +"`u c #242447", +"`v c #2C2C66", +"`w c #181824", +"`x c #25253E", +"`y c #161622", +"`z c #B9B9ED", +"a` c #3E3E67", +"aa c #1C1C3F", +"ab c #6767A3", +"ac c #2B2B47", +"ad c #222248", +"ae c #292931", +"af c #29295C", +"ag c #252544", +"ah c #1E1E47", +"ai c #2B2B61", +"aj c #29295F", +"ak c #1F1F3E", +"al c #2F2F68", +"am c #2D2D66", +"an c #30305F", +"ao c #2C2C5B", +"ap c #11111C", +"aq c #262655", +"ar c #31316D", +"as c #4C4C6D", +"at c #323264", +"au c #2D2D69", +"av c #33335B", +"aw c #212146", +"ax c #37374B", +"ay c #22223D", +"az c #252536", +"b` c #1D1D42", +"ba c #28285A", +"bb c #2B2B53", +"bc c #333372", +"bd c #2F2F6E", +"be c #2C2C36", +"bf c #424266", +"bg c #232337", +"bh c #2F2FB0", +"bi c #34346C", +"bj c #525265", +"bk c #32326A", +"bl c #1B1B2F", +"bm c #3B3B55", +"bn c #303068", +"bo c #21214C", +"bp c #2C2C64", +"bq c #292957", +"br c #26264A", +"bs c #202044", +"bt c #5D5D97", +"bu c #2B2B5C", +"bv c #363674", +"bw c #3C3C66", +"bx c #252556", +"by c #30306E", +"bz c #3E3E54", +"c` c #2C2C6A", +"ca c #25252E", +"cb c #27275B", +"cc c #363663", +"cd c #4C4C68", +"ce c #20204A", +"cf c #2E2E5B", +"cg c #29294C", +"ch c #242451", +"ci c #27274A", +"cj c #343464", +"ck c #252548", +"cl c #16162C", +"cm c #292938", +"cn c #333384", +"co c #3C3C6F", +"cp c #353572", +"cq c #1E1E37", +"cr c #38386B", +"cs c #414156", +"ct c #242454", +"cu c #31316E", +"cv c #181831", +"cw c #232349", +"cx c #272739", +"cy c #4C4C85", +"cz c #2F2F83", +"d` c #28285B", +"da c #292952", +"db c #48486D", +"dc c #23234C", +"dd c #37377A", +"de c #1E1E3D", +"df c #26265C", +"dg c #313174", +"dh c #4C4C60", +"di c #27273F", +"dj c #3C3C78", +"dk c #48485C", +"dl c white", +"dm c #383874", +"dn c #333379", +"do c #444458", +"dp c #272756", +"dq c #1B1B33", +"dr c #1E1E2C", +"ds c #30306C", +"dt c #40407F", +"du c #292944", +"dv c #212150", +"dw c #23233E", +"dx c #343473", +"dy c #323271", +"dz c #2D2D76", +"e` c #2E2E6D", +"ea c #40406E", +"eb c #21213F", +"ec c #8080BA", +"ed c #23232D", +"ee c #25255A", +"ef c #35356D", +"eg c #191937", +"eh c #262651", +"ei c #313169", +"ej c #2C2C6E", +"ek c #22224D", +"el c #18182C", +"em c #373786", +"en c #2D2D65", +"eo c #232344", +"ep c #2B2B63", +"eq c #292961", +"er c #27275F", +"es c #1C1C33", +"et c #242452", +"eu c #45456F", +"ev c #484868", +"ew c #1F1F43", +"ex c #2C2C5D", +"ey c #3535DD", +"ez c #262657", +"f` c #393963", +"fa c #242455", +/* pixels */ +"``````````````````dkdhbjbjbjbjdh````````````````", +"``````````````csasascdevcdascddbevdh````````````", +"``````````dodobfa`dbeubfeueueacrbfbfcsax````````", +"````````bzcsbwf`bwcrbicobteccratcof`bmbzbz``````", +"```````n`navavanefcjbibt`zcrcobicratccf``nax````", +"``````acbbao`oat`fambycobtdldjbkbialan`can`n````", +"````dicg`icj`fbi`fefdyauarabbybiefbnaicfbbcg`x``", +"````ac`udcbqenbk`tdyabczdgdxdmdtbpcpcjeicwcgcq``", +"```wdq`acfaiefcpe`bydn`hcyeydmc`ambcef`fcf`u`y`s", +"```ydudaandfbnaubvdgerbhdd`h`pdyc`cu`tezcf`b`ubl", +"``elad`abqezbndmdsbccncnczeydnbvdmdxamep`fcgcv`w", +"```weoetdv`leidfdd`gbddzdzdncncneqeebpexan`ucvap", +"``elcwdaexehd`epaubd`hdz`hcz`gdycucueeba`oekcl`w", +"``eldebsdcbxfaeedmejcuemdtcnbdbyalafambuet`bdq`w", +"```yclakboce`fbx`mcper`veccyauei`mbncbaqdpdaesap", +"````clakegbsceetbxdsdjdt`zbt`tctajdvafahakayel``", +"````eldqdeebetboenepetezbnbxencb`lbaeteoaabldr``", +"``````blakb`ceetekambxctbbafezctdcbo`eew`xcq````", +"``````ed`qakbsawekchchchetd``jboceaddwcxesed````", +"````````cmazag`xdcek`bchctetbrci`deocqbg`q``````", +"```````````qbgayckaybr`uacek`beo`x`xazca````````", +"``````````````aecxdi`kagacag`xcxcxcm````````````", +"``````````````````ca`rcmbebebeae````````````````", +"````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass6.xpm b/hacks/images/bubbles/glass6.xpm new file mode 100644 index 00000000..63b01d0a --- /dev/null +++ b/hacks/images/bubbles/glass6.xpm @@ -0,0 +1,218 @@ +/* XPM */ +static char *glass6[] = { +/* width height ncolors chars_per_pixel */ +"30 30 181 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #3535A1", +"`h c #23234D", +"`i c #29293F", +"`j c #2C2C63", +"`k c #2A2A61", +"`l c #33334C", +"`m c #353579", +"`n c #272754", +"`o c #20202C", +"`p c #2E2E3D", +"`q c #1C1C28", +"`r c #2E2E68", +"`s c #242447", +"`t c #2C2C66", +"`u c #222245", +"`v c #181824", +"`w c #25253E", +"`x c #161622", +"`y c #B9B9ED", +"`z c #3E3E67", +"a` c #1C1C3F", +"aa c #6767A3", +"ab c #2B2B47", +"ac c #272743", +"ad c #292931", +"ae c #29295C", +"af c #1D1D39", +"ag c #252544", +"ah c #1E1E47", +"ai c #2B2B61", +"aj c #29295F", +"ak c #1F1F3E", +"al c #2F2F68", +"am c #2D2D66", +"an c #30305F", +"ao c #2C2C5B", +"ap c #11111C", +"aq c #262655", +"ar c #31316D", +"as c #4C4C6D", +"at c #222251", +"au c #323264", +"av c #2D2D69", +"aw c #33335B", +"ax c #43436E", +"ay c #2B2B67", +"az c #212146", +"b` c #37374B", +"ba c #22223D", +"bb c #252536", +"bc c #1D1D42", +"bd c #28285A", +"be c #2B2B53", +"bf c #333372", +"bg c #2F2F6E", +"bh c #2C2C36", +"bi c #424266", +"bj c #232337", +"bk c #2F2FB0", +"bl c #34346C", +"bm c #525265", +"bn c #32326A", +"bo c #1B1B2F", +"bp c #3B3B55", +"bq c #303068", +"br c #21214C", +"bs c #2C2C64", +"bt c #292957", +"bu c #232351", +"bv c #26264A", +"bw c #2F2F60", +"bx c #202044", +"by c #5D5D97", +"bz c #2B2B5C", +"c` c #363674", +"ca c #3C3C66", +"cb c #252556", +"cc c #30306E", +"cd c #3E3E54", +"ce c #414178", +"cf c #2C2C6A", +"cg c #2F2F4F", +"ch c #25252E", +"ci c #27275B", +"cj c #363663", +"ck c #4C4C68", +"cl c #20204A", +"cm c #2E2E5B", +"cn c #29294C", +"co c #242451", +"cp c #27274A", +"cq c #343464", +"cr c #4F4F64", +"cs c #252548", +"ct c #16162C", +"cu c #292938", +"cv c #333384", +"cw c #3C3C6F", +"cx c #353572", +"cy c #1E1E37", +"cz c #38386B", +"d` c #414156", +"da c #242454", +"db c #31316E", +"dc c #181831", +"dd c #232349", +"de c #272739", +"df c #393979", +"dg c #4C4C85", +"dh c #2F2F83", +"di c #28285B", +"dj c #292952", +"dk c #36366C", +"dl c #48486D", +"dm c #23234C", +"dn c #37377A", +"do c #20203F", +"dp c #1E1E3D", +"dq c #26265C", +"dr c #313174", +"ds c #4C4C60", +"dt c #27273F", +"du c #3C3C78", +"dv c #48485C", +"dw c white", +"dx c #383874", +"dy c #333379", +"dz c #444458", +"e` c #272756", +"ea c #47477C", +"eb c #32326E", +"ec c #1E1E2C", +"ed c #30306C", +"ee c #40407F", +"ef c #292944", +"eg c #212150", +"eh c #23233E", +"ei c #141422", +"ej c #343473", +"ek c #323271", +"el c #2D2D76", +"em c #2E2E6D", +"en c #40406E", +"eo c #21213F", +"ep c #272731", +"eq c #8080BA", +"er c #23232D", +"es c #25255A", +"et c #1B1B39", +"eu c #35356D", +"ev c #191937", +"ew c #262651", +"ex c #313169", +"ey c #2C2C6E", +"ez c #22224D", +"f` c #18182C", +"fa c #373786", +"fb c #2D2D65", +"fc c #232344", +"fd c #2B2B63", +"fe c #292961", +"ff c #27275F", +"fg c #202037", +"fh c #1C1C33", +"fi c #242452", +"fj c #45456F", +"fk c #484868", +"fl c #535380", +"fm c #1F1F43", +"fn c #2C2C5D", +"fo c #353573", +"fp c #262657", +"fq c #393963", +"fr c #242455", +/* pixels */ +"````````````````````````bmbmbmbmbmbmbm``````````````````````", +"``````````````````dscrasasascrckasasasfkckbm````````````````", +"````````````````dsdsdzbifjfjfjfjaxaxfjfjckdzdv``````````````", +"````````````d`dvfqdzenfkfjencaendlaxaxcabibi`zdvb```````````", +"``````````cd`zaw`cfqcacaceflczbydg`zencjcwca`cbpbpcd````````", +"````````d`cdb``cawcqczdkeubycwbyczdwcwczcqaucaawb`b`b```````", +"````````b``lcmcqaoczaublbndgeqdfeqczdgbn`jcmanfnawcg`l``````", +"``````cu`w`wcmcmcqblardxeu`yceareqdueualbleuexdjcmbeba`p````", +"````chabcg`acmbwbqczaiebcfdfdgekeqdudxebcxblbncmcm`ababjer``", +"`````o`aeodmaobdalbn`rcfdf`mdhdrdyeaejdubscxffbwbwdd`b`w`q``", +"````fhbadjcmbq`jcxcxekemeydr`gdy`geeekek`t`rexe`e``ndjdcdc``", +"```q`veocnbtdialbleb`rfo`medfadnelbkc`bffeedeufn`jcmfmbvfg`x", +"``ecbo`sbze`feaeayexavbgej`gbkdyeydhdudnemdbfdal`kfna``udc`v", +"```xeieodjbtfpexfbc`avekbg`gbkelfa`g`gdxcxcfdxamfpbtcpfcdoap", +"```vcya`btegex`kbldqdncfeycvdyelcv`gdycvfefeebaedianfmfcdc`q", +"``fhcyetahfncobdbs`tbncfdybgcf`gdhcfavavav`tfraifnbtbteteoei", +"```xdpaz`bbtcl`fesfbedfdekelbkdhaaavbgcf`jfe`fesbwez`bbxdcei", +"```xfhdcbx`hfratbresfdedcfee`meedffded`t`tbqdiaee``nazazdcap", +"`````vdp`sew`bbqaifpfpdbbsccdxdfekbyee`j`jdialbzfidmazafct``", +"`````vbodpevbcaqbdatcb`tfdamar`ydg`taicbaje`dadaahaketevbo``", +"`````qf`bjakdobdezegfbaidacibncxdgbddiajalatfibz`ubccyfh`q``", +"``````chbjbcbcfmbdaediatcbfpfpajfpdaesfpbudmco`h`eewfhf`````", +"`````````ocydp`waz`e`baqfiesfpdjfpfiaidacpewah`wafdpbb``````", +"````````chfgfgfmddcofibdfi`bfi`ada`hegbu`h`seodtbafhec``````", +"``````````cuepdo`wefdmfidd`b`hdae``bbvcn`dagakbabj`o````````", +"````````````erbbdeefcsefcpabezcp`habef`sbx`wehbber``````````", +"````````````````chbbba`ief`iacagabef`i`wba`wcu``````````````", +"``````````````````chbb`p`p`w`w`pcu`p`icucuch````````````````", +"````````````````````````adadcudeepadbh``````````````````````", +"````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass7.xpm b/hacks/images/bubbles/glass7.xpm new file mode 100644 index 00000000..750c2514 --- /dev/null +++ b/hacks/images/bubbles/glass7.xpm @@ -0,0 +1,230 @@ +/* XPM */ +static char *glass7[] = { +/* width height ncolors chars_per_pixel */ +"36 36 187 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #353579", +"`p c #272754", +"`q c #414188", +"`r c #20202C", +"`s c #2E2E3D", +"`t c #1C1C28", +"`u c #2E2E68", +"`v c #242447", +"`w c #2C2C66", +"`x c #222245", +"`y c #181824", +"`z c #25253E", +"a` c #161622", +"aa c #B9B9ED", +"ab c #3E3E67", +"ac c #1C1C3F", +"ad c #6767A3", +"ae c #2B2B47", +"af c #272743", +"ag c #222248", +"ah c #292931", +"ai c #29295C", +"aj c #1D1D39", +"ak c #252544", +"al c #1E1E47", +"am c #2B2B61", +"an c #29295F", +"ao c #1F1F3E", +"ap c #2F2F68", +"aq c #2D2D66", +"ar c #30305F", +"as c #2C2C5B", +"at c #11111C", +"au c #262655", +"av c #31316D", +"aw c #4C4C6D", +"ax c #222251", +"ay c #323264", +"az c #2D2D69", +"b` c #33335B", +"ba c #43436E", +"bb c #2B2B67", +"bc c #212146", +"bd c #37374B", +"be c #22223D", +"bf c #252536", +"bg c #1D1D42", +"bh c #2A2A5C", +"bi c #28285A", +"bj c #2B2B53", +"bk c #333372", +"bl c #2F2F6E", +"bm c #2B2B3F", +"bn c #2C2C36", +"bo c #424266", +"bp c #232337", +"bq c #2F2FB0", +"br c #34346C", +"bs c #525265", +"bt c #32326A", +"bu c #1B1B2F", +"bv c #3B3B55", +"bw c #303068", +"bx c #21214C", +"by c #2C2C64", +"bz c #292957", +"c` c #232351", +"ca c #26264A", +"cb c #2F2F60", +"cc c #202044", +"cd c #5D5D97", +"ce c #2B2B5C", +"cf c #363674", +"cg c #3C3C66", +"ch c #252556", +"ci c #30306E", +"cj c #3E3E54", +"ck c #414178", +"cl c #2C2C6A", +"cm c #2F2F4F", +"cn c #25252E", +"co c #27275B", +"cp c #363663", +"cq c #4C4C68", +"cr c #20204A", +"cs c #2E2E5B", +"ct c #29294C", +"cu c #242451", +"cv c #27274A", +"cw c #343464", +"cx c #4F4F64", +"cy c #252548", +"cz c #16162C", +"d` c #292938", +"da c #333384", +"db c #3C3C6F", +"dc c #353572", +"dd c #1E1E37", +"de c #38386B", +"df c #414156", +"dg c #242454", +"dh c #31316E", +"di c #181831", +"dj c #232349", +"dk c #272739", +"dl c #393979", +"dm c #4C4C85", +"dn c #2F2F83", +"do c #28285B", +"dp c #292952", +"dq c #48486D", +"dr c #23234C", +"ds c #37377A", +"dt c #1E1E3D", +"du c #26265C", +"dv c #313174", +"dw c #4C4C60", +"dx c #27273F", +"dy c #3C3C78", +"dz c #48485C", +"e` c white", +"ea c #383874", +"eb c #333379", +"ec c #444458", +"ed c #272756", +"ee c #47477C", +"ef c #32326E", +"eg c #1B1B33", +"eh c #1E1E2C", +"ei c #30306C", +"ej c #40407F", +"ek c #292944", +"el c #212150", +"em c #23233E", +"en c #141422", +"eo c #343473", +"ep c #323271", +"eq c #2D2D76", +"er c #2E2E6D", +"es c #40406E", +"et c #21213F", +"eu c #272731", +"ev c #8080BA", +"ew c #23232D", +"ex c #25255A", +"ey c #1B1B39", +"ez c #35356D", +"f` c #191937", +"fa c #262651", +"fb c #313169", +"fc c #2C2C6E", +"fd c #22224D", +"fe c #18182C", +"ff c #373786", +"fg c #2D2D65", +"fh c #232344", +"fi c #2B2B63", +"fj c #292961", +"fk c #27275F", +"fl c #202037", +"fm c #1C1C33", +"fn c #242452", +"fo c #45456F", +"fp c #484868", +"fq c #535380", +"fr c #1F1F43", +"fs c #2C2C5D", +"ft c #3535DD", +"fu c #353573", +"fv c #262657", +"fw c #393963", +"fx c #242455", +/* pixels */ +"````````````````````````````````bsbsbsdwbs``````````````````````````````", +"````````````````````````dwbsdwcqcxbscqdwcqcxdzcxbs``````````````````````", +"````````````````````fpcxawcqawcqawawcqawfocqcqawfpcqcx``````````````````", +"``````````````````ececfpfpbofodqdqdqesbababadqfobafpeccj````````````````", +"``````````````dfeccjabcgesbobaabadcgabbaeefobaesbob`cgdfcjcj````````````", +"````````````cjdfbvcgfwfwcgcgesbrevdbcdeeesdedbfwdbcgcpbvbvdfcj``````````", +"``````````bdbvbvcg`ccpcwdecwayckcdeecddydcbrezdecpayfwb`ar`ncjbd````````", +"```````````saecmcscpcscwbwaqayeaevfqdyckbtdefbcpeicscbcscpb`cmae````````", +"`````````scvbjcmar`pcsfb`fbt`fcidmdecdcdefdyezaqbraz`farasasarek`s``````", +"``````bnaecmdjayb`fscsbwaqfbbwdyaacddheacdfudbfbbrbtfbaqbzcsdpafcmcn````", +"```````s`zbj`basfs`fbr`f`wdcepeqcfcdfue`dmdvcdbkbkbrfb`fbwbjcaaect`z````", +"`````taeaoccdrcsfdfgbwbr`ubb`oadebdndvebe`eadsejbyavfgcwbtcsdjbjaeddbf``", +"````eudidjbzdp`pbzbwbbefeperfjdabldadada`qcfdveofi`wfb`fay`ped`aeteg`k``", +"`````yflfadpcsfs`lbrdcav`wcfeoepdsda`qbqebdydsepfiaveabwbz`maybc`abufe``", +"````fmek`aararaiambwbyefcfcfbqfkeqejds`gft`qeofuclfkbw`ubibtcs`bcv`vfe``", +"```ydi`v`xdpbzamaxaqfkavererbkfffcfc`hdaeqdscffudcclbkfgapanayaodpczeg`t", +"``atbpao`adpbzdo`mfgbtepereperfcbqft`g`hffbqbkdlfucleiaqfbdg`bctfrfmfea`", +"```yetfh`xdpelfbfsfbaz`mdsci`gblffdneqftebda`hdafjfjfgbybwdgardr`xdia`at", +"``ateheycccredfsaxfgcibbeffjejdafc`g`heqblfjepclazazap`wfscbbz`jacfrflat", +"``atczey`v`afsacfsdgco`lbb`gebffereqft`qffdaer`wfgfifififjbzcu`i`adda`at", +"````a`dtcy`xdrcrexfxfvfgeabkbbdhffadejdndnblclepapdubhaqfvcefn`xdtegfe``", +"````a`dieybxfnbx`jfsfxfkfgfgdheoev`qdncdfcdlfjfi`wfiapcuchaubzaceydiat``", +"````atdifr`abz`bbzbranaifneifufidyckejepckffepfibyaianancu`bbgbgagegen``", +"````atczegeyf`bgascrcrelchanefdyfieaaa`qaq`uexduanbhfxaicecraoemajfea```", +"```````tfebedtccaled`dcoaqdoamdeaiandydyaifi`mfbaqfdfnbh`pagfrddfmfe````", +"```````t`reydidjagbzaxchanfnaianchch`lbhcoaichauc`chdoelbgbgbcegfm`r````", +"`````````reyaoacetcrfn`afd`ffvchc`fvbjaianfvco`bdrdgbz`e`vbe`zeyeg``````", +"```````````regacem`vccfnbxc`cu`jbifnfvcoc`bi`ich`adjac`xflajemew````````", +"``````````ewbpbpdtaobcbc`jchbic``ac``afafafnfd`jfncybcdxdkbedd`r````````", +"````````````d`ddbeakfh`kdrfd`b`b`jcudged`bcacvct`dcyccddewd``r``````````", +"``````````````eubndddxdxakaecvcaae`ecaagaecvafcabcfhbp`keucn````````````", +"``````````````````d`flem`z`s`v`kbc`bekaeagaeetafekd`bmbf````````````````", +"`````````````````````s`zdk`zae`kdxakaeekek`zekbfdkd`bn``````````````````", +"````````````````````````bnbmd`dkdk`sbndxd`bmbfbnah``````````````````````", +"````````````````````````````````cnbneu`sah``````````````````````````````", +"````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass8.xpm b/hacks/images/bubbles/glass8.xpm new file mode 100644 index 00000000..0fcd41b7 --- /dev/null +++ b/hacks/images/bubbles/glass8.xpm @@ -0,0 +1,240 @@ +/* XPM */ +static char *glass8[] = { +/* width height ncolors chars_per_pixel */ +"44 44 189 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #353579", +"`p c #272754", +"`q c #414188", +"`r c #20202C", +"`s c #2E2E3D", +"`t c #1C1C28", +"`u c #2E2E68", +"`v c #242447", +"`w c #2C2C66", +"`x c #222245", +"`y c #181824", +"`z c #25253E", +"a` c #161622", +"aa c #B9B9ED", +"ab c #3E3E67", +"ac c #1C1C3F", +"ad c #6767A3", +"ae c #2B2B47", +"af c #272743", +"ag c #222248", +"ah c #292931", +"ai c #29295C", +"aj c #1D1D39", +"ak c #252544", +"al c #1E1E47", +"am c #2B2B61", +"an c #29295F", +"ao c #1F1F3E", +"ap c #2F2F68", +"aq c #2D2D66", +"ar c #30305F", +"as c #2C2C5B", +"at c #11111C", +"au c #262655", +"av c #31316D", +"aw c #4C4C6D", +"ax c #222251", +"ay c #323264", +"az c #2D2D69", +"b` c #33335B", +"ba c #43436E", +"bb c #2B2B67", +"bc c #212146", +"bd c #37374B", +"be c #22223D", +"bf c #252536", +"bg c #1D1D42", +"bh c #2A2A5C", +"bi c #28285A", +"bj c #2B2B53", +"bk c #333372", +"bl c #2F2F6E", +"bm c #2B2B3F", +"bn c #2C2C36", +"bo c #424266", +"bp c #232337", +"bq c #2F2FB0", +"br c #34346C", +"bs c #525265", +"bt c #32326A", +"bu c #1B1B2F", +"bv c #3B3B55", +"bw c #303068", +"bx c #21214C", +"by c #2C2C64", +"bz c #292957", +"c` c #232351", +"ca c #26264A", +"cb c #2F2F60", +"cc c #202044", +"cd c #5D5D97", +"ce c #2B2B5C", +"cf c #363674", +"cg c #3C3C66", +"ch c #252556", +"ci c #30306E", +"cj c #3E3E54", +"ck c #414178", +"cl c #2C2C6A", +"cm c #2F2F4F", +"cn c #25252E", +"co c #27275B", +"cp c #363663", +"cq c #4C4C68", +"cr c #20204A", +"cs c #2E2E5B", +"ct c #29294C", +"cu c #242451", +"cv c #27274A", +"cw c #343464", +"cx c #4F4F64", +"cy c #252548", +"cz c #16162C", +"d` c #292938", +"da c #333384", +"db c #3C3C6F", +"dc c #353572", +"dd c #1E1E37", +"de c #38386B", +"df c #414156", +"dg c #242454", +"dh c #31316E", +"di c #181831", +"dj c #232349", +"dk c #272739", +"dl c #393979", +"dm c #4C4C85", +"dn c #2F2F83", +"do c #28285B", +"dp c #292952", +"dq c #36366C", +"dr c #48486D", +"ds c #23234C", +"dt c #37377A", +"du c #20203F", +"dv c #1E1E3D", +"dw c #26265C", +"dx c #313174", +"dy c #4C4C60", +"dz c #27273F", +"e` c #3C3C78", +"ea c #48485C", +"eb c white", +"ec c #383874", +"ed c #333379", +"ee c #444458", +"ef c #272756", +"eg c #47477C", +"eh c #32326E", +"ei c #1B1B33", +"ej c #1E1E2C", +"ek c #30306C", +"el c #40407F", +"em c #292944", +"en c #212150", +"eo c #23233E", +"ep c #141422", +"eq c #343473", +"er c #323271", +"es c #2D2D76", +"et c #2E2E6D", +"eu c #40406E", +"ev c #21213F", +"ew c #272731", +"ex c #8080BA", +"ey c #23232D", +"ez c #25255A", +"f` c #1B1B39", +"fa c #35356D", +"fb c #191937", +"fc c #262651", +"fd c #313169", +"fe c #2C2C6E", +"ff c #22224D", +"fg c #18182C", +"fh c #373786", +"fi c #2D2D65", +"fj c #232344", +"fk c #2B2B63", +"fl c #292961", +"fm c #27275F", +"fn c #202037", +"fo c #1C1C33", +"fp c #242452", +"fq c #45456F", +"fr c #484868", +"fs c #535380", +"ft c #1F1F43", +"fu c #2C2C5D", +"fv c #3535DD", +"fw c #353573", +"fx c #262657", +"fy c #393963", +"fz c #242455", +/* pixels */ +"````````````````````````````````````````````bs``````````````````````````````````````````", +"````````````````````````````````dybseabsawbsbscxawcxbsdybs``````````````````````````````", +"````````````````````````````eedycqcqcqdrcxawcqawawawawfrfrcxcq``````````````````````````", +"````````````````````````eadyfrdybafrfqawawfqdrawawfrfrdrawcqeaeeee``````````````````````", +"````````````````````eeeebofrboawbofqdrbadrfqeufqfqbababafqfrbobobocjee``````````````````", +"``````````````````dfeebvfybvcgbaboeueueueuababfqdefqegeuabeufybocgdfeacj````````````````", +"````````````````bvbo`nfydffybocgcgdedbegfsfqeuegexeudbdqdedbdeabfybvcjdfcj``````````````", +"``````````````bdcjbvfyfyb`defyfydedbckexexebckdmaqdbdbdbayaydeaycpbvab`ccjbd````````````", +"`````````````s`ccjb`b`b`b`ardededeaydcexadckaddbdbaadqdqbrbtbrayb`cpb``c`ccm`n``````````", +"```````````n`n`ncmcsb`cpascpegfi`ucwbrcdcdebehaddbbrdmfaayaqcbb`arcscs`ccmb`ae`s````````", +"``````````aeafcmaeasfu`paraycbbtfd`lavecckegcdcdaaec`qfa`ufa`f`ubwarbzb`cscs`kbm````````", +"````````ewaectfjbzcsb`arcwbtdcapec`fdcaadmcd`ueqaddmekecav`fapbtecbwdparbjcmaoct`n``````", +"````````bddzcmbjdparcscb`fdbfdfidcdlcieqbbdlciebexeletegbwbk`ubtbwfufucsdpcm`zctbm``````", +"```````ycmdjdpctauaramefcsbwapehekereddleledcfdmdmdmerelecaqaqbrehcbbzarfc`vbjcyem`r````", +"``````bpaobefjccbzasenbw`ufafdblcl`oeldldnbqededdtcdbkdldlet`lekamcbbw`fbjauctdp`zfn````", +"`````yfoaj`bbzeodsfibhbrekavcfcletfldneddxeddadtdadmbkerercleh`ubwbwcbbzarbhdpfjdiei`t``", +"````atfoemfcdpbzasfi`ffadcekbkazeqerbkerdadtdmfhbqdldleddxfkfdapdcfdfcam`pbz`e`ifoepa```", +"````a`dd`v`bbzbjefdw`lbwbtehdceccf`hfeerbqfhedesbqfvdlcifwcifldhbrficbficsefcc`v`xajbp``", +"````fnfgeo`vfubzbwdwco`ufm`m`ucfbler`ofh`hfveddndnbqdldldtcffmbkbwapbwaiefaybgctczfgei``", +"`````yczacaodpbjayfxcobwapbkehdhblerdtdnfe`hbqfhbqfedtcfeqecaqeqbwfiapanbhbr`zdjbcaofo``", +"````atczf``bbzbzbhax`laqbwaqdhciblfeclfhfhdafmbqdabqdacidldtdhflcf`wby`fauef`vccakev`y``", +"``ata`fnagccbzenbhfiaifdehezdhdlet`geteddnbqesfvedbqesdndabbfmfmbtbyamfufuasbcccdidiepat", +"````fgfgao`dbg`e`falcobwfkfmdh`o`gcidnesdn`gdabqed`geteretblekazfk`u`fdocb`j`abgf`ev`y``", +"`````yeicv`v`b`pamfcbhfxfidwetazazdx`q`heted`qfveder`get`wciekehchcodgbhffefeffcczbu`y``", +"````epdvfjfj`acubzenanbifxbyaqci`w`gereleddnesehdnazdxbkcl`wfmfm`f`lfmayenau`bfceidia```", +"`````ybuev`xcc`j`pfzaxau`jezekcferblcifhfhdmdmdldtfmblekdhekaq`fbififzbzftbidudvdifgbu``", +"````atfgfoaobgal`pc`auamaxcoekapdcfwaqe`edeldnele`ekelfm`manapaqficubi`pdjfcacf`bgdvep``", +"`````ya`f`ag`bdpasbcfubraibifmfmdhcfanekdcdmdtdhflexblcifkbyfiaifian`pau`pagbgbceicza```", +"``````epdif`dubcefbgauenaxfmco`f`mecekfied`uavexfkbbaqfmdwanapcubifxffbgacftbef`di`y````", +"``````a`czbuf`ddddbcfffcfcdgdoancofdezbwecfkap`wehaifmbtfiandwaxenbibzagf`ccbpaj`t`y````", +"`````````yfoeyaceoevenfpffbx`mam`mbifpdwchapehaicocoamaibibtezfxdgfxeffjccfpeiddfg``````", +"````````ej`rdidvaobzalbzfp`mauchfpfkezfkau`f`fdechchchfzbic`axbxfpauff`ebg`pejej`t``````", +"```````````tf`f`ajal`zcrfpendsffaycochfzdgfzbjcoancofpdo`ben`affce`edjbcbebef`di````````", +"```````````t`rf`dvaoeobcdu`ece`bfpencucofxbic`auc`dgficuef`bbxffbg`ebedddvaobfew````````", +"````````````cnejbpaodvftdj`jcr`pcoen`j`jcu`ifcbifx`jc``jen`bbx`vccbe`z`zddddcn``````````", +"``````````````ewbpddfbddaccycr`dfp`jfpca`jcu`dc`cacv`dff`d`d`x`dft`z`zbeejcn````````````", +"````````````````fgfneoduembmfj`vag`act`bds`ac``j`j`acv`bbcagak`xdudvbpcn`t``````````````", +"``````````````````ewd`fnaeakemcyaecvdjaeaecrcvdsakaeakafcy`jao`zfnd`cn`t````````````````", +"````````````````````d`dkfndzd``zbm`v`k`b`ecvemaeca`vaedudz`zafew`kbfey``````````````````", +"````````````````````````bfdkd`dz`kafdzae`vemcyafakakaedzdzbed`dkcn``````````````````````", +"````````````````````````````ahdkbnbnbm`z`sdk`s`zd`bm`safd`bn`s``````````````````````````", +"````````````````````````````````bnbn`sd`d`dk`sbmbnah`s`sah``````````````````````````````", +"````````````````````````````````````````````cn``````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/glass9.xpm b/hacks/images/bubbles/glass9.xpm new file mode 100644 index 00000000..9e3ac20a --- /dev/null +++ b/hacks/images/bubbles/glass9.xpm @@ -0,0 +1,245 @@ +/* XPM */ +static char *glass9[] = { +/* width height ncolors chars_per_pixel */ +"50 50 188 2", +/* colors */ +"`` c None", +"`a c #27274E", +"`b c #25254C", +"`c c #383858", +"`d c #23234A", +"`e c #212148", +"`f c #2E2E62", +"`g c #292967", +"`h c #3535A1", +"`i c #272751", +"`j c #23234D", +"`k c #29293F", +"`l c #2C2C63", +"`m c #2A2A61", +"`n c #33334C", +"`o c #353579", +"`p c #272754", +"`q c #414188", +"`r c #20202C", +"`s c #2E2E3D", +"`t c #1C1C28", +"`u c #2E2E68", +"`v c #242447", +"`w c #2C2C66", +"`x c #222245", +"`y c #181824", +"`z c #25253E", +"a` c #161622", +"aa c #B9B9ED", +"ab c #3E3E67", +"ac c #1C1C3F", +"ad c #6767A3", +"ae c #2B2B47", +"af c #272743", +"ag c #222248", +"ah c #292931", +"ai c #29295C", +"aj c #1D1D39", +"ak c #252544", +"al c #1E1E47", +"am c #2B2B61", +"an c #29295F", +"ao c #1F1F3E", +"ap c #2F2F68", +"aq c #2D2D66", +"ar c #30305F", +"as c #2C2C5B", +"at c #11111C", +"au c #262655", +"av c #31316D", +"aw c #4C4C6D", +"ax c #222251", +"ay c #323264", +"az c #2D2D69", +"b` c #33335B", +"ba c #43436E", +"bb c #2B2B67", +"bc c #212146", +"bd c #37374B", +"be c #22223D", +"bf c #252536", +"bg c #1D1D42", +"bh c #2A2A5C", +"bi c #28285A", +"bj c #2B2B53", +"bk c #333372", +"bl c #2F2F6E", +"bm c #2B2B3F", +"bn c #2C2C36", +"bo c #424266", +"bp c #232337", +"bq c #2F2FB0", +"br c #34346C", +"bs c #525265", +"bt c #32326A", +"bu c #1B1B2F", +"bv c #3B3B55", +"bw c #303068", +"bx c #21214C", +"by c #292957", +"bz c #232351", +"c` c #26264A", +"ca c #2F2F60", +"cb c #202044", +"cc c #5D5D97", +"cd c #2B2B5C", +"ce c #363674", +"cf c #3C3C66", +"cg c #252556", +"ch c #30306E", +"ci c #3E3E54", +"cj c #414178", +"ck c #2C2C6A", +"cl c #2F2F4F", +"cm c #25252E", +"cn c #27275B", +"co c #363663", +"cp c #4C4C68", +"cq c #20204A", +"cr c #2E2E5B", +"cs c #29294C", +"ct c #242451", +"cu c #27274A", +"cv c #343464", +"cw c #4F4F64", +"cx c #252548", +"cy c #16162C", +"cz c #292938", +"d` c #333384", +"da c #3C3C6F", +"db c #353572", +"dc c #1E1E37", +"dd c #38386B", +"de c #414156", +"df c #242454", +"dg c #31316E", +"dh c #181831", +"di c #232349", +"dj c #272739", +"dk c #393979", +"dl c #4C4C85", +"dm c #2F2F83", +"dn c #28285B", +"do c #292952", +"dp c #36366C", +"dq c #48486D", +"dr c #23234C", +"ds c #37377A", +"dt c #20203F", +"du c #1E1E3D", +"dv c #26265C", +"dw c #313174", +"dx c #4C4C60", +"dy c #27273F", +"dz c #3C3C78", +"e` c #48485C", +"ea c white", +"eb c #383874", +"ec c #333379", +"ed c #444458", +"ee c #272756", +"ef c #47477C", +"eg c #32326E", +"eh c #1B1B33", +"ei c #1E1E2C", +"ej c #30306C", +"ek c #40407F", +"el c #292944", +"em c #212150", +"en c #23233E", +"eo c #141422", +"ep c #343473", +"eq c #323271", +"er c #2D2D76", +"es c #2E2E6D", +"et c #40406E", +"eu c #21213F", +"ev c #272731", +"ew c #8080BA", +"ex c #23232D", +"ey c #25255A", +"ez c #1B1B39", +"f` c #35356D", +"fa c #191937", +"fb c #262651", +"fc c #313169", +"fd c #2C2C6E", +"fe c #22224D", +"ff c #18182C", +"fg c #373786", +"fh c #2D2D65", +"fi c #232344", +"fj c #2B2B63", +"fk c #292961", +"fl c #27275F", +"fm c #202037", +"fn c #1C1C33", +"fo c #242452", +"fp c #45456F", +"fq c #484868", +"fr c #535380", +"fs c #1F1F43", +"ft c #2C2C5D", +"fu c #3535DD", +"fv c #353573", +"fw c #262657", +"fx c #393963", +"fy c #242455", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````e`bscwbscwbsbsbsbsbsbsbscw````````````````````````````````````", +"````````````````````````````````bse`bscpbse`awawcwbsbsdqawawbsdxdxcwcw``````````````````````````````", +"````````````````````````````e`eddxfqcwcpfqfqawawdqawdqawawfqcwawawfqfqe`cw``````````````````````````", +"````````````````````````cie`e`dxfqboboawfpfpdqfpbafpawfpdqbofpabdqfqfqedcfdee```````````````````````", +"``````````````````````edede`cifqbodqabfpfpbabobaccbabafpbaddbaetfpfqabbobobodee`````````````````````", +"````````````````````deedbvbvfxfxcfetboetfpcfewetddetetdaefetbaetabetbofxabcfedcici``````````````````", +"``````````````````bdedbd`cabdefxababfxddetddcccjefbacjeaetddddcfdpdaddababb``cdeedde````````````````", +"````````````````bvbdbvfx`cb`fxcfcffxdddaddefccaaeaefewbwdldadaddcoayddcvcfb``cbvbdbvci``````````````", +"```````````````s`cbvbdb`b`b`cocvdddaddayf`braadlfrccdldzewdddaebddfcbwayfxcfb``cbd`cbd`s````````````", +"````````````bd`sclclbjb`crb`arcofr`ubtbtfcdkaaewewdlcjdabtdabtcvddebayaycadoarb``c`n`ncl`s``````````", +"``````````bdbv`c`ccub`b`b`ascrdp`fcadzaqbwfjebcjeaccewaaccdlfrdlegbw`f`lcab`crcrcrclclelbpbd````````", +"``````````bnbmcuclclcrb``pararcv`ff`fcegf`dzewcjcjeqdleabkavf`fc`mbrcaegfcaycabjararcrae`sbm````````", +"````````evaedycragcacvb`apcrasbwf``faybtavekewaddleqdkccccdkbrdzfcavapbrfhf`biascac`bjcuel`kbf``````", +"````````aeae`vcldo`acrcacr`fbtddaqapebceckbleqdzdseqaaadekdwebdkavceapbrbt`fftamcrbybjaeclbpbp``````", +"```````rfnbeakdocubzarfw`faiarbraqegejbkcheqeqekd``oefekewdzchekbkaqfhbtbkapcrcacr`j`vdocbbpfn`t````", +"``````cz`zdoakbccbbyasdr`fap`uf`fcejck`obkdl`odmfudwecdwaadzbkdzdbaz`legaqftar`fcadofbdobjafdccm````", +"``````bfehdc`aeefifbftaiambw`gavbkblck`gckd`eqecec`hfgd`addsepbkfvfkapazavf`fw`fbycrcd`a`vehbubp````", +"`````tbuehdyfbasdocaapayayebebbteq`geqchfvdwecbqdkaddsfudwdzbkckdwfjbrapf`bwf`byfwbyasdr`iezbucy`t``", +"`````yfnfieu`bdi`abydn`mfcf`f`egdbavdbec`odwcefgecdsd`dmbqepceeqf`az`wejdbbrambi`lcdft`bcbc``va`ei``", +"````a`eoenfifsaycrbyfl`mfc`uan`webceebdmer`gdwbqdsdsdmdmbqekdkeccechckfkejegfhbiftarby`a`v`vfiffbu``", +"````fmcycxdidt`iardpdnemanavflejazeqesepcefgblerfud`fgfderfgdkdsdkdzfkeqbkapapbt`lctfceuas`vcydhfn``", +"````ehdheudtagbybjcabidnapapfcebejblchcheqer`hbqbqerbqfufgecdsebcedkbkbleqf`fjambicaaycu`vcxa`du`y``", +"````fnfndhdtbgdobybifocnbwameqckdgeqeqfdesfdfgfgdwflfddmfufudwch`odschflejebdvayby`pee`vcbacfndcbu``", +"````bube`vacfe`iembyfc`f`ufc`wdveqdkeqflfddwfudm`her`hd`fgbqecd`ecbbflfkfjapdvbwdnftas`jfifieh`yeo``", +"````ffehdhdhdrcqalft`jembtai`wfkdg`obbesbldmfddm`gecfud`dmbbdw`ochbl`ufkap`weganaiar`j`j`ddu`adhff``", +"````ffdcdrdtbj`a`pfhfebibh`legfkesapaqeq`obqbqfddkfu`hd`dwfkchdw`wcheq`ufjemfyaucdby`peectduezdhbu``", +"`````tfadhag`v`iee`fcqfweefleyanaqfjazazebfg`g`qfu`hadcher`q`h`gazdwaibbap`lfw`waybxct`aagcbeueofn``", +"````eoa`ffcbfididr`eaxeybzbhcgaqepdlbkckazeqds`qfueqfdblefeqdzchdg`wfheyamey`laibyalbiagdraodheheo``", +"````at`ydhdh`dfsal`pfyalfyemeyey`waqdgazckepbkdw`qekepecfjdmejflazfj`ubw`lbiftaxee`beecbcbbcdu`ta```", +"````a`a`a`ficbalcqeeauct`fcgdffyflejapds`wefdleradewegaaegeseqbr`lfl`u`megamamctfb`vfebc`deudceoat``", +"``````eofffacb`abyftcbbybtfcanfwaidvapepap`wegazdzdlek`uerfgepdgfj`laqdncn`mbyfoct`p`vbgacezdhbu````", +"```````yffdhfsficbeealbybxbiemcncnamflch`u`uccew`udgdlf``wdldbcgflanbweefycnaxeeacezfsdyfmdh`y`t````", +"```````teoeiezajdcdc`ealeeai`jaxaiamcgavaiew`ucc`w`mandzanebflfcamfldvbiemdffw`pfeezcbdcbpeh`yeo````", +"`````````tfffffmaoakdtalamfbdremfjamaiaidffraiddegdbfhancnbrdn`mamegfwaxfocgftct`x`efeezeifn`t``````", +"````````ex`tehbeezdubydialcdaxcnbidndfbhfwbweydf`mandfcgdvananfyfofycncgcnaxfoacbg`e`pfadueiex``````", +"```````````rbufndcajacfscbbycqfofodnaifhfyai`paxcnfweyddcg`pcgfwfofedifeaxbyalfs`j`kduehfmfm````````", +"```````````yeifndhbefsao`vaxbxbxcsfebyfwbzfybidfcgbjfwaidnambibybzbx`afocdbc`vfidtezajbueha`````````", +"`````````````y`r`rezduaocxficb`jfw`abz`jct`jdnfwbzfwdnaufofofw`afo`i`ddiducb`zdudcezdu`rex``````````", +"``````````````evbudjfmajcbagbcctbcfwcgaufoct`afofb`afodf`jbzemfobx`dfe`val`xczdjbebpdccm````````````", +"````````````````evcmezfneufsaoelcqcxctfeaufecsfectbxbzfeae`b`jdrc``b`x`ecb`zbpfmfmeiev``````````````", +"``````````````````ffbubpfiafafbmbc`vag`bc`csdr`j`bct`jfefbcxcx`j`xdificxacbeenbfev`t````````````````", +"````````````````````cmczczdy`zak`kcucucudrcuaecxc`cxdrcxaeelak`vc``jajakbpafbfbf`r``````````````````", +"``````````````````````cmczbpdjdc`kcxelaoelakagbc`aaeel`bbxakakeu`zdtbm`zdjbpevbf````````````````````", +"````````````````````````cmbfeibfbmeuel`kelelafelelakaeelaf`k`k`zdjbebm`zbncmah``````````````````````", +"````````````````````````````czbnczbp`zafbmaedyafelbmdy`zdybeczdjczbf`kbpex``````````````````````````", +"`````````````````````````````````sevdjbncz`zdj`sczcz`k`k`s`sdjbfahevbn``````````````````````````````", +"``````````````````````````````````````evah`sbncz`kev`sbnczbnczah````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade.pov b/hacks/images/bubbles/jade.pov new file mode 100644 index 00000000..7c1cb023 --- /dev/null +++ b/hacks/images/bubbles/jade.pov @@ -0,0 +1,24 @@ +#include "colors.inc" +#include "shapes.inc" +#include "textures.inc" + +/* The following make the field of view as wide as it is high + * Thus, you should have the -W and -H command line options + * equal to each other. */ +camera { + location <5.8, 0, 0> + up <0, 1, 0> + right <1, 0, 0> + look_at <0, 0, 0> +} + +sphere { + <0,0,0>, 2.5 + texture { Jade + scale <0.7, 0.7, 0.7> + rotate y*clock } + finish { phong 0.4 } +} + +light_source {<6, 1, 0> color White} +light_source {<6.1, 1, 0> color White} diff --git a/hacks/images/bubbles/jade1.xpm b/hacks/images/bubbles/jade1.xpm new file mode 100644 index 00000000..2a13045e --- /dev/null +++ b/hacks/images/bubbles/jade1.xpm @@ -0,0 +1,75 @@ +/* XPM */ +static char *jade1[] = { +/* width height ncolors chars_per_pixel */ +"10 10 58 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #149914", +"`d c #179317", +"`e c #158B15", +"`f c #148914", +"`g c #148514", +"`h c #0F890F", +"`i c #0D830D", +"`j c #0F730F", +"`k c #0F6F0F", +"`l c #0E6B0E", +"`m c #077307", +"`n c #0E630E", +"`o c #0B630B", +"`p c #026502", +"`q c #046104", +"`r c #0A550A", +"`s c #0B530B", +"`t c #065306", +"`u c #054F05", +"`v c #074B07", +"`w c #064706", +"`x c #003700", +"`y c #042B04", +"`z c #011901", +"a` c #21B621", +"aa c #1AAC1A", +"ab c #18A818", +"ac c #17A217", +"ad c #189E18", +"ae c #127C12", +"af c #107C10", +"ag c #0F7A0F", +"ah c #0B800B", +"ai c #0E720E", +"aj c #0A760A", +"ak c #106A10", +"al c #0F6A0F", +"am c #0A6E0A", +"an c #0B620B", +"ao c #0D580D", +"ap c #076007", +"aq c #045E04", +"ar c #015E01", +"as c #015201", +"at c #034803", +"au c #044604", +"av c #083E08", +"aw c #014601", +"ax c #044004", +"ay c #063606", +"az c #052E05", +"b` c #013401", +"ba c #042404", +"bb c #002600", +"bc c #022002", +/* pixels */ +"```````v`l`g`k`v````", +"````an`gad`cajaqal``", +"``az`f`hahah`parapao", +"```wagac`m`aa`aa`o`x", +"``ak`d`qai`babau`e`w", +"``b`aeafat`u`ias`j`s", +"``bc`n`kafam`jaw`xay", +"````avaxau`t`r`n`z``", +"```````ybbavazba````", +"````````````````````" +}; diff --git a/hacks/images/bubbles/jade10.xpm b/hacks/images/bubbles/jade10.xpm new file mode 100644 index 00000000..e601fecf --- /dev/null +++ b/hacks/images/bubbles/jade10.xpm @@ -0,0 +1,259 @@ +/* XPM */ +static char *jade10[] = { +/* width height ncolors chars_per_pixel */ +"60 60 192 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #016101", +"ax c #0C4F0C", +"ay c #0A510A", +"az c #025B02", +"b` c #094F09", +"ba c #045704", +"bb c #0A4D0A", +"bc c #065306", +"bd c #0A4B0A", +"be c #065106", +"bf c #015901", +"bg c #074D07", +"bh c #054F05", +"bi c #074B07", +"bj c #084908", +"bk c #094709", +"bl c #084508", +"bm c #064706", +"bn c #014F01", +"bo c #004B00", +"bp c #063D06", +"bq c #063B06", +"br c #073907", +"bs c #033D03", +"bt c #004100", +"bu c #013F01", +"bv c #033B03", +"bw c #053505", +"bx c #003D00", +"by c #063306", +"bz c #053105", +"c` c #023502", +"ca c #003700", +"cb c #042B04", +"cc c #042904", +"cd c #012301", +"ce c #022102", +"cf c #011D01", +"cg c #021B02", +"ch c #011901", +"ci c #011701", +"cj c #011501", +"ck c #011301", +"cl c #010D01", +"cm c #21B621", +"cn c #1CB41C", +"co c #22AA22", +"cp c #1AAC1A", +"cq c #18A818", +"cr c #1F9C1F", +"cs c white", +"ct c #18A418", +"cu c #17A217", +"cv c #189E18", +"cw c #189A18", +"cx c #149C14", +"cy c #149014", +"cz c #119011", +"d` c #128A12", +"da c #0F8C0F", +"db c #128612", +"dc c #148214", +"dd c #138013", +"de c #127E12", +"df c #127C12", +"dg c #107C10", +"dh c #0F7A0F", +"di c #0B800B", +"dj c #0E780E", +"dk c #0B7C0B", +"dl c #117211", +"dm c #0A7A0A", +"dn c #0E720E", +"do c #0A780A", +"dp c #0A760A", +"dq c #106A10", +"dr c #0B720B", +"ds c #0F6A0F", +"dt c #0A700A", +"du c #0A6E0A", +"dv c #0B6C0B", +"dw c #0A6A0A", +"dx c #0B680B", +"dy c #067006", +"dz c #0C660C", +"e` c #0A660A", +"ea c #056E05", +"eb c #056C05", +"ec c #0B620B", +"ed c #0C600C", +"ee c #0D5E0D", +"ef c #056A05", +"eg c #066806", +"eh c #076407", +"ei c #0D580D", +"ej c #0A5C0A", +"ek c #076007", +"el c #046404", +"em c #0A5A0A", +"en c #075A07", +"eo c #085808", +"ep c #045E04", +"eq c #095409", +"er c #015E01", +"es c #055605", +"et c #055405", +"eu c #015601", +"ev c #015401", +"ew c #035003", +"ex c #015201", +"ey c #034C03", +"ez c #034A03", +"f` c #B1FFB1", +"fa c #074207", +"fb c #034803", +"fc c #044604", +"fd c #074007", +"fe c #083E08", +"ff c #014601", +"fg c #024402", +"fh c #034203", +"fi c #044004", +"fj c #053805", +"fk c #063606", +"fl c #013A01", +"fm c #023802", +"fn c #052E05", +"fo c #013401", +"fp c #013201", +"fq c #042C04", +"fr c #013001", +"fs c #012E01", +"ft c #012C01", +"fu c #042604", +"fv c #012A01", +"fw c #022802", +"fx c #042404", +"fy c #002600", +"fz c #022002", +"g` c #011E01", +"ga c #001000", +"gb c #000A00", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````fwbdftaxbdbqavfjc`bkfvfycc``````````````````````````````````````````````", +"``````````````````````````````````````````fnfjbpfaeefofrftaqbubifhbdbmfibkanfdfj````````````````````````````````````````", +"````````````````````````````````````byfvfofidqaldqdqafa`a`bcfraoagafbubcbianeifafdfrce``````````````````````````````````", +"````````````````````````````````byfraybjalfrbxfga`aidlenenffbsb`fffbeyddecaqbedlcafpbpbdby``````````````````````````````", +"``````````````````````````````feeianbiezagbtakeyah`rdedge`bo`sfobndfffenafesffembsbubib`fofk````````````````````````````", +"``````````````````````````bybqbjbmbxeqejenendde`addh`oadafbibobnbmboekbabne`dxffeyeybeagdqaqbkfq````````````````````````", +"````````````````````````fwftaneebuedamaoenabdhdb`q`qdr`q`iaiejagbf`qcabaflbaekdgdceteoejbeayavfabz``````````````````````", +"``````````````````````fkbqfialdsbtetdv`uduad`qdrdpcw`o`zazafcwcy`qdnevdpekcyahaeenar`rfrakakfdfifafw````````````````````", +"````````````````````brbpb`emaafia``rdg`i`o`zcw`zdjcwct`w`oe`dodpaodnduelegexbfamaoaubaemakfgeyfybibqfv``````````````````", +"``````````````````fec`bbaledfma`af`saddj`uehdbcv`ed`aj`fcpdp`madegerbx`oeldpd`d`dt`sev`rboa`dlafcacabkfw````````````````", +"````````````````fwbkaydqecb`dcdv`rdc`scwexdp`g`ecvawdxdber`y`hctdiawdgfbdpduegcy`pdwepbodfenemaldsbmbmbqfn``````````````", +"``````````````cffafralfjc`dnecaqaddb`x`zevatdp`vacfgeyerelfgetda`fdyaw`u`n`pdmd`cwdbexeqboa`ffeta`affhfmbzfn````````````", +"``````````````fwfmeeemedaadca`eoepdrcvcvegeuebdoajefdhcncmeyetdicndocye`as`tcp`f`vcw`eeuaiflewaiffdldlayeife````````````", +"````````````feavfieeaaeyfr`sdeexdwcvcu`meldk`fct`dcudidyamcyar`ycuct`tesdvea`eefdodp`e`peubearbobibhageeb`fvcd``````````", +"``````````fxcdbdandlffesboek`xemdb`pdkbfel`k`dcncpajcmefewdjapdmefea`f`jcz`h`hdycydtd`cwegepfcfmdfaragemalbdbkch````````", +"``````````fwbqbjakagenewencyad`gdrazeraccucpcpcncu`zdharap`kasdo`ndiap`k`dcuajcncpcwepdkcycydtdgdwafdlbcedeeblcc````````", +"````````fxfrfnayeqbceyes`qekatexfldu`tcpdo`y`hcudiades`hewdmdicp`ccn`wapasaw`ges`xbherbxdbcy`idbekdlesa`dqaleibwcg``````", +"````````fnfpeefhfbafalbodeehdwdder`p`e`yaddodicndkefcqcxdacq`c`d`ccz`h`eescme`drene`eaelfhegegdwedalewagauemavaxcc``````", +"````````brbzakeebceyfcek`o`odhbief`k`ediapajcncx`fdict`ccucqcncm`ccx`tdr`ed`ardyebdpazegdgcvateoekaeenagedakeifdg```````", +"``````cebdeieeala`alewekdrdrdbegeg`k`fcpdacmctdid`czczcn`ddacucm`c`cajasdmdmawdyea`fczacazcvexfgbnaraba`ameoeiblfech````", +"``````byfjfadqfgauej`redaebnex`m`f`vczcxcpdadaawea`neadp`e`r`lcrcmcvdyefcncxajcydydyczdicwepcacabsbaabdea`ezb`bbbwfw````", +"``````cdfebdakfgezet`s`u`z`uepeg`fcpctcpcqcq`teydmczdpa`coco`b`baacm`rdicmcn`jef`majascpdjbf`o`gemfhdddfddeobibsfefw````", +"````cjbwfsbmbmbubh`rbodhdh`iegctefcwcucucncpcpdhaj`yabco`b`a`a`a`a`lcodpcmcqczdicp`ecpcvdb`efgehambmabdxaiemcabkbqfqga``", +"````g`blblfifhdqbcfiba`qdhcw`xfbcwefacdydacncqeacmd`co`b`af`f`f``acocrcwcq`ccxeaef`merajegbxe`a``iba`renecemdqeibrchcc``", +"````fxbqbdaneefgecffeydu`q`i`iepcpame`awdkcpcpar`ycm`b`a`af`f`f``a`b`l`e`ccn`jasdieady`pacatahcabuai`rewecfgdlcabqbqby``", +"````cibkaxfianfafgffaie`cycwcvefelajdbbtawcz`jaw`t`e`b`a`af`csf``a`b`ldh`w`nasap`yczdpcw`kacahbcboba`odnbhbualalc`brg```", +"````g`bkavbvb`bceebvetewekdh`xd`dp`kaccycydocncvdacvco`b`af`f`f``a`bcralapef`fcy`w`ycz`gcw`zazdb`qe``r`rfgfcdqakcdfefn``", +"````fnfybqanfhbebhafenew`ibadu`wdp`k`wfbapdacparczcm`c`b`b`a`a`acocraed`cucpcpdoer`ydpdp`m`mcy`xbadca`dfdfecauavfafycc``", +"````fzfvfdaudqbgecbcenbo`iaeeueheuelatefczcncuacdncu`cco`lcr`b`b`l`lcrczcq`wdkcpdpdhfcflducweh`i`oabdcdlemeqbmaqeichfn``", +"````cbfrfjblfcagbxbha`dnarbobnehdxfbaz`kcv`fda`een`jcn`ddvdldlaecrdraoczcq`f`y`d`ndoac`eelcydhadardv`rdlejeqavbjbbbyfu``", +"````fxbrbqbsfifhaifbah`oddduehdgcyeoeg`gcucvajdv`t`e`hcpdmcm`d`vajeo`ddy`n`ecx`dcv`f`meu`e`g`z`g`qdcahaheyedb`fmbdcdfx``", +"````fncdfkbdb`bmafezdn`rdedn`xdueubu`o`ycw`fdidj`hcpct`deaen`udk`j`yefelebcz`dcpd``fac`edcbnex`i`sa`aea`beemaufpbwfuch``", +"````cjfnfteib`c`ejecaoa`ad`idbbaeuaideazdkcv`pazdp`d`d`tdyasefcucn`fdibfbfcwdoct`p`wdpeuexameh`o`sendcaialakalc`bkfecf``", +"````ckceftaxbsaqaldlejagde`uehepepbgexeg`e`wacerbfdmdi`dasapdpcvcpcueben`tdpfcdtdpdwdtekbcfidcada`aeabagakakaqbqfwbyfz``", +"````clg`bzfafoblemdldzdfdfecfiexbnfcdg`icvegd`eufbat`ierct`ubhat`wdydvcp`y`kacfbelegexfibgexbodxaeabaabhfcayavfdcgfzck``", +"``````fxfwbdfdfjfceedldzamboeqbebmbebhcvducy`gdregeuegdkaccyer`eaceladdgel`x`zevazcveoezboboe``raiddaibgfdfdbvbdcjfx````", +"``````fxcdblfafofjbgdlbcbcaufrbsfidlexeu`q`icv`g`kcwcw`gcwegcwdeeodedhfgbu`iexatdudrbnbobadddgaeffbhaoeeakbdbrbdcjfz````", +"``````ckfzfqfabpbjcaedakemakeya`abewdjardjcydbehdwdreg`ictdbdrdebu`gcteldwabepdu`i`xdgdr`re`dveyalb`anaubzfofwfyfnck````", +"````````g`cccfbpbjfmbiaifceeakfieddcekdg`q`s`gdgdudrdrcwcvcvcweuflembudh`udtdv`gdwendne`ekesbtedaqavflflbdblbdcdch``````", +"````````fzcecfbpcbfiaveeaufbeebheyetewdddn`u`q`i`odb`i`gcwcvdjehdgbgepdudwep`udjbafffhagedaaedafbmdqflc`fjfncdcfcg``````", +"````````clcffzblcdbvfobsaldlbsecabddaf`odne`esbadgdr`x`o`ocwdudbdgekehbaaeeqdj`rdga`ffafbheoaadlcaftbdfmbkfzfkfxgb``````", +"``````````fxcbfkfsc`frbmeibic`bedlabdzdcaeareyfiardvdnduaddge`dg`sduehboa`eje``r`rendleoaiaaaiakavfifnftfkfkcecj````````", +"``````````gbfxfnfebpeibveiakflanfgejafdldxetbob`ardvdedv`o`oabene`dxekbnboaodfaebebibca`eqeqakdqeebsfqfvfwfwfxcl````````", +"````````````clfxcdfkbwfwanbjavflfaafeya`agafeyddarah`se`aedeababdxenaoewdn`samdldsbcafejaibgdqalaqc`fqbrg`ceci``````````", +"``````````````fxfubybkfsfjanayaubibubxdldsaidzaodfabafaoe`a`dddxe`fbewe`aea`anbcaodzagdqeedqaqeiaxftbwfwcech````````````", +"``````````````gbfucgbzfebybpeieeaqfhdqeeakeqaiemdsdzeoaidcezecbhaidzeoemafecb`aaakagaqayaqb`blbkbdblfkcffzgb````````````", +"````````````````gbcgfxbyfefjaxeieeayfiflfrbjeebxfcdsbxezagbxbcememeyaobhaubcbeakedaqalb`eiblavfrchccfzfzcj``````````````", +"``````````````````clcgcjccbwaxavfaaqeeeib`fiblaybiemfgfhblblbdfcfhembeemdlbbdqaueianfableibdfrfvcbcccccj````````````````", +"````````````````````gbfubzfnbrbkbpc`fpbpbvfjcafhakayavakflbmakbdbidqeefccabiakavbvfrbqblblfefqcbbzfxcj``````````````````", +"``````````````````````gbcgcgg`fwfefvbkbdaxfmanfpalaycafaaudqalfob`bifmaxaqaneibdfrbqbkbkfeccbybyfxck````````````````````", +"````````````````````````clcgcgfnfwfqfvfabwc`bqeiblbsfeavbvbsfrbvanbbfabzeiblc`bwbwbpfafeccg`fxfxcl``````````````````````", +"``````````````````````````gbckchcfccbrbyfkbdfjbkfabpbrfkcdbveiaxaxbbfafdbwfefvfvfwbrfefkcffzcgcl````````````````````````", +"``````````````````````````````gagafzcbfnbrfkfkfyfybzfebkbdbdfefefvbkfubzfnfnbzfebrfqfxfxcgck````````````````````````````", +"````````````````````````````````gbclckfxfnbyfnfwfwbzfqfkfqcdfnfqchfucgbrccfnfwfncccjcgcjgb``````````````````````````````", +"````````````````````````````````````clclcjcjcjckgaccfxcdcdcecicfcgfzcgcefufncefzckclgb``````````````````````````````````", +"``````````````````````````````````````````clgacjcjcgcjcjcjgachcjfzcgfzfxfzckgacl````````````````````````````````````````", +"````````````````````````````````````````````````clgbclckckcjcigackgaclgbgb``````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade11.xpm b/hacks/images/bubbles/jade11.xpm new file mode 100644 index 00000000..a556fe25 --- /dev/null +++ b/hacks/images/bubbles/jade11.xpm @@ -0,0 +1,271 @@ +/* XPM */ +static char *jade11[] = { +/* width height ncolors chars_per_pixel */ +"72 72 192 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #016101", +"ax c #0C4F0C", +"ay c #0A510A", +"az c #025B02", +"b` c #094F09", +"ba c #045704", +"bb c #0A4D0A", +"bc c #065306", +"bd c #0A4B0A", +"be c #065106", +"bf c #015901", +"bg c #074D07", +"bh c #054F05", +"bi c #074B07", +"bj c #084908", +"bk c #094709", +"bl c #084508", +"bm c #064706", +"bn c #014F01", +"bo c #004B00", +"bp c #063D06", +"bq c #063B06", +"br c #073907", +"bs c #033D03", +"bt c #004100", +"bu c #013F01", +"bv c #033B03", +"bw c #053505", +"bx c #003D00", +"by c #063306", +"bz c #053105", +"c` c #023502", +"ca c #003700", +"cb c #042B04", +"cc c #042904", +"cd c #012301", +"ce c #022102", +"cf c #011D01", +"cg c #021B02", +"ch c #011901", +"ci c #011701", +"cj c #011501", +"ck c #011301", +"cl c #010D01", +"cm c #21B621", +"cn c #1CB41C", +"co c #22AA22", +"cp c #1AAC1A", +"cq c #18A818", +"cr c #1F9C1F", +"cs c white", +"ct c #18A418", +"cu c #17A217", +"cv c #189E18", +"cw c #189A18", +"cx c #149C14", +"cy c #149014", +"cz c #119011", +"d` c #128A12", +"da c #0F8C0F", +"db c #128612", +"dc c #148214", +"dd c #138013", +"de c #127E12", +"df c #127C12", +"dg c #107C10", +"dh c #0F7A0F", +"di c #0B800B", +"dj c #0E780E", +"dk c #0B7C0B", +"dl c #117211", +"dm c #0A7A0A", +"dn c #0E720E", +"do c #0A780A", +"dp c #0A760A", +"dq c #106A10", +"dr c #0B720B", +"ds c #0F6A0F", +"dt c #0A700A", +"du c #0A6E0A", +"dv c #0B6C0B", +"dw c #0A6A0A", +"dx c #0B680B", +"dy c #067006", +"dz c #0C660C", +"e` c #0A660A", +"ea c #056E05", +"eb c #056C05", +"ec c #0B620B", +"ed c #0C600C", +"ee c #0D5E0D", +"ef c #056A05", +"eg c #066806", +"eh c #076407", +"ei c #0D580D", +"ej c #0A5C0A", +"ek c #076007", +"el c #046404", +"em c #0A5A0A", +"en c #075A07", +"eo c #085808", +"ep c #045E04", +"eq c #095409", +"er c #015E01", +"es c #055605", +"et c #055405", +"eu c #015601", +"ev c #015401", +"ew c #035003", +"ex c #015201", +"ey c #034C03", +"ez c #034A03", +"f` c #B1FFB1", +"fa c #074207", +"fb c #034803", +"fc c #044604", +"fd c #074007", +"fe c #083E08", +"ff c #014601", +"fg c #024402", +"fh c #034203", +"fi c #044004", +"fj c #053805", +"fk c #063606", +"fl c #013A01", +"fm c #023802", +"fn c #052E05", +"fo c #013401", +"fp c #013201", +"fq c #042C04", +"fr c #013001", +"fs c #012E01", +"ft c #012C01", +"fu c #042604", +"fv c #012A01", +"fw c #022802", +"fx c #042404", +"fy c #002600", +"fz c #022002", +"g` c #011E01", +"ga c #001000", +"gb c #000A00", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````brfebwfabdfafvbwbqfqbr````````````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````feblaxfnfofjbkfaaqeibmfiavblavblbdbwfk````````````````````````````````````````````````````", +"````````````````````````````````````````````````fnfrftfpbjalavfcdqfjbmakedagafakbmfcaqbsfyanavaxbz``````````````````````````````````````````````", +"````````````````````````````````````````````ftbqfmbjanakalaldldlaaafemaqbtfbafagdlfhflbufvalbpfwc`frft``````````````````````````````````````````", +"````````````````````````````````````````fvbdbdbmalfyb`bhfgdqaianeydzesa`bsbvdlbheyesddafbjezaufhcaakbwbbbl``````````````````````````````````````", +"````````````````````````````````````cebkanalbgbmedfbfsfbbeah`rdcdf`samdlbncaewbofh`raraeaeaveoejfdfcbmavanfkcb``````````````````````````````````", +"``````````````````````````````````bravayfcbialaaeoa`eyesecdvdedxdnen`oedfcaieobedle`ekabarambjemfmbifbdqdqanfabz````````````````````````````````", +"``````````````````````````````fwfaaxfmeefyejemaoamenewardv`qcydbdbadafafepexemfhex`oca`oenad`odndcddddaaafdqeefafvfk````````````````````````````", +"````````````````````````````fqftayfidqb`eoecetarde`i`i`g`o`u`idb`idpdgdgdzejexatepafeudfbhddevdnabaoc`anbcfgbubdaycdfk``````````````````````````", +"``````````````````````````fkbdcabldqaiafece`dg`idrad`q`uegdr`id``xegad`qategfgfh`ieudtdu`gflaoahewbafi`sftaybxbubbfifqfy````````````````````````", +"````````````````````````brbdbsaueqdlfiaeddaedg`i`o`x`o`mdudpcwcwcyege``xdodperdnbfegelegevbfbnejaobibaekfffffgeyfhanbvfjfv``````````````````````", +"``````````````````````fefacaakeqalaudcah`r`idg`q`xdudrcv`m`e`tdk`k`ed`erarcyeneabfameudteg`wdbdbdudeedevaoewfibtbxfleeavaxfe````````````````````", +"````````````````````ccblfadqaqeoeedcecewbofoa`ddbiegac`ecpcydpbfatap`yctcpdkefdp`dbce`ategeg`v`i`iduekbaaien`rbiauejbgfab`fjfn``````````````````", +"``````````````````ccbkavfiembeaiaedfbnbndtdu`zdoeueldpcw`n`h`xeren`z`derelda`ddkd`erbx`y`pacac`gctdjepfcafba`saqffecaabgfvbqbwci````````````````", +"``````````````````fxeifmakbxalbtahffbodj`u`xcycyazbfebdpajapdgaodhapcnaddvapcpcucnasaodk`k`pcycp`kctdtbffhfobnfretendlafbmfefwbr````````````````", +"````````````````fwblfoanakdzeyaoekboemeudjcyct`gdycwebacdmacdpcn`uascwekdrajcpczdy`edxd``wct`dd`dk`gctdhdeaedlba`oaibtdldqakbkfvfy``````````````", +"``````````````ccfyfdeiemaabhejekdudgexatcycv`gd`eldpcv`jcpcqcudidyawe``uardmczcp`f`wesdhcn`nczegdodtcw`wdjexbebabnflfraoagedakbzfjfn````````````", +"``````````````fefdbmaldlbhbtfme`dgdjbidrcy`mdo`ibf`n`dcncn`daj`z`eetd`ezapdmajeadkcndadi`w`e`tbferaj`wcwd`dubafcdc`rdvaoaieqdqbbfdfe````````````", +"````````````cebzblayakdsbcbcboardhdjexd`docvfger`h`dcncpcn`fas`kapasaw`p`dehapasawad`w`d`d`f`tap`ecpajdk`mdj`zbaendgabdedlbcdqanayblg```````````", +"````````````brbpavauedamdzeye``oadepadatcweb`pcu`f`hcq`fcm`yeydjcue`cvas`m`ycucncxdoawasea`wapad`ueycyesdrcwcw`o`q`iesdxafecauananfafe``````````", +"``````````cfbwfjeebmbeeoagff`se`ehexep`sdpcy`dcxerajdmdacpeaeyapead``ddacxcq`c`c`j`yasdrasd`ffdv`ddjer`oendp`z`xadddboaiesdlafdqanbdfece````````", +"``````````fefaanfceqeoaiaia``odrehegdxafac`f`ddp`qdoeacpcueaefcxcpcqcxcp`c`d`ccu`j`jcyewdvenffdrbtaoeldybfeyepegbabaembseya`ememakavaxfq````````", +"````````fzccbzeeeqeebhbtfcba`rcyd`djbieucy`ecvajapdo`f`ndabtdicx`ccn`jcqcncn`ccn`w`wdr`fcmd``udyebdobfajeffccvepeuepbobnendcejemalavfdcech``````", +"````````fnfabdanakbefgbteybadhdh`x`geueu`tcu`e`hdkcp`dcudyasdacxcu`c`j`p`fcp`ccmcqebaseaajeaad`wajcx`kdodmahaz`odzbnboehdnabahecdqbmbkfvfz``````", +"````````ccbdfaaledfbaqdcbnbna`bueoegct`pcy`y`fcpcq`f`hczenaj`tdida`d`i`r`r`e`ccm`feb`k`ncqdaaraserdoda`ydyddeladeccafoe`a`dddfedbmdqeifdfn``````", +"``````fxfvfrfaakbmfbauezfmboekdrepeodr`ecv`hcxctcncudiea`mdm`fdicmcrcrcr`bcrcr`r`z`rea`dcncxdo`eapebaj`yazeyelamde`ibiboa``ra`dlflbiaybqfyg`````", +"``````fxfac`bbakbxfbbheneodedb`z`zexbfd`cv`ectcncncqcueaasaj`wdj`bcoco`bcr`a`a`l`raadicm`ccnczaw`zapapctdveoazfgeuafeoejdgabaea`bmfcbzfqfvch````", +"``````cbbqbjfib`bubiejbmetdv`zdjcvepcyeaacct`d`ncncncndmareaaca`cr`b`a`a`a`a`bcr`leiaccmcpcqdidk`ednbfey`eeueubuatepezaiabaedzembgfpbdbrfvcd````", +"``````fnbweifibgbufaeyagba`q`u`icwdrfbdjerdy`tajdacmcqcxawapd`co`b`a`af`f`f``a`bcrcocwcu`ccn`yefefcucnerdyegbxahfhem`iev`rendzemfbbkeiblccfw````", +"````cgg`bdbdalb`ezfgamffewdh`i`g`od`euazbeafbfapdicqcn`wbh`wcm`b`b`af`f`csf`f``a`b`bcocn`ccp`tcndmapajdy`wdpazfl`ubueoae`sesecaobheeeifrbqfyck``", +"````fzbybkanbmeeflbtejffewen`gcw`i`idpelbfe`ad`meaczcmeaaj`jco`b`a`af`f`f`f`f``a`acrdbcvcpczdyasdi`ydy`tcv`pdpflbhexddekdddxeoemeqeqaufwaxfecg``", +"````cgbrfjanbseqbuftftemffendu`ucw`o`zebacd`efcpenajcqdyaj`pcv`c`a`af`f`f`f``a`a`ldq`celawardhefdk`k`f`k`md`dudcbnehenardc`sbhfgejaleefaaxfqfx``", +"````cgbzftbdfobdembeaieqekbaexdjepdhcyacd``edpbt`mdm`najdo`j`eco`b`b`a`af``a`a`bcocrdudy`naccpd``wdo`h`gcvcvdpegdhdb`ie`dddcaheyfcakaqfdfjfqch``", +"````g`cbfqfwfmbueqbcbhfaenaragbobaduacdudk`kelardydacx`j`p`hcm`c`b`bco`a`a`a`b`b`ldj`p`ncq`f`j`ycydpdpazeg`pcw`g`zbnekdcdeabdlagakayavayfafefz``", +"````ccbzftbpauakaueyaoeyenewboam`iepehbfeuegafdycz`dcu`najascu`c`ccr`lcr`b`bcr`lcrducz`fcxdi`tcndp`dbxenecdocwduepa`badddcaiaiagfhfhaqanfkfecc``", +"````fxbrfrfdbdbiakbcbcetabafbaboageuepdzeodnat`h`hcu`kdias`q`ncn`cdbafa`aa`ccobdegeb`n`fcpdmcz`d`jdpaceadnegcvdhduekesdx`sabaiecfcbkavaxfkfqfx``", +"````cibzftfdfofibiafa`eydd`rdvdvepepdu`iev`odk`e`e`ncxefaodk`hctcucvegcmegdbdw`o`idwajczcq`kcp`dcv`n`vcyezazehcy`qdb`uaddxaheoaub`bsfmbkbzbyfx``", +"````cjfqbrc`fabmbseebhfgaodc`sdhdv`zdhbf`iazel`e`e`d`perdmctcp`hcpctdpcmejdk`pdycnelapdi`hcp`e`dcvcv`pdtdxamfbex`q`oddaeafafeoemalbmbvfrbwfkci``", +"````gaccfwfneibjfcauamfgag`rad`o`odjdwbfezdbbfac`k`k`e`ycwcu`dcpctcz`dfgdbdp`n`ndaapefcvapcpcpcp`pcw`vdpen`gdc`r`o`s`oahaga`aieqakeiavfrfwbrcj``", +"````gag`fefeaxaybmfcaiecaoa`a``o`idebabaeqdgeobfdp`k`fdpffdicvcp`yapdpaseacu`d`ecxajctercvcv`y`e`v`xdodw`i`oejba`s`sabamdfaidlakdqb`bvaxcebzga``", +"``````fzfnaxaxb`cdbxema`ejaeab`rdnekepepaheuepat`edk`felcweldm`yer`uefefdp`jcn`dczapendi`tbfdh`zdpatdudtcwdnfieoen`rabdfabdlageealbjbqfrcfce````", +"``````fufeg`fafacafieeaaecdedc`rbo`rbabnah`gexazafep`eegbfflebaterbfcwbfeneldi`kaze`cv`y`n`pepbhdududwbu`sbgevdden`saba`a`ecbgbgayanfdfycjg`````", +"``````cgbyfeaxfdbqblbgdlaaama`dfafafedbgflcafcaiat`xcwaceg`gfgctatatazcwerbhdkacbfdbcyegd`cyegbxfbaeflbebuboboewdxdeaeaidlbicafjbmblaxfwg`cg````", +"``````clfxbyfjbdfmfyfhalafeoenbtb`ffbgfmfobmexba`z`icv`vdodod``mdk`vdpateuddeleuerejafadazdoduexehekbndfdebodvafdeahbcafalalakbbavfsbdccfuga````", +"````````fucbfnaxaxcabdfcdleoeoa`bmb`fofodlbababadgcv`gcycycvd`ac`ect`gdt`e`qbcdvae`iamcyemfh`regdr`ue`arbadw`r`ra`fbfbfcakalakcabqbdbkfxcf``````", +"````````fxcbfnc`bbfpbscaemdsalbtfgffddagboe`duekdg`gcwdhepdwdrep`pcv`ed`doexeoaoeufbegdreheodudrcyad`o`sdg`ramaobhbpb`bbaqaqfwfrbrcfbrfqfz``````", +"````````cichccfkaxfsavfdbidlbcbxdsb`fieddcbodnde`q`z`idbaddrdrdrcycvcwcvcwatbufgecemdhdbdre``x`odwexdve`afenesfaemeyc`faflbsbjeifvfecdccga``````", +"``````````cgcdfkbkbkfrbsanaleeezdqbteyeyewffe`deab`s`icwdb`xdh`i`icwcvcwdhdr`ueqbeekduehe`ducyehen`oeyb`ewfmaybhaaeoakcacafveibvbyfncfch````````", +"``````````ckcig`fefrccbsalfidqfgdqaqeoaiafaoaf`rdnehdvdwdj`qdhdbcw`i`g`gdjdrdrbabaepexaieqex`udedvewa`bsc`fgbhdldlaibpflfrfmfjbkg`brgacg````````", +"````````````fzcdfeblg`bvfrbsbieqflb`ema`dfabdcdcahamarbsaiepdwdjdg`u`i`odr`q`o`xe`ehexahafen`o`o`saoaabmeyejaoafafeqfcbseic`fvbyfncccg``````````", +"````````````gafubybrbrfjc`caayakbgfrfbaiaadlecdcafenboafffbaekduekdv`s`udvehadadeke`bodlfhesab`rdeetagbhecaaakejeeanb`fpfrbdfsbkbrfzcg``````````", +"``````````````fxcefqfebqfvaveiaqaleeauavfbaidla`dzeneyfiffendx`rdnab`q`idharekdndnenenewecdn`recbtbjbhdfaieqaualdqakaqfmfqfebzfqcjfz````````````", +"``````````````cjchfxbzfjbwblbjavbgb`fleebjdqemdeagaebca`ffarah`sdne`dea`abdedvamararewafdeaeeobvdsbhaaamemakbgeeeialavftfqbzfwchcjga````````````", +"````````````````cifubybybdfsfteieibjb`bsfhfyezafdsedemejamdlababdxecaedf`rahafar`rbhecafaedzbmeybcaadldldldqakakaneifdfvfqfkcffxcg``````````````", +"``````````````````fxcccdfefefwfjeieialaqb`avbgdldlafaaagafdeafaoafamaresameyesafbceoaoamagbheyaaaidsalemauakeibmbjblfabqfefzcecj````````````````", +"``````````````````gbcegaccfefvcdfaeianavanflbqcafhbueqbgeyemaibcbhfgfmdeaoaiaiamaiedbcejemfabeakededdqaqbvaqbjaxbdfjfjfkcecccgcl````````````````", +"````````````````````clfzfxfwfefvfaavavbkavauavfidqbxfabkc`ejembgfbafc`bteybhfbdlbcecfbakejbqdlananayb`alb`eifaaxbwfyfycig`fxcj``````````````````", +"``````````````````````clcjfzfwbzfkbdaxfdbkayeeavayfob`bqbpeeejfcbufhfabxbqbxbueqemb`eddqalauemaueianbsbdfaaxaxbzfvcbfnfnfuci````````````````````", +"````````````````````````gbcgfzfkfebrbkfabqfrc`fibvbdfofibiakaydqbqfcbxbiakfsfheqakaqfcflfhanakb`bvfrbyfmaxbkfecdfqbyccfxcj``````````````````````", +"``````````````````````````ckcjcccifqcbfwfjfvfrc`g`bvfdfrbsakbgfmfjfheedqdqfhfldqb`bvcdbianeeanblblfofdbdfdfefzbybycccgcl````````````````````````", +"````````````````````````````clfxcicccefnfwchfrfrftc`blfmeiavblbsfvbsbbayfabdfaanavbseebjbsblfabdaxaxblbkfeccfucffxfzgb``````````````````````````", +"``````````````````````````````gbcicicbfqcdbyblbqbdfdfebdavfofrbdaxfrfwbzaxblaneiaxfafrfjfsftfrfvfvbwfefeccfzccfxcgcl````````````````````````````", +"``````````````````````````````````gackcgcgfxbrbybrfafkbwbqaxaxfabrfwfpbdbkbqbkbkblbqfafvcffyfyfnbyfkfececfcjfzcj````````````````````````````````", +"````````````````````````````````````gbgacjfxbyccbzfebzfvccfvfwbqbkblbqblbqbqfsfkfybrbzfwfyfqbrfebrfucjchcgcjcl``````````````````````````````````", +"````````````````````````````````````````clgbcgfxfnbyfqfqfwccbzcbbybyfyfwfnbzbzcfchfxbrfwbzcdfncccccjcjcjcl``````````````````````````````````````", +"````````````````````````````````````````````clcifzcichckcgcbccfuccfwcbg`cecfbrfncefzfubybzcbchchgagacl``````````````````````````````````````````", +"````````````````````````````````````````````````gbclcgchckfxcjchchcccifxckgachcicjchfzfufxcjgaclgb``````````````````````````````````````````````", +"``````````````````````````````````````````````````````clclckcggacicicjcgcgcjcgcgcgcgckcjclgb````````````````````````````````````````````````````", +"``````````````````````````````````````````````````````````````clgbgbgbgbgbclgbgbclgb````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade2.xpm b/hacks/images/bubbles/jade2.xpm new file mode 100644 index 00000000..b070304a --- /dev/null +++ b/hacks/images/bubbles/jade2.xpm @@ -0,0 +1,95 @@ +/* XPM */ +static char *jade2[] = { +/* width height ncolors chars_per_pixel */ +"12 12 76 2", +/* colors */ +"`` c None", +"`a c #35CB35", +"`b c #1AA71A", +"`c c #158B15", +"`d c #148914", +"`e c #158715", +"`f c #137513", +"`g c #107710", +"`h c #0F6D0F", +"`i c #0E6B0E", +"`j c #0E690E", +"`k c #0F650F", +"`l c #0E630E", +"`m c #0A5F0A", +"`n c #036703", +"`o c #0B570B", +"`p c #075D07", +"`q c #0A550A", +"`r c #0C4F0C", +"`s c #0A510A", +"`t c #045704", +"`u c #065106", +"`v c #074D07", +"`w c #074B07", +"`x c #094709", +"`y c #063B06", +"`z c #073907", +"a` c #033D03", +"aa c #033B03", +"ab c #053505", +"ac c #003D00", +"ad c #053105", +"ae c #003700", +"af c #042904", +"ag c #012301", +"ah c #011501", +"ai c #1CB41C", +"aj c #17A217", +"ak c #189E18", +"al c #189A18", +"am c #119011", +"an c #128A12", +"ao c #0F8C0F", +"ap c #148214", +"aq c #138013", +"ar c #0F7A0F", +"as c #0B800B", +"at c #0A7A0A", +"au c #0A780A", +"av c #0A760A", +"aw c #0B720B", +"ax c #0F6A0F", +"ay c #0A6A0A", +"az c #056C05", +"b` c #056A05", +"ba c #076407", +"bb c #0D580D", +"bc c #0A5C0A", +"bd c #046404", +"be c #075A07", +"bf c #045E04", +"bg c #055605", +"bh c #035003", +"bi c #015201", +"bj c #B1FFB1", +"bk c #034803", +"bl c #044604", +"bm c #074007", +"bn c #083E08", +"bo c #024402", +"bp c #044004", +"bq c #013A01", +"br c #052E05", +"bs c #042C04", +"bt c #012A01", +"bu c #000A00", +/* pixels */ +"`````````l`ja`aqae``````", +"`````zbp`calaubd`mbobt``", +"`````fbibdaj`pbgau`u`h``", +"``adbl`w`nasaiawazakbebm", +"``bp`tbkaoanbjalb`ac`ebb", +"```qbebaamaj`aamavalap`o", +"```rbcbf`batavbeavbp`g`y", +"``af`wbp`dawalaraybgbqag", +"````abbq`h`i`gbhax`vbs``", +"````bu`xaa`s`kblaabnah``", +"````````bradbr`zaf``````", +"````````````````````````" +}; diff --git a/hacks/images/bubbles/jade3.xpm b/hacks/images/bubbles/jade3.xpm new file mode 100644 index 00000000..3e8a1025 --- /dev/null +++ b/hacks/images/bubbles/jade3.xpm @@ -0,0 +1,114 @@ +/* XPM */ +static char *jade3[] = { +/* width height ncolors chars_per_pixel */ +"14 14 93 2", +/* colors */ +"`` c None", +"`a c #35CB35", +"`b c #1CB11C", +"`c c #1AA71A", +"`d c #169D16", +"`e c #179717", +"`f c #179317", +"`g c #158B15", +"`h c #148914", +"`i c #158715", +"`j c #0F890F", +"`k c #128312", +"`l c #0D830D", +"`m c #127912", +"`n c #137513", +"`o c #0C7D0C", +"`p c #0E750E", +"`q c #0F730F", +"`r c #0F6F0F", +"`s c #0F6D0F", +"`t c #0E6B0E", +"`u c #077307", +"`v c #0E630E", +"`w c #0B630B", +"`x c #0A5F0A", +"`y c #0A550A", +"`z c #0B530B", +"a` c #0C4F0C", +"aa c #094F09", +"ab c #045704", +"ac c #0A4D0A", +"ad c #065306", +"ae c #0A4B0A", +"af c #065106", +"ag c #015901", +"ah c #054F05", +"ai c #074B07", +"aj c #084908", +"ak c #084508", +"al c #064706", +"am c #073907", +"an c #033D03", +"ao c #053505", +"ap c #063306", +"aq c #042B04", +"ar c #042904", +"as c #011D01", +"at c #011901", +"au c #21B621", +"av c #1CB41C", +"aw c white", +"ax c #18A418", +"ay c #189A18", +"az c #149C14", +"b` c #149014", +"ba c #0F8C0F", +"bb c #128612", +"bc c #148214", +"bd c #138013", +"be c #107C10", +"bf c #0A760A", +"bg c #0F6A0F", +"bh c #0A6A0A", +"bi c #0C660C", +"bj c #0A660A", +"bk c #0B620B", +"bl c #0C600C", +"bm c #056A05", +"bn c #066806", +"bo c #076407", +"bp c #0D580D", +"bq c #0A5C0A", +"br c #076007", +"bs c #046404", +"bt c #0A5A0A", +"bu c #075A07", +"bv c #095409", +"bw c #035003", +"bx c #034C03", +"by c #074207", +"bz c #034803", +"c` c #044604", +"ca c #074007", +"cb c #083E08", +"cc c #024402", +"cd c #053805", +"ce c #023802", +"cf c #012E01", +"cg c #042604", +"ch c #022802", +"ci c #042404", +"cj c #022002", +"ck c #011E01", +/* pixels */ +"``````````aa`rbdahbp````````", +"``````akbi`gay`hal`qbgce````", +"````aebu`kbnayah`c`o`xahcf``", +"`````sb`cc`bbj`eaubmbfbbai``", +"``ambd`q`o`dba`f`cbxbfbkbcae", +"``aebk`fbeav`aawbc`j`obqadae", +"``ca`wbvbsaxau`abfazcc`t`mbp", +"``a``s`f`xax`d`ubm`lbo`i`nae", +"``aqaaajab`ebhagbzagbwafc`cb", +"````cjai`rbj`pbhbr`gafblam``", +"````asaoanbtadbiad`v`yaecg``", +"``````cichcdby`zceacaeci````", +"``````````arcgckapat````````", +"````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade4.xpm b/hacks/images/bubbles/jade4.xpm new file mode 100644 index 00000000..ce3dc397 --- /dev/null +++ b/hacks/images/bubbles/jade4.xpm @@ -0,0 +1,170 @@ +/* XPM */ +static char *jade4[] = { +/* width height ncolors chars_per_pixel */ +"20 20 143 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #1A8B1A", +"`k c #158B15", +"`l c #148914", +"`m c #158715", +"`n c #148514", +"`o c #0F890F", +"`p c #128312", +"`q c #0E850E", +"`r c #0D830D", +"`s c #0F7F0F", +"`t c #127912", +"`u c #107710", +"`v c #0C7D0C", +"`w c #0E750E", +"`x c #0F730F", +"`y c #0F6F0F", +"`z c #0E6B0E", +"a` c #077307", +"aa c #0F650F", +"ab c #0E630E", +"ac c #0B630B", +"ad c #0D5B0D", +"ae c #036703", +"af c #0B570B", +"ag c #075D07", +"ah c #026502", +"ai c #046104", +"aj c #0A550A", +"ak c #0B530B", +"al c #016101", +"am c #094F09", +"an c #065306", +"ao c #0A4B0A", +"ap c #065106", +"aq c #074D07", +"ar c #054F05", +"as c #074B07", +"at c #084908", +"au c #094709", +"av c #084508", +"aw c #064706", +"ax c #014F01", +"ay c #004B00", +"az c #063B06", +"b` c #073907", +"ba c #004100", +"bb c #013F01", +"bc c #033B03", +"bd c #053505", +"be c #003700", +"bf c #042B04", +"bg c #042904", +"bh c #012301", +"bi c #022102", +"bj c #021B02", +"bk c #011901", +"bl c #011701", +"bm c #011501", +"bn c #011301", +"bo c #010D01", +"bp c #21B621", +"bq c #1CB41C", +"br c #22AA22", +"bs c #1AAC1A", +"bt c #18A818", +"bu c white", +"bv c #18A418", +"bw c #17A217", +"bx c #189E18", +"by c #189A18", +"bz c #149014", +"c` c #119011", +"ca c #128A12", +"cb c #128612", +"cc c #127E12", +"cd c #127C12", +"ce c #107C10", +"cf c #0F7A0F", +"cg c #0B800B", +"ch c #0E780E", +"ci c #0B7C0B", +"cj c #117211", +"ck c #0A7A0A", +"cl c #0E720E", +"cm c #0A760A", +"cn c #106A10", +"co c #0B720B", +"cp c #0F6A0F", +"cq c #0A6E0A", +"cr c #0B6C0B", +"cs c #0A6A0A", +"ct c #0B680B", +"cu c #067006", +"cv c #0A660A", +"cw c #056C05", +"cx c #0B620B", +"cy c #0D5E0D", +"cz c #056A05", +"d` c #066806", +"da c #076407", +"db c #0D580D", +"dc c #076007", +"dd c #0A5A0A", +"de c #075A07", +"df c #085808", +"dg c #045E04", +"dh c #015E01", +"di c #055605", +"dj c #015201", +"dk c #034C03", +"dl c #034A03", +"dm c #074207", +"dn c #034803", +"do c #044604", +"dp c #083E08", +"dq c #014601", +"dr c #044004", +"ds c #053805", +"dt c #063606", +"du c #013A01", +"dv c #023802", +"dw c #052E05", +"dx c #013401", +"dy c #042C04", +"dz c #013001", +"e` c #042604", +"ea c #012A01", +"eb c #022802", +"ec c #042404", +"ed c #002600", +"ee c #022002", +"ef c #011E01", +"eg c #001000", +/* pixels */ +"``````````````dwdmdzbbaoauds````````````", +"``````````dpasba`zce`ncd`yddasdt````````", +"````````azcpcr`wcm`sbycldc`x`maadm``````", +"``````aucxcr`ncmbxcb`halcmbzdgdecpaz````", +"````dpcydzdjbwci`dcuagbvcrcz`eapascybh``", +"````dwan`ldj`o`rcg`hcgbqahdidhbzdc`tdb``", +"``bicyabcod``fbpcabqbw`cckcuc`bxax`tdbbk", +"``bdaw`mcfbvbwbsa`br`a`jbpcgbs`eacctbedy", +"``auaddqbzczcbc``o`abu`b`qaecm`vayclabb`", +"``eacnan`idaaibqclbr`b`jbtbsdoby`kcjawbk", +"``bhamdlcccq`k`f`h`d`p`rcwbs`vax`n`taje`", +"``efdxcjcddjced`dndharcu`rdndjdj`xarakee", +"``bndmbedd`tchbzcs`ico`gcscqcecvabajebbn", +"````eebcabcx`ycvce`kcqdc`x`mdqdfbedvdt``", +"````bodtaddudk`yagcv`udeclcj`yaqafb`bl``", +"``````bjdpdbdratdodlandkajaaabavbkee````", +"````````bjebaudvabdmabasafaoaubgec``````", +"``````````egbfdtedaudpaudwdpecbn````````", +"``````````````bobmbmbkbjeebo````````````", +"````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade5.xpm b/hacks/images/bubbles/jade5.xpm new file mode 100644 index 00000000..120e97b1 --- /dev/null +++ b/hacks/images/bubbles/jade5.xpm @@ -0,0 +1,200 @@ +/* XPM */ +static char *jade5[] = { +/* width height ncolors chars_per_pixel */ +"24 24 169 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #149914", +"`h c #179317", +"`i c #139713", +"`j c #149514", +"`k c #1A8B1A", +"`l c #159315", +"`m c #129312", +"`n c #158B15", +"`o c #148914", +"`p c #158715", +"`q c #148514", +"`r c #128312", +"`s c #0F870F", +"`t c #0E850E", +"`u c #108110", +"`v c #0D830D", +"`w c #0F7F0F", +"`x c #127912", +"`y c #137513", +"`z c #107710", +"a` c #0C7D0C", +"aa c #0E750E", +"ab c #0F730F", +"ac c #0F6F0F", +"ad c #0F6D0F", +"ae c #0E6B0E", +"af c #0E690E", +"ag c #077307", +"ah c #0F650F", +"ai c #0E630E", +"aj c #0B630B", +"ak c #0D5B0D", +"al c #0A5F0A", +"am c #036703", +"an c #0B570B", +"ao c #075D07", +"ap c #0A550A", +"aq c #0B530B", +"ar c #016101", +"as c #0C4F0C", +"at c #0A510A", +"au c #025B02", +"av c #045704", +"aw c #0A4D0A", +"ax c #065306", +"ay c #0A4B0A", +"az c #065106", +"b` c #015901", +"ba c #074D07", +"bb c #054F05", +"bc c #074B07", +"bd c #084908", +"be c #094709", +"bf c #084508", +"bg c #064706", +"bh c #014F01", +"bi c #004B00", +"bj c #063B06", +"bk c #073907", +"bl c #033D03", +"bm c #004100", +"bn c #033B03", +"bo c #053505", +"bp c #003D00", +"bq c #063306", +"br c #053105", +"bs c #003700", +"bt c #042B04", +"bu c #042904", +"bv c #012301", +"bw c #022102", +"bx c #011D01", +"by c #021B02", +"bz c #011901", +"c` c #011701", +"ca c #011501", +"cb c #011301", +"cc c #010D01", +"cd c #1CB41C", +"ce c #1AAC1A", +"cf c #1F9C1F", +"cg c #18A418", +"ch c #17A217", +"ci c #189E18", +"cj c #189A18", +"ck c #149C14", +"cl c #149014", +"cm c #119011", +"cn c #128A12", +"co c #0F8C0F", +"cp c #128612", +"cq c #148214", +"cr c #138013", +"cs c #127C12", +"ct c #0F7A0F", +"cu c #0B800B", +"cv c #0B7C0B", +"cw c #117211", +"cx c #0A7A0A", +"cy c #0E720E", +"cz c #0A780A", +"d` c #0A760A", +"da c #106A10", +"db c #0B720B", +"dc c #0F6A0F", +"dd c #0A700A", +"de c #0A6E0A", +"df c #0B6C0B", +"dg c #0A6A0A", +"dh c #067006", +"di c #0C660C", +"dj c #0A660A", +"dk c #056E05", +"dl c #056C05", +"dm c #0B620B", +"dn c #0C600C", +"do c #0D5E0D", +"dp c #056A05", +"dq c #066806", +"dr c #076407", +"ds c #0D580D", +"dt c #0A5C0A", +"du c #076007", +"dv c #046404", +"dw c #0A5A0A", +"dx c #075A07", +"dy c #045E04", +"dz c #095409", +"e` c #015E01", +"ea c #055605", +"eb c #015601", +"ec c #035003", +"ed c #015201", +"ee c #034C03", +"ef c #034A03", +"eg c #B1FFB1", +"eh c #074207", +"ei c #034803", +"ej c #044604", +"ek c #074007", +"el c #083E08", +"em c #014601", +"en c #024402", +"eo c #034203", +"ep c #044004", +"eq c #053805", +"er c #063606", +"es c #013A01", +"et c #023802", +"eu c #052E05", +"ev c #042C04", +"ew c #013001", +"ex c #012E01", +"ey c #012C01", +"ez c #012A01", +"f` c #022802", +"fa c #042404", +"fb c #002600", +"fc c #022002", +"fd c #011E01", +"fe c #001000", +"ff c #000A00", +/* pixels */ +"``````````````````eleubedsaqbfer````````````````", +"``````````````ayaibbafdiblbbcrefbsaw````````````", +"``````````f`etdtajaoclaadyeobsaacq`ydoer````````", +"````````bkapepab`n`lcjdqczcydvb`alduenakez``````", +"``````buepafbhdeebcj`u`wdvcvbpa`cgej`qdmezc`````", +"``````ek`yduedcidv`icharaoceea`mcz`tazesadbr````", +"````bkapdi`naadl`f`feedj`lcdar`t`reacj`hacakel``", +"````brdoejclbc`eam`mcucdcdcddbcndlagcidydxdwek``", +"``faeheietdbdb`gcddk`fcf`b`pdkckam`vdv`h`xcwatfd", +"``euepehav`heidhcockcn`aeg`bcjcddpe`bpdw`pdwdsf`", +"``bkbleyem`r`wcndxdhci`aeg`a`caocv`jdedrcqendoev", +"``brapeedxajdrdqcm`mchcf`b`kcmcud`dxcj`xcqadanel", +"``evehdoalctctau`ee`cecgdtdhamceciddei`nacdwbner", +"``fcasbpdt`pdyeb`edvcx`rd``ddxb`d`ddep`p`zdobjbw", +"``cceqfbacbmbabg`w`scn`sebebacczdrcsdfaeaiawayfe", +"````buexbcbpepbi`ocpdbcicjenctdjdgdjeaeeesdsbv``", +"````fcbfewdzdw`zaebldg`rdb`ueddx`qbgaldzdsbqby``", +"``````faboaqesdaad`xaedj`zajecabdcajbaaievbz````", +"``````ffbubvakeseobaafenalajaxehdnanbdeqbwcc````", +"````````fferbeewbnepatejahdzejakbnetelbqca``````", +"``````````ffbtbqayayewewasdseweyezelbucc````````", +"``````````````ffeuevbrbqeubxbkbvbuca````````````", +"``````````````````ccbyc`bybycbff````````````````", +"````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade6.xpm b/hacks/images/bubbles/jade6.xpm new file mode 100644 index 00000000..521acf93 --- /dev/null +++ b/hacks/images/bubbles/jade6.xpm @@ -0,0 +1,222 @@ +/* XPM */ +static char *jade6[] = { +/* width height ncolors chars_per_pixel */ +"30 30 185 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #0C4F0C", +"ax c #0A510A", +"ay c #025B02", +"az c #094F09", +"b` c #045704", +"ba c #065306", +"bb c #0A4B0A", +"bc c #065106", +"bd c #015901", +"be c #074D07", +"bf c #054F05", +"bg c #074B07", +"bh c #084908", +"bi c #094709", +"bj c #084508", +"bk c #064706", +"bl c #014F01", +"bm c #004B00", +"bn c #063D06", +"bo c #063B06", +"bp c #073907", +"bq c #033D03", +"br c #004100", +"bs c #013F01", +"bt c #033B03", +"bu c #053505", +"bv c #003D00", +"bw c #063306", +"bx c #053105", +"by c #023502", +"bz c #003700", +"c` c #042B04", +"ca c #042904", +"cb c #012301", +"cc c #022102", +"cd c #011D01", +"ce c #021B02", +"cf c #011901", +"cg c #011701", +"ch c #011501", +"ci c #011301", +"cj c #010D01", +"ck c #21B621", +"cl c #1CB41C", +"cm c #22AA22", +"cn c #1AAC1A", +"co c #18A818", +"cp c #1F9C1F", +"cq c #18A418", +"cr c #17A217", +"cs c #189E18", +"ct c #189A18", +"cu c #149C14", +"cv c #149014", +"cw c #119011", +"cx c #128A12", +"cy c #0F8C0F", +"cz c #128612", +"d` c #148214", +"da c #138013", +"db c #127E12", +"dc c #127C12", +"dd c #107C10", +"de c #0F7A0F", +"df c #0B800B", +"dg c #0E780E", +"dh c #0B7C0B", +"di c #117211", +"dj c #0A7A0A", +"dk c #0E720E", +"dl c #0A780A", +"dm c #0A760A", +"dn c #106A10", +"do c #0B720B", +"dp c #0F6A0F", +"dq c #0A6E0A", +"dr c #0B6C0B", +"ds c #0A6A0A", +"dt c #0B680B", +"du c #067006", +"dv c #0C660C", +"dw c #0A660A", +"dx c #056E05", +"dy c #056C05", +"dz c #0B620B", +"e` c #0C600C", +"ea c #0D5E0D", +"eb c #056A05", +"ec c #066806", +"ed c #076407", +"ee c #0D580D", +"ef c #0A5C0A", +"eg c #076007", +"eh c #046404", +"ei c #0A5A0A", +"ej c #075A07", +"ek c #085808", +"el c #045E04", +"em c #095409", +"en c #015E01", +"eo c #055605", +"ep c #055405", +"eq c #015601", +"er c #035003", +"es c #015201", +"et c #034C03", +"eu c #B1FFB1", +"ev c #074207", +"ew c #034803", +"ex c #044604", +"ey c #074007", +"ez c #083E08", +"f` c #014601", +"fa c #024402", +"fb c #044004", +"fc c #053805", +"fd c #063606", +"fe c #013A01", +"ff c #023802", +"fg c #052E05", +"fh c #013401", +"fi c #013201", +"fj c #042C04", +"fk c #013001", +"fl c #012E01", +"fm c #012C01", +"fn c #042604", +"fo c #012A01", +"fp c #022802", +"fq c #042404", +"fr c #002600", +"fs c #022002", +"ft c #011E01", +"fu c #001000", +"fv c #000A00", +/* pixels */ +"````````````````````````fpfmbbavbyfoca``````````````````````", +"``````````````````bwfhdndnafa`fkagbsbgeeeycc````````````````", +"````````````````eebgagakahdbdw`sblf`aff`bqbgfh``````````````", +"````````````fpanbsamejde`qdo`iefbdbzfeegd`ekbcavbx``````````", +"``````````bpazaaa`dd`octdgcq`odlaodqecbdaob`aketbgfo````````", +"````````fpaxdzd``r`ses`gcsdten`hdfdddmec`peldceidpbkfg``````", +"````````ffeiaaa`elcsecdyajdeckepclcvascn`v`eaierf`diee``````", +"``````cbanf`bm`xczdheh`dcnckerapeb`fcw`hcvcxecexdcagalbi````", +"````fqfgemet`qatfe`tdl`hdfeoerdf`c`was`g`xencz`iegeodneece``", +"````bpakbaex`odeeb`eapcl`fcqcrcl`c`t`eardyayddategeje`eeft``", +"````fcdnau`raees`fcwcncydxdx`e`lckduclajducwctbzbqaba`azbu``", +"``chflbkbfbmdeecebcrclcnajab`b`a`acmckcwcncnczfaamabaibzbofu", +"``fqbbeadzet`q`icndwdhcn`y`b`aeu`a`l`c`jdfduacahbs`rdzdibobw", +"``ftavazeaepeg`xdmaccvclcycm`aeu`acpap`f`wcwctay`q`rfadncbfg", +"``fseydndzej`ieqeqatcwcrdk`c`l`b`lcpcodhdmexdqed`od`eibkeefg", +"``fqbofbaiahdaedcveccraj`t`hdj`daj`d`ncucs`m`e`z`qahetazbbfq", +"``chfmazefaoadczeqdbdh`pdm`dduebcldfbddl`pdmesed`sd`alalbicd", +"``cjbxfheidvdcfbblddcscxew`icqbf`wdr`yacehesbebmaeaaexavceci", +"````cbevfcdibafkfbes`qcs`kctctctekdebsesdqblb`ddf`aoakbpch``", +"````ftcdbhbgexake`eg`q`gdqdocsctfebs`udrdsdkegbraqfebbbbcf``", +"````cjfscbfhalbqabafdkeodd`x`odqddedaedgddf`bfaabzbbbifdfv``", +"``````fqezeeeefefaafdtbmardb`oabdwegbmdcbcbaemakeafjfpfq````", +"````````fnbifcaxbgbvdpdvdcafdwdadweraeanaoageaaqawbucc``````", +"````````fvfqezaweafbfkeaexbvagbaeiaoaubce`aleeavcffsch``````", +"``````````fvbxbpbnfibtbzakavfeakbgeabzakbtbobjfjbxch````````", +"````````````cjcefpfobubobjezbtfkaneveebybuevcafqcj``````````", +"````````````````fuc`bpfdfrezbbezfofnfgbxbpfqce``````````````", +"``````````````````cjchchfufqcbcgcecefncccifv````````````````", +"````````````````````````cjcjcicgcicjfv``````````````````````", +"````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade7.xpm b/hacks/images/bubbles/jade7.xpm new file mode 100644 index 00000000..8c26b3d5 --- /dev/null +++ b/hacks/images/bubbles/jade7.xpm @@ -0,0 +1,232 @@ +/* XPM */ +static char *jade7[] = { +/* width height ncolors chars_per_pixel */ +"36 36 189 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #016101", +"ax c #0C4F0C", +"ay c #0A510A", +"az c #025B02", +"b` c #094F09", +"ba c #045704", +"bb c #0A4D0A", +"bc c #065306", +"bd c #0A4B0A", +"be c #065106", +"bf c #015901", +"bg c #074D07", +"bh c #054F05", +"bi c #074B07", +"bj c #084908", +"bk c #094709", +"bl c #084508", +"bm c #064706", +"bn c #014F01", +"bo c #004B00", +"bp c #063D06", +"bq c #063B06", +"br c #073907", +"bs c #033D03", +"bt c #013F01", +"bu c #033B03", +"bv c #053505", +"bw c #003D00", +"bx c #063306", +"by c #053105", +"bz c #023502", +"c` c #003700", +"ca c #042904", +"cb c #012301", +"cc c #022102", +"cd c #011D01", +"ce c #021B02", +"cf c #011901", +"cg c #011701", +"ch c #011501", +"ci c #011301", +"cj c #010D01", +"ck c #21B621", +"cl c #1CB41C", +"cm c #22AA22", +"cn c #1AAC1A", +"co c #18A818", +"cp c #1F9C1F", +"cq c #18A418", +"cr c #17A217", +"cs c #189E18", +"ct c #189A18", +"cu c #149C14", +"cv c #149014", +"cw c #119011", +"cx c #128A12", +"cy c #0F8C0F", +"cz c #128612", +"d` c #148214", +"da c #138013", +"db c #127E12", +"dc c #127C12", +"dd c #107C10", +"de c #0F7A0F", +"df c #0B800B", +"dg c #0E780E", +"dh c #0B7C0B", +"di c #117211", +"dj c #0A7A0A", +"dk c #0E720E", +"dl c #0A780A", +"dm c #0A760A", +"dn c #106A10", +"do c #0B720B", +"dp c #0F6A0F", +"dq c #0A700A", +"dr c #0A6E0A", +"ds c #0B6C0B", +"dt c #0A6A0A", +"du c #0B680B", +"dv c #067006", +"dw c #0C660C", +"dx c #0A660A", +"dy c #056E05", +"dz c #056C05", +"e` c #0B620B", +"ea c #0C600C", +"eb c #0D5E0D", +"ec c #056A05", +"ed c #066806", +"ee c #076407", +"ef c #0D580D", +"eg c #0A5C0A", +"eh c #076007", +"ei c #046404", +"ej c #0A5A0A", +"ek c #075A07", +"el c #085808", +"em c #045E04", +"en c #095409", +"eo c #015E01", +"ep c #055605", +"eq c #055405", +"er c #015601", +"es c #015401", +"et c #035003", +"eu c #015201", +"ev c #034C03", +"ew c #034A03", +"ex c #B1FFB1", +"ey c #074207", +"ez c #034803", +"f` c #044604", +"fa c #074007", +"fb c #083E08", +"fc c #014601", +"fd c #024402", +"fe c #034203", +"ff c #044004", +"fg c #053805", +"fh c #063606", +"fi c #013A01", +"fj c #023802", +"fk c #052E05", +"fl c #013401", +"fm c #013201", +"fn c #042C04", +"fo c #013001", +"fp c #012E01", +"fq c #012C01", +"fr c #042604", +"fs c #012A01", +"ft c #022802", +"fu c #042404", +"fv c #002600", +"fw c #022002", +"fx c #011E01", +"fy c #001000", +"fz c #000A00", +/* pixels */ +"````````````````````````````````fbeyeybvfn``````````````````````````````", +"````````````````````````fkfqbjavdnbmeaafbmaqfvavby``````````````````````", +"````````````````````fsbdalb`fdaievepbsdievdabjauc`bvbl``````````````````", +"``````````````````avf`aleleve`dbdk`of`eldieharbjfjezdney````````````````", +"``````````````fnaydneleqdb`i`o`i`idddweuemerbhesabbzbcbtayfh````````````", +"````````````brbsenffdadd`o`odrctcvdxdleobfeiesbnaobafcfdfebufs``````````", +"``````````caeyaqebe`boa`biaccndmat`ycnec`ddxed`v`iehai`raubgb`fk````````", +"``````````efakalahbo`ucvazdzajdddecldscnclao`kcv`kdqfebneqdibmft````````", +"````````fvefaaegdreucv`geicscncrdvdxarcw`fepclcwdlctdgbebnfoagakfg``````", +"``````ccblakbcbodeeudlfd`hclclasapaw`dapaw`w`d`t`eaj`m`zekabdidnayfx````", +"``````bvebbeag`seeemdm`deodjcnevdy`dcu`c`jasasfc`deoek`zadboepafanfb````", +"````fwbyenbhf``rcxbicvcsap`fcydf`c`jcl`c`wdock`udzbfeccserboekegalfacf``", +"````caeyeaaqbna`elcqcv`fco`hek`tcy`i`r`c`f`kcoareocydveie`fla`dcbmeffk``", +"````eybbbwbhelcz`zbfcscqclcras`w`bcmcp`a`rdf`ccw`zapdsazerelddaebmbyfs``", +"````bvffbtevba`uctezeo`tcycoawcx`b`aex`acpct`c`yeccldvbwfe`i`rdwezefca``", +"``fwbkbmfieget`g`idmbfaddyckajcm`aexexex`aczcndvdfdvcsdmbhdadaelenauaxce", +"``cefqflejaieheuemcvcxdm`m`ndl`e`b`aex`acmdr`ncn`w`hcsdmde`idaahf`aqfgcf", +"``cafqauauaoekbo`ieeerafcwcrajcr`c`l`bcpcpcwcu`tdmbwe`ctembad`aifeaqfhca", +"``cgfqflbia`dadsemdresdh`ecuao`hcrededdt`iajcocncs`vewee`q`uduelb`fjbyfu", +"``fyfteff`amagad`odtewbf`k`ect`dcq`dcz`ncyecapcn`p`vekd``o`oagaiakavftch", +"````fkaxcbejegabdkemahem`e`fctdjeoecdmclcwek`tdedmdrctffekababagalbqcd``", +"````bxaxbqbgaaa`afeafif`atctedfdatazeodhbfcvcxedezfibtboduaedic`bmaxfx``", +"````frfkaxbddielbmfldibadd`gcvcx`e`g`ebcaeamej`rdodxba`ra`ezakakbqbkcd``", +"````cgcaaxavbibcdpffd`dk`q`iaddocvctctbte`dedo`xdtdsafepejbzfibjfscbfy``", +"``````cgfbcaaldndnelafafdkdsdgdect`gdgdobaeuen`udsa`bzbhdibpfofgfxfy````", +"``````fybxbrbzaybgezaae`afbofceheh`sdsadehbofeabdbage`akebb`fofpbrce````", +"````````cfbybvbjbgfibjejagbcfcahdkdbabdsaretdbeldpaaejbgefavfnftch``````", +"``````````cafbftefalb`bgdiaaafafafaramepbcaoagevaialauefbjeyfbcc````````", +"``````````cjfufbeyavavavdneybzejezbzevezbcezegdianb`b`eybvfvfxch````````", +"````````````fzfwfbbkbqbzbuflbiaybqbwakfeakf`feakbubxaxfbfncach``````````", +"``````````````cjcgccftfofqblefblfsbbeyeyavebbseyaxblfbfrfufz````````````", +"``````````````````cicebrbrfhbqaxbrfmbkbkbleycdfvbxfbcdfw````````````````", +"````````````````````cjcefkfnftbybxfvfkbycfbrbyfkcachcj``````````````````", +"````````````````````````fzcecichcfcgcicfchfwfufyfz``````````````````````", +"````````````````````````````````fzfzfzfzcj``````````````````````````````", +"````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade8.xpm b/hacks/images/bubbles/jade8.xpm new file mode 100644 index 00000000..3c737378 --- /dev/null +++ b/hacks/images/bubbles/jade8.xpm @@ -0,0 +1,240 @@ +/* XPM */ +static char *jade8[] = { +/* width height ncolors chars_per_pixel */ +"44 44 189 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #016101", +"ax c #0C4F0C", +"ay c #0A510A", +"az c #025B02", +"b` c #094F09", +"ba c #045704", +"bb c #0A4D0A", +"bc c #065306", +"bd c #0A4B0A", +"be c #065106", +"bf c #015901", +"bg c #074D07", +"bh c #054F05", +"bi c #074B07", +"bj c #084908", +"bk c #094709", +"bl c #084508", +"bm c #064706", +"bn c #014F01", +"bo c #004B00", +"bp c #063D06", +"bq c #063B06", +"br c #073907", +"bs c #033D03", +"bt c #004100", +"bu c #013F01", +"bv c #033B03", +"bw c #053505", +"bx c #003D00", +"by c #063306", +"bz c #053105", +"c` c #023502", +"ca c #003700", +"cb c #042B04", +"cc c #042904", +"cd c #012301", +"ce c #022102", +"cf c #011D01", +"cg c #021B02", +"ch c #011901", +"ci c #011701", +"cj c #011501", +"ck c #011301", +"cl c #010D01", +"cm c #21B621", +"cn c #1CB41C", +"co c #22AA22", +"cp c #1AAC1A", +"cq c #18A818", +"cr c #1F9C1F", +"cs c #18A418", +"ct c #17A217", +"cu c #189E18", +"cv c #189A18", +"cw c #149C14", +"cx c #149014", +"cy c #119011", +"cz c #128A12", +"d` c #0F8C0F", +"da c #128612", +"db c #148214", +"dc c #138013", +"dd c #127E12", +"de c #127C12", +"df c #107C10", +"dg c #0F7A0F", +"dh c #0B800B", +"di c #0E780E", +"dj c #0B7C0B", +"dk c #117211", +"dl c #0A7A0A", +"dm c #0E720E", +"dn c #0A780A", +"do c #0A760A", +"dp c #106A10", +"dq c #0B720B", +"dr c #0F6A0F", +"ds c #0A6E0A", +"dt c #0B6C0B", +"du c #0A6A0A", +"dv c #0B680B", +"dw c #067006", +"dx c #0C660C", +"dy c #0A660A", +"dz c #056E05", +"e` c #056C05", +"ea c #0B620B", +"eb c #0C600C", +"ec c #0D5E0D", +"ed c #056A05", +"ee c #066806", +"ef c #076407", +"eg c #0D580D", +"eh c #0A5C0A", +"ei c #076007", +"ej c #046404", +"ek c #0A5A0A", +"el c #075A07", +"em c #085808", +"en c #045E04", +"eo c #095409", +"ep c #015E01", +"eq c #055605", +"er c #055405", +"es c #015601", +"et c #015401", +"eu c #035003", +"ev c #015201", +"ew c #034C03", +"ex c #034A03", +"ey c #B1FFB1", +"ez c #074207", +"f` c #034803", +"fa c #044604", +"fb c #074007", +"fc c #083E08", +"fd c #014601", +"fe c #024402", +"ff c #034203", +"fg c #044004", +"fh c #053805", +"fi c #063606", +"fj c #013A01", +"fk c #023802", +"fl c #052E05", +"fm c #013401", +"fn c #013201", +"fo c #042C04", +"fp c #013001", +"fq c #012E01", +"fr c #012C01", +"fs c #042604", +"ft c #012A01", +"fu c #022802", +"fv c #042404", +"fw c #002600", +"fx c #022002", +"fy c #011E01", +"fz c #001000", +/* pixels */ +"````````````````````````````````````````````br``````````````````````````````````````````", +"````````````````````````````````bzftfkbvavakbsavb`aqbwfbfc``````````````````````````````", +"````````````````````````````bwfgalaldpafafbcecebdkbubic`bpfmfq``````````````````````````", +"````````````````````````fhavaubgbldkerahdbaoauekdeewaof`eadpfffmbw``````````````````````", +"````````````````````fobbfaemdrewdrardfdfduekama`eoelamdydbfdbjaiakbbch``````````````````", +"``````````````````fravakexamam`q`scx`odidiaoffdxenfaevdddyabeqfdembgaqbl````````````````", +"````````````````bpbmekbeabdbdg`z`ods`z`mdqafeeatew`u`zemffba`rfdfdbubxbmft``````````````", +"``````````````fbfkaufe`sdd`q`zdqdn`gcxdo`e`ydtfaedfeejdqczdg`qeuboecf`fjfmby````````````", +"````````````fcecakbha`eaeuesefescz`f`yawdme`d`cpdzcsbf`ydocvdiekdebnfkaibiaybr``````````", +"``````````fybjb`exbtei`odgdacxaoeddodydiapcucs`dd`asep`y`f`mcsdqdc`oabemaaecbzcd````````", +"``````````bqayagbhewdtev`zcs`pdmctcp`fdhaj`eard`cp`wewas`jedaj`pefbeelb`emecanfh````````", +"````````blegdpdxeleq`idd`xeebucscncncyepawewfeeierajcpcn`nbfepcz`pefabdddyekdpavfc``````", +"````````c`egekeheu`udufjdm`z`edj`fcmapdiczapascq`cdjdtawapelbceadjcu`gdgeidcecalbw``````", +"``````fobrffbedd`rdqdyabdscudlasdncpfe`fcq`h`ccn`j`jeicsdy`mdvdz`uejenbob`afemecegfo````", +"``````bqegdpfeafba`ocudvdncpcy`tcnd`dzct`c`jcq`ccndncndnaraj`ke`dzesevdueqdvekdpblfl````", +"````fvfpanaqbpddbobhaecu`fdhctcq`h`m`tdjct`o`rcm`eaj`ycqcpdwaj`nedatbhexefdbddbgakbqch``", +"````fuftegbuembo`s`xdsencvcscncncycsdjdi`l`b`b`b`ldkcq`cd`eiedbf`gbfffahbe`rdkexezbrfi``", +"````cdbkakbuemfddgdgcvemaj`hac`dcmcme``l`b`a`aey`aeccu`d`yedbuea`u`qcababo`raoembzfuce``", +"````fcbdbmbuamfmdm`i`gbfeaarap`t`dfecu`b`aeyeyey`aco`dcmcy`eeddw`pencxfmdxafdxexfac`fc``", +"````bravalbifkbmei`xcvdqatdwcpawcndwcx`b`aeyeyey`bdpdodo`das`j`w`pdsbuazel`rfdbeakfpfl``", +"````fcblbwehbe`rarbadu`mdncsbtdncqedcpco`b`a`a`acrcodnctajcsacdjcu`xdidqdsa`dkbealbjbr``", +"``cgflfkb`bgamfdbndxazef`eeedzcsctdldh`ccocr`b`b`lef`hcyac`h`gfecscvendddgddehffanegbzfz", +"````bzbqfmaqbtam`sarahds`uazcuct`nbudhcqcmcr`cdi`demd``fcwcs`p`p`edi`xdqdmdbeheobqegfy``", +"````flfpblffaoeldd`o`xadabes`kcu`tepcq`fcnapdm`pajedej`f`d`fctdobfdddy`rababemecfgc`cc``", +"````fuftegfgaiela``s`ibacxevaz`w`ndfctcndwaje`cpctdl`zbx`ycu`xdsdxebdm`raoahagdpbdaxfl``", +"````fxbkayfmebaidbdeeuaret`iefcu`m`oazedawdzepd`cybfajczbfdseeaz`sdberafdca`aqakblfufx``", +"````ccfwezfbbmaaamahfpehfmbc`sdg`eeebxazdw`gazajdwfeaz`vdncaehbseo`sdvdedkaialbsaxfvfx``", +"````fzccblbjayaubcf`alfkeoeles`g`gcs`e`pcu`wcuf`el`idfaoabdydgbabo`o`sfeewakcdfpfrcfcj``", +"``````flfwbjbdffaffedbauffdydy`o`gdqefef`icu`xdccxfa`xeeef`gdy`ua`aobiakbjbgecfpbybz````", +"``````cecdbdbybvebbgbmewew`rddadcx`o`u`icvcvdicvahatdyei`oefbob`eualdkewdpblblfibyce````", +"````````cefcfxc`fjekftekdedddcdyetafefdfda`gdq`qdgeiafbe`r`seuafbcekaibgfmfnaxfuby``````", +"````````fvbzezc`fmaybgbuamafddaofdbobaaddmdcdsdydteiboeoabdcagbcaaemdpaqfkfyfpbycj``````", +"``````````chfibdfiavegfjfwbudeabbhfdei`sdy`rabdtameiardbaofkbeamecbgecanfqfwcdch````````", +"``````````clflfcfpbqanecauaudkdka`a`a`dxagdxaheqeabhdxagbtdkdralauakfgaxfhbrfxcj````````", +"````````````cjfxbrfrbkanalfgbkbbbibudrf`exfpemdxemehbhemexalecalbibjbkfqfucech``````````", +"``````````````fzcffobzaxbdanauffblezdkfafec`ftfeekb`alfralaqanblayavbrcbflfx````````````", +"````````````````cjflccfcfcc`c`fgfmbjavavbsaub`fqdpb`bwegecfmccbqezbzbzflci``````````````", +"``````````````````chcjcccdbkfcfhfregbkaxc`bjbsfkavfgc`c`bpbkbdbdfccffvfz````````````````", +"````````````````````clcjbzbzfifcbrezbkfnbzbpaxbkbkfbfhbzfcftfiflcffxcl``````````````````", +"````````````````````````clfsflfoficbbzflbqftbqftchfublfofuflcgcgcj``````````````````````", +"````````````````````````````cjckchckcefvfsfufsfychciflflcgckfz``````````````````````````", +"````````````````````````````````clclfzcjchcgcicgfxfvcgcjcl``````````````````````````````", +"````````````````````````````````````````````cl``````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/bubbles/jade9.xpm b/hacks/images/bubbles/jade9.xpm new file mode 100644 index 00000000..85f5ca98 --- /dev/null +++ b/hacks/images/bubbles/jade9.xpm @@ -0,0 +1,248 @@ +/* XPM */ +static char *jade9[] = { +/* width height ncolors chars_per_pixel */ +"50 50 191 2", +/* colors */ +"`` c None", +"`a c #69E169", +"`b c #35CB35", +"`c c #23BD23", +"`d c #1CB11C", +"`e c #1AA71A", +"`f c #169D16", +"`g c #179717", +"`h c #149914", +"`i c #179317", +"`j c #139713", +"`k c #149514", +"`l c #1A8B1A", +"`m c #159315", +"`n c #129312", +"`o c #158B15", +"`p c #128D12", +"`q c #148914", +"`r c #158715", +"`s c #148514", +"`t c #0F890F", +"`u c #128312", +"`v c #0F870F", +"`w c #0E850E", +"`x c #108110", +"`y c #0D830D", +"`z c #0F7F0F", +"a` c #127912", +"aa c #137513", +"ab c #107710", +"ac c #0C7D0C", +"ad c #0E750E", +"ae c #0F730F", +"af c #0F6F0F", +"ag c #0F6D0F", +"ah c #0E6B0E", +"ai c #0E690E", +"aj c #077307", +"ak c #0F650F", +"al c #0E630E", +"am c #0B630B", +"an c #0D5B0D", +"ao c #0A5F0A", +"ap c #036703", +"aq c #0B570B", +"ar c #075D07", +"as c #026502", +"at c #046104", +"au c #0A550A", +"av c #0B530B", +"aw c #016101", +"ax c #0C4F0C", +"ay c #0A510A", +"az c #025B02", +"b` c #094F09", +"ba c #045704", +"bb c #0A4D0A", +"bc c #065306", +"bd c #0A4B0A", +"be c #065106", +"bf c #015901", +"bg c #074D07", +"bh c #054F05", +"bi c #074B07", +"bj c #084908", +"bk c #094709", +"bl c #084508", +"bm c #064706", +"bn c #014F01", +"bo c #004B00", +"bp c #063D06", +"bq c #063B06", +"br c #073907", +"bs c #033D03", +"bt c #004100", +"bu c #013F01", +"bv c #033B03", +"bw c #053505", +"bx c #003D00", +"by c #063306", +"bz c #053105", +"c` c #023502", +"ca c #003700", +"cb c #042B04", +"cc c #042904", +"cd c #012301", +"ce c #022102", +"cf c #011D01", +"cg c #021B02", +"ch c #011901", +"ci c #011701", +"cj c #011501", +"ck c #011301", +"cl c #010D01", +"cm c #21B621", +"cn c #1CB41C", +"co c #22AA22", +"cp c #1AAC1A", +"cq c #18A818", +"cr c #1F9C1F", +"cs c #18A418", +"ct c #17A217", +"cu c #189E18", +"cv c #189A18", +"cw c #149C14", +"cx c #149014", +"cy c #119011", +"cz c #128A12", +"d` c #0F8C0F", +"da c #128612", +"db c #148214", +"dc c #138013", +"dd c #127E12", +"de c #127C12", +"df c #107C10", +"dg c #0F7A0F", +"dh c #0B800B", +"di c #0E780E", +"dj c #0B7C0B", +"dk c #117211", +"dl c #0A7A0A", +"dm c #0E720E", +"dn c #0A780A", +"do c #0A760A", +"dp c #106A10", +"dq c #0B720B", +"dr c #0F6A0F", +"ds c #0A700A", +"dt c #0A6E0A", +"du c #0B6C0B", +"dv c #0A6A0A", +"dw c #0B680B", +"dx c #067006", +"dy c #0C660C", +"dz c #0A660A", +"e` c #056E05", +"ea c #056C05", +"eb c #0B620B", +"ec c #0C600C", +"ed c #0D5E0D", +"ee c #056A05", +"ef c #066806", +"eg c #076407", +"eh c #0D580D", +"ei c #0A5C0A", +"ej c #076007", +"ek c #046404", +"el c #0A5A0A", +"em c #075A07", +"en c #085808", +"eo c #045E04", +"ep c #095409", +"eq c #015E01", +"er c #055605", +"es c #055405", +"et c #015601", +"eu c #015401", +"ev c #035003", +"ew c #015201", +"ex c #034C03", +"ey c #034A03", +"ez c #B1FFB1", +"f` c #074207", +"fa c #034803", +"fb c #044604", +"fc c #074007", +"fd c #083E08", +"fe c #014601", +"ff c #024402", +"fg c #034203", +"fh c #044004", +"fi c #053805", +"fj c #063606", +"fk c #013A01", +"fl c #023802", +"fm c #052E05", +"fn c #013401", +"fo c #013201", +"fp c #042C04", +"fq c #013001", +"fr c #012E01", +"fs c #012C01", +"ft c #042604", +"fu c #012A01", +"fv c #022802", +"fw c #042404", +"fx c #002600", +"fy c #022002", +"fz c #011E01", +"g` c #001000", +"ga c #000A00", +/* pixels */ +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"``````````````````````````````````````fvcdfsbwbsehehfqbdblbkbqfm````````````````````````````````````", +"````````````````````````````````fvfvc`ayakalepauaabcakdkfgb`aufnbjbkfp``````````````````````````````", +"````````````````````````````cdehbmaqanelbeexfeexdragfraobedebcfobbayedbqbl``````````````````````````", +"````````````````````````fmbdedbiecelbmfeah`rafdc`o`sfba`ecemaffeenbufkbiedfdfj``````````````````````", +"``````````````````````fpehfhaqenebema`ejdm`i`gdvfhbadcfhba`oevdmdwahaoaodkakblcd````````````````````", +"````````````````````fsbbbmeyelemaodb`i`i`u`icudqbeaha`ateu`g`rahbnabdzflenbudpbjbz``````````````````", +"``````````````````fdfobidkfeab`rad`xdf`zdt`mcxekbheadsbxetatdvfaamewbodbfea`fgbpbvfr````````````````", +"````````````````brfndpakbcdz`r`q`odids`ecuczcycueeenbfeeeq`eefac`xdiaebabiesfabxbkbdcf``````````````", +"``````````````fdbdedebfea`ahab`saeel`v`ecucxffcpdj`h`fdobxaododtaccxdqeoewdbexc`drbsbkfj````````````", +"````````````ftehfnanfla`bseg`u`x`peme``yeacpdzeeerdv`f`fcu`x`t`t`p`pcsatfkewbgexagdkcacdfw``````````", +"``````````cjfifhagaiexdz`ibn`zcv`mdadn`yd``vapeqemdq`t`nap`odqcycsdjcxcuazbgejbobmdkecfnfuce````````", +"``````````brbbdpaffeec`rdueo`iczeke``dcpcnapff`gdfasdjdjcs`wdndh`weqdx`g`patecevemameialbvbq````````", +"````````chbqb`akaoeserdfeg`xdtbedxcpcncqcqdzasapdqaseedncme`cnctdjeq`ods`zdgaddvdf`saiepalbbcd``````", +"````````brfmb`enbefe`qbaetbeef`t`ee`d``jdhem`mczdjdhcn`c`fdxasas`madbceq`uda`i`uejfea`dkakehbr``````", +"``````cefpedbmelaiabdcegetfa`vcpajeqee`cdlaj`dcqcs`ccncq`jasev`zex`uemdxat`idteoaifnaheiedavblfw````", +"``````bzfvalakfaafev`ucv`zfa`pcp`t`ycmctev`ncq`ccwcp`c`cd`btawas`gdxcyekdnddeo`uejbadwaiaiayf`ch````", +"``````fpanakffakfebn`gca`z`w`taccncn`jdje`d``y`dda`qcmcm`jej`j`hfaajdl`kdxdgdmcafbdzdddebcakehby````", +"````chblavakbifebiegdidtbhcxcp`fcpcmcycndh`jdqcrco`b`ba`die``cct`ydze`dxbfdddybudmbo`ra`aibmf`fuce``", +"````cjfuaybmffeieladdgcuduaj`pct`fcmcpemaj`z`l`b`a`a`acoa`cmcmcpd`e``icp`eazbcefamah`rafdycafifscd``", +"````byfdbvfbavfaep`o`ucvekffcvajajcq`fcyas`e`b`aezezez`a`b`ictcmd`eqeqekdoekenendybnabdyenbxfobdcc``", +"````cdfqbjedbudyfhdz`ucx`zdodudwcp`ycmdw`kcm`b`aezezez`acr`i`dcndxasacdxcsdn`ofbbmemdfexfaakfhbdbr``", +"````fmbpbsbmfffqfhemdt`i`pac`zdn`e`dcwebcyco`b`aezezez`a`lcodufaardocy`hcxczeoeuegej`oesfaakavblfp``", +"````cbbqbkakepfeboarbneo`x`w`p`naddo`jcpcy`c`c`b`a`a`acrcrcz`ncnaj`u`v`w`pcx`x`gdzdmaedebgecaybyby``", +"````fdfqaldpbiaoboev`idfeoeobfatdx`f`f`wdm`d`c`lcr`bcocrdp`pcq`ycy`kbffbfgcxdiba`o`sdcafdrbmavf`fd``", +"````fmbzbdfhalffdudcejboazcvduekcucpcteq`d`e`e`icr`bdgaacpdjcq`h`kct`p`zdcefcvaddudwdbececanfhfqby``", +"````fzfdbjfgepeybe`r`oeg`uegamekcpcp`kdz`kcncp`hekel`wdx`iap`v`d`e`ncu`vbcaf`i`idcabdeenecayc`bkfm``", +"````fmfsaxb`ehaibh`rdm`i`zbnenbudt`wctdnd`cpcqdhctcu`jcy`tasexdn`ecv`m`zeienfn`o`oaoa`dkededaxfuby``", +"````fmfxavf`edelebaedbddaretbcetazefcvekeqdhee`easdo`dcp`wda`vateqczegdqejbnamdmdda`ahdkdpaqbpcdfy``", +"````fwfxbkfnfieddkabdebna`ewendf`icucubffaefdu`odabhea`pbcdf`y`metetdvewamfl`oaraea`a`fbanavbdfpcg``", +"````g`fzfrf`bzfgakelemelb`bsbvdceucz`g`zdtdodj`peqatateeazarazacdsetazddamboam`rardedpfkavfqbdcdck``", +"``````fwbzavbdbkelenbcfsbvfhbodzeo`g`gcz`i`z`gcsczetbxadcxeb`rab`gdt`qejbaaedcaffabtalfkbdaxfdfy````", +"``````ftcdfqfvb`fgafexagfefhdkdudv`ocvdgejdv`zcucu`wcuffeteg`xewdt`ieg`qdcdweybtbvalbiedbjcccgfy````", +"``````cjcfchc`c`fkecbibtbtesevexdcdg`i`oda`u`gcu`gdgewey`idtdqegcxeg`s`obofsbtaafgfkfcanfufdftcj````", +"````````cgfyf`cdbvfkalaaexabdbafdbdmdzewdfdmda`o`idt`xduejbaaeai`qddbnfebtbhebafcafrbqfqfjfjcc``````", +"````````cjchfubwflfkaubgakebdedy`sduevb`erdvdzdtdfdzdidfejevdkbodf`rendkendkalalayfnc`fxbrbyci``````", +"``````````fwccbqfibpalakbjc`bxaiabambhfneradabdm`odfdzdvdmarardcaba`alaienauauakalfqcdbwfyfw````````", +"``````````gafwfzblfqbjavaqfhdkbxafaoenbeaiaeabam`r`rabaoeyenafabaaexafdkdkelededehbzbwcccega````````", +"````````````cjfwfmfdblbdalanbibuafakafeca`ebdyarexebexdkenbcaheibcaadrelauakbjavbdfdccfwcj``````````", +"``````````````g`fzbzfdfiavbbaqfhedfuf`fkfbelffbtanbcenexeibeauffafecelalb`avbkbqchcdfwcg````````````", +"````````````````g`fybzfjbdbkblehayfbbdalbgaqfgbuanblfbepauedakfgauaqehbsbpaxbwfmcbfmcg``````````````", +"``````````````````cjccfzfdfcbqflbvfhcafhedb`aybib`bibpanedbsakalalfnfjfoaxf`fvcccccj````````````````", +"````````````````````cjcgfmcecdfufufnbqbpanbmbqf`ehbmehedbdfvbbblblaxaxbkblcdfmfwg```````````````````", +"``````````````````````cjclfwftbrbzbkfiaxfifqbdbkfqf`ehavavbpc`fzfrfxfjfdfycfceck````````````````````", +"````````````````````````gacgfycbccbrbrfxfxbzbdbdbdfdfdcffzfqfmbzfdbrbyfwchcgcl``````````````````````", +"````````````````````````````gag`fyfwcececcfpbybzcbfucbcbcfcdbyfmfmcicjcgga``````````````````````````", +"````````````````````````````````gackcgcifychchcccfchcjckcgchccfycjg`ga``````````````````````````````", +"``````````````````````````````````````gagagackcjchfycjchcgg`clga````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````", +"````````````````````````````````````````````````````````````````````````````````````````````````````" +}; diff --git a/hacks/images/noseguy/nose-f1.xbm b/hacks/images/noseguy/nose-f1.xbm new file mode 100644 index 00000000..543af3e4 --- /dev/null +++ b/hacks/images/noseguy/nose-f1.xbm @@ -0,0 +1,38 @@ +#define nose_f1_width 64 +#define nose_f1_height 64 +static unsigned char nose_f1_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,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x04,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00, + 0x08,0x00,0xc0,0x1f,0x00,0x20,0x00,0x00,0x08,0x00,0x30,0x60,0x00,0x20,0x00, + 0x00,0xf8,0xff,0x0f,0x80,0xff,0x3f,0x00,0x00,0x00,0x02,0x02,0x00,0x82,0x00, + 0x00,0x00,0x00,0x03,0x01,0x00,0x84,0x01,0x00,0x00,0x00,0x81,0x00,0x00,0x08, + 0x01,0x00,0x00,0x80,0x80,0x00,0x00,0x08,0x02,0x00,0x00,0x80,0x40,0x00,0x00, + 0x10,0x02,0x00,0x00,0x40,0x40,0x00,0x00,0x10,0x04,0x00,0x00,0x40,0x20,0x00, + 0x00,0x20,0x04,0x00,0x00,0x60,0x20,0x00,0x00,0x20,0x0c,0x00,0x00,0x20,0x20, + 0x00,0x00,0x20,0x08,0x00,0x00,0x20,0x20,0x00,0x00,0x20,0x08,0x00,0x00,0x10, + 0x20,0x00,0x00,0x20,0x10,0x00,0x00,0x10,0x20,0x00,0x00,0x20,0x10,0x00,0x00, + 0x10,0x20,0x00,0x00,0x20,0x10,0x00,0x00,0x10,0x40,0x00,0x00,0x10,0x10,0x00, + 0x00,0x10,0x40,0x00,0x00,0x10,0x10,0x00,0x00,0x10,0x80,0x00,0x00,0x08,0x10, + 0x00,0x00,0x10,0x80,0x00,0x00,0x08,0x10,0x00,0x00,0x30,0x00,0x01,0x00,0x04, + 0x18,0x00,0x00,0x20,0x00,0x02,0x00,0x02,0x08,0x00,0x00,0x20,0x00,0x0c,0x80, + 0x01,0x08,0x00,0x00,0x60,0x00,0x30,0x60,0x00,0x0c,0x00,0x00,0x40,0x00,0xc0, + 0x1f,0x00,0x04,0x00,0x00,0xc0,0x00,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x02,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0xc0,0x0f,0x00,0x00,0x00, + 0x00,0x40,0x10,0x20,0x10,0x00,0x00,0x00,0x00,0x20,0x60,0x30,0x20,0x00,0x00, + 0x00,0x00,0x20,0xc0,0x18,0x20,0x00,0x00,0xc0,0x7f,0x10,0x80,0x0d,0x40,0xe0, + 0x01,0x70,0xc0,0x18,0x00,0x05,0x40,0x1c,0x06,0x10,0x00,0x0f,0x00,0x05,0x80, + 0x07,0x08,0x08,0x00,0x06,0x00,0x05,0x80,0x01,0x08,0x08,0x00,0x18,0x00,0x05, + 0xc0,0x00,0x10,0x04,0x00,0x30,0x00,0x05,0x30,0x00,0x10,0x04,0x00,0x00,0x80, + 0x08,0x18,0x00,0x20,0x04,0x00,0x00,0x80,0x08,0x00,0x00,0x20,0x04,0x00,0x00, + 0x40,0x10,0x00,0x00,0x20,0x24,0x00,0x00,0x40,0x10,0x00,0x00,0x22,0x24,0x00, + 0x00,0x40,0x10,0x00,0x00,0x22,0x44,0x00,0x00,0x40,0x10,0x00,0x00,0x11,0x84, + 0x01,0x00,0xc0,0x18,0x00,0xc0,0x10,0x08,0x00,0x00,0x80,0x08,0x00,0x00,0x08, + 0x30,0x00,0x00,0x80,0x08,0x00,0x00,0x04,0xe0,0xff,0xff,0xff,0xf8,0xff,0xff, + 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00}; diff --git a/hacks/images/noseguy/nose-f1.xpm b/hacks/images/noseguy/nose-f1.xpm new file mode 100644 index 00000000..a6e03bfb --- /dev/null +++ b/hacks/images/noseguy/nose-f1.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_f1_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXXX.......XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXX..ooooooo..XXXXXXXXXXXXXX. ", +" .................ooooooooooo............... ", +" .OOOOOOO.ooooooooooooooo.OOOOO. ", +" ..OOOOOO.ooooooooooooooooo.OOOO.. ", +" .OOOOOO.ooooooooooooooooooo.OOOO. ", +" .OOOOOOO.ooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooooo.OOOO. ", +" .OOOOOOO.ooooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooooooo.OOOO. ", +" ..OOOOOO.ooooooooooooooooooooooo.OOOO.. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOOOOO.ooooooooooooooooooo.OOOOOOOO. ", +" .OOOOOOOOOO.ooooooooooooooooooo.OOOOOOOO. ", +" ..OOOOOOOOOO.ooooooooooooooooo.OOOOOOOO.. ", +" .OOOOOOOOOOO.ooooooooooooooo.OOOOOOOOO. ", +" .OOOOOOOOOOOO..ooooooooooo..OOOOOOOOOO. ", +" ..OOOOOOOOOOOOO..ooooooo..OOOOOOOOOOO.. ", +" .OOOOOOOOOOOOOOO.......OOOOOOOOOOOOO. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ................................ ", +" ", +" ..... ...... ", +" .+++++. .++++++. ", +" .+++++++.. ..+++++++. ", +" .++++++++.. ..++++++++. ", +" ......... .++++++++++.. ..++++++++++. .... ", +" ...+++++++.. ..+++++++++++. .+++++++++++. ...++++.. ", +" .+++++++++++....@+++++++++++. .+++++++++++@....++++++++. ", +" .+++++++++++++..@@+++++++++++. .++++++++++@@..++++++++++. ", +" .+++++++++++++++..@++++++++++. .+++++++++@@..++++++++++++. ", +" .+++++++++++++++++..@+++++++++. .++++++++@..++++++++++++++. ", +" .++++++++++++++++++++++++++++. .+++++++..++++++++++++++++. ", +" .++++++++++++++++++++++++++++. .+++++++++++++++++++++++++. ", +" .+++++++++++++++++++++++++++. .++++++++++++++++++++++++. ", +" .+@.++++++++++++++++++++++++. .++++++++++++++++++++.+++. ", +" .+@.++++++++++++++++++++++++. .++++++++++++++++++++.@++. ", +" .+@@.+++++++++++++++++++++++. .+++++++++++++++++++.@@+. ", +" .++@@..+++++++++++++++++++++.. ..+++++++++++++++++..@@++. ", +" .++@@++++++++++++++++++++++@. .@++++++++++++++++++@@++. ", +" ..@@@@@@@@@@@@@@@@@@@@@@@@@. .@@@@@@@@@@@@@@@@@@@@@@. ", +" ........................... ....................... ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-f2.xbm b/hacks/images/noseguy/nose-f2.xbm new file mode 100644 index 00000000..6851b201 --- /dev/null +++ b/hacks/images/noseguy/nose-f2.xbm @@ -0,0 +1,38 @@ +#define nose_f2_width 64 +#define nose_f2_height 64 +static unsigned char nose_f2_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,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x04,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00, + 0x08,0x00,0xe0,0x0f,0x00,0x20,0x00,0x00,0x08,0x00,0x18,0x30,0x00,0x20,0x00, + 0x00,0xf8,0xff,0x07,0xc0,0xff,0x3f,0x00,0x00,0x00,0x02,0x01,0x00,0x81,0x00, + 0x00,0x00,0x00,0x83,0x00,0x00,0x82,0x01,0x00,0x00,0x00,0x41,0x00,0x00,0x04, + 0x01,0x00,0x00,0x80,0x40,0x00,0x00,0x04,0x02,0x00,0x00,0x80,0x20,0x00,0x00, + 0x08,0x02,0x00,0x00,0x40,0x20,0x00,0x00,0x08,0x04,0x00,0x00,0x40,0x10,0x00, + 0x00,0x10,0x04,0x00,0x00,0x60,0x10,0x00,0x00,0x10,0x0c,0x00,0x00,0x20,0x10, + 0x00,0x00,0x10,0x08,0x00,0x00,0x30,0x10,0x00,0x00,0x10,0x08,0x00,0x00,0x10, + 0x10,0x00,0x00,0x10,0x10,0x00,0x00,0x10,0x10,0x00,0x00,0x10,0x10,0x00,0x00, + 0x10,0x10,0x00,0x00,0x10,0x10,0x00,0x00,0x10,0x20,0x00,0x00,0x08,0x10,0x00, + 0x00,0x10,0x20,0x00,0x00,0x08,0x10,0x00,0x00,0x10,0x40,0x00,0x00,0x04,0x10, + 0x00,0x00,0x30,0x40,0x00,0x00,0x04,0x10,0x00,0x00,0x20,0x80,0x00,0x00,0x02, + 0x18,0x00,0x00,0x20,0x00,0x01,0x00,0x01,0x08,0x00,0x00,0x60,0x00,0x06,0xc0, + 0x00,0x08,0x00,0x00,0x80,0x00,0x18,0x30,0x00,0x0c,0x00,0x00,0x80,0x00,0xe0, + 0x0f,0x00,0x04,0x00,0x00,0x80,0x01,0x00,0x00,0x00,0x06,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x02,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x0f,0x00,0x00,0x00, + 0x00,0xff,0x00,0x04,0x10,0x00,0x00,0x00,0xe0,0x00,0x07,0x02,0x10,0x00,0x00, + 0x00,0x30,0x00,0x8c,0x01,0x20,0x00,0x00,0x00,0x0c,0x00,0x90,0x00,0x20,0x00, + 0x00,0x00,0x04,0x03,0x60,0x00,0x20,0x00,0x00,0x00,0xc2,0x00,0xc0,0x00,0x20, + 0x00,0x00,0x00,0x42,0x00,0x00,0x01,0x20,0x00,0x00,0x00,0x21,0x00,0x00,0x02, + 0x20,0x00,0x00,0x00,0x21,0x00,0x00,0x06,0x20,0x00,0x00,0x00,0x21,0x00,0x00, + 0x00,0x20,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x03,0x00, + 0x00,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x20,0x00,0x00,0x00, + 0x18,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x10,0x00,0x00, + 0x00,0xc0,0xff,0xff,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,0x00}; diff --git a/hacks/images/noseguy/nose-f2.xpm b/hacks/images/noseguy/nose-f2.xpm new file mode 100644 index 00000000..3763b58d --- /dev/null +++ b/hacks/images/noseguy/nose-f2.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_f2_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXX.......XXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXX..ooooooo..XXXXXXXXXXXXXXX. ", +" ................ooooooooooo................ ", +" .OOOOOO.ooooooooooooooo.OOOOOO. ", +" ..OOOOO.ooooooooooooooooo.OOOOO.. ", +" .OOOOO.ooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooo.OOOOOO. ", +" .OOOOO.ooooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooooo.OOOOOO. ", +" .OOOOO.ooooooooooooooooooooooo.OOOOO. ", +" ..OOOOO.ooooooooooooooooooooooo.OOOOO.. ", +" .OOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" ..OOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooo.OOOOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooo.OOOOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooooo.OOOOOOOOO. ", +" ..OOOOOOOO.ooooooooooooooooooo.OOOOOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooo.OOOOOOOOO.. ", +" .OOOOOOOOOO.ooooooooooooooo.OOOOOOOOOO. ", +" ..OOOOOOOOOO..ooooooooooo..OOOOOOOOOOO. ", +" .OOOOOOOOOOO..ooooooo..OOOOOOOOOOOO.. ", +" .OOOOOOOOOOOOO.......OOOOOOOOOOOOOO. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ................................ ", +" ", +" ......... ", +" ........ .+++++++++. ", +" ...++++++++... .++++++++++. ", +" ..++++++++++++.. ..++++++++++++. ", +" ..++++++++++++++++. .@++++++++++++. ", +" .++++@..+++++++++++..@@++++++++++++. ", +" .++++..++++++++++++++..@++++++++++++. ", +" .+++@.+++++++++++++++++.@+++++++++++. ", +" .+++@.+++++++++++++++++++.@++++++++++. ", +" .+++@.+++++++++++++++++++..++++++++++. ", +" .+++@.+++++++++++++++++++++++++++++++. ", +" .++++++++++++++++++++++++++++++++++++@. ", +" ..@++++++++++++++++++++++++++++++++++@. ", +" .@@+++++++++++++++++++++++++++++++++@. ", +" .@@++++++++++++++++++++++++++++++++@@. ", +" .@@@++++++++++++++++++++++++++++++@. ", +" ..@@@++++++++++++++++++++@@@++++@@. ", +" ...@@@@@@@@@@@@@@@@@@@@@@@@@@@@@. ", +" .............................. ", +" ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-f3.xbm b/hacks/images/noseguy/nose-f3.xbm new file mode 100644 index 00000000..e70f2293 --- /dev/null +++ b/hacks/images/noseguy/nose-f3.xbm @@ -0,0 +1,38 @@ +#define nose_f3_width 64 +#define nose_f3_height 64 +static unsigned char nose_f3_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,0xe0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x20,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x20,0x00,0x00,0x02,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xff,0x1f,0x00,0x00, + 0x04,0x00,0xf0,0x07,0x00,0x10,0x00,0x00,0x04,0x00,0x0c,0x18,0x00,0x10,0x00, + 0x00,0xfc,0xff,0x03,0xe0,0xff,0x1f,0x00,0x00,0x00,0x81,0x00,0x80,0x40,0x00, + 0x00,0x00,0x80,0x41,0x00,0x00,0xc1,0x00,0x00,0x00,0x80,0x20,0x00,0x00,0x82, + 0x00,0x00,0x00,0x40,0x20,0x00,0x00,0x02,0x01,0x00,0x00,0x40,0x10,0x00,0x00, + 0x04,0x01,0x00,0x00,0x20,0x10,0x00,0x00,0x04,0x02,0x00,0x00,0x20,0x08,0x00, + 0x00,0x08,0x02,0x00,0x00,0x30,0x08,0x00,0x00,0x08,0x06,0x00,0x00,0x10,0x08, + 0x00,0x00,0x08,0x04,0x00,0x00,0x10,0x08,0x00,0x00,0x08,0x0c,0x00,0x00,0x08, + 0x08,0x00,0x00,0x08,0x08,0x00,0x00,0x08,0x08,0x00,0x00,0x08,0x08,0x00,0x00, + 0x08,0x08,0x00,0x00,0x08,0x08,0x00,0x00,0x08,0x10,0x00,0x00,0x04,0x08,0x00, + 0x00,0x08,0x10,0x00,0x00,0x04,0x08,0x00,0x00,0x08,0x20,0x00,0x00,0x02,0x08, + 0x00,0x00,0x08,0x20,0x00,0x00,0x02,0x0c,0x00,0x00,0x18,0x40,0x00,0x00,0x01, + 0x04,0x00,0x00,0x10,0x80,0x00,0x80,0x00,0x04,0x00,0x00,0x10,0x00,0x03,0x60, + 0x00,0x06,0x00,0x00,0x30,0x00,0x0c,0x18,0x00,0x01,0x00,0x00,0x20,0x00,0xf0, + 0x07,0x00,0x01,0x00,0x00,0x60,0x00,0x00,0x00,0x80,0x01,0x00,0x00,0x40,0x00, + 0x00,0x00,0x80,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x08,0x20,0x00,0xff,0x00,0x00,0x00,0x00,0x08,0x40,0xe0,0x00,0x07,0x00, + 0x00,0x00,0x04,0x80,0x31,0x00,0x0c,0x00,0x00,0x00,0x04,0x00,0x09,0x00,0x30, + 0x00,0x00,0x00,0x04,0x00,0x06,0xc0,0x20,0x00,0x00,0x00,0x04,0x00,0x03,0x00, + 0x43,0x00,0x00,0x00,0x04,0x80,0x00,0x00,0x42,0x00,0x00,0x00,0x04,0x40,0x00, + 0x00,0x84,0x00,0x00,0x00,0x04,0x60,0x00,0x00,0x84,0x00,0x00,0x00,0x04,0x00, + 0x00,0x00,0x84,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0xc0,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00, + 0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x20,0x00,0x00, + 0x00,0x04,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x0e,0x00, + 0x00,0x00,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}; diff --git a/hacks/images/noseguy/nose-f3.xpm b/hacks/images/noseguy/nose-f3.xpm new file mode 100644 index 00000000..c60c5f37 --- /dev/null +++ b/hacks/images/noseguy/nose-f3.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_f3_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXX.......XXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXX..ooooooo..XXXXXXXXXXXXXXX. ", +" ................ooooooooooo................ ", +" .OOOOOO.ooooooooooooooo.OOOOOO. ", +" ..OOOOO.ooooooooooooooooo.OOOOO.. ", +" .OOOOO.ooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooo.OOOOOO. ", +" .OOOOO.ooooooooooooooooooooo.OOOOO. ", +" .OOOOOO.ooooooooooooooooooooo.OOOOOO. ", +" .OOOOO.ooooooooooooooooooooooo.OOOOO. ", +" ..OOOOO.ooooooooooooooooooooooo.OOOOO.. ", +" .OOOOOO.ooooooooooooooooooooooo.OOOOOO. ", +" .OOOOOO.ooooooooooooooooooooooo.OOOOOO.. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOO.ooooooooooooooooooooooo.OOOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooo.OOOOOOOO. ", +" .OOOOOOOO.ooooooooooooooooooooo.OOOOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooooo.OOOOOOOOO. ", +" .OOOOOOOOO.ooooooooooooooooooo.OOOOOOOO.. ", +" ..OOOOOOOOO.ooooooooooooooooo.OOOOOOOOO. ", +" .OOOOOOOOOO.ooooooooooooooo.OOOOOOOOOO. ", +" .OOOOOOOOOOO..ooooooooooo..OOOOOOOOOO.. ", +" ..OOOOOOOOOOOO..ooooooo..OOOOOOOOOOO. ", +" .OOOOOOOOOOOOOO.......OOOOOOOOOOOOO. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ................................ ", +" ", +" ......... ", +" .+++++++++. ........ ", +" .++++++++++. ...++++++++... ", +" .++++++++++++.. ..++++++++++++.. ", +" .++++++++++++@. .++++++++++++++++.. ", +" .++++++++++++@@..+++++++++++..@++++. ", +" .++++++++++++@..++++++++++++++..++++. ", +" .+++++++++++@.+++++++++++++++++.@+++. ", +" .++++++++++@.+++++++++++++++++++.@+++. ", +" .++++++++++..+++++++++++++++++++.@+++. ", +" .+++++++++++++++++++++++++++++++.@+++. ", +" .@++++++++++++++++++++++++++++++++++++. ", +" .@++++++++++++++++++++++++++++++++++@.. ", +" .@+++++++++++++++++++++++++++++++++@@. ", +" .@@++++++++++++++++++++++++++++++++@@. ", +" .@++++++++++++++++++++++++++++++@@@. ", +" .@@++++@@@++++++++++++++++++++@@@.. ", +" .@@@@@@@@@@@@@@@@@@@@@@@@@@@@@... ", +" .............................. ", +" ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-f4.xbm b/hacks/images/noseguy/nose-f4.xbm new file mode 100644 index 00000000..024eead8 --- /dev/null +++ b/hacks/images/noseguy/nose-f4.xbm @@ -0,0 +1,38 @@ +#define nose_f4_width 64 +#define nose_f4_height 64 +static unsigned char nose_f4_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,0xfc,0xff,0x01,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x1e,0x00, + 0x00,0x00,0x00,0x38,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x06,0x00,0x00,0x00, + 0x03,0x00,0x00,0x80,0x01,0x00,0x00,0x00,0x04,0x00,0x00,0x40,0x00,0x00,0x00, + 0x00,0x08,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x10,0x00,0x80, + 0x1f,0x00,0x40,0x00,0x00,0x08,0x00,0x60,0x60,0x00,0x80,0x00,0x00,0x08,0x00, + 0x10,0x80,0x00,0x80,0x00,0x00,0x04,0x00,0x08,0x00,0x01,0x00,0x01,0x00,0x04, + 0x00,0x08,0x00,0x01,0x00,0x01,0x00,0x02,0x00,0x18,0x80,0x01,0x00,0x02,0x00, + 0x02,0x00,0x68,0x60,0x01,0x00,0x02,0x00,0x02,0x00,0x88,0x1f,0x01,0x00,0x02, + 0x00,0x02,0x00,0x08,0x00,0x01,0x00,0x02,0x00,0x02,0x00,0x10,0x80,0x00,0x00, + 0x03,0x00,0x06,0x00,0x60,0x60,0x00,0x80,0x02,0x00,0x0c,0x00,0x80,0x1f,0x00, + 0x40,0x01,0x00,0x14,0x00,0x00,0x00,0x00,0x20,0x01,0x00,0x28,0x00,0x00,0x00, + 0x00,0x90,0x00,0x00,0x50,0x00,0x00,0x00,0x00,0x48,0x00,0x00,0xa0,0x01,0x00, + 0x00,0x00,0x26,0x00,0x00,0x40,0x1e,0x00,0x00,0xc0,0x11,0x00,0x00,0x80,0xe1, + 0x03,0x00,0x3c,0x0c,0x00,0x00,0x00,0x0e,0xfc,0xff,0x83,0x03,0x00,0x00,0x00, + 0xf0,0x01,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x00, + 0x00,0x80,0x03,0x00,0x0c,0x00,0x00,0x00,0x00,0x80,0x02,0x00,0x14,0x00,0x00, + 0x00,0x00,0x60,0x04,0x00,0x12,0x00,0x00,0xc0,0x7f,0x10,0x04,0x00,0x22,0xe0, + 0x01,0x70,0xc0,0x18,0x08,0x00,0x61,0x1c,0x06,0x10,0x00,0x0f,0x30,0xc0,0x80, + 0x07,0x08,0x08,0x00,0x06,0xc0,0x3f,0x80,0x01,0x08,0x08,0x00,0x18,0x00,0x02, + 0xc0,0x00,0x10,0x04,0x00,0x30,0x00,0x05,0x30,0x00,0x10,0x04,0x00,0x00,0x80, + 0x08,0x18,0x00,0x20,0x04,0x00,0x00,0x80,0x08,0x00,0x00,0x20,0x04,0x00,0x00, + 0x40,0x10,0x00,0x00,0x20,0x24,0x00,0x00,0x40,0x10,0x00,0x00,0x22,0x24,0x00, + 0x00,0x40,0x10,0x00,0x00,0x22,0x44,0x00,0x00,0x40,0x10,0x00,0x00,0x11,0x84, + 0x01,0x00,0xc0,0x18,0x00,0xc0,0x10,0x08,0x00,0x00,0x80,0x08,0x00,0x00,0x08, + 0x30,0x00,0x00,0x80,0x08,0x00,0x00,0x04,0xe0,0xff,0xff,0xff,0xf8,0xff,0xff, + 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00}; diff --git a/hacks/images/noseguy/nose-f4.xpm b/hacks/images/noseguy/nose-f4.xpm new file mode 100644 index 00000000..faa52e03 --- /dev/null +++ b/hacks/images/noseguy/nose-f4.xpm @@ -0,0 +1,73 @@ +/* XPM */ +static char * nose_f4_xpm[] = { +"64 64 6 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ", +" ............... ", +" ....XXXXXXXXXXXXXXX.... ", +" ...XXXXXXXXXXXXXXXXXXXXXXX... ", +" ..XXXXXXXXXXXXXXXXXXXXXXXXXXXXX.. ", +" ..XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.. ", +" .XXXXXXXXXXXXXXXXXX......XXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXX..XXXXXX..XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXX.XXXXXXXXXX.XXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXX.XXXXXXXXXXXX.XXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXX.XXXXXXXXXXXX.XXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXX..XXXXXXXXXX..XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXX.X..XXXXXX..X.XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXX.XXX......XXX.XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXX.XXXXXXXXXXXX.XXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXX.XXXXXXXXXX.XXXXXXXXXXXXXXXX.. ", +" ..XXXXXXXXXXXXXXXXXX..XXXXXX..XXXXXXXXXXXXXXXX. . ", +" ..XXXXXXXXXXXXXXXXXXX......XXXXXXXXXXXXXXXXX.X. ", +" .X.XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.XX. ", +" .X.XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.XX. ", +" .X.XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.XX. ", +" .X..XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX..XX. ", +" .XX....XXXXXXXXXXXXXXXXXXXXXXXXX...XXX. ", +" ..XXXX.....XXXXXXXXXXXXXXXX....XXXX.. ", +" ...XXXXXX................XXXXX... ", +" .....XXXXXXXXXXXXXXXXXX.... ", +" ................... ", +" ...oooooooooooooooo.. ", +" .+.oooooooooooooooo.+. ", +" ..+++.oooooooooooooo.++. ", +" ......... .+++++.oooooooooooooo.+++. .... ", +" ...+++++++.. ..++++++.oooooooooooo.++++.. ...++++.. ", +" .+++++++++++....@+++++++..oooooooo..++++++@....++++++++. ", +" .+++++++++++++..@@+++++++++........+++++++@@..++++++++++. ", +" .+++++++++++++++..@+++++++++++.++++++++++@@..++++++++++++. ", +" .+++++++++++++++++..++++++++++. .+++++++++..++++++++++++++. ", +" .++++++++++++++++++++++++++++. .+++++++..++++++++++++++++. ", +" .++++++++++++++++++++++++++++. .+++++++++++++++++++++++++. ", +" .+++++++++++++++++++++++++++. .++++++++++++++++++++++++. ", +" .+@.++++++++++++++++++++++++. .++++++++++++++++++++.+++. ", +" .++.++++++++++++++++++++++++. .++++++++++++++++++++.@+@. ", +" .@+@.+++++++++++++++++++++++. .+++++++++++++++++++.@+@. ", +" .@@+@..++++++++++++++++++++@.. ..@++++++++++++++++..@++@. ", +" .@@+++++++++++++++++++++++@@. .@@+++++++++++++++++++@@. ", +" ..@@@@@@@@@@@@@@@@@@@@@@@@@. .@@@@@@@@@@@@@@@@@@@@@@. ", +" ........................... ....................... ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-l1.xbm b/hacks/images/noseguy/nose-l1.xbm new file mode 100644 index 00000000..e3cb7030 --- /dev/null +++ b/hacks/images/noseguy/nose-l1.xbm @@ -0,0 +1,38 @@ +#define nose_l1_width 64 +#define nose_l1_height 64 +static unsigned char nose_l1_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,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x04,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00, + 0x08,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x20,0x00, + 0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00,0xf0,0x03,0x00,0x00,0x80,0x00, + 0x00,0x00,0x0e,0x0c,0x00,0x00,0x80,0x01,0x00,0x00,0x03,0x30,0x00,0x00,0x00, + 0x01,0x00,0x80,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x40,0x00,0xc0,0x00,0x00, + 0x00,0x02,0x00,0x20,0x00,0x80,0x00,0x00,0x00,0x04,0x00,0x10,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x0c,0x00,0x08,0x00,0x00, + 0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00, + 0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10, + 0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x10,0x00,0x00,0x01,0x00,0x00, + 0x18,0x00,0x20,0x00,0x00,0x01,0x00,0x00,0x08,0x00,0x40,0x00,0x80,0x00,0x00, + 0x00,0x08,0x00,0x80,0x00,0x40,0x00,0x00,0x00,0x0c,0x00,0x00,0x01,0x20,0x00, + 0x00,0x00,0x04,0x00,0x00,0x06,0x18,0x00,0x00,0x00,0x06,0x00,0x00,0xf8,0x07, + 0x00,0x00,0x00,0x02,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x0f,0x00,0x00,0x00, + 0x00,0xff,0x00,0x04,0x10,0x00,0x00,0x00,0xc0,0x00,0x03,0x03,0x10,0x00,0x00, + 0x00,0x30,0x00,0x0c,0x01,0x20,0x00,0x00,0x00,0x08,0x00,0x98,0x00,0x20,0x00, + 0x00,0x00,0x0c,0x03,0x60,0x00,0x20,0x00,0x00,0x00,0xc2,0x00,0xc0,0x00,0x20, + 0x00,0x00,0x00,0x42,0x00,0x80,0x00,0x20,0x00,0x00,0x00,0x21,0x00,0x00,0x01, + 0x20,0x00,0x00,0x00,0x21,0x00,0x00,0x01,0x20,0x00,0x00,0x00,0x21,0x00,0x00, + 0x00,0x20,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x20,0x00,0x00,0x00, + 0x18,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x10,0x00,0x00, + 0x00,0xc0,0xff,0xff,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,0x00}; diff --git a/hacks/images/noseguy/nose-l1.xpm b/hacks/images/noseguy/nose-l1.xpm new file mode 100644 index 00000000..205d18be --- /dev/null +++ b/hacks/images/noseguy/nose-l1.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_l1_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" ......OOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ...ooOOOO..OOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" ..oooOOOOOOO..OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOO.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOO..OOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOO.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooooOOOOOOOOOOOOOOo.OOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .ooooOOOOOOOOOOoooo.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooooooOOOOOoooo.OOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooooooooooooo.OOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .oooooooooooo.OOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ..oooooooo..OOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" ........OOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .............................. ", +" ", +" ......... ", +" ........ .+++++++++. ", +" ...++++++++... .++++++++++. ", +" ..++++++++++++.. ..++++++++++++. ", +" ..++++++++++++++++. .@++++++++++++. ", +" .++++@..+++++++++++..@@++++++++++++. ", +" .++++..++++++++++++++..@++++++++++++. ", +" .+++@.+++++++++++++++++.@+++++++++++. ", +" .+++@.+++++++++++++++++++.@++++++++++. ", +" .+++@.+++++++++++++++++++..++++++++++. ", +" .+++@.+++++++++++++++++++++++++++++++. ", +" .++++++++++++++++++++++++++++++++++++@. ", +" ..@++++++++++++++++++++++++++++++++++@. ", +" .@@+++++++++++++++++++++++++++++++++@. ", +" .@@++++++++++++++++++++++++++++++++@@. ", +" .@@@++++++++++++++++++++++++++++++@. ", +" ..@@@++++++++++++++++++++@@@++++@@. ", +" ...@@@@@@@@@@@@@@@@@@@@@@@@@@@@@. ", +" .............................. ", +" ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-l2.xbm b/hacks/images/noseguy/nose-l2.xbm new file mode 100644 index 00000000..fa39343b --- /dev/null +++ b/hacks/images/noseguy/nose-l2.xbm @@ -0,0 +1,38 @@ +#define nose_l2_width 64 +#define nose_l2_height 64 +static unsigned char nose_l2_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,0xc0,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x04,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x04,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00, + 0x08,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x20,0x00, + 0x00,0xf8,0xff,0xff,0xff,0xff,0x3f,0x00,0x00,0xf0,0x03,0x00,0x00,0x80,0x00, + 0x00,0x00,0x0e,0x0c,0x00,0x00,0x80,0x01,0x00,0x00,0x03,0x30,0x00,0x00,0x00, + 0x01,0x00,0x80,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x40,0x00,0xc0,0x00,0x00, + 0x00,0x02,0x00,0x20,0x00,0x80,0x00,0x00,0x00,0x04,0x00,0x10,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x0c,0x00,0x08,0x00,0x00, + 0x00,0x00,0x00,0x08,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x08,0x00, + 0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10, + 0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x10,0x00,0x00,0x01,0x00,0x00, + 0x18,0x00,0x10,0x00,0x00,0x01,0x00,0x00,0x08,0x00,0x20,0x00,0x80,0x00,0x00, + 0x00,0x08,0x00,0x40,0x00,0x40,0x00,0x00,0x00,0x0c,0x00,0x80,0x00,0x20,0x00, + 0x00,0x00,0xe4,0x00,0x00,0x03,0x18,0x00,0x00,0x00,0x26,0x03,0x00,0xfc,0x07, + 0x00,0x00,0x00,0x12,0x0c,0x00,0x00,0xf8,0xff,0xff,0xff,0x11,0x10,0x80,0x1f, + 0x00,0x00,0x00,0x00,0x08,0x20,0x60,0x60,0xc0,0x07,0x00,0x00,0x04,0x40,0x10, + 0xc0,0x20,0x08,0x00,0x1f,0x02,0x40,0x08,0x00,0x21,0x10,0xc0,0x60,0x02,0x40, + 0x04,0x00,0x12,0x20,0x20,0x80,0x02,0x20,0xc2,0x00,0x14,0x40,0x18,0x00,0x03, + 0x20,0x22,0x00,0x0c,0x80,0x04,0x03,0x02,0x10,0x12,0x00,0x08,0x80,0x86,0x00, + 0x04,0x10,0x12,0x00,0x10,0x80,0x42,0x00,0x18,0x08,0x12,0x00,0x10,0x40,0x42, + 0x00,0x00,0x04,0x02,0x00,0x20,0x40,0x42,0x00,0x00,0x04,0x02,0x00,0x00,0x20, + 0x42,0x00,0x00,0x02,0x04,0x00,0x00,0x20,0x02,0x00,0x00,0x01,0x04,0x00,0x00, + 0x20,0x02,0x00,0x00,0x01,0x08,0x00,0x00,0x20,0x04,0x00,0x80,0x00,0x10,0x00, + 0x00,0x20,0x0c,0x00,0x80,0x00,0x60,0x00,0x00,0x10,0x08,0x00,0x40,0x00,0x80, + 0xff,0xff,0x0f,0x30,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00}; diff --git a/hacks/images/noseguy/nose-l2.xpm b/hacks/images/noseguy/nose-l2.xpm new file mode 100644 index 00000000..f08a72eb --- /dev/null +++ b/hacks/images/noseguy/nose-l2.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_l2_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" ......OOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" ...ooOOOO..OOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" ..oooOOOOOOO..OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOO.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOO..OOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOO.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .ooooOOOOOOOOOOOOOOo.OOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .ooooOOOOOOOOOOoooo.OOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooooooOOOOOoooo.OOOOOOOOOOOOOOOOOOOOOOOOOOO. ", +" .oooooooooooooo.OOOOOOOOOOOOOOOOOOOOOOOOOOO.. ", +" .oooooooooooo.OOOOOOOOOOOOOOOOOOOOOOOOOOOO. ... ", +" ..oooooooo..OOOOOOOOOOOOOOOOOOOOOOOOOOOO.. .++.. ", +" ........OOOOOOOOOOOOOOOOOOOOOOOOOOOOOO. .+++++.. ", +" .............................. .+++++++. ", +" ...... .+++++++++. ", +" ..++++++.. ..... .++++++++++@. ", +" .+++++++++.. .+++++. ..... .+++++++++++@. ", +" .++++++++++++. .++++++. ..+++++.. .++++++++++@@. ", +" .++++++++++++++. .++++++++. .+++++++++. .@+++++++++@. ", +" .++++..++++++++++. .+++++++++. ..+++++++++++..@++++++++@@. ", +" .+++.@@++++++++++..@++++++++++. .+++++..+++++++.@@+++++++@. ", +" .++.@+++++++++++++.@@+++++++++. ..++++.@@++++++++.@@+++++@@. ", +" .++.@++++++++++++++.@+++++++++. .++++.@+++++++++++..++++@@. ", +" .++.@++++++++++++++.@++++++++. .++++.@+++++++++++++++++@. ", +" .@++++++++++++++++++.@+++++++. .++++.@++++++++++++++++@@. ", +" .@@+++++++++++++++++++++++++. .++++.@+++++++++++++++@@. ", +" .@++++++++++++++++++++++++@. .+++++++++++++++++++++@. ", +" .@@+++++++++++++++++++++++@. .++++++++++++++++++++@@. ", +" .@@++++++++++++++++++++++@. .+++++++++++++++++++@. ", +" .@@@+++++++++++++++++++@@. ..+++++++++++++++++@@. ", +" ..@@@@@@@@@@@@@@@@@@@@@. .@@@+++@@@++++++@@@. ", +" ..................... ..@@@@@@@@@@@@@@.. ", +" .............. ", +" ", +" ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-r1.xbm b/hacks/images/noseguy/nose-r1.xbm new file mode 100644 index 00000000..72df86c2 --- /dev/null +++ b/hacks/images/noseguy/nose-r1.xbm @@ -0,0 +1,38 @@ +#define nose_r1_width 64 +#define nose_r1_height 64 +static unsigned char nose_r1_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,0xe0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x20,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x20,0x00,0x00,0x02,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xff,0x1f,0x00,0x00, + 0x04,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x10,0x00, + 0x00,0xfc,0xff,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x01,0x00,0x00,0xc0,0x0f, + 0x00,0x00,0x80,0x01,0x00,0x00,0x30,0x70,0x00,0x00,0x80,0x00,0x00,0x00,0x0c, + 0xc0,0x00,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x01,0x00,0x40,0x00,0x00,0x00, + 0x03,0x00,0x02,0x00,0x20,0x00,0x00,0x00,0x01,0x00,0x04,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x08,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x10,0x00, + 0x00,0x00,0x00,0x00,0x10,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10, + 0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00, + 0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x18,0x00,0x00,0x80,0x00, + 0x00,0x08,0x00,0x10,0x00,0x00,0x80,0x00,0x00,0x04,0x00,0x10,0x00,0x00,0x00, + 0x01,0x00,0x02,0x00,0x30,0x00,0x00,0x00,0x02,0x00,0x01,0x00,0x20,0x00,0x00, + 0x00,0x04,0x80,0x00,0x00,0x60,0x00,0x00,0x00,0x18,0x60,0x00,0x00,0x40,0x00, + 0x00,0x00,0xe0,0x1f,0x00,0x00,0x80,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x08,0x20,0x00,0xff,0x00,0x00,0x00,0x00,0x08,0xc0,0xc0,0x00,0x03,0x00, + 0x00,0x00,0x04,0x80,0x30,0x00,0x0c,0x00,0x00,0x00,0x04,0x00,0x19,0x00,0x10, + 0x00,0x00,0x00,0x04,0x00,0x06,0xc0,0x30,0x00,0x00,0x00,0x04,0x00,0x03,0x00, + 0x43,0x00,0x00,0x00,0x04,0x00,0x01,0x00,0x42,0x00,0x00,0x00,0x04,0x80,0x00, + 0x00,0x84,0x00,0x00,0x00,0x04,0x80,0x00,0x00,0x84,0x00,0x00,0x00,0x04,0x00, + 0x00,0x00,0x84,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00, + 0x02,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x20,0x00,0x00, + 0x00,0x04,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x0e,0x00, + 0x00,0x00,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}; diff --git a/hacks/images/noseguy/nose-r1.xpm b/hacks/images/noseguy/nose-r1.xpm new file mode 100644 index 00000000..901dd428 --- /dev/null +++ b/hacks/images/noseguy/nose-r1.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_r1_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOO...... ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOO..OOOOoo... ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO..OOOOOOOooo.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.OOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOO..OOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.OOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOO.oOOOOOOOOOOOOOOoooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.ooooOOOOOOOOOOoooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOO.ooooOOOOOooooooo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOO.oooooooooooooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOO.oooooooooooo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOO..oooooooo.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOO........ ", +" .............................. ", +" ", +" ......... ", +" .+++++++++. ........ ", +" .++++++++++. ...++++++++... ", +" .++++++++++++.. ..++++++++++++.. ", +" .++++++++++++@. .++++++++++++++++.. ", +" .++++++++++++@@..+++++++++++..@++++. ", +" .++++++++++++@..++++++++++++++..++++. ", +" .+++++++++++@.+++++++++++++++++.@+++. ", +" .++++++++++@.+++++++++++++++++++.@+++. ", +" .++++++++++..+++++++++++++++++++.@+++. ", +" .+++++++++++++++++++++++++++++++.@+++. ", +" .@++++++++++++++++++++++++++++++++++++. ", +" .@++++++++++++++++++++++++++++++++++@.. ", +" .@+++++++++++++++++++++++++++++++++@@. ", +" .@@++++++++++++++++++++++++++++++++@@. ", +" .@++++++++++++++++++++++++++++++@@@. ", +" .@@++++@@@++++++++++++++++++++@@@.. ", +" .@@@@@@@@@@@@@@@@@@@@@@@@@@@@@... ", +" .............................. ", +" ", +" ", +" "}; diff --git a/hacks/images/noseguy/nose-r2.xbm b/hacks/images/noseguy/nose-r2.xbm new file mode 100644 index 00000000..eb750ca7 --- /dev/null +++ b/hacks/images/noseguy/nose-r2.xbm @@ -0,0 +1,38 @@ +#define nose_r2_width 64 +#define nose_r2_height 64 +static unsigned char nose_r2_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,0xe0,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x20,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x20,0x00,0x00,0x02,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xff,0x1f,0x00,0x00, + 0x04,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x10,0x00, + 0x00,0xfc,0xff,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x01,0x00,0x00,0xc0,0x0f, + 0x00,0x00,0x80,0x01,0x00,0x00,0x30,0x70,0x00,0x00,0x80,0x00,0x00,0x00,0x0c, + 0xc0,0x00,0x00,0x40,0x00,0x00,0x00,0x02,0x00,0x01,0x00,0x40,0x00,0x00,0x00, + 0x03,0x00,0x02,0x00,0x20,0x00,0x00,0x00,0x01,0x00,0x04,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x08,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x10,0x00, + 0x00,0x00,0x00,0x00,0x10,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10, + 0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00, + 0x10,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x18,0x00,0x00,0x80,0x00, + 0x00,0x08,0x00,0x10,0x00,0x00,0x80,0x00,0x00,0x08,0x00,0x10,0x00,0x00,0x00, + 0x01,0x00,0x04,0x00,0x30,0x00,0x00,0x00,0x02,0x00,0x02,0x00,0x27,0x00,0x00, + 0x00,0x04,0x00,0x01,0xc0,0x64,0x00,0x00,0x00,0x18,0xc0,0x00,0x30,0x48,0x00, + 0x00,0x00,0xe0,0x3f,0x00,0x08,0x88,0xff,0xff,0xff,0x1f,0x00,0x00,0x04,0x10, + 0x00,0x00,0x00,0x00,0xf8,0x01,0x02,0x20,0x00,0x00,0xe0,0x03,0x06,0x06,0x02, + 0x40,0xf8,0x00,0x10,0x04,0x03,0x08,0x02,0x40,0x06,0x03,0x08,0x84,0x00,0x10, + 0x04,0x40,0x01,0x04,0x04,0x48,0x00,0x20,0x04,0xc0,0x00,0x18,0x02,0x28,0x00, + 0x43,0x08,0x40,0xc0,0x20,0x01,0x30,0x00,0x44,0x08,0x20,0x00,0x61,0x01,0x10, + 0x00,0x48,0x10,0x18,0x00,0x42,0x01,0x08,0x00,0x48,0x20,0x00,0x00,0x42,0x02, + 0x08,0x00,0x48,0x20,0x00,0x00,0x42,0x02,0x04,0x00,0x40,0x40,0x00,0x00,0x42, + 0x04,0x00,0x00,0x40,0x80,0x00,0x00,0x40,0x04,0x00,0x00,0x20,0x80,0x00,0x00, + 0x40,0x04,0x00,0x00,0x20,0x00,0x01,0x00,0x20,0x04,0x00,0x00,0x10,0x00,0x01, + 0x00,0x30,0x04,0x00,0x00,0x08,0x00,0x02,0x00,0x10,0x08,0x00,0x00,0x06,0x00, + 0x0c,0x00,0x0c,0xf0,0xff,0xff,0x01,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00}; diff --git a/hacks/images/noseguy/nose-r2.xpm b/hacks/images/noseguy/nose-r2.xpm new file mode 100644 index 00000000..ddf0edaf --- /dev/null +++ b/hacks/images/noseguy/nose-r2.xpm @@ -0,0 +1,74 @@ +/* XPM */ +static char * nose_r2_xpm[] = { +"64 64 7 1", +" c black m black", +". c black m white", +"X c gray m black", +"o c yellow m black", +"O c yellow2 m black", +"+ c purple m black", +"@ c purple3 m black", +" ", +" ", +" ", +" ", +" ", +" ", +" ..................... ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" .XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. ", +" ........................................... ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOO...... ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOO..OOOOoo... ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO..OOOOOOOooo.. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.OOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOO..OOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.OOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOoo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOooo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOO.oOOOOOOOOOOOOOOoooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOO.ooooOOOOOOOOOOoooo. ", +" .OOOOOOOOOOOOOOOOOOOOOOOOOOO.ooooOOOOOooooooo. ", +" ..OOOOOOOOOOOOOOOOOOOOOOOOOOO.oooooooooooooo. ", +" ... .OOOOOOOOOOOOOOOOOOOOOOOOOOOO.oooooooooooo. ", +" ..++. ..OOOOOOOOOOOOOOOOOOOOOOOOOOOO..oooooooo.. ", +" ..+++++. .OOOOOOOOOOOOOOOOOOOOOOOOOOOOOO........ ", +" .+++++++. .............................. ", +" .+++++++++. ...... ", +" .@++++++++++. ..... ..++++++.. ", +" .@+++++++++++. ..... .+++++. ..+++++++++. ", +" .@@++++++++++. ..+++++.. .++++++. .++++++++++++. ", +" .@+++++++++@. .+++++++++. .++++++++. .++++++++++++++. ", +" .@@++++++++@..+++++++++++.. .+++++++++. .++++++++++..++++. ", +" .@+++++++@@.+++++++..+++++. .++++++++++@..++++++++++@@.+++. ", +" .@@+++++@@.++++++++@@.++++.. .+++++++++@@.+++++++++++++@.++. ", +" .@@++++..+++++++++++@.++++. .+++++++++@.++++++++++++++@.++. ", +" .@+++++++++++++++++@.++++. .++++++++@.++++++++++++++@.++. ", +" .@@++++++++++++++++@.++++. .+++++++@.++++++++++++++++++@. ", +" .@@+++++++++++++++@.++++. .+++++++++++++++++++++++++@@. ", +" .@+++++++++++++++++++++. .@++++++++++++++++++++++++@. ", +" .@@++++++++++++++++++++. .@+++++++++++++++++++++++@@. ", +" .@+++++++++++++++++++. .@++++++++++++++++++++++@@. ", +" .@@+++++++++++++++++.. .@@+++++++++++++++++++@@@. ", +" .@@@++++++@@@+++@@@. .@@@@@@@@@@@@@@@@@@@@@.. ", +" ..@@@@@@@@@@@@@@.. ..................... ", +" .............. ", +" ", +" ", +" ", +" "}; diff --git a/hacks/images/puzzle/puzzle.xbm b/hacks/images/puzzle/puzzle.xbm new file mode 100644 index 00000000..b09d6688 --- /dev/null +++ b/hacks/images/puzzle/puzzle.xbm @@ -0,0 +1,1614 @@ +#define puzzle_width 523 +#define puzzle_height 366 +static char puzzle_bits[] = { + 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,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x01,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x10,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78, + 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x20,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00, + 0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x08,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x08,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x04,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,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,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x02,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,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,0xf8, + 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,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,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,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04, + 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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x08,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,0xf8, + 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,0x10,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10, + 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,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x08, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x20,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,0xf8, + 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,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20, + 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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,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,0xf8, + 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,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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,0x08, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20, + 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,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x20,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,0x00,0xf8,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,0x10, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0x00,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x10,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,0x00,0xf8, + 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,0x10,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08, + 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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,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,0xf8, + 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,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,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,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 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,0xf8,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,0x80,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x02,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,0xf8,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, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,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,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x01,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,0xf8, + 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,0x02,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,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,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x40,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,0xf8,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, + 0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x10,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x02,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x08,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x03,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00, + 0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x0c,0x00,0x00,0x00,0x00,0x00,0x60,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x18, + 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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x00,0x00,0x00,0x00,0x00,0x06,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x80,0x01,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00, + 0x00,0x70,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x0e,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0xf0,0x01,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0xff,0x0f,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,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,0xf8,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,0x20,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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,0x80,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,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,0x04,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x03,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,0x10,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,0xff,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0xc0,0x07, + 0x00,0x7c,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x1f,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x80,0x03,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,0x40,0x00,0x00,0x00,0x00,0x00,0x0e,0x00,0x00, + 0xe0,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x1c, + 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,0x80,0x00,0x00, + 0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0xc0,0x00,0x00,0x00,0x00,0x60,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,0x01,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x18,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x80,0x01,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,0x02,0x00,0x00,0x00,0x0c, + 0x00,0x00,0x00,0x00,0x60,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x0c,0x00,0x00, + 0x00,0x00,0x00,0x06,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,0x04,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x80,0x01,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x00,0x18,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,0x08,0x00,0x00,0xc0,0x00,0x00,0x00,0x00, + 0x00,0x00,0x06,0x00,0x00,0xf8,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00, + 0x20,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,0x10,0x00, + 0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0xf8,0x00,0x00,0x60, + 0x00,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x20,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x30, + 0x00,0x00,0xf8,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff, + 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0xff,0xff,0x07,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0xf8,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,0x80,0x00,0x00,0xf8, + 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,0x03,0x00,0xf8,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,0x04,0x00,0xf8,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, + 0x08,0x00,0xf8,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0xf8,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,0x20,0x00,0xf8, + 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,0x40,0x00,0xf8,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,0x40,0x00,0xf8,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, + 0x80,0x00,0xf8,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,0x00,0x00,0x01,0xf8,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,0x02,0xf8, + 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,0x02,0xf8,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,0x04,0xf8,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,0x08,0xf8,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,0x08,0xf8,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0xf8, + 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,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x10,0xf8,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,0x00,0x00,0x20,0xf8,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,0x00, + 0x00,0x20,0xf8,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,0x40,0xf8,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,0x40,0xf8, + 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,0xf8,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,0xf8,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,0xf8,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,0x00,0x00,0x00,0x00,0xf9,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,0x00,0x00,0x00,0x00,0xf9, + 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,0x00,0x00,0x00,0x00,0xf9,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,0xfa,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,0xfa,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,0xfa,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,0xfa, + 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,0xfa,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,0xfc,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,0xfc,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,0xfc,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,0xfc, + 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,0xfc,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,0xfc,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,0xfc,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,0xfc,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,0xfc, + 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,0xfc,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,0xfc,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,0xfc,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,0xfc,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,0xfc, + 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,0xfc,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,0xfa,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,0xfa,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,0xfa,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,0xfa, + 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,0xfa,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,0x00,0x00,0x00,0x00,0xf9,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,0x00,0x00, + 0x00,0x00,0xf9,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,0x00,0x00,0x00,0x00,0xf9,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,0xf8, + 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,0xf8,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,0xf8,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,0x40,0xf8,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,0x40,0xf8,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,0x00,0x00,0x20,0xf8, + 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,0x00,0x00,0x20,0xf8,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,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0xf8,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x10,0xf8,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,0x08,0xf8,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,0x08,0xf8, + 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,0x04,0xf8,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,0x02,0xf8,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,0x02,0xf8,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,0x00,0x00,0x01,0xf8,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,0x80,0x00,0xf8, + 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,0x40,0x00,0xf8,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,0x40,0x00,0xf8,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, + 0x20,0x00,0xf8,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0xf8,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,0x08,0x00,0xf8, + 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,0x04,0x00,0xf8,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,0x03,0x00,0xf8,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,0x80, + 0x00,0x00,0xf8,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff, + 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0xff,0xff,0x07,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0xf8,0x00,0x00,0x60,0x00,0x00,0x00, + 0x00,0x00,0x00,0xc0,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,0x20,0x00,0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0xf8, + 0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0x10,0x00,0x00,0x20,0x00,0x00,0x00,0x00, + 0x00,0x00,0x08,0x00,0x00,0xf8,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x00, + 0x18,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,0x08,0x00, + 0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x0c,0x00,0x00,0x00,0x00,0x00,0x06,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,0x04,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x00,0x80,0x01, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x80,0x01,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,0x02,0x00,0x00,0x00,0x0c, + 0x00,0x00,0x00,0x00,0x60,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0xc0,0x00,0x00, + 0x00,0x00,0x60,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,0x01,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x07,0x00,0x00,0x00,0x1c,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,0x80,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00, + 0x00,0x07,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x80,0x03, + 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,0x40,0x00,0x00, + 0x00,0x00,0x00,0x0e,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0xc0,0x07,0x00,0x7c,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,0x20,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x1f,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x03,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,0x10,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,0xff,0x00,0x00,0x00,0x00,0x00,0xf8,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,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x02,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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,0x80,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x40, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,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,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,0xf8,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,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0xff,0x0f,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0xf0,0x01,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x00,0x00, + 0x00,0x0e,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0x70,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x80,0x01, + 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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x00,0x00,0x00,0x00,0x00,0x06,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x30,0x00,0x00,0x00,0x00,0x00,0x18,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0c,0x00,0x00,0x00, + 0x00,0x00,0x60,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x03,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x18,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x30,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x08,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,0xf8, + 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,0x10,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x80,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,0xf8, + 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,0x02,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01, + 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,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x01,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,0xf8,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,0x80, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,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,0xf8,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,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x02,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,0xf8, + 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,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,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,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04, + 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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x08,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,0xf8, + 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,0x10,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10, + 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,0x00,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x10,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,0x00,0xf8,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,0x08, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x20,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,0x00,0xf8, + 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,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,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,0xf8, + 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,0x04,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40, + 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,0xf8,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,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,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,0x08, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x20,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,0xf8, + 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,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20, + 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,0xf8,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,0x08,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x10, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x10,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,0xf8, + 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,0x10,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08, + 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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,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,0xf8,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,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,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,0xf8, + 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,0x40,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04, + 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,0xf8,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,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,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, + 0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x04,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x00,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x00,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x20,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,0xf8,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, + 0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,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,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x20,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,0xf8, + 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,0x20,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x02,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08, + 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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x01,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x02,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x01, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00, + 0x00,0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x08,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,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x40,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00, + 0x00,0x20,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x20,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,0xf8,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x40,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x08,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf8,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,0x07,0x00,0x00,0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 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,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8}; diff --git a/hacks/images/puzzle/puzzle_a_e_f.xbm b/hacks/images/puzzle/puzzle_a_e_f.xbm new file mode 100644 index 00000000..69601290 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_e_f.xbm @@ -0,0 +1,77 @@ +#define puzzle_a_e_f_width 88 +#define puzzle_a_e_f_height 78 +#define puzzle_a_e_f_x_hot 20 +#define puzzle_a_e_f_y_hot 6 +static unsigned char puzzle_a_e_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0x0f, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, 0xff, 0xff, + 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, + 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x7e, 0x80, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xc0, 0xff, 0xc1, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x03, 0xfc, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x00, 0xf0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, + 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0x0f, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_e_h.xbm b/hacks/images/puzzle/puzzle_a_e_h.xbm new file mode 100644 index 00000000..a0de0dd8 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_e_h.xbm @@ -0,0 +1,77 @@ +#define puzzle_a_e_h_width 88 +#define puzzle_a_e_h_height 78 +#define puzzle_a_e_h_x_hot 20 +#define puzzle_a_e_h_y_hot 6 +static unsigned char puzzle_a_e_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x3f, 0x0c, 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, 0x03, 0x00, 0x00, 0xc0, 0x3f, 0x00, + 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, + 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, + 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, 0x60, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x60, 0x00, + 0x00, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, + 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0xc0, + 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0xc0, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x60, 0x00, 0x7e, 0x80, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xc0, 0xff, 0xc1, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xe0, 0xc1, 0xff, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x70, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x70, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0xe0, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0xc0, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x7f, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, + 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, + 0x00, 0x70, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, + 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0xc0, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0xc0, 0x01, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x38, 0x00, 0xc0, 0x01, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, + 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, + 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x7c, + 0x00, 0x00, 0xc0, 0x3f, 0x00, 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, + 0x00, 0x00, 0xfc, 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, 0x03, 0x00, 0x00, + 0x00, 0xc0, 0x3f, 0x0c, 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_f.xbm b/hacks/images/puzzle/puzzle_a_f.xbm new file mode 100644 index 00000000..10e92431 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_f.xbm @@ -0,0 +1,96 @@ +#define puzzle_a_f_width 108 +#define puzzle_a_f_height 78 +#define puzzle_a_f_x_hot 20 +#define puzzle_a_f_y_hot 5 +static unsigned char puzzle_a_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, + 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0xc0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x80, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xe0, 0x07, 0x00, 0xc0, 0xff, + 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf8, 0x3f, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf8, + 0x3f, 0x00, 0x00, 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0xc0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, 0x00, 0x00, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, + 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_h.xbm b/hacks/images/puzzle/puzzle_a_h.xbm new file mode 100644 index 00000000..dc9cc6d1 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_h.xbm @@ -0,0 +1,96 @@ +#define puzzle_a_h_width 108 +#define puzzle_a_h_height 78 +#define puzzle_a_h_x_hot 20 +#define puzzle_a_h_y_hot 5 +static unsigned char puzzle_a_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x0c, + 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x3f, 0x00, 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0xc0, + 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0xfe, 0x07, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, + 0xf0, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x80, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0xe0, 0x07, 0x00, 0xc0, 0xff, + 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0xf8, 0x3f, 0x00, + 0xe0, 0xc1, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, + 0x78, 0x00, 0x70, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x07, 0xe0, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x0c, 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, 0x06, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x70, 0x00, 0x3e, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0xe0, 0x00, 0xe0, 0x80, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1f, 0x70, 0x00, + 0xc0, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0xf8, + 0x3f, 0x00, 0x00, 0x7f, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0xf0, 0x00, + 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0xfe, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0xc0, + 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, + 0x00, 0xc0, 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0x03, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x3f, 0x00, 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x0c, 0x00, 0x00, + 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, + 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_n_f.xbm b/hacks/images/puzzle/puzzle_a_n_f.xbm new file mode 100644 index 00000000..989fefb8 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_n_f.xbm @@ -0,0 +1,91 @@ +#define puzzle_a_n_f_width 108 +#define puzzle_a_n_f_height 73 +#define puzzle_a_n_f_x_hot 21 +#define puzzle_a_n_f_y_hot 1 +static unsigned char puzzle_a_n_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x7e, + 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xe0, 0x07, 0x00, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf8, + 0x3f, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0xf8, 0x3f, 0x00, 0x00, 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x1f, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0xc0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x80, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, + 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_n_h.xbm b/hacks/images/puzzle/puzzle_a_n_h.xbm new file mode 100644 index 00000000..3c6ef130 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_n_h.xbm @@ -0,0 +1,91 @@ +#define puzzle_a_n_h_width 108 +#define puzzle_a_n_h_height 73 +#define puzzle_a_n_h_x_hot 21 +#define puzzle_a_n_h_y_hot 1 +static unsigned char puzzle_a_n_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x7e, + 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0xe0, 0x07, 0x00, + 0xc0, 0xff, 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0xf8, + 0x3f, 0x00, 0xe0, 0xc1, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0x3f, 0x78, 0x00, 0x70, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x07, 0xe0, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x1c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x0c, 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, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x70, 0x00, + 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0xe0, 0x00, + 0xe0, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1f, + 0x70, 0x00, 0xc0, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x7f, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0xf0, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x00, 0x30, 0x00, 0xc0, 0x00, 0xc0, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x03, 0x18, 0x00, 0x80, + 0x01, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x0c, + 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_ne_f.xbm b/hacks/images/puzzle/puzzle_a_ne_f.xbm new file mode 100644 index 00000000..5ed25170 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_ne_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_a_ne_f_width 89 +#define puzzle_a_ne_f_height 74 +#define puzzle_a_ne_f_x_hot 21 +#define puzzle_a_ne_f_y_hot 1 +static unsigned char puzzle_a_ne_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x7e, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0xe0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_ne_h.xbm b/hacks/images/puzzle/puzzle_a_ne_h.xbm new file mode 100644 index 00000000..6b0b3532 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_ne_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_a_ne_h_width 89 +#define puzzle_a_ne_h_height 74 +#define puzzle_a_ne_h_x_hot 21 +#define puzzle_a_ne_h_y_hot 1 +static unsigned char puzzle_a_ne_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x7e, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0xc0, 0xff, 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0xe0, 0xc1, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x70, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x70, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0xe0, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0xc0, 0xff, 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x7f, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0xfe, 0x0f, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x3e, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x78, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, 0x00, 0xe0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x80, 0x01, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0x80, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0x80, 0x03, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x80, 0x01, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, 0x00, 0xc0, 0x00, 0x00, 0xf8, 0x00, + 0x00, 0x00, 0xc0, 0x3f, 0x00, 0x30, 0x00, 0x80, 0x01, 0x80, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0x03, 0x18, 0x00, 0x00, 0x03, 0xf8, 0x07, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x0c, 0x00, 0x00, 0x86, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_nw_f.xbm b/hacks/images/puzzle/puzzle_a_nw_f.xbm new file mode 100644 index 00000000..9af2ee06 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_nw_f.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_nw_f_width 88 +#define puzzle_a_nw_f_height 74 +#define puzzle_a_nw_f_x_hot 1 +#define puzzle_a_nw_f_y_hot 1 +static unsigned char puzzle_a_nw_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x7e, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0xff, 0x03, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x83, 0xff, 0x03, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x3f, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x0f, 0x00, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x07, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, + 0x00, 0xfc, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, + 0xfc, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, + 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, + 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, + 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x07, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, + 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, + 0xfe, 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, + 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, + 0xff, 0x07, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, + 0x03, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_nw_h.xbm b/hacks/images/puzzle/puzzle_a_nw_h.xbm new file mode 100644 index 00000000..20cf8604 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_nw_h.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_nw_h_width 88 +#define puzzle_a_nw_h_height 74 +#define puzzle_a_nw_h_x_hot 1 +#define puzzle_a_nw_h_y_hot 1 +static unsigned char puzzle_a_nw_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x7e, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x83, 0xff, 0x03, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x83, 0x07, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x0e, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x7c, 0x00, 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0x01, 0x07, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x83, 0xff, 0x03, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0xfe, 0x00, 0x06, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0xf8, 0xf0, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x3c, 0xc0, 0x03, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x0e, 0x00, 0x07, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x06, 0x00, 0x06, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, + 0x00, 0x0c, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00, + 0x1c, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, + 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x03, 0x00, 0x0c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x06, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, + 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, + 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0xc0, 0x07, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x03, 0x00, 0x0c, 0x00, 0xfc, + 0x03, 0x00, 0x00, 0xc0, 0x3f, 0x80, 0x01, 0x00, 0x18, 0xc0, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xc3, 0x00, 0x00, 0x30, 0xfc, 0x03, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_s_f.xbm b/hacks/images/puzzle/puzzle_a_s_f.xbm new file mode 100644 index 00000000..687750f0 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_s_f.xbm @@ -0,0 +1,91 @@ +#define puzzle_a_s_f_width 108 +#define puzzle_a_s_f_height 73 +#define puzzle_a_s_f_x_hot 20 +#define puzzle_a_s_f_y_hot 5 +static unsigned char puzzle_a_s_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x0f, + 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, + 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0xc0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x80, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xe0, 0x0f, 0x00, 0xc0, 0xff, + 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf8, 0x3f, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xf8, + 0x3f, 0x00, 0x00, 0x7e, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_s_h.xbm b/hacks/images/puzzle/puzzle_a_s_h.xbm new file mode 100644 index 00000000..78c0d3ea --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_s_h.xbm @@ -0,0 +1,91 @@ +#define puzzle_a_s_h_width 108 +#define puzzle_a_s_h_height 73 +#define puzzle_a_s_h_x_hot 20 +#define puzzle_a_s_h_y_hot 5 +static unsigned char puzzle_a_s_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, + 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x0c, + 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x3f, 0x00, 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0xc0, + 0x01, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0xfe, 0x07, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0xf0, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x7f, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0xe0, 0x0f, 0x00, 0xc0, 0xff, + 0xc1, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0xf8, 0x3f, 0x00, + 0xe0, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1f, + 0x70, 0x00, 0x70, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x07, 0xe0, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0c, 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, 0x06, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x70, 0x00, 0x7e, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0xe0, 0x00, 0xe0, 0xc1, + 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x3f, 0x78, 0x00, + 0xc0, 0xff, 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0xf8, + 0x3f, 0x00, 0x00, 0x7e, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x1c, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_se_f.xbm b/hacks/images/puzzle/puzzle_a_se_f.xbm new file mode 100644 index 00000000..dbc5d0f5 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_se_f.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_se_f_width 88 +#define puzzle_a_se_f_height 74 +#define puzzle_a_se_f_x_hot 20 +#define puzzle_a_se_f_y_hot 6 +static unsigned char puzzle_a_se_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0xff, 0x0f, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, + 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, + 0xe0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x80, 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, + 0xff, 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, 0xff, + 0xff, 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, 0xff, 0xff, + 0x1f, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, + 0x00, 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, 0x00, + 0x80, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xc0, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0xe0, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x7f, 0x80, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xc0, 0xff, 0xc1, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xc0, 0xff, 0xc1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x7e, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, + 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x80, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_se_h.xbm b/hacks/images/puzzle/puzzle_a_se_h.xbm new file mode 100644 index 00000000..3dbe22ac --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_se_h.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_se_h_width 88 +#define puzzle_a_se_h_height 74 +#define puzzle_a_se_h_x_hot 20 +#define puzzle_a_se_h_y_hot 6 +static unsigned char puzzle_a_se_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x3f, 0x0c, 0x00, 0x00, 0xc3, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0x03, 0x18, 0x00, 0x80, 0x01, 0xfc, 0x03, 0x00, 0x00, 0xc0, 0x3f, 0x00, + 0x30, 0x00, 0xc0, 0x00, 0xc0, 0x3f, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x60, + 0x00, 0x60, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, + 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, + 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0xc0, 0x00, 0x00, 0x60, + 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0xc0, 0x01, 0x00, 0x60, 0x00, + 0x00, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, + 0x00, 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, 0x00, + 0x80, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, 0x00, 0xc0, + 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0xc0, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x60, 0x00, 0x60, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0xe0, 0x00, 0x70, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x00, 0x06, 0x00, 0xc0, 0x03, 0x3c, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x1f, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x60, 0x00, 0x7f, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xc0, 0xff, 0xc1, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xe0, 0x80, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x70, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x70, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0xe0, 0xc1, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0xc0, 0xff, 0xc1, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x7e, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_sw_f.xbm b/hacks/images/puzzle/puzzle_a_sw_f.xbm new file mode 100644 index 00000000..5a000bf1 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_sw_f.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_sw_f_width 88 +#define puzzle_a_sw_f_height 74 +#define puzzle_a_sw_f_x_hot 1 +#define puzzle_a_sw_f_y_hot 6 +static unsigned char puzzle_a_sw_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, + 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, + 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, + 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, + 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, + 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, + 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x07, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, + 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, + 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, + 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, + 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x0f, 0x00, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x3f, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x83, 0xff, 0x03, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0xff, 0x03, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x7e, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_sw_h.xbm b/hacks/images/puzzle/puzzle_a_sw_h.xbm new file mode 100644 index 00000000..9b34a486 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_sw_h.xbm @@ -0,0 +1,73 @@ +#define puzzle_a_sw_h_width 88 +#define puzzle_a_sw_h_height 74 +#define puzzle_a_sw_h_x_hot 1 +#define puzzle_a_sw_h_y_hot 6 +static unsigned char puzzle_a_sw_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xc3, + 0x00, 0x00, 0x30, 0xfc, 0x03, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x80, 0x01, + 0x00, 0x18, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x03, 0x00, + 0x0c, 0x00, 0xfc, 0x03, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x06, 0x00, 0x06, + 0x00, 0xc0, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x06, 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, + 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x0e, 0x00, 0x07, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x3c, 0xc0, 0x03, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0xf8, 0xf0, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x0f, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x80, 0x01, 0xfe, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x83, 0xff, 0x03, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0x01, 0x07, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x7c, 0x00, 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x38, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, + 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x83, 0x07, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x83, 0xff, 0x03, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x7e, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_w_f.xbm b/hacks/images/puzzle/puzzle_a_w_f.xbm new file mode 100644 index 00000000..f85ef759 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_w_f.xbm @@ -0,0 +1,77 @@ +#define puzzle_a_w_f_width 88 +#define puzzle_a_w_f_height 78 +#define puzzle_a_w_f_x_hot 1 +#define puzzle_a_w_f_y_hot 6 +static unsigned char puzzle_a_w_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, + 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x01, + 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, + 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, + 0xff, 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, + 0xff, 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, + 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x07, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, + 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, + 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, + 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, + 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x0f, 0x00, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x3f, 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xf0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x01, 0x7e, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x83, 0xff, 0x03, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x07, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x83, 0xff, 0x03, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xf0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x3f, 0xc0, + 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x0f, 0x00, 0xff, + 0xff, 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x01, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x01, + 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, + 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x03, 0x00, 0xfc, + 0xff, 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, + 0xff, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, + 0x07, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x07, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00, 0x00, + 0xfc, 0xff, 0xff, 0x03, 0x00, 0xfc, 0xff, 0xff, 0x03, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x01, 0x00, 0xf8, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, + 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_a_w_h.xbm b/hacks/images/puzzle/puzzle_a_w_h.xbm new file mode 100644 index 00000000..a82478f5 --- /dev/null +++ b/hacks/images/puzzle/puzzle_a_w_h.xbm @@ -0,0 +1,77 @@ +#define puzzle_a_w_h_width 88 +#define puzzle_a_w_h_height 78 +#define puzzle_a_w_h_x_hot 1 +#define puzzle_a_w_h_y_hot 6 +static unsigned char puzzle_a_w_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x7f, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xc3, + 0x00, 0x00, 0x30, 0xfc, 0x03, 0x00, 0x00, 0x00, 0xc0, 0x3f, 0x80, 0x01, + 0x00, 0x18, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0x03, 0x00, 0x03, 0x00, + 0x0c, 0x00, 0xfc, 0x03, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x06, 0x00, 0x06, + 0x00, 0xc0, 0x07, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x06, 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, + 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, + 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x60, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x0e, 0x00, 0x07, 0x00, 0x60, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x3c, 0xc0, 0x03, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0xf8, 0xf0, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0xe0, 0x7f, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x0f, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x01, 0x7e, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x83, 0xff, 0x03, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xff, 0x83, 0x07, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x7e, 0x00, 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x38, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0x00, + 0x0e, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x01, 0x07, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x83, 0xff, 0x03, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xfe, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x0f, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0xe0, 0x7f, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0xf8, + 0xf0, 0x01, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x3c, 0xc0, + 0x03, 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x0e, 0x00, 0x07, + 0x00, 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x60, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00, 0x1c, 0x00, 0xc0, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0xc0, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, + 0x00, 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, + 0x80, 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, + 0x01, 0x00, 0x18, 0x00, 0x80, 0x01, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, + 0x00, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x80, 0x03, 0x00, + 0x1c, 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x03, 0x00, 0x0c, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, + 0x00, 0x03, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x3e, 0x00, 0x00, 0x06, 0x00, 0x06, 0x00, 0xc0, 0x07, 0x00, 0x00, + 0xfc, 0x03, 0x00, 0x03, 0x00, 0x0c, 0x00, 0xfc, 0x03, 0x00, 0x00, 0xc0, + 0x3f, 0x80, 0x01, 0x00, 0x18, 0xc0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xc3, 0x00, 0x00, 0x30, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x7f, + 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_e_f.xbm b/hacks/images/puzzle/puzzle_b_e_f.xbm new file mode 100644 index 00000000..a49e771b --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_e_f.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_e_f_width 74 +#define puzzle_b_e_f_height 108 +#define puzzle_b_e_f_x_hot 6 +#define puzzle_b_e_f_y_hot 21 +static unsigned char puzzle_b_e_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0xf0, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, + 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0x07, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0x1f, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, + 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, 0xe0, 0x3f, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0xff, 0x01, 0xc0, 0x03, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_e_h.xbm b/hacks/images/puzzle/puzzle_b_e_h.xbm new file mode 100644 index 00000000..daa13c16 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_e_h.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_e_h_width 74 +#define puzzle_b_e_h_height 108 +#define puzzle_b_e_h_x_hot 6 +#define puzzle_b_e_h_y_hot 21 +static unsigned char puzzle_b_e_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0xf0, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, + 0xff, 0x01, 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, 0x8f, 0x01, + 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, 0x06, 0xff, 0x80, 0x01, 0x60, 0x00, + 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x01, 0x30, 0x00, 0xc0, 0x0f, + 0x00, 0x00, 0xf8, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0xf0, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0xf8, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xc0, 0x07, + 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0x1f, 0xf0, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0xc0, 0x0f, 0x00, 0x00, + 0xf8, 0x00, 0x80, 0x01, 0x60, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x0f, + 0x80, 0x01, 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, 0x06, 0xff, 0x80, 0x01, + 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, 0x8f, 0x01, 0xe0, 0x3f, + 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, 0xff, 0x01, 0xc0, 0x03, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_f.xbm b/hacks/images/puzzle/puzzle_b_f.xbm new file mode 100644 index 00000000..895abf9c --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_f.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_f_width 78 +#define puzzle_b_f_height 108 +#define puzzle_b_f_x_hot 5 +#define puzzle_b_f_y_hot 20 +static unsigned char puzzle_b_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0xf0, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, + 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf8, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xc0, 0x07, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0x00, 0xf8, 0x00, 0xe0, 0x1f, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xfe, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, + 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, 0xe0, 0x3f, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0xff, 0x01, 0xc0, 0x03, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_h.xbm b/hacks/images/puzzle/puzzle_b_h.xbm new file mode 100644 index 00000000..0ecc2048 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_h.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_h_width 78 +#define puzzle_b_h_height 108 +#define puzzle_b_h_x_hot 5 +#define puzzle_b_h_y_hot 20 +static unsigned char puzzle_b_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x70, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0xf0, 0x00, 0xe0, 0x3f, 0x00, 0x60, 0x00, 0xc0, 0x01, 0x00, + 0xff, 0x01, 0x60, 0xfc, 0x03, 0x30, 0x00, 0x80, 0x03, 0xf0, 0x8f, 0x01, + 0x60, 0xc0, 0x3f, 0x18, 0x00, 0x00, 0x07, 0xff, 0x80, 0x01, 0x60, 0x00, + 0xfc, 0x0f, 0x00, 0x00, 0xfe, 0x0f, 0x80, 0x01, 0x30, 0x00, 0xc0, 0x07, + 0x00, 0x00, 0xfc, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x18, 0xf0, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x06, 0x30, 0xf8, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0xff, 0x07, 0x03, 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0xe0, 0x00, + 0xf8, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x38, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xc0, 0x07, + 0xc0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0xf8, 0x00, 0xe0, 0x1f, 0xf0, 0x00, + 0x00, 0x00, 0xc0, 0x03, 0xfe, 0x01, 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0xff, 0x07, 0x03, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0x03, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0xc0, 0x07, 0x00, 0x00, + 0xfc, 0x00, 0x00, 0x03, 0x60, 0x00, 0xfc, 0x0f, 0x00, 0x00, 0xfe, 0x0f, + 0x80, 0x01, 0x60, 0xc0, 0x3f, 0x18, 0x00, 0x00, 0x07, 0xff, 0x80, 0x01, + 0x60, 0xfc, 0x03, 0x30, 0x00, 0x80, 0x03, 0xf0, 0x8f, 0x01, 0xe0, 0x3f, + 0x00, 0x60, 0x00, 0xc0, 0x01, 0x00, 0xff, 0x01, 0xc0, 0x03, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x80, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x01, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_n_f.xbm b/hacks/images/puzzle/puzzle_b_n_f.xbm new file mode 100644 index 00000000..e7a84b13 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_n_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_n_f_width 78 +#define puzzle_b_n_f_height 88 +#define puzzle_b_n_f_x_hot 6 +#define puzzle_b_n_f_y_hot 1 +static unsigned char puzzle_b_n_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xe0, 0x1f, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, + 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0x00, 0x00, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x00, 0xf8, 0x00, + 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x03, 0xfe, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, + 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, + 0xff, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0xff, 0x01, + 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_n_h.xbm b/hacks/images/puzzle/puzzle_b_n_h.xbm new file mode 100644 index 00000000..aae63330 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_n_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_n_h_width 78 +#define puzzle_b_n_h_height 88 +#define puzzle_b_n_h_x_hot 6 +#define puzzle_b_n_h_y_hot 1 +static unsigned char puzzle_b_n_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x06, + 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0x07, 0x03, 0xe0, 0x1f, + 0xf0, 0x00, 0x00, 0x00, 0xc0, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0x01, + 0x00, 0x00, 0xe0, 0x00, 0xf8, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, + 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, + 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x70, 0x00, + 0x00, 0x00, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0xf8, 0x00, + 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, 0xc0, 0x03, 0xfe, 0x01, 0x30, 0xf8, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0xff, 0x07, 0x03, 0x18, 0xf0, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0x03, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, + 0xc0, 0x0f, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x03, 0x60, 0x00, 0xfc, 0x1f, + 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x01, 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, + 0x06, 0xff, 0x80, 0x01, 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, + 0x8f, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, 0xff, 0x01, + 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x70, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_ne_f.xbm b/hacks/images/puzzle/puzzle_b_ne_f.xbm new file mode 100644 index 00000000..1a56171c --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_ne_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_ne_f_width 74 +#define puzzle_b_ne_f_height 88 +#define puzzle_b_ne_f_x_hot 6 +#define puzzle_b_ne_f_y_hot 1 +static unsigned char puzzle_b_ne_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0x1f, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0x07, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, + 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, + 0xff, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0xff, 0x01, + 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_ne_h.xbm b/hacks/images/puzzle/puzzle_b_ne_h.xbm new file mode 100644 index 00000000..72464994 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_ne_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_ne_h_width 74 +#define puzzle_b_ne_h_height 88 +#define puzzle_b_ne_h_x_hot 6 +#define puzzle_b_ne_h_y_hot 1 +static unsigned char puzzle_b_ne_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0x1f, + 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xc0, 0x07, 0xc0, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x07, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0xf8, + 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0xf0, 0x1f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, + 0xc0, 0x0f, 0x00, 0x00, 0xf8, 0x00, 0x80, 0x01, 0x60, 0x00, 0xfc, 0x1f, + 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x01, 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, + 0x06, 0xff, 0x80, 0x01, 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, + 0x8f, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, 0xff, 0x01, + 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x70, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_nw_f.xbm b/hacks/images/puzzle/puzzle_b_nw_f.xbm new file mode 100644 index 00000000..393e0b6d --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_nw_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_nw_f_width 74 +#define puzzle_b_nw_f_height 88 +#define puzzle_b_nw_f_x_hot 1 +#define puzzle_b_nw_f_y_hot 1 +static unsigned char puzzle_b_nw_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x0f, 0x80, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x07, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, 0x0f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0x83, 0xff, 0xff, 0x7f, + 0xf0, 0xff, 0x1f, 0x00, 0xfe, 0x3f, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xff, + 0x1f, 0x00, 0xfe, 0x03, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0xf0, 0x1f, 0x00, + 0x3e, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_nw_h.xbm b/hacks/images/puzzle/puzzle_b_nw_h.xbm new file mode 100644 index 00000000..7b330308 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_nw_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_nw_h_width 74 +#define puzzle_b_nw_h_height 88 +#define puzzle_b_nw_h_x_hot 1 +#define puzzle_b_nw_h_y_hot 1 +static unsigned char puzzle_b_nw_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x18, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x60, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x0e, 0x80, 0x0f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x80, 0x0f, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x3f, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, + 0x7c, 0x00, 0x00, 0xc0, 0x0f, 0x00, 0x30, 0x00, 0x06, 0xc0, 0xff, 0x00, + 0x00, 0xe0, 0xff, 0x00, 0x18, 0x00, 0x06, 0xfc, 0x83, 0x01, 0x00, 0x70, + 0xf0, 0x0f, 0x18, 0x00, 0xc6, 0x3f, 0x00, 0x03, 0x00, 0x38, 0x00, 0xff, + 0x18, 0x00, 0xfe, 0x03, 0x00, 0x06, 0x00, 0x1c, 0x00, 0xf0, 0x1f, 0x00, + 0x3e, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x1c, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x70, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_s_f.xbm b/hacks/images/puzzle/puzzle_b_s_f.xbm new file mode 100644 index 00000000..f72d7394 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_s_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_s_f_width 78 +#define puzzle_b_s_f_height 88 +#define puzzle_b_s_f_x_hot 5 +#define puzzle_b_s_f_y_hot 20 +static unsigned char puzzle_b_s_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0xf0, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, + 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xf8, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0xc0, 0x07, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0x00, 0xf8, 0x00, 0xe0, 0x1f, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xfe, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x0f, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x07, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_s_h.xbm b/hacks/images/puzzle/puzzle_b_s_h.xbm new file mode 100644 index 00000000..5f906707 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_s_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_s_h_width 78 +#define puzzle_b_s_h_height 88 +#define puzzle_b_s_h_x_hot 5 +#define puzzle_b_s_h_y_hot 20 +static unsigned char puzzle_b_s_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0xf0, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, + 0xff, 0x01, 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, 0x8f, 0x01, + 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, 0x06, 0xff, 0x80, 0x01, 0x60, 0x00, + 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x01, 0x30, 0x00, 0xc0, 0x0f, + 0x00, 0x00, 0xf8, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x18, 0xf0, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x06, 0x30, 0xf8, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0xff, 0x07, 0x03, 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, + 0xc0, 0x03, 0xfe, 0x01, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0xe0, 0x00, + 0xf8, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x38, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xc0, 0x07, + 0xc0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0xf8, 0x00, 0xe0, 0x1f, 0xf0, 0x00, + 0x00, 0x00, 0xc0, 0x03, 0xfe, 0x01, 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0xff, 0x07, 0x03, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0x03, 0x06, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x18, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_se_f.xbm b/hacks/images/puzzle/puzzle_b_se_f.xbm new file mode 100644 index 00000000..537725ef --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_se_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_se_f_width 74 +#define puzzle_b_se_f_height 88 +#define puzzle_b_se_f_x_hot 6 +#define puzzle_b_se_f_y_hot 20 +static unsigned char puzzle_b_se_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x7f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0xff, 0xff, + 0x00, 0x00, 0xf0, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00, + 0xff, 0x01, 0xe0, 0xff, 0x03, 0xf0, 0xff, 0xff, 0x03, 0xf0, 0xff, 0x01, + 0xe0, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x07, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0x1f, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xc0, 0x07, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0x00, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0x07, + 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0x1f, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfc, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfc, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xe0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_se_h.xbm b/hacks/images/puzzle/puzzle_b_se_h.xbm new file mode 100644 index 00000000..df99f701 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_se_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_se_h_width 74 +#define puzzle_b_se_h_height 88 +#define puzzle_b_se_h_x_hot 6 +#define puzzle_b_se_h_y_hot 20 +static unsigned char puzzle_b_se_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x38, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x60, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xe0, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, + 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, + 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xc0, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, + 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0xc0, 0x00, 0xc0, + 0x00, 0x00, 0xf0, 0x01, 0xe0, 0x3f, 0x00, 0xe0, 0x00, 0x80, 0x01, 0x00, + 0xff, 0x01, 0x60, 0xfc, 0x03, 0x70, 0x00, 0x00, 0x03, 0xf0, 0x8f, 0x01, + 0x60, 0xc0, 0x3f, 0x38, 0x00, 0x00, 0x06, 0xff, 0x80, 0x01, 0x60, 0x00, + 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x01, 0x30, 0x00, 0xc0, 0x0f, + 0x00, 0x00, 0xf8, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0xf0, + 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0xf8, 0x3f, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0x1f, 0xf0, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0xc0, 0x07, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xc0, 0x07, + 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0x1f, 0xf0, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0xf8, 0x3f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x18, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x0c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0xe0, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_sw_f.xbm b/hacks/images/puzzle/puzzle_b_sw_f.xbm new file mode 100644 index 00000000..f183b52a --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_sw_f.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_sw_f_width 74 +#define puzzle_b_sw_f_height 88 +#define puzzle_b_sw_f_x_hot 1 +#define puzzle_b_sw_f_y_hot 21 +static unsigned char puzzle_b_sw_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00, 0xfc, 0xff, 0x0f, + 0x00, 0x00, 0x0f, 0x00, 0xfe, 0x03, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0xf0, + 0x1f, 0x00, 0xfe, 0x3f, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xff, 0x1f, 0x00, + 0xfe, 0xff, 0x83, 0xff, 0xff, 0x7f, 0xf0, 0xff, 0x1f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, + 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_sw_h.xbm b/hacks/images/puzzle/puzzle_b_sw_h.xbm new file mode 100644 index 00000000..917853bd --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_sw_h.xbm @@ -0,0 +1,79 @@ +#define puzzle_b_sw_h_width 74 +#define puzzle_b_sw_h_height 88 +#define puzzle_b_sw_h_x_hot 1 +#define puzzle_b_sw_h_y_hot 21 +static unsigned char puzzle_b_sw_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0e, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x0c, 0x00, 0x0c, + 0x00, 0x00, 0x0f, 0x00, 0xfe, 0x03, 0x00, 0x06, 0x00, 0x1c, 0x00, 0xf0, + 0x1f, 0x00, 0xc6, 0x3f, 0x00, 0x03, 0x00, 0x38, 0x00, 0xff, 0x18, 0x00, + 0x06, 0xfc, 0x83, 0x01, 0x00, 0x70, 0xf0, 0x0f, 0x18, 0x00, 0x06, 0xc0, + 0xff, 0x00, 0x00, 0xe0, 0xff, 0x00, 0x18, 0x00, 0x06, 0x00, 0x7c, 0x00, + 0x00, 0xc0, 0x0f, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x80, + 0x0f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0e, 0x80, 0x0f, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, + 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_w_f.xbm b/hacks/images/puzzle/puzzle_b_w_f.xbm new file mode 100644 index 00000000..0b5b8d53 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_w_f.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_w_f_width 74 +#define puzzle_b_w_f_height 108 +#define puzzle_b_w_f_x_hot 1 +#define puzzle_b_w_f_y_hot 21 +static unsigned char puzzle_b_w_f_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, + 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00, 0xfc, 0xff, 0x0f, + 0x00, 0x00, 0x0f, 0x00, 0xfe, 0x03, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0xf0, + 0x1f, 0x00, 0xfe, 0x3f, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xff, 0x1f, 0x00, + 0xfe, 0xff, 0x83, 0xff, 0xff, 0x7f, 0xf0, 0xff, 0x1f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, + 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x01, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, + 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x0f, 0x80, 0x0f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0xe0, 0x1f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x7f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x00, + 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, + 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, + 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, + 0xff, 0xff, 0x3f, 0x00, 0xfe, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, + 0x1f, 0x00, 0xfe, 0xff, 0x83, 0xff, 0xff, 0x7f, 0xf0, 0xff, 0x1f, 0x00, + 0xfe, 0x3f, 0x00, 0xff, 0xff, 0x3f, 0x00, 0xff, 0x1f, 0x00, 0xfe, 0x03, + 0x00, 0xfe, 0xff, 0x1f, 0x00, 0xf0, 0x1f, 0x00, 0x3e, 0x00, 0x00, 0xfc, + 0xff, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, + 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1f, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0xfc, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0xf8, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, + 0xff, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/puzzle/puzzle_b_w_h.xbm b/hacks/images/puzzle/puzzle_b_w_h.xbm new file mode 100644 index 00000000..2c105c16 --- /dev/null +++ b/hacks/images/puzzle/puzzle_b_w_h.xbm @@ -0,0 +1,95 @@ +#define puzzle_b_w_h_width 74 +#define puzzle_b_w_h_height 108 +#define puzzle_b_w_h_x_hot 1 +#define puzzle_b_w_h_y_hot 21 +static unsigned char puzzle_b_w_h_bits[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, + 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 0x03, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x07, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0e, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00, 0x0c, 0x00, 0x0c, + 0x00, 0x00, 0x0f, 0x00, 0xfe, 0x03, 0x00, 0x06, 0x00, 0x1c, 0x00, 0xf0, + 0x1f, 0x00, 0xc6, 0x3f, 0x00, 0x03, 0x00, 0x38, 0x00, 0xff, 0x18, 0x00, + 0x06, 0xfc, 0x83, 0x01, 0x00, 0x70, 0xf0, 0x0f, 0x18, 0x00, 0x06, 0xc0, + 0xff, 0x00, 0x00, 0xe0, 0xff, 0x00, 0x18, 0x00, 0x06, 0x00, 0x7c, 0x00, + 0x00, 0xc0, 0x0f, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x80, + 0x0f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, + 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x0e, 0x80, 0x0f, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0xe0, 0x1f, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xf0, 0x7f, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, + 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, + 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x06, 0x00, 0x7c, 0x00, 0x00, 0xc0, + 0x0f, 0x00, 0x30, 0x00, 0x06, 0xc0, 0xff, 0x00, 0x00, 0xe0, 0xff, 0x00, + 0x18, 0x00, 0x06, 0xfc, 0x83, 0x01, 0x00, 0x70, 0xf0, 0x0f, 0x18, 0x00, + 0xc6, 0x3f, 0x00, 0x03, 0x00, 0x38, 0x00, 0xff, 0x18, 0x00, 0xfe, 0x03, + 0x00, 0x06, 0x00, 0x1c, 0x00, 0xf0, 0x1f, 0x00, 0x3e, 0x00, 0x00, 0x0c, + 0x00, 0x0c, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x38, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x03, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, + 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x18, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x18, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x0c, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x18, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, + 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/hacks/images/som.xbm b/hacks/images/som.xbm new file mode 100644 index 00000000..cd24fd01 --- /dev/null +++ b/hacks/images/som.xbm @@ -0,0 +1,1685 @@ +#define som_width 464 +#define som_height 435 +static unsigned char som_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,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,0x00,0x00,0x00, + 0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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, + 0xf8,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,0xfc,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,0xfc,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,0xfc,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,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xfe,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 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,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,0x00,0x00,0x00,0x00,0x00,0x00, + 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,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,0x80,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,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,0x7f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x7f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,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, + 0xf0,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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,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,0xf8,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,0x00,0x00,0x00,0x00, + 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,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,0x00,0x00,0x00,0x00,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,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,0x00,0x00,0x00,0x00,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,0xff,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,0x00,0x00,0x00,0x00,0x00,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,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,0xff,0xff,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe, + 0xff,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,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,0x00,0x00,0x00,0x00, + 0x00,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,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,0x80,0xff,0xff,0xff,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 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,0x00,0x00, + 0x00,0x00,0x00,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,0xff,0xff, + 0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0xff,0xff,0xff,0x7f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0xff,0xff,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0xff,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,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,0xff,0xff,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,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,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,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,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,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,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,0x00,0x00,0x00, + 0x00,0x00,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, + 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,0x00,0x00,0x00,0x00,0x00, + 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,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,0x00,0x00,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,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,0x00,0x00,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,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,0x00,0x00,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,0xff,0xff,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,0x00,0x00,0x00,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,0xdf,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe, + 0xff,0xdf,0xff,0xff,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x8f, + 0xff,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0xff,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0xff,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,0x00,0x00,0x00,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,0x07,0xff,0xff,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0xfe,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 0xff,0xff,0x03,0xfc,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, + 0x00,0x00,0x00,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,0xff,0xff, + 0x03,0xfc,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,0x00,0x00, + 0x00,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,0xff,0xff,0x03,0xfc, + 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,0x00,0x00,0x00,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,0xff,0x01,0xf8,0xff,0x7f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x01,0xf8,0xff,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x00,0xf0,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,0xe0,0xff,0xff,0x00,0xf0,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, + 0xe0,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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, + 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,0xf0,0x07,0x00,0x00, + 0x80,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,0x00, + 0x00,0x00,0x00,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, + 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,0x00, + 0x00,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,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,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,0xff,0xff,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0x03,0x00,0x00,0xe0,0xff,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff, + 0x7f,0xfe,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x01,0xfe, + 0x01,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x01,0xfe,0x01,0x00, + 0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x07,0x00,0xce,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfe,0x7f,0x00,0x00,0x87,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0xff,0x07,0x00,0x80,0x03,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfe,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc, + 0x3f,0x00,0x00,0x80,0x03,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x3f,0x00, + 0x00,0x80,0x03,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0x07,0x00,0x00,0xc0, + 0x01,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0x00,0xc0,0xfb,0xff, + 0x0f,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x07,0x00,0xc0,0xff,0xff,0x3f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0xff,0xc0,0xff,0x7f,0x00,0xe0,0xff,0xff,0x7f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xfe,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, + 0x80,0xff,0xc0,0xff,0x7f,0x00,0xe0,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,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,0xc0,0x1f, + 0x00,0xf8,0xff,0x0f,0xf0,0x0f,0xc0,0xff,0x01,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x0f,0x00,0x00, + 0xff,0x7f,0xf0,0x01,0x00,0xf8,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0x80,0xff, + 0x7b,0x00,0x00,0xe0,0x07,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0xfc,0x3f,0x00, + 0x00,0x80,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,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,0xf8,0x00,0x00,0x00,0x00,0xfc,0x3f,0x00,0x00,0x80, + 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,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,0x3c,0x00,0x00,0x00,0x00,0xe0,0x7f,0x00,0x00,0x00,0x7e,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x3e,0x00,0x00,0x00,0x00,0x00,0xff,0x03,0x00,0x00,0x70,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,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,0xf0,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,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,0x0f,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfe,0x01,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x07,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xe0,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x07,0x00,0x00,0x00,0x00,0x00,0x00, + 0xf8,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xe0,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xf8,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 0x00,0x00,0x00,0xfe,0x03,0x00,0x00,0x00,0xf0,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf8,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,0xf8,0x00,0x00, + 0x00,0xfe,0x03,0x00,0x00,0x00,0xf0,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,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,0xfc,0x00,0x00,0xf0,0xff, + 0x1f,0x00,0x00,0x00,0x80,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf0,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,0x3f,0x00,0x00,0xfc,0xff,0x7f,0x00, + 0x00,0x00,0x00,0xfe,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xc0,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x80,0x1f,0x00,0x00,0xff,0x47,0x7f,0x00,0x00,0x00, + 0x00,0xf8,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xf0,0x07,0x80,0xff,0xff,0x3f,0x7c,0x00,0x00,0x00,0x00,0xc0, + 0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0x80,0xff,0xff,0x3f,0x7c,0x00,0x00,0x00,0x00,0xc0,0xff,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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, + 0x03,0xc0,0xff,0xfe,0xff,0x7d,0x00,0x00,0x00,0x00,0x80,0xff,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,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,0xff,0x00,0x40, + 0x00,0x00,0xfe,0x7f,0x00,0x00,0x00,0x00,0x80,0xff,0x07,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x3f,0x00,0x00,0x80,0x03, + 0xf8,0x3f,0x00,0x00,0x00,0x00,0x80,0xe7,0x1f,0x00,0x00,0x00,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,0x00,0x00,0xf0,0xff,0xff,0x1f, + 0x00,0x00,0x00,0x00,0x80,0xc7,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 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,0xfe,0x0f,0x00,0x00,0xf0,0xff,0xff,0x1f,0x00,0x00, + 0x00,0x00,0x80,0xc7,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xc0,0xff,0x03,0x00,0x00,0xf0,0xff,0xff,0x0f,0x00,0x00,0x00,0x00, + 0xc0,0x0f,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0x00,0x00,0x00, + 0xf0,0x7f,0x00,0x00,0x00,0xc0,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0xc0,0x0f, + 0xfc,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0xff,0x0f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0xf0,0x0f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,0x00, + 0x00,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,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x1f,0x80,0x3f,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x1c,0x00,0xfe,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,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,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf0,0x1c,0x00,0xfe,0x03,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfe,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x70,0x1c,0x00,0xf0,0x07,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x70,0x38,0x00,0xc0,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xe0,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,0x80, + 0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70, + 0x78,0x00,0x00,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,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,0xc0,0x03,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x70,0x00, + 0x00,0xfc,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0xc0,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x70,0x00,0x00,0xfc, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,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,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x70,0x00,0x00,0xfe,0x03,0xfe, + 0x7f,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,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x38,0xf0,0x00,0x00,0xfe,0x0f,0xff,0xff,0x01, + 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,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x18,0xe0,0x00,0x80,0x9f,0xff,0x3f,0xfe,0x03,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,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1c,0xe0,0x00,0x80,0x0f,0xff,0x07,0xc0,0x0f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1e,0x00,0x00,0x00,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x1c,0xe0,0x00,0x80,0x0f,0xff,0x07,0xc0,0x0f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x1e,0x00,0x00,0x00,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,0xf1, + 0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0xe0, + 0x00,0xc0,0x07,0xfc,0x01,0x00,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00, + 0x00,0x00,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,0xe1,0xff,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0xe0,0x01,0xe0, + 0x03,0x60,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,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,0xc0,0xc3,0xff,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0xc0,0x01,0xf0,0x01,0x00, + 0xe0,0x03,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x00,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,0x07,0xf0,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0xc0,0x03,0xf8,0x00,0x00,0xf8,0x1f, + 0xe0,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x00,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,0x07,0xf0,0x03,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x07,0xc0,0x03,0xf8,0x00,0x00,0xf8,0x1f,0xe0,0x00, + 0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x00,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,0xc0,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x07,0x80,0x03,0x78,0x00,0x00,0xf8,0x7f,0xe0,0x01,0x00,0x00, + 0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x0f,0x80,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,0x03,0x80,0x03,0x3e,0x00,0x00,0x78,0x7e,0xc0,0x03,0x00,0x00,0x00,0x00, + 0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x1e,0x1c,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xf3, + 0x9f,0x03,0x1f,0x00,0x00,0x00,0xf0,0x80,0x03,0x00,0x00,0x00,0x00,0x00,0x70, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0xfe, + 0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x07, + 0x0f,0x00,0x00,0x00,0xe0,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0xfe,0x0f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x07,0x0f,0x00, + 0x00,0x00,0xe0,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0xfc,0x0f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x87,0x07,0x00,0x00,0x00, + 0xe0,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0xf8,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xc0,0x3f,0xf4,0xc7,0x07,0x00,0x00,0x00,0xe0,0x00, + 0x07,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,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,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0x03,0x80,0xe7,0x01,0x00,0x00,0x00,0xe0,0x00,0x07,0x00, + 0x00,0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,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,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0x00,0x00,0xff,0x01,0x00,0x00,0x00,0xe0,0x80,0x07,0x00,0x00,0x00, + 0x00,0x00,0xe0,0x00,0x00,0x00,0x00,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,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xff,0x00,0x00,0x00,0x00,0xf8,0x80,0x03,0x00,0x00,0x00,0x00,0x00, + 0xe0,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,0xe0, + 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xff,0x00,0x00,0x00,0x00,0xf8,0x80,0x03,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x80,0x07,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7e,0x00, + 0x00,0x00,0x00,0x7c,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00,0x80,0x07, + 0xe0,0x3f,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0xc0,0xff,0xff,0x0f, + 0xe0,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0xe0,0xff,0xff,0x03,0xe0,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0xe0,0xff,0xff,0x03,0xe0,0x00,0x00,0x00, + 0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0x3f,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0x07,0x00,0x80,0xff,0x7f,0x00,0xf8,0x01,0x00,0x00,0x00,0x00, + 0x00,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0x03,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xc0,0x07,0x00,0x00,0x00,0x00,0x00,0xfc,0x07,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x07,0x1e, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x03, + 0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x0f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00, + 0x00,0x00,0x80,0xcf,0x3f,0x00,0x00,0xfe,0x01,0x00,0xc0,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x0f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0x00,0x00, + 0x80,0xcf,0x3f,0x00,0x00,0xfe,0x01,0x00,0xc0,0x01,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,0x07,0x0f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0xe0,0xe7, + 0xff,0x00,0x00,0xfe,0x0f,0x00,0xc0,0xe1,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0x03,0x00,0xfc,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0x03,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0x00,0x00,0xf0,0xff,0xf9,0xff,0x01, + 0x00,0xe0,0x1f,0x00,0xc0,0xe1,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0x03,0x00,0xf8,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0x03,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x7e,0x00,0x00,0x00,0xc0,0xff,0x7f,0xfe,0xe1,0x07,0x00,0xc0, + 0xff,0x00,0xc0,0xe1,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0x01,0x00,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0x03,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x1e,0x00,0x00,0x00,0xfc,0xff,0x1f,0xff,0x81,0x0f,0x00,0x80,0xf1,0x03, + 0xc0,0xe1,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00, + 0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x03, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e, + 0x00,0x00,0x00,0xfc,0xff,0x1f,0xff,0x81,0x0f,0x00,0x80,0xf1,0x03,0xc0,0xe1, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,0xc0,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x81,0x0f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0x00, + 0x00,0xff,0x3f,0x80,0xff,0x00,0x1f,0x00,0x80,0xc1,0x07,0xc0,0xe1,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xc1,0xff,0x3f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x00,0x03,0xc0,0x3f, + 0x00,0xe0,0x7f,0x00,0x7e,0x00,0x80,0x01,0x1f,0xe0,0xe1,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xe0,0xff,0xff,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x80,0x07,0xf0,0x07,0x00,0xf0, + 0x3f,0x00,0xf8,0x00,0x80,0x01,0x3c,0xe0,0xe1,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xe0,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x80,0xff,0xff,0x01,0x00,0xfc,0x1f,0x00, + 0xf0,0x01,0xc0,0x01,0x38,0xe0,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0x7f,0xf0,0x00,0xf8,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0x03,0x00,0xfe,0x1f,0x00,0x80,0xbf,0x07,0x00,0x80,0x07, + 0xc0,0x01,0xe0,0xf1,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f, + 0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0x7f,0xf0,0x00,0xf8,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0x03,0x00,0xfe,0x1f,0x00,0x80,0xbf,0x07,0x00,0x80,0x07,0xc0,0x01, + 0xe0,0xf1,0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f,0x00,0x00, + 0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f, + 0xf0,0x00,0x00,0xfe,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0, + 0x01,0x00,0xf8,0x03,0x00,0xc0,0xcf,0x03,0x00,0x80,0x1f,0xf0,0x01,0xe0,0x71, + 0xe0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00, + 0x00,0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x7f,0xf0,0x00, + 0x00,0xe0,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x00,0x00, + 0x00,0x00,0x00,0xe0,0xe7,0x03,0x00,0x00,0x7e,0xff,0x00,0xc0,0x73,0xf0,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0xfc, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x3f,0xf0,0x00,0x00,0x00, + 0xfc,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00, + 0x00,0xf8,0xf3,0x00,0x00,0x00,0xfc,0x7f,0x00,0x00,0x7f,0xf0,0xff,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff, + 0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0xe0,0xff, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x7c, + 0xf8,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0x7f,0xf0,0xff,0xff,0xff,0xff,0xff, + 0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x1f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0xe0,0xff,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x7c,0xf8,0x00, + 0x00,0x00,0xf8,0xff,0xff,0xff,0x7f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff, + 0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x3f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x80,0xff,0x0f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x3e,0x00,0x00,0x00,0x00,0x00,0x7f,0x7c,0x00,0x00,0x00, + 0xe0,0xff,0xff,0xff,0x7f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x1f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0xfe,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0xc0,0x1f,0x3e,0x00,0x00,0x00,0xc0,0xff, + 0xff,0xff,0x7f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x7c,0x00,0x00,0x00,0x00,0xf0,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00, + 0x0f,0x00,0x00,0x00,0x00,0xe0,0x07,0x1f,0x00,0x00,0x00,0x80,0x0f,0x00,0x00, + 0x3c,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x3c, + 0x00,0x00,0x00,0x00,0x00,0xfe,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00, + 0x00,0x00,0x00,0xfc,0x83,0x0f,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x38,0xf0, + 0xff,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfc,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00, + 0x00,0x00,0x00,0xfe,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00, + 0x00,0xfc,0x83,0x0f,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x38,0xf0,0xff,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0, + 0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0xf8, + 0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0xff, + 0x80,0x07,0x00,0x00,0x00,0x00,0x3e,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00, + 0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff, + 0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0xff,0xff,0xff, + 0xff,0x03,0x00,0x00,0x00,0x00,0xe0,0x01,0x00,0x00,0x00,0xe0,0x1f,0xe0,0x03, + 0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x1c,0x00,0x00,0x00,0x00,0xe0,0xff,0xff, + 0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff, + 0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x00,0x00,0x00,0xff,0x3f,0xe0,0xff,0x0f, + 0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0x00,0xf8,0x07,0xf0,0x01,0x00,0x00, + 0x00,0x00,0xf0,0x01,0x00,0x1e,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x07, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x03,0x00, + 0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0xe0,0xff,0x01,0xfe,0x3f,0x00,0x00, + 0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0xfe,0x01,0xf8,0x00,0x00,0x00,0x00,0x00, + 0xc0,0x03,0x00,0x0e,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x01,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x03,0x00,0x00,0x00, + 0x00,0x80,0x07,0x00,0x00,0x00,0xe0,0xff,0x01,0xfe,0x3f,0x00,0x00,0x00,0x00, + 0xf0,0x00,0x00,0x00,0x00,0xfe,0x01,0xf8,0x00,0x00,0x00,0x00,0x00,0xc0,0x03, + 0x00,0x0e,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x80, + 0x07,0x00,0x00,0x00,0x00,0xf8,0x07,0xc0,0xff,0x01,0x00,0x00,0x00,0xf8,0x00, + 0x00,0x00,0x80,0x7f,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0x00,0x0e, + 0x00,0x00,0x00,0x00,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0xc0,0xe3,0xff, + 0xff,0x00,0x00,0xc0,0x1f,0x80,0xff,0x03,0x00,0x00,0x00,0x3c,0x00,0x00,0x00, + 0xe0,0x1f,0x00,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x07,0x00,0x00, + 0x00,0x80,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0xc0,0xfb,0xff,0xff,0x0f, + 0x00,0x00,0x3e,0x80,0xf3,0x1f,0x00,0x00,0x00,0x3e,0x00,0x00,0x00,0xf8,0x07, + 0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x07,0x00,0x00,0x00,0xe0, + 0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xff,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0xff,0x00,0x00, + 0x7c,0xc0,0x81,0xff,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,0xff,0x01,0x00,0x0f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x80,0x07,0x00,0x00,0x00,0xf0,0xff,0xff, + 0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff, + 0xff,0xff,0x03,0x00,0x00,0x00,0xc0,0x7f,0x00,0xe0,0xff,0x3f,0x00,0xf0,0xc0, + 0x01,0xfe,0x03,0x00,0x00,0x0f,0x00,0x00,0xc0,0x7f,0x00,0xc0,0x07,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf0,0xc0,0x03,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff, + 0x03,0x00,0x00,0x00,0xc0,0x7f,0x00,0xe0,0xff,0x3f,0x00,0xf0,0xc0,0x01,0xfe, + 0x03,0x00,0x00,0x0f,0x00,0x00,0xc0,0x7f,0x00,0xc0,0x07,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf0,0xc0,0x03,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0x07,0x00, + 0x00,0x00,0xc0,0x0f,0x00,0x00,0xfc,0xff,0x03,0xc0,0xe3,0x01,0xf0,0x07,0x00, + 0x80,0x07,0x00,0x00,0xf0,0x1f,0x00,0xc0,0x07,0x00,0x00,0x00,0x00,0x00,0x00, + 0xf0,0xc1,0x01,0x00,0x00,0x00,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x1f,0x00,0x00,0x00, + 0xc0,0x07,0x00,0x00,0x00,0xfc,0xff,0x00,0xf7,0x00,0x00,0x3f,0x00,0xc0,0x03, + 0x00,0x00,0xff,0x00,0x00,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xe3, + 0x01,0x00,0x00,0xc0,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0x00,0x00,0x00,0xc0,0x01, + 0x00,0x00,0x00,0xc0,0xff,0x07,0x7f,0x00,0x00,0xfc,0x00,0xe0,0x03,0x00,0xe0, + 0x3f,0x00,0x00,0xf0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0x00,0x00, + 0x00,0xf0,0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x00,0x00,0x00,0xc0,0x01,0x00,0x00, + 0x00,0x00,0xfe,0x7f,0x7f,0x00,0x00,0xf8,0x01,0xe0,0x01,0x00,0xfc,0x07,0x00, + 0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0xfc, + 0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xfe,0xff,0xff,0xff,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x00, + 0xfe,0x7f,0x7f,0x00,0x00,0xf8,0x01,0xe0,0x01,0x00,0xfc,0x07,0x00,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0xfc,0xff,0xff, + 0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfc,0xff,0xff,0xff,0x03,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0xe0,0xff, + 0x3f,0x00,0x00,0xf0,0x07,0xf0,0x00,0x00,0xff,0x03,0x00,0x00,0x7c,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x7e,0x00,0x00,0x00,0xff,0xff,0xff,0x7f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff, + 0xff,0xff,0x0f,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0xfe,0x3f,0x00, + 0x00,0xc0,0x3f,0xf8,0x00,0xf8,0x3f,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x80,0xff,0xff,0xff,0x3f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff, + 0x3f,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x0f,0x00,0x00, + 0x7f,0x7c,0x00,0xfe,0x07,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1e,0x00,0x00,0xe0,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00, + 0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x7f,0x00,0x00,0xfc,0x3e, + 0xe0,0x7f,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x1f,0x00,0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00,0x00,0x80, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x7f,0x00,0x00,0xfc,0x3e,0xe0,0x7f, + 0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00, + 0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x01,0x00,0x80,0x0f,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x1f,0x00,0xf0,0x1f,0xfe,0x0f,0x00,0x00, + 0x00,0x80,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0x00,0x00,0xfc, + 0xff,0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x0f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfc,0xff,0x3f,0xc0,0xff,0xff,0x00,0x00,0x00,0x00,0xc0, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x03,0x00,0x00,0xff,0xff,0xff, + 0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf0,0xff,0xff,0xff,0x0f,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0xe0,0x03,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x03,0x00,0xc0,0xff,0xff,0xff,0x1f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,0xff,0xff,0xff,0x7f,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xfc,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0x00,0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff, + 0xff,0xff,0x7f,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfc,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff, + 0xff,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8, + 0xff,0x1f,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x7c,0x00,0x00,0xfc,0xff,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x03, + 0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x7f, + 0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00, + 0x00,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x07,0x00,0xe0, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0xfe,0x00,0x00, + 0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x1f,0x00,0xc0,0xff, + 0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x1f,0x00,0xc0,0x03,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0xf8,0x03,0x00,0x00,0x00, + 0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x07,0x00,0xe0,0xff,0xff,0xff, + 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00,0x80,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0xe0,0x0f,0x00,0x00,0x00,0x0f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x03,0x00,0xf8,0xff,0xff,0xff,0x03,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x70,0xe0,0x0f,0x00,0x00,0x00,0x0f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf0,0x03,0x00,0xf8,0xff,0xff,0xff,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xff,0xff,0xff,0xff,0x00,0x80,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x70,0x00,0x3f,0x00,0x00,0x80,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x01,0x00,0xfe,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc, + 0xff,0xff,0xff,0x03,0x00,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x70,0x00,0xfe,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x7e,0x00,0x80,0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff, + 0xff,0x0f,0x00,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70, + 0x00,0xf8,0x01,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00, + 0xc0,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0x3f, + 0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x80, + 0x0f,0x00,0xf0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0x00,0xf8,0xff, + 0xff,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0x3f,0x00,0xf8, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x80,0x0f,0x00, + 0xf0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0x00,0xf8,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,0xff,0xff,0xff,0xff,0x00,0xe0,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x3e,0x00,0xf0,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x07,0x00,0xfe,0xff,0xff,0xff,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x03,0xc0,0x03,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0xfc,0x00,0x78,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0x01,0x80,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,0xf0,0xff,0xff,0xff,0x0f,0xc0,0x07,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x78,0x00,0x00,0xe0,0x03,0x3c,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x7c,0x00,0xe0,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,0xff,0xff,0xff,0x1f,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x7c,0x00,0x00,0xc0,0x1f,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x3e,0x00,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,0xc0, + 0xff,0xff,0xff,0x1f,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x7c,0x00,0x00,0xc0,0x1f,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3e,0x00, + 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,0x80,0xff,0xff, + 0xff,0x7f,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00, + 0x00,0x00,0x3f,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x00,0xfc,0xff, + 0xff,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,0xfe,0xff,0xff,0xff, + 0x01,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00, + 0xfc,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x07,0x00,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,0xfc,0xff,0xff,0xff,0x03,0x78, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0xf8,0x07, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0xc0,0xff,0xff,0xff,0x1f,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,0x07,0xf0,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0xfc,0x03,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0x00,0xf0,0xff,0xff,0xff,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,0xf0,0xff,0xff,0xff,0x07,0xf0,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0xfc,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf8,0x00,0xf0,0xff,0xff,0xff,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,0xe0,0xff,0xff,0xff,0x1f,0xe0,0x03,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x1c,0x00,0x00,0x00,0xfc,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x7e,0x00,0xf8,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, + 0x00,0x00,0xff,0xff,0xff,0xff,0x80,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x1e,0x00,0x00,0x00,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x00, + 0xfe,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,0x00,0x00, + 0xfc,0xff,0xff,0xff,0x01,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e, + 0x00,0x00,0x80,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x07,0x80,0xff,0xff, + 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,0x00,0xf8,0xff, + 0xff,0xff,0x07,0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0e,0x00,0x00, + 0xc0,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0xe0,0xff,0xff,0xff,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,0x00,0xe0,0xff,0xff,0xff, + 0x0f,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0xe0,0x3f, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x01,0xf8,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,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x0f,0x7c, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0xe0,0x3f,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0x01,0xf8,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,0x00,0x00,0x00,0xc0,0xff,0xff,0xff,0x3f,0xf0,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0xf0,0x1f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x7e,0x00,0xfc,0xff,0xff,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,0xfe,0xff,0xff,0x7f,0xe0,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x80,0x07,0x00,0x00,0xfc,0x1f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x3e,0x00,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, + 0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0xe0,0x03,0x00,0x00,0x00,0x00,0x00, + 0x00,0x80,0x07,0x00,0x00,0xfc,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0xc0, + 0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,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,0xc1,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x03,0x00,0x00,0xfe,0x07,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0xf0,0xff,0xff, + 0xff,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,0x00,0x00,0x00, + 0xf0,0xff,0xff,0xff,0xc1,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x00, + 0x00,0xfe,0x07,0x00,0x00,0x00,0x00,0x00,0xc0,0x0f,0xf0,0xff,0xff,0xff,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,0x00,0x00,0x00,0xf0,0xff, + 0xff,0xff,0x83,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xff, + 0x07,0x00,0x00,0x00,0x00,0x00,0xc0,0x07,0xf8,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,0x00,0x00,0x80,0xff,0xff,0xff, + 0x0f,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x01,0x00,0xc0,0xef,0x03,0x00, + 0x00,0x00,0x00,0x00,0xe0,0x01,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0x0f,0x1c, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0xe0,0xf3,0x01,0x00,0x00,0x00, + 0x00,0x00,0xf0,0x80,0xff,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x1f,0x38,0x00,0x00, + 0x00,0x00,0x00,0x00,0x70,0x00,0x00,0xf0,0xf9,0x00,0x00,0x00,0x00,0x00,0x00, + 0x78,0xe0,0xff,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0x1f,0x38,0x00,0x00,0x00,0x00, + 0x00,0x00,0x70,0x00,0x00,0xf0,0xf9,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0xe0, + 0xff,0xff,0xff,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,0x00, + 0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0x7f,0xf0,0x00,0x00,0x00,0x00,0x00,0x00, + 0x78,0x00,0x00,0x78,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,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,0x00,0x00, + 0x00,0x00,0x80,0xff,0xff,0xff,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00, + 0x00,0x7e,0x7c,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0xf8,0xff,0xff,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,0x00,0x00, + 0x00,0xff,0xff,0xff,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x3e, + 0x3e,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0xfe,0xff,0xff,0x7f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe, + 0xff,0xff,0xc1,0x03,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x0f,0x1e,0x00, + 0x00,0x00,0x00,0x00,0x00,0x0f,0xfe,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff, + 0xc1,0x03,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x0f,0x1e,0x00,0x00,0x00, + 0x00,0x00,0x00,0x0f,0xfe,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,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,0xff,0x83,0x07, + 0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0xc0,0x07,0x0f,0x00,0x00,0x00,0x00,0x00, + 0x80,0x07,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0x07,0x0f,0x00,0x00, + 0x00,0x00,0x00,0x0f,0x00,0xe0,0x83,0x0f,0x00,0x00,0x00,0x00,0x00,0x80,0xc7, + 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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x0f,0x0f,0x00,0x00,0x00,0x00, + 0x00,0x07,0x00,0xf0,0x81,0x07,0x00,0x00,0x00,0x00,0x00,0xc0,0xc3,0xff,0xff, + 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, + 0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x1f,0x1c,0x00,0x00,0x00,0x00,0x80,0x03, + 0x00,0x7c,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0xe0,0xe1,0xff,0xff,0x7f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,0xff,0x3f,0x3c,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x3f, + 0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0xe0,0xe0,0xff,0xff,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,0xff,0x3f,0x3c,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x3f,0xe0,0x01, + 0x00,0x00,0x00,0x00,0x00,0xe0,0xe0,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,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,0x3f,0x3c,0x00,0x00,0x00,0x00,0xe0,0x01,0x80,0x1f,0xe0,0x01,0x00,0x00, + 0x00,0x00,0x00,0xf0,0xe0,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x3f, + 0x38,0x00,0x00,0x00,0x00,0xe0,0x00,0xe0,0x07,0xf0,0x00,0x00,0x00,0x00,0x00, + 0x00,0x78,0xf8,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,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x38,0x00, + 0x00,0x00,0x00,0xf0,0x00,0xf0,0x03,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x78, + 0xf8,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x38,0x00,0x00,0x00, + 0x00,0x70,0x00,0xfe,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0xfc,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x38,0x00,0x00,0x00,0x00,0x70, + 0x00,0xfe,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x38,0x00,0x00,0x00,0x00,0x38,0x80,0x3f, + 0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xfc,0xff,0x3f,0x38,0x00,0x00,0x00,0x00,0x1c,0xc0,0x0f,0x00,0x1c, + 0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfc,0xff,0x1f,0x38,0x00,0x00,0x00,0x00,0x1e,0xf0,0x03,0x00,0x1e,0x00,0x00, + 0x00,0x00,0x00,0x00,0x1e,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff, + 0x1f,0x38,0x00,0x00,0x00,0x00,0x0f,0x7f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x0f,0xfc,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x1f,0x38, + 0x00,0x00,0x00,0x00,0x0f,0x7f,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x0f,0xfc,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x1f,0x38,0x00,0x00, + 0x00,0x00,0xe7,0x3f,0x00,0x00,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0xfc, + 0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x0f,0x38,0x00,0x00,0x00,0x80, + 0xfb,0x0f,0x00,0x80,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x07,0xfc,0xff,0x7f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0x38,0x00,0x00,0x00,0xc0,0xff,0x01, + 0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0xf8,0xff,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0xff,0xff,0x07,0x38,0x00,0x00,0x00,0xe0,0x3f,0x00,0x00,0xc0, + 0x01,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0xf8,0xff,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0xff,0xff,0x07,0x38,0x00,0x00,0x00,0xe0,0x3f,0x00,0x00,0xc0,0x01,0x00, + 0x00,0x00,0x00,0x00,0xc0,0x03,0xf8,0xff,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,0x00,0x00,0x00,0x00,0x00,0x80,0xff, + 0xff,0x07,0x38,0x00,0x00,0x00,0xe0,0x0f,0x00,0x00,0xe0,0x00,0x00,0x00,0x00, + 0x00,0x00,0xc0,0x03,0xf8,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,0x03, + 0x38,0x00,0x00,0x00,0xf0,0x03,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00, + 0xe0,0x01,0xf8,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,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x03,0x38,0x00, + 0x00,0x00,0x70,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x01, + 0xf0,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0xff,0x01,0x38,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x00,0xf0,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x00,0x38,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xf0,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0xff,0xff,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x38,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0xff,0xff,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0xe0,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0, + 0xff,0xff,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00, + 0x00,0x00,0x00,0x78,0x00,0xe0,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f, + 0x00,0x18,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00, + 0x00,0x78,0x00,0xc0,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0x18, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x3c, + 0x00,0xc0,0xff,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0x18,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0xc0, + 0xff,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x7f,0x00,0x1c,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x80,0xff,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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x00,0x1c,0x00,0x00,0x00,0x00,0x00,0x00, + 0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x80,0xff,0xff,0x1f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03, + 0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x80,0xff,0xff,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,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,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x00, + 0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1f,0x00,0x00,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00, + 0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00, + 0x0f,0x00,0x00,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, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x1c,0x00, + 0x00,0x00,0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00, + 0x00,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x07,0x00,0x1c,0x00,0x00,0x00, + 0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0xfe, + 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,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xff,0xff,0x07,0x00,0x1e,0x00,0x00,0x00,0x00,0x00, + 0x00,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0xfe,0xff,0x7f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x70, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0xfe,0xff,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x07,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0xfc,0xff,0x7f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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,0x03,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x38,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0x03,0x00,0x00,0xfc,0xff,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,0x00,0x00,0x00,0x80,0xff,0xff,0x03, + 0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00, + 0xc0,0x03,0x00,0x00,0xfc,0xff,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,0x00,0x00,0x00,0xc0,0xff,0xff,0x03,0x00,0x1e, + 0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03, + 0x00,0x00,0xf8,0xff,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,0x00,0x00,0x00,0xc0,0xff,0xff,0x03,0x00,0x1e,0x00,0x00, + 0x00,0x00,0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x00, + 0xf8,0xff,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,0x00,0x00,0x00,0xc0,0xff,0xff,0x01,0x00,0x1e,0x00,0x00,0x00,0x00, + 0x00,0x00,0x1e,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x00,0xf8,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0xff,0xff,0x01,0x00,0x1c,0x00,0x00,0x00,0x00,0x00,0x00, + 0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0xff,0xff,0x00,0x00,0x1c,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00, + 0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0, + 0xff,0xff,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00, + 0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f, + 0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x80,0x03,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,0x01,0x00,0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0x00, + 0x3c,0x00,0x00,0x00,0x00,0x00,0x80,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x01,0x00,0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00,0xf0,0xff,0x7f,0x00,0x00,0x38,0x00, + 0x00,0x00,0x00,0x00,0xc0,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00, + 0x00,0xe0,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,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x00,0x00,0x38,0x00,0x00,0x00, + 0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xe0, + 0xff,0xff,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,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf8,0xff,0x3f,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00, + 0xe0,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0,0xff,0xff, + 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,0x00,0x00,0x00,0x00, + 0x00,0x00,0xfc,0xff,0x1f,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0xe0,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfc,0xff,0x1f,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0xe0,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0,0xff,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff, + 0x1f,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xc0,0x01,0x00,0x00,0x80,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0x1f,0x00, + 0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xc0,0x03,0x00,0x00,0x80,0xff,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,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x38, + 0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0x03, + 0x00,0x00,0x00,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x3c,0x00,0x00, + 0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00, + 0x00,0xff,0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x3c,0x00,0x00,0x00,0x00, + 0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0xff, + 0xff,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0xfc,0x3f,0x00,0x00,0x00,0x00,0x00,0x3e, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0xfe,0xff,0x1f, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x0f,0x00,0xe0,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x1e,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0xfe,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xfc,0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0xfe,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff, + 0xff,0x0f,0x3c,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x0e,0x00,0x00,0x00,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0x0f, + 0x3c,0x00,0x00,0x00,0x00,0x00,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x0e,0x00,0x00,0x00,0xfc,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0x01,0x00,0x38,0x00, + 0x00,0x00,0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1e,0x00, + 0x00,0x00,0xfc,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x38,0x00,0x00,0x00, + 0x00,0x80,0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00, + 0xfc,0xff,0x7f,0x00,0x00,0x00,0x00,0x00,0x00,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,0x03,0x00,0x00,0x00,0x38,0x00,0x00,0x00,0x00,0xc0, + 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00,0xf8,0xff, + 0x7f,0x00,0x00,0x00,0x00,0x00,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,0x00,0x78,0x00,0x00,0x00,0x00,0xc0,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0xf8,0xff,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,0xc0,0xff,0xff, + 0x01,0x00,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0xe0,0x01,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0xf0,0xff,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,0xc0,0xff,0xff,0x01,0x00, + 0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0xe0,0x01,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xf0,0x01,0x00,0x00,0xf0,0xff,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,0xff,0xff,0x07,0x00,0xfe,0x00,0x00, + 0x00,0x70,0x00,0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xe0,0x03,0x00,0x00,0xf0,0xff,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,0xf0,0xff,0x1f,0x00,0xf8,0xff,0x00,0x00,0x00,0x70, + 0x00,0x00,0x00,0x00,0xf0,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x03,0x00,0x00,0xf0,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, + 0x00,0x00,0x00,0xfe,0x7f,0x00,0xe0,0xff,0x7f,0x00,0x00,0x00,0x70,0x00,0x00, + 0x00,0x00,0xf8,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x0f,0x00, + 0x00,0xf0,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,0x00,0x00, + 0xe0,0xff,0x03,0x00,0xf0,0xff,0x3f,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00, + 0x78,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0xe0, + 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,0xe0,0xff, + 0x03,0x00,0xf0,0xff,0x3f,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x78,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1f,0x00,0x00,0xe0,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,0xfc,0x7f,0x00,0x00, + 0xf8,0xff,0x3f,0x00,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x78,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xe0,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,0x80,0xff,0x07,0x00,0x00,0xf8,0xff, + 0x1f,0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xf8,0x01,0x00,0xe0,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,0xc0,0xff,0x00,0x00,0x00,0xfc,0xff,0x1f,0x00, + 0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,0x07,0x00,0xc0,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,0xc0,0x1f,0x00,0x00,0x00,0xfe,0xff,0x1f,0x00,0x00,0x00, + 0xe0,0x00,0x00,0x00,0x00,0x3c,0x00,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,0x3f,0x00,0xc0,0xff,0xff,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,0xc0,0x1f,0x00,0x00,0x00,0xfe,0xff,0x1f,0x00,0x00,0x00,0xe0,0x00, + 0x00,0x00,0x00,0x3c,0x00,0x00,0x60,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0, + 0x3f,0x00,0xc0,0xff,0xff,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, + 0x80,0x03,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x00,0xe0,0x00,0x00,0x00, + 0x00,0x3e,0x00,0x00,0x70,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x01, + 0x80,0xff,0xff,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,0x00, + 0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x00,0x00,0xe0,0x00,0x00,0x00,0x00,0x3f, + 0x00,0x00,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0x3f,0x80,0xff, + 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,0x00,0x00,0x00, + 0x00,0xff,0xff,0x07,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0xff,0x00,0x00, + 0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x00,0xfc,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,0x00,0x00,0x00,0x00,0xff, + 0xff,0x07,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0xf7,0x03,0x00,0x3c,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x0f,0xc0,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,0x00,0x00,0x00,0x00,0xff,0xff,0x07, + 0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0x00,0xf7,0x03,0x00,0x3c,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x0f,0xc0,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,0x00,0x00,0x00,0x80,0xff,0xff,0x03,0x00,0x00, + 0x00,0xc0,0x01,0x00,0x00,0x80,0xe3,0x0f,0x00,0x3f,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf0,0x7f,0x00,0xf8,0x1f,0x00,0x00,0x00,0x00,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,0x03,0x00,0x00,0x00,0xc0, + 0x01,0x00,0x00,0x80,0xe3,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x80,0xff,0x03,0x80,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,0x80,0xff,0xff,0x03,0x00,0x00,0x00,0xc0,0x01,0x00, + 0x00,0x80,0xc3,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfe,0x1f,0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0xff,0x01,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0, + 0x01,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0, + 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,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,0xff,0xff,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0,0x01,0xfe, + 0x7f,0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x1f, + 0x00,0x00,0x00,0x00,0x00,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, + 0xff,0xff,0x00,0x00,0x00,0x00,0xc0,0x01,0x00,0x00,0xc0,0x01,0xfe,0x7f,0x38, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfe,0x1f,0x00,0x00, + 0x00,0x00,0x00,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,0xff, + 0x00,0x00,0x00,0x00,0xc1,0x01,0x00,0x00,0xe0,0x00,0x3e,0x00,0x38,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,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,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0x00,0x00, + 0x00,0x80,0xc3,0x01,0x00,0x00,0xe0,0x00,0x7c,0x00,0x3c,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff,0x7f,0x00,0x00,0x00,0x00,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,0x7f,0x00,0x00,0x00,0xf0, + 0xc3,0x01,0x00,0x00,0xf0,0x00,0xf0,0x00,0x3c,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xff,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,0xf8,0xff,0x7f,0x00,0x00,0x00,0xf8,0xc3,0x01, + 0x00,0x00,0xf0,0x00,0xe0,0x01,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0xe0,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,0xf8,0xff,0x7f,0x00,0x00,0x00,0xf8,0xc3,0x01,0x00,0x00, + 0xf0,0x00,0xe0,0x01,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xe0,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,0xf8,0xff,0x7f,0x00,0x00,0x00,0xff,0xc3,0x03,0x00,0x00,0x70,0x00, + 0xc0,0x03,0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x80,0xff,0xff,0xff,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, + 0xf8,0xff,0x3f,0x00,0x00,0x80,0xff,0xc3,0x03,0x00,0x00,0x70,0x00,0xc0,0x03, + 0x3c,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x01,0x00, + 0xf0,0xff,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,0xf8,0xff, + 0x1f,0x00,0x00,0xe0,0xff,0xc3,0x03,0x00,0x00,0x78,0x00,0x80,0x07,0x3c,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x7f,0x00,0x00,0x00, + 0xfc,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,0xfc,0xff,0x1f,0x00, + 0x00,0xf8,0xff,0xc3,0x03,0x00,0x00,0x78,0x00,0x00,0x0f,0x3c,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0x00,0xfc,0xff,0x1f,0x00,0x00,0xf8, + 0xff,0xc3,0x03,0x00,0x00,0x78,0x00,0x00,0x0f,0x3c,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0x00,0xfc,0xff,0x0f,0x00,0x00,0xfe,0xff,0x83, + 0x03,0x00,0x00,0x3c,0x00,0x00,0x1e,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xfc,0xff,0x01,0xe0,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,0x00,0x00,0x00,0x00,0xfe,0xff,0x0f,0x00,0x80,0xff,0xff,0x87,0x03,0x00, + 0x00,0x3c,0x00,0x00,0x3c,0x1c,0x00,0x00,0x00,0x00,0x00,0x00,0xf8,0xff,0xff, + 0xff,0xff,0xe1,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,0x00,0xfe,0xff,0x0f,0x00,0xc0,0xff,0xff,0x87,0x03,0x00,0x00,0x3c, + 0x00,0x00,0x78,0x1c,0x00,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,0xff, + 0xe1,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, + 0x00,0xff,0xff,0x07,0x00,0xf8,0xff,0xff,0xc7,0x03,0x00,0x00,0x1c,0x00,0x00, + 0xe0,0x1c,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0xc0,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,0x00,0xff, + 0xff,0x07,0x00,0xf8,0xff,0xff,0xc7,0x03,0x00,0x00,0x1c,0x00,0x00,0xe0,0x1c, + 0x00,0x00,0x00,0x80,0xff,0xff,0xff,0x01,0x00,0x00,0x00,0xc0,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,0x00,0xff,0xff,0x03, + 0x00,0xfe,0xff,0xff,0xc7,0x03,0x00,0x00,0x1c,0x00,0x00,0xe0,0x1f,0x00,0x00, + 0x00,0xf0,0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x80,0xff,0xff,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,0x00,0x80,0xff,0xff,0x03,0x00,0xff, + 0xff,0xff,0xc7,0x03,0x00,0x00,0x1c,0x00,0x00,0x80,0x1f,0x00,0x00,0x00,0xff, + 0xff,0x03,0x00,0x00,0x00,0xfc,0x03,0x80,0xff,0xff,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,0x00,0x80,0xff,0xff,0x03,0xc0,0xff,0xff,0xff, + 0xc7,0x03,0x00,0x00,0x1e,0x00,0x00,0x00,0x1f,0x00,0x00,0xf8,0xff,0x0f,0x00, + 0x80,0xff,0xff,0xff,0x1f,0x00,0xff,0xff,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,0x00,0x80,0xff,0xff,0x01,0xf0,0xff,0xff,0xff,0xc3,0x03, + 0x00,0x00,0xfe,0xff,0x00,0x00,0x1f,0x00,0xe0,0xff,0x3f,0x00,0x00,0x80,0xff, + 0xff,0xff,0x3f,0x00,0xff,0xff,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,0x00,0xc0,0xff,0xff,0x01,0xfc,0xff,0xff,0xff,0xc1,0x03,0x00,0x00, + 0xfe,0xff,0xff,0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x80,0xff,0xff,0xff, + 0x7f,0x00,0xff,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, + 0x00,0xc0,0xff,0xff,0x01,0xfc,0xff,0xff,0xff,0xc1,0x03,0x00,0x00,0xfe,0xff, + 0xff,0xff,0xff,0xff,0xff,0xff,0x01,0x00,0x00,0x80,0xff,0xff,0xff,0x7f,0x00, + 0xff,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,0x00,0xe0, + 0xff,0xff,0x01,0xff,0xff,0xff,0xff,0x80,0x03,0x00,0x00,0xfe,0xff,0xff,0xff, + 0xff,0xff,0xff,0x07,0x00,0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0x01,0xfe,0xff, + 0x1f,0x00,0x00,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,0xff, + 0x80,0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x7c,0x00,0x00,0xf5,0xff,0xff, + 0x3f,0x00,0x00,0x00,0x00,0x00,0xfc,0xff,0xff,0xff,0x07,0xfe,0xff,0x1f,0x00, + 0x00,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,0x7f,0xf0,0xff, + 0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf0,0xff,0xff,0xff,0x1f,0xfe,0xff,0x1f,0x00,0x00,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,0x7f,0xf8,0xff,0xff,0xff, + 0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xc0,0xff,0xff,0xff,0x3f,0xfe,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,0x00,0x00,0xf0,0xff,0x7f,0xf8,0xff,0xff,0xff,0x03,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0xc0,0xff,0xff,0xff,0x3f,0xfe,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,0x00,0x00,0xf0,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xff, + 0xff,0xff,0xff,0xfc,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, + 0x00,0x00,0xf8,0xff,0xff,0xff,0xff,0xff,0x3f,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xfc,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,0x00,0x00, + 0xf8,0xff,0xff,0xff,0xff,0xff,0x0f,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xf0,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,0x00,0x00,0xfc,0xff, + 0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0xff,0xff,0x7f, + 0x00,0x00,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,0xff,0xff, + 0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00, + 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,0xff,0xff,0xff,0xff, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x80,0xff,0xff,0xff,0xff,0xff,0x7f,0x00,0x00,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,0xff,0xff,0xff,0x7f,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xfe,0xff,0xff,0xff,0xff,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,0xfe,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,0xfc,0xff,0xff,0xff,0xff,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,0xfe,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,0xf0, + 0xff,0xff,0xff,0xff,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,0xfe,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,0xf0,0xff,0xff, + 0xff,0xff,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,0xfe, + 0xff,0xff,0xff,0xff,0x03,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x00,0x00,0xff,0xff,0xff, + 0xff,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,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,0x00,0x80,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,0xfe,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,0x00,0x80,0xff,0xff,0xff,0xff,0x1f,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,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,0xc0,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,0x00,0x00,0xf0,0xff,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,0xc0,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,0x00, + 0x00,0xf0,0xff,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,0xc0,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,0xc0, + 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,0x00,0x00,0x00,0x00,0xc0, + 0xff,0xff,0xff,0xff,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, + 0xff,0xff,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,0xe0,0xff,0xff, + 0xff,0x1f,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, + 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,0xe0,0xff,0xff,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,0xfc,0xff,0xff,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,0xe0,0xff,0xff,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,0xfc,0xff,0xff,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,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,0xf8,0xff,0xff,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,0xf0,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,0x00,0xe0,0xff,0xff,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,0xf8,0xff,0xff,0x7f,0x00,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,0xff,0xff,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, + 0xf8,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,0x00,0x00, + 0xff,0xff,0xff,0x1f,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,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,0x00,0x00,0xff,0xff, + 0xff,0x1f,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,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,0x00,0xfc,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,0xfc,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,0xf8,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,0xfe,0xff,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,0xe0,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,0xfe,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,0x00,0x00,0x00,0x80,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,0xfe,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, + 0x00,0x00,0x00,0x80,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,0xfe,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,0x00, + 0x00,0x00,0xfe,0xff,0x7f,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,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,0x00,0x00,0x00, + 0xfc,0xff,0x7f,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,0x00, + 0x00,0x00,0x00,0x00,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, + 0x7f,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,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,0x00,0x00,0x00,0x00,0x00,0xc0,0xff,0x7f,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,0x1f,0x00,0x00,0x00,0x00,0x00, + 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,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,0x1f,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0xc0,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,0x00,0x00,0x00,0x00,0xfe,0xff,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0xc0,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,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xfc,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0xf0,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x1f,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,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,0xff,0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x1f,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,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,0xff, + 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xe0,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,0x80,0xff,0x01,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,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,0xfe,0x03,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x03,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x03,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0xf0,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,0xc0,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,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,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,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, + 0x00,0x00,0x00,0x00,0x00,0x00,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/hacks/imsmap.c b/hacks/imsmap.c new file mode 100644 index 00000000..54e8a774 --- /dev/null +++ b/hacks/imsmap.c @@ -0,0 +1,502 @@ +/* imsmap, Copyright (c) 1992 Juergen Nickelsen + * Derived from code by Markus Schirmer, TU Berlin. + * + * 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-aug-92: jwz: hacked. + * 17-May-97: jwz: hacked more. + */ + +#include +#include +#include /* for gettimeofday() */ + +#include +#include + +#include "screenhack.h" + +#define NSTEPS 7 +#define COUNT (1 << NSTEPS) +#define CELL(c, r) cell[((unsigned int)(c)) + ((unsigned int) (r)) * xmax] + +static enum mode_t { MODE_H, MODE_S, MODE_V, MODE_RANDOM } mode; + +static GC gc, gc2; +static XWindowAttributes xgwa; + +#if defined(sun) && !__STDC__ /* sun cc doesn't know "signed char" */ +#define signed /**/ +#endif + +static Colormap cmap; +static int ncolors; +static XColor *colors; +static Bool cycle_p; +static int cycle_direction; +static Bool extra_krinkly_p; + +static int delay, cycle_delay; +static signed char *cell = NULL; +static int xmax, ymax; +static int iterations; + +static void +init_map (Display *dpy, Window window) +{ + unsigned long fg_pixel = 0, bg_pixel = 0; + int fg_h, bg_h; + double fg_s, fg_v, bg_s, bg_v; + + enum mode_t this_mode; + static Bool rv_p; + + XGCValues gcv; + + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + + if (!ncolors) + { + char *mode_str = get_string_resource ("mode", "Mode"); + rv_p = get_boolean_resource ("reverseVideo", "ReverseVideo"); + cycle_p = get_boolean_resource ("cycle", "Cycle"); + ncolors = get_integer_resource ("ncolors", "Integer"); + delay = get_integer_resource ("delay", "Integer"); + cycle_delay = get_integer_resource ("cycleDelay", "Integer"); + iterations = get_integer_resource ("iterations", "Integer"); + if (iterations < 0) iterations = 0; + else if (iterations > 7) iterations = 7; + + if (ncolors <= 2) ncolors = 0; + if (ncolors == 0) mono_p = True; + + fg_pixel = get_pixel_resource ("background", "Background", dpy, cmap); + bg_pixel = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + + if (fg_pixel == bg_pixel) + { + XColor black, white; + black.red = black.green = black.blue = 0; + white.red = white.green = white.blue = 0xFFFF; + black.flags = white.flags = DoRed|DoGreen|DoBlue; + XAllocColor(dpy, cmap, &black); + XAllocColor(dpy, cmap, &white); + if (bg_pixel == black.pixel) + fg_pixel = white.pixel; + else + fg_pixel = black.pixel; + } + + if (mono_p) cycle_p = False; + + gcv.foreground = fg_pixel; + gcv.background = bg_pixel; + gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + gcv.foreground = bg_pixel; + gc2 = XCreateGC (dpy, window, GCForeground, &gcv); + + if (!mode_str || !strcmp (mode_str, "random")) + mode = MODE_RANDOM; + else if (!strcmp (mode_str, "h") || !strcmp (mode_str, "hue")) + mode = MODE_H; + else if (!strcmp (mode_str, "s") || !strcmp (mode_str, "saturation")) + mode = MODE_S; + else if (!strcmp (mode_str, "v") || !strcmp (mode_str, "value")) + mode = MODE_V; + else + { + fprintf (stderr, + "%s: mode must be hue, saturation, value, or random, not \"%s\"\n", + progname, mode_str); + mode = MODE_RANDOM; + } + } + + this_mode = mode; + if (!mono_p && mode == MODE_RANDOM) + switch (random () % 6) { + case 0: this_mode = MODE_H; break; + case 1: this_mode = MODE_S; break; + case 2: this_mode = MODE_V; break; + default: break; + } + + if (mono_p) + extra_krinkly_p = !(random() % 15); + else + extra_krinkly_p = !(random() % 5); + + if (!mono_p) + { + double distance, fg_H, bg_H, dh; + + RETRY: + fg_h = random() % 360; + fg_s = frand(1.0); + fg_v = frand(1.0); + + bg_h = fg_h; + bg_s = fg_s; + bg_v = fg_v; + + switch (this_mode) + { + case MODE_H: + bg_h = random() % 360; + if (fg_v < 0.4) + goto RETRY; + distance = fg_h - bg_h; + if (distance < 0) + distance = -distance; + if (distance > 360) + distance = 180 - (distance - 180); + if (distance < 30) + goto RETRY; + break; + + case MODE_S: + bg_s = frand(1.0); + if (fg_v < 0.4) + goto RETRY; + distance = fg_s - bg_s; + if (distance < 0) + distance = -distance; + if (distance < 0.2) + goto RETRY; + break; + + case MODE_V: + bg_v = frand(1.0); + distance = fg_v - bg_v; + if (distance < 0) + distance = -distance; + if (distance < 0.4) + goto RETRY; + break; + + default: + bg_h = random() % 360; + bg_s = frand(1.0); + bg_v = frand(1.0); + + fg_H = ((double) fg_h) / 360; + bg_H = ((double) bg_h) / 360; + dh = fg_H - bg_H; + if (dh < 0) dh = -dh; + if (dh > 0.5) dh = 0.5 - (dh - 0.5); + distance = sqrt ((dh * dh) + + ((fg_s - bg_s) * (fg_s - bg_s)) + + ((fg_v - bg_v) * (fg_v - bg_v))); + if (distance < 0.2) + goto RETRY; + } + + cycle_p = True; + if (colors) + free_colors (dpy, cmap, colors, ncolors); + else + colors = (XColor *) malloc (ncolors * sizeof(*colors)); + + cycle_direction = (random() & 1 ? 1 : -1); + + RETRY_NON_WRITABLE: + { + int n = ncolors; + make_color_ramp (dpy, cmap, + fg_h, fg_s, fg_v, + bg_h, bg_s, bg_v, + colors, &n, + True, True, cycle_p); + if (n == 0 && cycle_p) + { + cycle_p = False; + goto RETRY_NON_WRITABLE; + } + ncolors = n; + } + + if (ncolors <= 0) + mono_p = 1; + } + + if (mono_p) + { + static Bool done = False; + static XColor c[50]; + colors = c; + cycle_p = False; + ncolors = sizeof(c)/sizeof(*c); + if (!done) + { + int i; + done = True; + colors[0].pixel = fg_pixel; + for (i = 1; i < ncolors; i++) + colors[i].pixel = bg_pixel; + } + } + + XSetForeground (dpy, gc, colors[1].pixel); + XFillRectangle (dpy, window, gc, 0, 0, xgwa.width, xgwa.height); +} + + +#define HEIGHT_TO_PIXEL(height) \ + ((height) < 0 \ + ? (extra_krinkly_p \ + ? ncolors - ((-(height)) % ncolors) \ + : 0) \ + : ((height) >= ncolors \ + ? (extra_krinkly_p \ + ? (height) % ncolors \ + : ncolors-1) \ + : (height))) + + +static unsigned int +set (unsigned int l, + unsigned int c, + unsigned int size, + int height) +{ + int rang = 1 << (NSTEPS - size); + height = height + (random () % rang) - rang / 2; + height = HEIGHT_TO_PIXEL(height); + CELL (l, c) = height; + return colors[height].pixel; +} + +static void +floyd_steinberg (Display *dpy, Window window) +{ + int x, y, err; + + /* Instead of repeatedly calling XPutPixel(), we make an Image and then + send its bits over all at once. This consumes much less network + bandwidth. The image we create is Wx1 intead of WxH, so that we + don't use enormous amounts of memory. + */ + XImage *image = + XCreateImage (dpy, xgwa.visual, + 1, XYBitmap, 0, /* depth, format, offset */ + (char *) calloc ((xmax + 8) / 8, 1), /* data */ + xmax, 1, 8, 0); /* w, h, pad, bpl */ + + XSetForeground (dpy, gc, colors[0].pixel); + XSetBackground (dpy, gc, colors[1].pixel); + + for (y = 0; y < ymax - 1; y++) + { + for (x = 0; x < xmax - 1; x++) + { + if (CELL(x, y) < 0) + { + err = CELL (x, y); + XPutPixel (image, x, 0, 1); + } + else + { + err = CELL (x, y) - 1; + XPutPixel (image, x, 0, 0); + } + /* distribute error */ + CELL (x, y+1) += (int) (((float) err) * 3.0/8.0); + CELL (x+1, y) += (int) (((float) err) * 3.0/8.0); + CELL (x+1, y+1) += (int) (((float) err) * 1.0/4.0); + } + XPutImage (dpy, window, gc, image, 0, 0, 0, y, xmax, 1); + } + XDestroyImage (image); +} + +static void +draw (Display *dpy, Window window, + int x, int y, unsigned long pixel, int grid_size) +{ + static unsigned int last_pixel, last_valid = 0; + if (! (last_valid && pixel == last_pixel)) + XSetForeground (dpy, gc, pixel); + last_valid = 1, last_pixel = pixel; + if (grid_size == 1) + XDrawPoint (dpy, window, gc, x, y); + else + XFillRectangle (dpy, window, gc, x, y, grid_size, grid_size); +} + + +static void +draw_map (Display *dpy, Window window) +{ + int xstep, ystep, xnextStep, ynextStep; + int x, y, i, x1, x2, y1, y2; + unsigned int pixel, qpixels [4]; + + int backwards = random() & 1; + + xmax = xgwa.width; + ymax = xgwa.height; + + cell = (signed char *) calloc (xmax * ymax, 1); + if (cell == NULL) + exit (1); + + CELL (0, 0) = 0; + xstep = (backwards ? -COUNT : COUNT); + ystep = COUNT; + for (i = 0; i < iterations; i++) + { + xnextStep = xstep / 2; + ynextStep = ystep / 2; + for (x = (backwards ? xmax-1 : 0); + (backwards ? x >= 0 : x < xmax); + x += xstep) + { + x1 = x + xnextStep; + if (x1 < 0) + x1 = xmax-1; + else if (x1 >= xmax) + x1 = 0; + + x2 = x + xstep; + if (x2 < 0) + x2 = xmax-1; + else if (x2 >= xmax) + x2 = 0; + + for (y = 0; y < ymax; y += ystep) + { + y1 = y + ynextStep; + if (y1 < 0) + y1 = ymax-1; + else if (y1 >= ymax) + y1 = 0; + + y2 = y + ystep; + if (y2 < 0) + y2 = ymax-1; + else if (y2 >= ymax) + y2 = 0; + + qpixels [0] = colors [HEIGHT_TO_PIXEL (CELL (x, y))].pixel; + qpixels [1] = colors [HEIGHT_TO_PIXEL (CELL (x, y2))].pixel; + qpixels [2] = colors [HEIGHT_TO_PIXEL (CELL (x2, y))].pixel; + qpixels [3] = colors [HEIGHT_TO_PIXEL (CELL (x2, y2))].pixel; + + pixel = set (x, y1, i, + ((int) CELL (x, y) + (int) CELL (x, y2) + 1) / 2); + if (! mono_p && + (pixel != qpixels[0] || pixel != qpixels[1] || + pixel != qpixels[2] || pixel != qpixels[3])) + draw (dpy, window, x, y1, pixel, ynextStep); + + pixel = set (x1, y, i, + ((int) CELL (x, y) + (int) CELL (x2, y) + 1) / 2); + if (! mono_p && + (pixel != qpixels[0] || pixel != qpixels[1] || + pixel != qpixels[2] || pixel != qpixels[3])) + draw (dpy, window, x1, y, pixel, ynextStep); + + pixel = set (x1, y1, i, + ((int) CELL (x, y) + (int) CELL (x, y2) + + (int) CELL (x2, y) + (int) CELL (x2, y2) + 2) + / 4); + if (! mono_p && + (pixel != qpixels[0] || pixel != qpixels[1] || + pixel != qpixels[2] || pixel != qpixels[3])) + draw (dpy, window, x1, y1, pixel, ynextStep); + + + if (cycle_p) + { + struct timeval now; + static struct timeval then = { 0, }; + unsigned long diff; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; + gettimeofday(&now, &tzp); +#else + gettimeofday(&now); +#endif + diff = (((now.tv_sec - then.tv_sec) * 1000000) + + (now.tv_usec - then.tv_usec)); + if (diff > cycle_delay) + { + rotate_colors (dpy, cmap, colors, ncolors, + cycle_direction); + then = now; + } + } + } + } + xstep = xnextStep; + ystep = ynextStep; + if (!mono_p) + XSync (dpy, True); + } + if (mono_p) + /* in mono-mode, we do all the drawing at the end */ + floyd_steinberg (dpy, window); + + free (cell); + XSync (dpy, True); +} + + +char *progclass = "Imsmap"; + +char *defaults [] = { + "Imsmap.background: black", /* to placate SGI */ + "Imsmap.foreground: black", + "*mode: random", + "*ncolors: 50", + "*iterations: 7", + "*delay: 10", + "*cycleDelay: 100000", + "*cycle: true", + 0 +}; + +XrmOptionDescRec options [] = { + { "-ncolors", ".ncolors", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-cycle-delay", ".cycleDelay", XrmoptionSepArg, 0 }, + { "-mode", ".mode", XrmoptionSepArg, 0 }, + { "-iterations", ".iterations", XrmoptionSepArg, 0 }, + { "-cycle", ".cycle", XrmoptionNoArg, "True" }, + { "-no-cycle", ".cycle", XrmoptionNoArg, "False" }, + { 0, 0, 0, 0 } +}; + + +void +screenhack (Display *dpy, Window window) +{ + while (1) + { + init_map (dpy, window); + draw_map (dpy, window); + if (delay) + { + if (cycle_p) + { + time_t start = time((time_t) 0); + while (start + delay > time((time_t) 0)) + { + rotate_colors (dpy, cmap, colors, ncolors, + cycle_direction); + if (cycle_delay) usleep(cycle_delay); + } + } + else + sleep (delay); + } + } +} diff --git a/hacks/imsmap.man b/hacks/imsmap.man new file mode 100644 index 00000000..d0ea4183 --- /dev/null +++ b/hacks/imsmap.man @@ -0,0 +1,66 @@ +.TH XScreenSaver 1 "17-May-97" "X Version 11" +.SH NAME +imsmap - generate fractal maps +.SH SYNOPSIS +.B imsmap +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIint\fP] [\-delay \fIseconds\fP] [\-iterations \fIint\fP] [\-mode h|s|v|random] [\-cycle] [\-no\-cycle] +.SH DESCRIPTION +The \fIimsmap\fP program generates map or cloud-like patterns. It looks +quite different in monochrome and color. +.SH OPTIONS +.I imsmap +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors to use. Default 50. +.TP 8 +.B \-delay \fIinteger\fP +How long to delay between images. Default 10 seconds. +.TP 8 +.B \-iterations \fIinteger\fP +A measure of the resolution of the resultant image, from 0 to 7. Default 7. +.TP 8 +.B \-mode [ hue | saturation | value | random ] +The axis upon which colors should be interpolated between the foreground +and background color. Default random. +.TP 8 +.B \-cycle +.TP 8 +.B \-no\-cycle +Whether to do colormap cycling. Default is to cycle. +.TP 8 +.B \-cycle\-delay +Number of microseconds between shifts of the colormap; default 100000, +or 1/10th second. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH AUTHOR +Juergen Nickelsen , 23-aug-92. + +Hacked on by Jamie Zawinski , 24-aug-92, 17-May-97. diff --git a/hacks/julia.c b/hacks/julia.c new file mode 100644 index 00000000..680a5b19 --- /dev/null +++ b/hacks/julia.c @@ -0,0 +1,420 @@ +/* -*- Mode: C; tab-width: 4 -*- + * julia --- continuously varying Julia set. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)julia.c 4.03 97/04/10 xlockmore"; +#endif + +/* Copyright (c) 1995 Sean McCullough . + * + * 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: + * 28-May-97: jwz@netscape.com: added interactive frobbing with the mouse. + * 10-May-97: jwz@netscape.com: 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 "*count: 1000 \n" \ + "*cycles: 20 \n" \ + "*delay: 10000 \n" \ + "*ncolors: 200 \n" +# define UNIFORM_COLORS +# include "xlockmore.h" /* in xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* in xlockmore distribution */ +#endif /* !STANDALONE */ + + +static Bool track_p; + +#define DEF_MOUSE "False" + +static XrmOptionDescRec opts[] = +{ + {"-mouse", ".julia.mouse", XrmoptionNoArg, (caddr_t) "on"}, + {"+mouse", ".julia.mouse", XrmoptionNoArg, (caddr_t) "off"}, +}; +static argtype vars[] = +{ + {(caddr_t *) & track_p, "mouse", "Mouse", DEF_MOUSE, t_Bool}, +}; +static OptionStruct desc[] = +{ + {"-/+mouse", "turn on/off mouse tracking"}, +}; + +ModeSpecOpt julia_opts = { 2, opts, 1, vars, desc }; + + +#define numpoints ((0x2<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; + Cursor cursor; + GC stippledGC; + XPoint **pointBuffer; /* pointer for XDrawPoints */ + +} 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 */ + 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); + + d--; + apply(jp, xr, xi, d); + apply(jp, -xr, -xi, d); + } +} + +static void +incr(ModeInfo * mi, juliastruct * jp) +{ + int cx, cy; + + if (track_p) + { + Window r, c; + int rx, ry; + unsigned int m; + XQueryPointer(MI_DISPLAY(mi), MI_WINDOW(mi), + &r, &c, &rx, &ry, &cx, &cy, &m); + if (cx <= 0 || cy <= 0 || + cx >= MI_WIN_WIDTH(mi) || cy >= MI_WIN_HEIGHT(mi)) + goto NOTRACK; + } + + if (track_p) + { + jp->cr = ((double) (cx + 2 - jp->centerx)) * 2 / jp->centerx; + jp->ci = ((double) (cy + 2 - jp->centery)) * 2 / jp->centery; + } + else + { + NOTRACK: + 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; + + if (julias == NULL) { + if ((julias = (juliastruct *) calloc(MI_NUM_SCREENS(mi), + sizeof (juliastruct))) == NULL) + return; + } + jp = &julias[MI_SCREEN(mi)]; + + jp->centerx = MI_WIN_WIDTH(mi) / 2; + jp->centery = MI_WIN_HEIGHT(mi) / 2; + + jp->depth = MI_BATCHCOUNT(mi); + if (jp->depth > 10) + jp->depth = 10; + + + if (track_p && !jp->cursor) + { + Pixmap bit; + XColor black; + black.red = black.green = black.blue = 0; + black.flags = DoRed|DoGreen|DoBlue; + bit = XCreatePixmapFromBitmapData (display, window, "\000", 1, 1, + MI_WIN_BLACK_PIXEL(mi), + MI_WIN_BLACK_PIXEL(mi), 1); + jp->cursor = XCreatePixmapCursor (display, bit, bit, &black, &black, + 0, 0); + XFreePixmap (display, bit); + } + + 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 (MI_WIN_IS_INROOT(mi)) + ; + else if (jp->circsize > 0) + XDefineCursor (display, window, jp->cursor); + else + XUndefineCursor (display, window); + + if (!jp->stippledGC) { + gcv.foreground = MI_WIN_BLACK_PIXEL(mi); + gcv.background = MI_WIN_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 = ((LRAND() & 1) * 2 - 1) * NRAND(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]) + (void) memset((char *) jp->pointBuffer[i], 0, + numpoints * sizeof (XPoint)); + else + jp->pointBuffer[i] = (XPoint *) calloc(numpoints, sizeof (XPoint)); + jp->buffer = 0; + jp->redrawing = 0; + jp->erase = 0; + XClearWindow(display, window); +} + + +/* hack: moved here by jwz. */ +#define ERASE_IMAGE(d,w,g,x,y,xl,yl,xs,ys) \ +if (yly) \ +(y>yl-ys)?XFillRectangle(d,w,g,xl,y+ys,xs,yl-y): \ +XFillRectangle(d,w,g,xl,yl,xs,ys); \ +if (xlx) \ +(x>xl-xs)?XFillRectangle(d,w,g,x+xs,yl,xl-x,ys): \ +XFillRectangle(d,w,g,xl,yl,xs,ys) + + +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; + + 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_WIN_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_WIN_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_WIN_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 = 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)]; + + jp->redrawing = 1; + jp->redrawpos = 0; +} diff --git a/hacks/julia.man b/hacks/julia.man new file mode 100644 index 00000000..8b40e487 --- /dev/null +++ b/hacks/julia.man @@ -0,0 +1,83 @@ +.TH XScreenSaver 1 "28-May-97" "X Version 11" +.SH NAME +julia - draws spinning, animating julia-set fractals +.SH SYNOPSIS +.B julia +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] [\-mouse] [\-nomouse] + +.SH DESCRIPTION +The \fIjulia\fP program draws spinning, animating julia-set fractals. + +It uses ifs {w0 = sqrt(x-c), w1 = -sqrt(x-c)} with random iteration +to plot the julia set, and sinusoidially varied parameters for the set, +and plots parameters with a circle. + +One thing to note is that count is the \fIdepth\fP of the search tree, +so the number of points computed is (2^count)-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. + +.SH OPTIONS +.I julia +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-mouse +.TP 8 +.B \-nomouse +If \fI\-mouse\fP is specified, the control point of the Julia set will +be derived from the position of the mouse in the window. When the mouse +is not in the window, the control point is chosen the normal way. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1995 by Sean McCullough. + +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. +.SH AUTHOR +Sean McCullough , 1995. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/kaleidescope.c b/hacks/kaleidescope.c new file mode 100644 index 00000000..c6d7a981 --- /dev/null +++ b/hacks/kaleidescope.c @@ -0,0 +1,464 @@ +/* kaleidescope, Copyright (c) 1997 Ron Tapia + * + * 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. + */ + +/* + * The above, for lack of a better copyright statement in easy reach + * was just lifted from the xscreensaver source. + * + * One of the odd things about this hack is that the radial motion of the + * segments depends on roundoff error alone. + * + * I tried to make the source easy to add other shapes. So far, I've + * only messed with elipses and I couldn't do much with them that looked + * cool. A nice addition would be to add some sort of spline based shapes. + * Maybe rectangles would look nice. + * + */ + + +#include +#include +#include +#include +#include "spline.h" +#include "screenhack.h" + +#define NEWX(x,y) ((x*g.costheta) + (y*g.sintheta)) +#define NEWY(x,y) ((y*g.costheta) - (x*g.sintheta)) + + +typedef struct { + int xoff, yoff; /* offset of origin xmax/2, ymax/2 */ + int xmax, ymax; /* width, height of window */ + float costheta, sintheta; + int symmetry; + int ntrails; + int nsegments; + int narcs; + int nobjects; + int local_rotation; + int global_rotation; + int spring_constant; + Colormap cmap; + GC draw_gc; + GC erase_gc; + unsigned int default_fg_pixel; + Display *dpy; + Window window; + unsigned long delay; + unsigned short redmin,redrange,greenmin,greenrange,bluemin,bluerange; + int color_mode; +} GLOBAL; + +typedef struct Obj OBJECT; +struct Obj { + int type; + int time; + void (*propogate) (OBJECT *); + void (*draw) (OBJECT *); + void (*init) (OBJECT *); + void *cur; +}; + +typedef struct KSEGMENT { + struct KSEGMENT *next; + XColor color; + int drawn; + short int x1,y1,x2,y2; /* these are in the natural coordinate system */ + XSegment *xsegments; /* these are in the X coordinate system */ +} Ksegment; + +/* BEGIN global variables */ + +GLOBAL g; +OBJECT *objects; + +char *progclass = "Kaleidescope"; +char *defaults [] = { + "Kaleidescope.background: black", /* to placate SGI */ + "Kaleidescope.foreground: white", + "*color_mode: nice", + "*symmetry: 11", + "*ntrails: 100", + "*nsegments: 7", + "*local_rotation: -59", + "*global_rotation: 1", + "*spring_constant: 5", + "*delay: 20000", + "*redmin: 30000", + "*redrange: 20000", + "*greenmin: 30000", + "*greenrange: 20000", + "*bluemin: 30000", + "*bluerange: 20000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-color_mode", ".color_mode", XrmoptionSepArg, 0 }, + { "-symmetry", ".symmetry", XrmoptionSepArg, 0 }, + { "-nsegments", ".nsegments", XrmoptionSepArg, 0 }, + { "-ntrails", ".ntrails", XrmoptionSepArg, 0 }, + { "-local_rotation", ".local_rotation", XrmoptionSepArg, 0 }, + { "-global_rotation", ".global_rotation", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-spring_constant", ".spring_constant", XrmoptionSepArg, 0 }, + { "-redmin", ".redmin", XrmoptionSepArg, 0 }, + { "-redrange", ".redmin", XrmoptionSepArg, 0 }, + { "-bluemin", ".bluemin", XrmoptionSepArg, 0 }, + { "-bluerange", ".bluerange", XrmoptionSepArg, 0 }, + { "-greenmin", ".greenmin", XrmoptionSepArg, 0 }, + { "-greenrange", ".greenrange", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +/* END global variables */ + +static void +krandom_color(XColor *color) +{ + int r; + r = ya_random() % 3; + + if((g.color_mode == 0) || (g.color_mode == 1)) { + + color->blue = ((r = ya_random()) % g.bluerange) + g.bluemin; + color->green = ((r = ya_random()) % g.greenrange) + g.greenmin; + color->red = ((r = ya_random()) % g.redrange) + g.redmin; + + if(!XAllocColor(g.dpy, g.cmap, color)) { + color->pixel = g.default_fg_pixel; + } + return; + } else { + color->pixel = g.default_fg_pixel; + return; + } +} + + +static void +kcopy_color(XColor *to, XColor *from) +{ + to->red = from->red; + to->green = from->green; + to->blue = from->blue; + to->pixel = from->pixel; +} + +static void +kcycle_color(XColor *color, + unsigned short redstep, + unsigned short greenstep, + unsigned short bluestep) +{ + unsigned short red,green,blue; + + if (! g.color_mode) { + XColor copy; + color->flags = DoRed|DoGreen|DoBlue; + color->red = (red = color->red) - redstep; + color->green = (green = color->green) - greenstep; + color->blue = (blue = color->blue) - bluestep; + copy = *color; + + if(!XAllocColor(g.dpy, g.cmap, color)) { + /* printf("couldn't alloc color...\n"); */ + color->pixel = g.default_fg_pixel; + } + copy.pixel = color->pixel; + *color = copy; + + color->red = red - redstep; + color->green = green- greenstep; + color->blue = blue - bluestep; + return; + } +} + + +static Ksegment * +create_ksegment (void) +{ + Ksegment *seg, *prev; + XColor new_color; + int i; + unsigned short redstep,bluestep,greenstep; + + krandom_color(&new_color); + + redstep = new_color.red/(2 * g.ntrails); + greenstep = new_color.green/(2 * g.ntrails); + bluestep = new_color.blue/(2 * g.ntrails); + + seg = (Ksegment *) malloc(sizeof(Ksegment)); + seg->xsegments = (XSegment *) malloc(g.symmetry * sizeof(XSegment)); + + prev = seg; + for(i=0; i< (g.ntrails - 1); i++) { + + kcycle_color(&new_color,redstep,greenstep,bluestep); + + kcopy_color(&(prev->color), &new_color); + + prev->next = (Ksegment*)malloc(sizeof(Ksegment)); + (prev->next)->xsegments = (XSegment*)malloc(g.symmetry * sizeof(XSegment)); + prev->drawn = 0; + prev = (prev->next); + } + + prev->drawn = 0; + prev->next = seg; + kcopy_color(&(prev->color), &new_color); + + return seg; +} + +static void +init_ksegment (OBJECT *obj) +{ + + /* Give the segment some random values */ + ((Ksegment *)obj->cur)->x1 = ya_random() % g.xoff; + ((Ksegment *)obj->cur)->y1 = ya_random() % g.yoff; + ((Ksegment *)obj->cur)->x2 = ya_random() % g.xoff; + ((Ksegment *)obj->cur)->y2 = ya_random() % g.yoff; +} + + +static void +draw_ksegment (OBJECT *obj) +{ + register short x1, y1, x2, y2; + int dx, dy; + int i; + static int counter=0; + + counter++; + + x1 = ((Ksegment *)obj->cur)->x1; /* in the natural coordinate system */ + y1 = ((Ksegment *)obj->cur)->y1; + x2 = ((Ksegment *)obj->cur)->x2; + y2 = ((Ksegment *)obj->cur)->y2; + + dx = x2 - x1; + dy = y2 - y1; + + /* maybe throw away values and start over */ + if( ((dx*dx) + (dy * dy)) < 100) { + init_ksegment (obj); + x1 = ((Ksegment *)obj->cur)->x1; /* in the natural coordinate system */ + y1 = ((Ksegment *)obj->cur)->y1; + x2 = ((Ksegment *)obj->cur)->x2; + y2 = ((Ksegment *)obj->cur)->y2; + } + + for (i=0; icur)->xsegments)[i].x1 = NEWX(x1,y1); + (((Ksegment *)obj->cur)->xsegments)[i].y1 = NEWY(x1,y1); + (((Ksegment *)obj->cur)->xsegments)[i].x2 = NEWX(x2,y2); + (((Ksegment *)obj->cur)->xsegments)[i].y2 = NEWY(x2,y2); + + (((Ksegment *)obj->cur)->xsegments)[i].x1 = (x1 = (((Ksegment *)obj->cur)->xsegments)[i].x1) + g.xoff; + (((Ksegment *)obj->cur)->xsegments)[i].y1 = (y1 = (((Ksegment *)obj->cur)->xsegments)[i].y1) + g.yoff; + (((Ksegment *)obj->cur)->xsegments)[i].x2 = (x2 = (((Ksegment *)obj->cur)->xsegments)[i].x2) + g.xoff; + (((Ksegment *)obj->cur)->xsegments)[i].y2 = (y2 = (((Ksegment *)obj->cur)->xsegments)[i].y2) + g.yoff; + } + + XSetForeground(g.dpy, g.draw_gc, (((Ksegment *)obj->cur)->color).pixel); + + XDrawSegments(g.dpy, g.window, g.draw_gc, ((Ksegment *)obj->cur)->xsegments, g.symmetry); + ((Ksegment *)obj->cur)->drawn = 1; + + if (((((Ksegment *)obj->cur)->next)->drawn) != 0) { + XDrawSegments(g.dpy, g.window, g.erase_gc, ((Ksegment *)obj->cur)->next->xsegments, g.symmetry); + } +} + +static void +propogate_ksegment(OBJECT *obj) +{ + int t; + short int x1,y1,x2,y2; + short int midx,midy,nmidx,nmidy; + float lsin, lcos, gsin, gcos; + + lsin = sin((2*M_PI/10000)*g.local_rotation); + lcos = cos((2*M_PI/10000)*g.local_rotation); + gsin = sin((2*M_PI/10000)*g.global_rotation); + gcos = cos((2*M_PI/10000)*g.global_rotation); + + t=obj->time; + obj->time = t + 1; + + x1 = ((Ksegment *) obj->cur)->x1; + y1 = ((Ksegment *) obj->cur)->y1; + x2 = ((Ksegment *) obj->cur)->x2; + y2 = ((Ksegment *) obj->cur)->y2; + + midx = (x1 + x2)/2; + midy = (y1 + y2)/2; + + nmidx = midx*gcos + midy*gsin; + nmidy = midy*gcos - midx*gsin; + + x1 = x1 - midx; + x2 = x2 - midx; + y1 = y1 - midy; + y2 = y2 - midy; + + + /* This is where we move to the next ksegment... */ + obj->cur = ((Ksegment *)obj->cur)->next; + + ((Ksegment *)obj->cur)->x1 = ((x1*lcos) + (y1*lsin)) + nmidx; + ((Ksegment *)obj->cur)->y1 = ((y1*lcos) - (x1*lsin)) + nmidy; + ((Ksegment *)obj->cur)->x2 = ((x2*lcos) + (y2*lsin)) + nmidx; + ((Ksegment *)obj->cur)->y2 = ((y2*lcos) - (x2*lsin)) + nmidy; + + return ; +} + +static void +init_objects (void) +{ + int i; + for (i=0; i, 20-Mar-97. + diff --git a/hacks/laser.c b/hacks/laser.c new file mode 100644 index 00000000..a0080932 --- /dev/null +++ b/hacks/laser.c @@ -0,0 +1,319 @@ +/* -*- Mode: C; tab-width: 4 -*- + * laser --- draws swinging laser beams. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)laser.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1995 Pascal Pensa + * + * 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: + * 10-May-97: jwz@netscape.com: turned into a standalone program. + */ + +#ifdef STANDALONE +# define PROGCLASS "Laser" +# define HACK_INIT init_laser +# define HACK_DRAW draw_laser +# define laser_opts xlockmore_opts +# define DEFAULTS "*count: 10 \n" \ + "*cycles: 200 \n" \ + "*delay: 40000 \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 */ + +ModeSpecOpt laser_opts = { + 0, NULL, 0, NULL, NULL }; + +#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) ((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_WIN_WIDTH(mi); + lp->height = MI_WIN_HEIGHT(mi); + lp->time = 0; + + lp->ln = MI_BATCHCOUNT(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_WIN_WHITE_PIXEL(mi); + gcv.background = MI_WIN_BLACK_PIXEL(mi); + lp->gcv_black.foreground = MI_WIN_BLACK_PIXEL(mi); + lp->stippledGC = XCreateGC(MI_DISPLAY(mi), MI_WINDOW(mi), + GCForeground | GCBackground, &gcv); + } + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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 = 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_WIN_WHITE_PIXEL(mi); + } +} + +static void +draw_laser_once(ModeInfo * mi) +{ + Display *display = MI_DISPLAY(mi); + lasersstruct *lp = &lasers[MI_SCREEN(mi)]; + int i; + + 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) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/laser.man b/hacks/laser.man new file mode 100644 index 00000000..c219bfc7 --- /dev/null +++ b/hacks/laser.man @@ -0,0 +1,64 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +laser - draws vaguely laser-like moving lines +.SH SYNOPSIS +.B laser +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIlaser\fP program draws vaguely laser-like moving lines +.SH OPTIONS +.I laser +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors used cycle through the hue, making N stops around the color wheel. +.TP 8 +.B \-cycles \fIinteger\fP +Default 200. +.TP 8 +.B \-count \fIinteger\fP +Default 10. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1995 by Pascal Pensa. + +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. +.SH AUTHOR +Pascal Pensa , 1995. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/lightning.c b/hacks/lightning.c new file mode 100644 index 00000000..baa255dd --- /dev/null +++ b/hacks/lightning.c @@ -0,0 +1,580 @@ +/* -*- Mode: C; tab-width: 4 -*- + * lightning --- fractal lightning bolts. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)lightning.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1996 by Keith Romberg . + * + * 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@netscape.com: turned into a standalone program. + * 14-Jul-96: Cleaned up code. + * 27-Jun-96: Written and submitted by Keith Romberg . + */ + +#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" \ + "*ncolors: 200 \n" +# define BRIGHT_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt lightning_opts = { + 0, NULL, 0, NULL, NULL }; + +/*---------------------------- defines -------------------------------*/ + +#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<= 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 *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[*index].x = mid.x; + verts[*index].y = mid.y; + (*index)++; + return; + } + generate(A, mid, iter - 1, verts, index); + generate(mid, B, iter - 1, verts, 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) +{ + wiggle_bolt(bolt); + if ((bolt->wiggle_amount == 0) && (bolt->wiggle_number > 2)) + bolt->wiggle_number = 0; + if (((time % 3) == 0)) + bolt->wiggle_amount++; + + if (((time >= bolt->delay_time) && (time < bolt->flash_begin)) || + (time > bolt->flash_stop)) + bolt->visible = 1; + else + bolt->visible = 0; + + if (time == bolt->delay_time) + bolt->strike_level = FIRST_LEVEL_STRIKE; + else if (time == (bolt->delay_time + 1)) + bolt->strike_level = LEVEL_ONE_STRIKE; + else if ((time > (bolt->delay_time + 1)) && + (time <= (bolt->delay_time + bolt->flash_begin - 2))) + bolt->strike_level = LEVEL_TWO_STRIKE; + else if (time == (bolt->delay_time + bolt->flash_begin - 1)) + bolt->strike_level = LEVEL_ONE_STRIKE; + else if (time == (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_WIN_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_WIN_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_WIN_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_WIN_WIDTH(mi); + st->scr_height = MI_WIN_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; + + switch (st->stage) { + case 0: + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + st->color = NRAND(MI_NPIXELS(mi)); + st->draw_time = 0; + if (storm_active(st)) + st->stage++; + else + st->stage = 3; + 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++; + XFlush(MI_DISPLAY(mi)); + MI_PAUSE(mi) = 60000; + st->stage++; + break; + case 2: + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + if (storm_active(st)) + st->stage = 1; + else + st->stage++; + break; + case 3: + MI_PAUSE(mi) = 1000000; + 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 */ +} diff --git a/hacks/lightning.man b/hacks/lightning.man new file mode 100644 index 00000000..7e602bfb --- /dev/null +++ b/hacks/lightning.man @@ -0,0 +1,58 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +lightning - draws fractal lightning bolts +.SH SYNOPSIS +.B lightning +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] + +.SH DESCRIPTION +The \fIlightning\fP program draws fractal lightning bolts +.SH OPTIONS +.I lightning +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1996 by Keith Romberg. + +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. +.SH AUTHOR +Keith Romberg , 27-Jun-96. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/link_axp.com b/hacks/link_axp.com new file mode 100644 index 00000000..58ce0318 --- /dev/null +++ b/hacks/link_axp.com @@ -0,0 +1,109 @@ +$! We fisrt test the version of DECW/Motif ; if 1.2 we need to link with new +$! X11R5 libraries +$@sys$update:decw$get_image_version sys$share:decw$xlibshr.exe decw$version +$ if f$extract(4,3,decw$version).eqs."1.2" +$ then +$! DECW/Motif 1.2 : link with X11R5 libraries +$ link/exe=attraction.exe screenhack,attraction,vms_axp_12.opt/opt +$ link/exe=blitspin.exe screenhack,blitspin,vms_axp_12.opt/opt +$ link/exe=bouboule.exe screenhack-xlock,bouboule,xlockmore,vms_axp_12.opt/opt +$ link/exe=braid.exe screenhack-xlock,braid,xlockmore,vms_axp_12.opt/opt +$ link/exe=bubbles.exe screenhack,bubbles,bubbles_default,vms_axp_12.opt/opt +$ link/exe=coral.exe screenhack,coral,vms_axp_12.opt/opt +$ link/exe=decayscreen.exe screenhack,decayscreen,vms_axp_12.opt/opt +$ link/exe=deco.exe screenhack,deco,vms_axp_12.opt/opt +$ link/exe=drift.exe screenhack-xlock,drift,xlockmore,vms_axp_12.opt/opt +$ link/exe=fadeplot.exe screenhack-xlock,fadeplot,xlockmore,vms_axp_12.opt/opt +$ link/exe=flag.exe screenhack-xlock,flag,xlockmore,vms_axp_12.opt/opt +$ link/exe=flame.exe screenhack,flame,vms_axp_12.opt/opt +$ link/exe=forest.exe screenhack-xlock,forest,xlockmore,vms_axp_12.opt/opt +$ link/exe=vines.exe screenhack-xlock,vines,xlockmore,vms_axp_12.opt/opt +$ link/exe=galaxy.exe screenhack-xlock,galaxy,xlockmore,vms_axp_12.opt/opt +$ link/exe=grav.exe screenhack-xlock,grav,xlockmore,vms_axp_12.opt/opt +$ link/exe=greynetic screenhack,greynetic,vms_axp_12.opt/opt +$ link/exe=halo.exe screenhack,halo,vms_axp_12.opt/opt +$ link/exe=helix.exe screenhack,helix,vms_axp_12.opt/opt +$ link/exe=hopalong.exe screenhack-xlock,hopalong,xlockmore,vms_axp_12.opt/opt +$ link/exe=hypercube.exe screenhack,hypercube,vms_axp_12.opt/opt +$ link/exe=ifs.exe screenhack-xlock,ifs,xlockmore,vms_axp_12.opt/opt +$ link/exe=imsmap.exe screenhack,imsmap,vms_axp_12.opt/opt +$ link/exe=julia.exe screenhack-xlock,julia,xlockmore,vms_axp_12.opt/opt +$ link/exe=kaleidescope.exe screenhack,kaleidescope,vms_axp_12.opt/opt +$ link/exe=laser.exe screenhack-xlock,laser,xlockmore,vms_axp_12.opt/opt +$ link/exe=lightning.exe screenhack-xlock,lightning,xlockmore,vms_axp_12.opt/opt +$ link/exe=lisa.exe screenhack-xlock,lisa,xlockmore,vms_axp_12.opt/opt +$ link/exe=lmorph.exe screenhack,lmorph,vms_axp_12.opt/opt +$ link/exe=maze.exe screenhack,maze,vms_axp_12.opt/opt +$ link/exe=moire.exe screenhack,moire,vms_axp_12.opt/opt +$ link/exe=noseguy.exe screenhack,noseguy,vms_axp_12.opt/opt +$ link/exe=pedal.exe screenhack,pedal,vms_axp_12.opt/opt +$ link/exe=penrose.exe screenhack-xlock,penrose,xlockmore,vms_axp_12.opt/opt +$ link/exe=pyro.exe screenhack,pyro,vms_axp_12.opt/opt +$ link/exe=qix.exe screenhack,qix,vms_axp_12.opt/opt +$ link/exe=rd-bomb.exe screenhack,rd-bomb,vms_axp_12.opt/opt +$ link/exe=rocks.exe screenhack,rocks,vms_axp_12.opt/opt +$ link/exe=rorschach.exe screenhack,rorschach,vms_axp_12.opt/opt +$ link/exe=sierpinski.exe screenhack-xlock,sierpinski,xlockmore,vms_axp_12.opt/opt +$ link/exe=slidescreen.exe screenhack,slidescreen,vms_axp_12.opt/opt +$ link/exe=slip.exe screenhack-xlock,slip,xlockmore,vms_axp_12.opt/opt +$ link/exe=sphere.exe screenhack-xlock,sphere,xlockmore,vms_axp_12.opt/opt +$ link/exe=spiral.exe screenhack-xlock,spiral,xlockmore,vms_axp_12.opt/opt +$ link/exe=strange.exe screenhack-xlock,strange,xlockmore,vms_axp_12.opt/opt +$ link/exe=swirl.exe screenhack-xlock,swirl,xlockmore,vms_axp_12.opt/opt +$ link/exe=xroger.exe screenhack,xroger-hack,vms_axp_12.opt/opt +$ link/exe=goop.exe screenhack,goop,vms_axp_12.opt/opt +$ link/exe=starfish.exe screenhack,starfish,vms_axp_12.opt/opt +$ link/exe=munch.exe screenhack,munch,vms_axp_12.opt/opt +$ else +$! Else, link with X11R4 libraries +$ link/exe=attraction.exe screenhack,attraction,vms_axp.opt/opt +$ link/exe=blitspin.exe screenhack,blitspin,vms_axp.opt/opt +$ link/exe=bouboule.exe screenhack-xlock,bouboule,xlockmore,vms_axp.opt/opt +$ link/exe=braid.exe screenhack-xlock,braid,xlockmore,vms_axp.opt/opt +$ link/exe=bubbles.exe screenhack,bubbles,bubbles_default,vms_axp.opt/opt +$ link/exe=coral.exe screenhack,coral,vms_axp.opt/opt +$ link/exe=decayscreen.exe screenhack,decayscreen,vms_axp.opt/opt +$ link/exe=deco.exe screenhack,deco,vms_axp.opt/opt +$ link/exe=drift.exe screenhack-xlock,drift,xlockmore,vms_axp.opt/opt +$ link/exe=fadeplot.exe screenhack-xlock,fadeplot,xlockmore,vms_axp.opt/opt +$ link/exe=flag.exe screenhack-xlock,flag,xlockmore,vms_axp.opt/opt +$ link/exe=flame.exe screenhack,flame,vms_axp.opt/opt +$ link/exe=forest.exe screenhack-xlock,forest,xlockmore,vms_axp.opt/opt +$ link/exe=vines.exe screenhack-xlock,vines,xlockmore,vms_axp.opt/opt +$ link/exe=galaxy.exe screenhack-xlock,galaxy,xlockmore,vms_axp.opt/opt +$ link/exe=grav.exe screenhack-xlock,grav,xlockmore,vms_axp.opt/opt +$ link/exe=greynetic screenhack,greynetic,vms_axp.opt/opt +$ link/exe=halo.exe screenhack,halo,vms_axp.opt/opt +$ link/exe=helix.exe screenhack,helix,vms_axp.opt/opt +$ link/exe=hopalong.exe screenhack-xlock,hopalong,xlockmore,vms_axp.opt/opt +$ link/exe=hypercube.exe screenhack,hypercube,vms_axp.opt/opt +$ link/exe=ifs.exe screenhack-xlock,ifs,xlockmore,vms_axp.opt/opt +$ link/exe=imsmap.exe screenhack,imsmap,vms_axp.opt/opt +$ link/exe=julia.exe screenhack-xlock,julia,xlockmore,vms_axp.opt/opt +$ link/exe=kaleidescope.exe screenhack,kaleidescope,vms_axp.opt/opt +$ link/exe=laser.exe screenhack-xlock,laser,xlockmore,vms_axp.opt/opt +$ link/exe=lightning.exe screenhack-xlock,lightning,xlockmore,vms_axp.opt/opt +$ link/exe=lisa.exe screenhack-xlock,lisa,xlockmore,vms_axp.opt/opt +$ link/exe=lmorph.exe screenhack,lmorph,vms_axp.opt/opt +$ link/exe=maze.exe screenhack,maze,vms_axp.opt/opt +$ link/exe=moire.exe screenhack,moire,vms_axp.opt/opt +$ link/exe=noseguy.exe screenhack,noseguy,vms_axp.opt/opt +$ link/exe=pedal.exe screenhack,pedal,vms_axp.opt/opt +$ link/exe=penrose.exe screenhack-xlock,penrose,xlockmore,vms_axp.opt/opt +$ link/exe=pyro.exe screenhack,pyro,vms_axp.opt/opt +$ link/exe=qix.exe screenhack,qix,vms_axp.opt/opt +$ link/exe=rd-bomb.exe screenhack,rd-bomb,vms_axp.opt/opt +$ link/exe=rocks.exe screenhack,rocks,vms_axp.opt/opt +$ link/exe=rorschach.exe screenhack,rorschach,vms_axp.opt/opt +$ link/exe=sierpinski.exe screenhack-xlock,sierpinski,xlockmore,vms_axp.opt/opt +$ link/exe=slidescreen.exe screenhack,slidescreen,vms_axp.opt/opt +$ link/exe=slip.exe screenhack-xlock,slip,xlockmore,vms_axp.opt/opt +$ link/exe=sphere.exe screenhack-xlock,sphere,xlockmore,vms_axp.opt/opt +$ link/exe=spiral.exe screenhack-xlock,spiral,xlockmore,vms_axp.opt/opt +$ link/exe=strange.exe screenhack-xlock,strange,xlockmore,vms_axp.opt/opt +$ link/exe=swirl.exe screenhack-xlock,swirl,xlockmore,vms_axp.opt/opt +$ link/exe=xroger.exe screenhack,xroger-hack,vms_axp.opt/opt +$ link/exe=goop.exe screenhack,goop,vms_axp.opt/opt +$ link/exe=starfish.exe screenhack,starfish,vms_axp.opt/opt +$ link/exe=munch.exe screenhack,munch,vms_axp.opt/opt +$ endif diff --git a/hacks/link_decc.com b/hacks/link_decc.com new file mode 100644 index 00000000..3e001cd9 --- /dev/null +++ b/hacks/link_decc.com @@ -0,0 +1,109 @@ +$! We fisrt test the version of DECW/Motif ; if 1.2 we need to link with new +$! X11R5 libraries +$@sys$update:decw$get_image_version sys$share:decw$xlibshr.exe decw$version +$ if f$extract(4,3,decw$version).eqs."1.2" +$ then +$! DECW/Motif 1.2 : link with X11R5 libraries +$ link/exe=attraction.exe screenhack,attraction,vms_decc_12.opt/opt +$ link/exe=blitspin.exe screenhack,blitspin,vms_decc_12.opt/opt +$ link/exe=bouboule.exe screenhack-xlock,bouboule,xlockmore,vms_decc_12.opt/opt +$ link/exe=braid.exe screenhack-xlock,braid,xlockmore,vms_decc_12.opt/opt +$ link/exe=bubbles.exe screenhack,bubbles,bubbles_default,vms_decc_12.opt/opt +$ link/exe=coral.exe screenhack,coral,vms_decc_12.opt/opt +$ link/exe=decayscreen.exe screenhack,decayscreen,vms_decc_12.opt/opt +$ link/exe=deco.exe screenhack,deco,vms_decc_12.opt/opt +$ link/exe=drift.exe screenhack-xlock,drift,xlockmore,vms_decc_12.opt/opt +$ link/exe=fadeplot.exe screenhack-xlock,fadeplot,xlockmore,vms_decc_12.opt/opt +$ link/exe=flag.exe screenhack-xlock,flag,xlockmore,vms_decc_12.opt/opt +$ link/exe=flame.exe screenhack,flame,vms_decc_12.opt/opt +$ link/exe=forest.exe screenhack-xlock,forest,xlockmore,vms_decc_12.opt/opt +$ link/exe=vines.exe screenhack-xlock,vines,xlockmore,vms_decc_12.opt/opt +$ link/exe=galaxy.exe screenhack-xlock,galaxy,xlockmore,vms_decc_12.opt/opt +$ link/exe=grav.exe screenhack-xlock,grav,xlockmore,vms_decc_12.opt/opt +$ link/exe=greynetic screenhack,greynetic,vms_decc_12.opt/opt +$ link/exe=halo.exe screenhack,halo,vms_decc_12.opt/opt +$ link/exe=helix.exe screenhack,helix,vms_decc_12.opt/opt +$ link/exe=hopalong.exe screenhack-xlock,hopalong,xlockmore,vms_decc_12.opt/opt +$ link/exe=hypercube.exe screenhack,hypercube,vms_decc_12.opt/opt +$ link/exe=ifs.exe screenhack-xlock,ifs,xlockmore,vms_decc_12.opt/opt +$ link/exe=imsmap.exe screenhack,imsmap,vms_decc_12.opt/opt +$ link/exe=julia.exe screenhack-xlock,julia,xlockmore,vms_decc_12.opt/opt +$ link/exe=kaleidescope.exe screenhack,kaleidescope,vms_decc_12.opt/opt +$ link/exe=laser.exe screenhack-xlock,laser,xlockmore,vms_decc_12.opt/opt +$ link/exe=lightning.exe screenhack-xlock,lightning,xlockmore,vms_decc_12.opt/opt +$ link/exe=lisa.exe screenhack-xlock,lisa,xlockmore,vms_decc_12.opt/opt +$ link/exe=lmorph.exe screenhack,lmorph,vms_decc_12.opt/opt +$ link/exe=maze.exe screenhack,maze,vms_decc_12.opt/opt +$ link/exe=moire.exe screenhack,moire,vms_decc_12.opt/opt +$ link/exe=noseguy.exe screenhack,noseguy,vms_decc_12.opt/opt +$ link/exe=pedal.exe screenhack,pedal,vms_decc_12.opt/opt +$ link/exe=penrose.exe screenhack-xlock,penrose,xlockmore,vms_decc_12.opt/opt +$ link/exe=pyro.exe screenhack,pyro,vms_decc_12.opt/opt +$ link/exe=qix.exe screenhack,qix,vms_decc_12.opt/opt +$ link/exe=rd-bomb.exe screenhack,rd-bombs,vms_decc_12.opt/opt +$ link/exe=rocks.exe screenhack,rocks,vms_decc_12.opt/opt +$ link/exe=rorschach.exe screenhack,rorschach,vms_decc_12.opt/opt +$ link/exe=sierpinski.exe screenhack-xlock,sierpinski,xlockmore,vms_decc_12.opt/opt +$ link/exe=slidescreen.exe screenhack,slidescreen,vms_decc_12.opt/opt +$ link/exe=slip.exe screenhack-xlock,slip,xlockmore,vms_decc_12.opt/opt +$ link/exe=sphere.exe screenhack-xlock,sphere,xlockmore,vms_decc_12.opt/opt +$ link/exe=spiral.exe screenhack-xlock,spiral,xlockmore,vms_decc_12.opt/opt +$ link/exe=strange.exe screenhack-xlock,strange,xlockmore,vms_decc_12.opt/opt +$ link/exe=swirl.exe screenhack-xlock,swirl,xlockmore,vms_decc_12.opt/opt +$ link/exe=xroger.exe screenhack,xroger-hack,vms_decc_12.opt/opt +$ link/exe=goop.exe screenhack,goop,vms_decc_12.opt/opt +$ link/exe=starfish.exe screenhack,starfish,vms_decc_12.opt/opt +$ link/exe=munch.exe screenhack,munch,vms_decc_12.opt/opt +$ else +$! Else, link with X11R4 libraries +$ link/exe=attraction.exe screenhack,attraction,vms_decc.opt/opt +$ link/exe=blitspin.exe screenhack,blitspin,vms_decc.opt/opt +$ link/exe=bouboule.exe screenhack-xlock,bouboule,xlockmore,vms_decc.opt/opt +$ link/exe=braid.exe screenhack-xlock,braid,xlockmore,vms_decc.opt/opt +$ link/exe=bubbles.exe screenhack,bubbles,bubbles_default,vms_decc.opt/opt +$ link/exe=coral.exe screenhack,coral,vms_decc.opt/opt +$ link/exe=decayscreen.exe screenhack,decayscreen,vms_decc.opt/opt +$ link/exe=deco.exe screenhack,deco,vms_decc.opt/opt +$ link/exe=drift.exe screenhack-xlock,drift,xlockmore,vms_decc.opt/opt +$ link/exe=fadeplot.exe screenhack-xlock,fadeplot,xlockmore,vms_decc.opt/opt +$ link/exe=flag.exe screenhack-xlock,flag,xlockmore,vms_decc.opt/opt +$ link/exe=flame.exe screenhack,flame,vms_decc.opt/opt +$ link/exe=forest.exe screenhack-xlock,forest,xlockmore,vms_decc.opt/opt +$ link/exe=vines.exe screenhack-xlock,vines,xlockmore,vms_decc.opt/opt +$ link/exe=galaxy.exe screenhack-xlock,galaxy,xlockmore,vms_decc.opt/opt +$ link/exe=grav.exe screenhack-xlock,grav,xlockmore,vms_decc.opt/opt +$ link/exe=greynetic screenhack,greynetic,vms_decc.opt/opt +$ link/exe=halo.exe screenhack,halo,vms_decc.opt/opt +$ link/exe=helix.exe screenhack,helix,vms_decc.opt/opt +$ link/exe=hopalong.exe screenhack-xlock,hopalong,xlockmore,vms_decc.opt/opt +$ link/exe=hypercube.exe screenhack,hypercube,vms_decc.opt/opt +$ link/exe=ifs.exe screenhack-xlock,ifs,xlockmore,vms_decc.opt/opt +$ link/exe=imsmap.exe screenhack,imsmap,vms_decc.opt/opt +$ link/exe=julia.exe screenhack-xlock,julia,xlockmore,vms_decc.opt/opt +$ link/exe=kaleidescope.exe screenhack,kaleidescope,vms_decc.opt/opt +$ link/exe=laser.exe screenhack-xlock,laser,xlockmore,vms_decc.opt/opt +$ link/exe=lightning.exe screenhack-xlock,lightning,xlockmore,vms_decc.opt/opt +$ link/exe=lisa.exe screenhack-xlock,lisa,xlockmore,vms_decc.opt/opt +$ link/exe=lmorph.exe screenhack,lmorph,vms_decc.opt/opt +$ link/exe=maze.exe screenhack,maze,vms_decc.opt/opt +$ link/exe=moire.exe screenhack,moire,vms_decc.opt/opt +$ link/exe=noseguy.exe screenhack,noseguy,vms_decc.opt/opt +$ link/exe=pedal.exe screenhack,pedal,vms_decc.opt/opt +$ link/exe=penrose.exe screenhack-xlock,penrose,xlockmore,vms_decc.opt/opt +$ link/exe=pyro.exe screenhack,pyro,vms_decc.opt/opt +$ link/exe=qix.exe screenhack,qix,vms_decc.opt/opt +$ link/exe=rd-bombs.exe screenhack,rd-bombs,vms_decc.opt/opt +$ link/exe=rocks.exe screenhack,rocks,vms_decc.opt/opt +$ link/exe=rorschach.exe screenhack,rorschach,vms_decc.opt/opt +$ link/exe=sierpinski.exe screenhack-xlock,sierpinski,xlockmore,vms_decc.opt/opt +$ link/exe=slidescreen.exe screenhack,slidescreen,vms_decc.opt/opt +$ link/exe=slip.exe screenhack-xlock,slip,xlockmore,vms_decc.opt/opt +$ link/exe=sphere.exe screenhack-xlock,sphere,xlockmore,vms_decc.opt/opt +$ link/exe=spiral.exe screenhack-xlock,spiral,xlockmore,vms_decc.opt/opt +$ link/exe=strange.exe screenhack-xlock,strange,xlockmore,vms_decc.opt/opt +$ link/exe=swirl.exe screenhack-xlock,swirl,xlockmore,vms_decc.opt/opt +$ link/exe=xroger.exe screenhack,xroger-hack,vms_decc.opt/opt +$ link/exe=goop.exe screenhack,goop,vms_decc.opt/opt +$ link/exe=starfish.exe screenhack,starfish,vms_decc.opt/opt +$ link/exe=munch.exe screenhack,munch,vms_decc.opt/opt +$ endif diff --git a/hacks/lisa.c b/hacks/lisa.c new file mode 100644 index 00000000..af680ea2 --- /dev/null +++ b/hacks/lisa.c @@ -0,0 +1,485 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* lisa --- animated full-loop lisajous figures */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)lisa.c 4.04 97/07/28 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" /* from the xscreensaver distribution */ + void refresh_lisa(ModeInfo * mi); + void change_lisa(ModeInfo * mi); +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +#define DEF_ADDITIVE "True" + +static Bool additive; + +static XrmOptionDescRec lisa_xrm_opts[] = +{ + {"-additive", ".lisa.additive", XrmoptionNoArg, (caddr_t) "True"}, + {"+additive", ".lisa.additive", XrmoptionNoArg, (caddr_t) "False"} +}; + +static argtype lisa_vars[] = +{ + {(caddr_t *) & additive, "additive", "Additive", DEF_ADDITIVE, t_Bool} +}; + +static OptionStruct lisa_vars_desc[] = +{ + {"-/+additive", "turn on/off additive functions mode"} +}; + +ModeSpecOpt lisa_opts = +{2, lisa_xrm_opts, 1, lisa_vars, lisa_vars_desc}; + + +#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) >= MI_NPIXELS(mi)) { loop->color=0; } \ + } else { XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_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 { + int radius, color, dx, dy, nsteps, nfuncs, melting; + double pistep, phi, theta; + XPoint center, *lastpoint; + lisafuncs *function[LISAMAXFUNCS]; +} lisas; + +typedef struct lisacontext_struct { + lisas *lisajous; + int width, height, nlisajous, loopcount; + int maxcycles; +} 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 + /* erase the last cycle's point */ + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_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); +#else + /* erase the last cycle's point */ + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_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_WIN_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 = 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); + } + 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 + } + + { + int line_width = -15; /* #### make this a resource */ + if (line_width == 0) + line_width = -8; + if (line_width < 0) + line_width = NRAND(-line_width)+1; + XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), line_width, + LineSolid, CapProjecting, JoinMiter); + } +} + +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_WIN_WIDTH(mi); + lc->height = MI_WIN_HEIGHT(mi); + lc->loopcount = 0; + lc->nlisajous = MI_BATCHCOUNT(mi); + if (lc->nlisajous <= 0) + lc->nlisajous = 1; + + if (lc->lisajous == NULL) { + if ((lc->lisajous = (lisas *) calloc(lc->nlisajous, sizeof (lisas))) \ + == NULL) + return; + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + for (lctr = 0; lctr < lc->nlisajous; lctr++) { + initlisa(mi, &lc->lisajous[lctr]); + lc->loopcount++; + } + } else { + refresh_lisa(mi); + } + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); +} + +void +draw_lisa(ModeInfo * mi) +{ + lisacons *lc = &Lisa[MI_SCREEN(mi)]; + + if (++lc->loopcount > lc->maxcycles) { + change_lisa(mi); + } + refresh_lisa(mi); +} + +void +refresh_lisa(ModeInfo * mi) +{ + lisacons *lc = &Lisa[MI_SCREEN(mi)]; + int lctr; + + for (lctr = 0; lctr < lc->nlisajous; lctr++) { + drawlisa(mi, &lc->lisajous[lctr]); + } +} + +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; + } +} + +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; + } +} diff --git a/hacks/lisa.man b/hacks/lisa.man new file mode 100644 index 00000000..0e9aeeba --- /dev/null +++ b/hacks/lisa.man @@ -0,0 +1,67 @@ +.TH XScreenSaver 1 "27-May-97" "X Version 11" +.SH NAME +lisa - draws animated full-loop lisajous figures +.SH SYNOPSIS +.B lisa +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] [\-size \fIinteger\fP] + +.SH DESCRIPTION +The \fIlisa\fP program draws animated full-loop lisajous figures. +.SH OPTIONS +.I lisa +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors are chosen randomly. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.TP 8 +.B \-size \fIinteger\fP + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Caleb Cullen, 1997. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 27-May-97. diff --git a/hacks/lissie.c b/hacks/lissie.c new file mode 100644 index 00000000..2a8fafac --- /dev/null +++ b/hacks/lissie.c @@ -0,0 +1,284 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* lissie --- the Lissajous worm */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)lissie.c 4.04 97/07/28 xlockmore"; +#endif + +/*- + * lissie.c - The Lissajous worm for xlock, the X Window System + * lockscreen. + * + * Copyright (c) 1996 by Alexander Jolk + * + * 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: 2000 \n" \ + "*size: -200 \n" \ + "*ncolors: 64 \n" +# define SMOOTH_COLORS +# include "xlockmore.h" /* in xscreensaver distribution */ +#else /* STANDALONE */ +# include "xlock.h" /* in xlockmore distribution */ +#endif /* STANDALONE */ + +ModeSpecOpt lissie_opts = +{0, NULL, 0, NULL, NULL}; + +#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]; + int color; +} lissiestruct; + +typedef struct { + 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_WIN_BLACK_PIXEL(mi)); + Lissie(oldp); + + /* Redraw */ + if (MI_NPIXELS(mi) > 2) { + XSetForeground(display, gc, MI_PIXEL(mi, lissie->color)); + if (++lissie->color >= MI_NPIXELS(mi)) + lissie->color = 0; + } else + XSetForeground(display, gc, MI_WIN_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_WIN_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_WIN_WIDTH(mi); + lp->height = MI_WIN_HEIGHT(mi); + + lp->nlissies = MI_BATCHCOUNT(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)); + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + 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; + + if (++lp->loopcount > MI_CYCLES(mi)) + init_lissie(mi); + else + 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; + + for (i = 0; i < lp->nlissies; i++) { + lp->lissie[i].redrawing = 1; + lp->lissie[i].redrawpos = 0; + } + } +} diff --git a/hacks/lmorph.c b/hacks/lmorph.c new file mode 100644 index 00000000..70c91eee --- /dev/null +++ b/hacks/lmorph.c @@ -0,0 +1,508 @@ + +/************************************************************************** + * + * FILE lmorph.c + * MODULE OF xscreensaver + * + * DESCRIPTION Bilinear interpolation for morphing line shapes. + * + * WRITTEN BY Sverre H. Huseby Glenn T. Lines + * Maridalsvn. 122, leil 101 Frysjavn. 3, 5. etg. + * N-0461 Oslo N-0883 Oslo + * Norway Norway + * + * Phone: +47 22 71 99 08 Phone: +47 22 23 71 99 + * E-mail: sverrehu@ifi.uio.no E-mail: gtl@si.sintef.no + * + * The original idea, and the bilinear interpolation + * mathematics used, emerged in the head of the wise + * Glenn Terje Lines. + * + * MODIFICATIONS march 1995 + * * Converted from an MS-Windows program to X Window. + * + **************************************************************************/ + +#include +#include +#include +#include +#include "screenhack.h" + +/************************************************************************** + * * + * P R I V A T E D A T A * + * * + **************************************************************************/ + +/* Define MARGINS to make some space around the figure */ +#define MARGINS /**/ + +#define MAXFIGS 20 +#define TWO_PI (2.0 * M_PI) +#define RND(x) (random() % (x)) +static int + cFig = 0, /* Number of figure arrays. */ + cPoint, /* Number of points in each array. */ + nWork, /* Current work array number. */ + nFrom, /* Current from array number. */ + nTo; /* Current to array number. */ +static long + delay; /* usecs to wait between updates. */ +static XPoint + *aWork[2], /* Working arrays. */ + *a[MAXFIGS], /* The figure arrays. */ + *aTmp, /* Used as source when interrupting morph */ + *aPrev, /* Previous points displayed. */ + *aCurr, /* The current points displayed. */ + *aFrom, /* Figure converting from. */ + *aTo; /* Figure converting to. */ +static double + gam, + maxGamma = 1.0, + delta_gam; +static GC + gcDraw, gcClear; +static Display + *dpy; +static Window + window; + + + +/************************************************************************** + * * + * P U B L I C D A T A * + * * + **************************************************************************/ + +char *progclass = "LMorph"; + +char *defaults [] = { + "LMorph.background: black", + "LMorph.foreground: green", + "*points: 150", + "*steps: 0", + "*delay: 50000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-points", ".points", XrmoptionSepArg, 0 }, + { "-steps", ".steps", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + + +/************************************************************************** + * * + * P R I V A T E F U N C T I O N S * + * * + **************************************************************************/ + +static void * +xmalloc(size_t size) +{ + void *ret; + + if ((ret = malloc(size)) == NULL) { + fprintf(stderr, "lmorph: out of memory\n"); + exit(1); + } + return ret; +} + + + +static double frnd (void) +{ + /* + * Hm. for some reason the second line (using RAND_MAX) didn't + * work on some machines, so I always use the first. + */ +#ifndef dont_use_RAND_MAX + return (double) (random() & 0x7FFF) / 0x7FFF; +#else /* RAND_MAX */ + return ((double) random()) / RAND_MAX; +#endif /* RAND_MAX */ +} + + + +static void initPointArrays (void) +{ + XWindowAttributes wa; + int q, w, + mx, my, /* Max screen coordinates. */ + mp, /* Max point number. */ + s, rx, ry, + marginx, marginy; + double scalex, scaley; + + XGetWindowAttributes(dpy, window, &wa); + mx = wa.width - 1; + my = wa.height - 1; + mp = cPoint - 1; + + aWork[0] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + aWork[1] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + aTmp = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + + + /* + * Figure 0 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + s = cPoint / 4; + for (q = 0; q < s; q++) { + a[cFig][q].x = ((double) q / s) * mx; + a[cFig][q].y = 0; + a[cFig][s + q].x = mx; + a[cFig][s + q].y = ((double) q / s) * my; + a[cFig][2 * s + q].x = mx - ((double) q / s) * mx; + a[cFig][2 * s + q].y = my; + a[cFig][3 * s + q].x = 0; + a[cFig][3 * s + q].y = my - ((double) q / s) * my; + } + for (q = 4 * s; q < cPoint; q++) + a[cFig][q].x = a[cFig][q].y = 0; + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 1 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = ((double) q / cPoint) * mx; + a[cFig][q].y = (1.0 - sin(((double) q / mp) * TWO_PI)) * my / 2.0; + } + ++cFig; + + /* + * Figure 2 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + rx * sin(1 * TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * cos(3 * TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 3 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * sin(3 * TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * cos(1 * TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 4 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * (1 - 0.1 * frnd()) + * sin(TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * (1 - 0.1 * frnd()) + * cos(TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 5 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * (0.8 - 0.2 * sin(30 * TWO_PI * q / mp)) + * sin(TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * (0.8 - 0.2 * sin(30 * TWO_PI * q / mp)) + * cos(TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 6 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * sin(TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * cos(TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 7 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + rx * cos(TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * sin(TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 8 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = ((double) q / mp) * mx; + a[cFig][q].y = (1.0 - cos(((double) q / mp) * 3 * TWO_PI)) * my / 2.0; + } + ++cFig; + + /* + * Figure 9 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + rx * sin(2 * TWO_PI * (double) q / mp); + a[cFig][q].y = my / 2 + ry * cos(3 * TWO_PI * (double) q / mp); + } + a[cFig][mp].x = a[cFig][0].x; + a[cFig][mp].y = a[cFig][0].y; + ++cFig; + + /* + * Figure 10 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * sin(5 * TWO_PI * (double) q / mp) + * ((double) q / mp); + a[cFig][q].y = my / 2 + ry * cos(5 * TWO_PI * (double) q / mp) + * ((double) q / mp); + } + ++cFig; + + /* + * Figure 11 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + rx = mx / 2; + ry = my / 2; + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = mx / 2 + ry * sin(6 * TWO_PI * (double) q / mp) + * ((double) q / mp); + a[cFig][q].y = my / 2 - ry * cos(6 * TWO_PI * (double) q / mp) + * ((double) q / mp); + } + ++cFig; + + /* + * Figure 12 + */ + a[cFig] = (XPoint *) xmalloc(cPoint * sizeof(XPoint)); + for (q = 0; q < cPoint; q++) { + a[cFig][q].x = ((double) q / mp) * mx; + a[cFig][q].y = (1.0 - sin(((double) q / mp) * 5 * TWO_PI)) * my / 2.0; + } + ++cFig; + +#ifdef MARGINS + /* + * Make some space around the figures. + */ + marginx = (mx + 1) / 10; + marginy = (my + 1) / 10; + scalex = (double) ((mx + 1) - 2.0 * marginx) / (mx + 1.0); + scaley = (double) ((my + 1) - 2.0 * marginy) / (my + 1.0); + for (q = 0; q < cFig; q++) + for (w = 0; w < cPoint; w++) { + a[q][w].x = marginx + a[q][w].x * scalex; + a[q][w].y = marginy + a[q][w].y * scaley; + } +#endif +} + + + +static void createPoints (void) +{ + int q; + XPoint *pa = aCurr, *pa1 = aFrom, *pa2 = aTo; + long lg, l1g; + + + lg = 8192L * gam, l1g = 8192L * (1.0 - gam); + for (q = 0; q < cPoint; q++) { + pa->x = (short) ((l1g * pa1->x + lg * pa2->x) / 8192L); + pa->y = (short) ((l1g * pa1->y + lg * pa2->y) / 8192L); + ++pa; + ++pa1; + ++pa2; + } +} + + +static void drawImage (void) +{ + register int q; + XPoint *old0, *old1, *new0, *new1; + + /* + * Problem: update the window without too much flickering. I do + * this by handling each linesegment separately. First remove a + * line, then draw the new line. The problem is that this leaves + * small black pixels on the figure. To fix this, I draw the + * entire figure using XDrawLines() afterwards. + */ + if (aPrev) { + old0 = aPrev; + old1 = aPrev + 1; + new0 = aCurr; + new1 = aCurr + 1; + for (q = cPoint - 1; q; q--) { + XDrawLine(dpy, window, gcClear, + old0->x, old0->y, old1->x, old1->y); + XDrawLine(dpy, window, gcDraw, + new0->x, new0->y, new1->x, new1->y); + ++old0; + ++old1; + ++new0; + ++new1; + } + } + XDrawLines(dpy, window, gcDraw, aCurr, cPoint, CoordModeOrigin); + XFlush(dpy); +} + +static void initLMorph (void) +{ + int steps; + XGCValues gcv; + XWindowAttributes wa; + Colormap cmap; + + cPoint = get_integer_resource("points", "Integer"); + steps = get_integer_resource("steps", "Integer"); + delay = get_integer_resource("delay", "Integer"); + + if (steps <= 0) + steps = (random() % 400) + 100; + + delta_gam = 1.0 / steps; + XGetWindowAttributes(dpy, window, &wa); + cmap = wa.colormap; + gcv.foreground = get_pixel_resource("foreground", "Foreground", dpy, cmap); + gcDraw = XCreateGC(dpy, window, GCForeground, &gcv); + XSetForeground(dpy, gcDraw, gcv.foreground); + gcv.foreground = get_pixel_resource("background", "Background", dpy, cmap); + gcClear = XCreateGC(dpy, window, GCForeground, &gcv); + XClearWindow(dpy, window); + + initPointArrays(); + aCurr = aWork[nWork = 0]; + aPrev = NULL; + gam = 2.0; + nTo = RND(cFig); + + { + int width = random() % 10; + int style = LineSolid; + int cap = (width > 1 ? CapRound : CapButt); + int join = (width > 1 ? JoinRound : JoinBevel); + if (width == 1) width = 0; + XSetLineAttributes(dpy, gcDraw, width, style, cap, join); + XSetLineAttributes(dpy, gcClear, width, style, cap, join); + } + +} + +static void animateLMorph (void) +{ + if (gam > maxGamma) { + gam = 0.0; + if (maxGamma == 1.0) { + nFrom = nTo; + aFrom = a[nFrom]; + } else { + memcpy(aTmp, aCurr, cPoint * sizeof(XPoint)); + aFrom = aTmp; + nFrom = -1; + } + do { + nTo = RND(cFig); + } while (nTo == nFrom); + aTo = a[nTo]; + if (RND(2)) { + /* + * Reverse the array to get more variation. + */ + int i1, i2; + XPoint p; + + for (i1 = 0, i2 = cPoint - 1; i1 < cPoint / 2; i1++, i2--) { + p = aTo[i1]; + aTo[i1] = aTo[i2]; + aTo[i2] = p; + } + } + /* + * It may be nice to interrupt the next run. + */ + if (RND(3) > 0) + maxGamma = 0.1 + 0.7 * (RND(1001) / 1000.0); + else + maxGamma = 1.0; + } + + createPoints(); + drawImage(); + aPrev = aCurr; + aCurr = aWork[nWork ^= 1]; + + gam += delta_gam; +} + + + +/************************************************************************** + * * + * P U B L I C F U N C T I O N S * + * * + **************************************************************************/ + +void +screenhack(Display *disp, Window win) +{ + dpy = disp; + window = win; + initLMorph(); + for (;;) { + animateLMorph(); + screenhack_usleep(delay); + } +} diff --git a/hacks/lmorph.man b/hacks/lmorph.man new file mode 100644 index 00000000..a631f24c --- /dev/null +++ b/hacks/lmorph.man @@ -0,0 +1,54 @@ +.TH LMORPH 1 "xscreensaver hack" +.SH NAME +lmorph \- morphing lines +.SH SYNOPSIS +.B lmorph +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-points \fIint\fP] [\-steps \fIint\fP] [\-delay \fIusecs\fP] +.SH DESCRIPTION +The \fIlmorph\fP program morphs between simple linedrawings using bilinear +interpolation. +.SH OPTIONS +.I lmorph +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-points \fIinteger\fP +Number of points in each line drawing. Default is 150 points. +.TP 8 +.B \-steps \fIinteger\fP +Interpolation steps from one drawing to the next. Default is 0, which +means a random number between 100 and 500. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 50000. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH AUTHOR +Sverre H. Huseby and Glenn T. Lines , +built on top of the screen saver routines by Jamie Zawinski . diff --git a/hacks/maze.c b/hacks/maze.c new file mode 100644 index 00000000..9150bb29 --- /dev/null +++ b/hacks/maze.c @@ -0,0 +1,1522 @@ +/****************************************************************************** + * [ maze ] ... + * + * modified: [ 4-10-97 ] Johannes Keukelaar + * Added multiple maze creators. Robustified solver. + * Added bridge option. + * modified: [ 8-11-95 ] Ed James + * added fill of dead-end box to solve_maze while loop. + * modified: [ 3-7-93 ] Jamie Zawinski + * added the XRoger logo, cleaned up resources, made + * grid size a parameter. + * modified: [ 3-3-93 ] Jim Randell + * Added the colour stuff and integrated it with jwz's + * screenhack stuff. There's still some work that could + * be done on this, particularly allowing a resource to + * specify how big the squares are. + * modified: [ 10-4-88 ] Richard Hess ...!uunet!cimshop!rhess + * [ Revised primary execution loop within main()... + * [ Extended X event handler, check_events()... + * modified: [ 1-29-88 ] Dave Lemke lemke@sun.com + * [ Hacked for X11... + * [ Note the word "hacked" -- this is extremely ugly, but at + * [ least it does the job. NOT a good programming example + * [ for X. + * original: [ 6/21/85 ] Martin Weiss Sun Microsystems [ SunView ] + * + ****************************************************************************** + 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. + *****************************************************************************/ + +#include "screenhack.h" +#include "erase.h" + +#define XROGER + +static int solve_delay, pre_solve_delay, post_solve_delay; + +#include +#include +#include +#ifndef VMS +# include +#else /* VMS */ +# include "sys$common:[decw$include.bitmaps]gray1.xbm" +#endif /* VMS */ + +#define MAX_MAZE_SIZE_X 500 +#define MAX_MAZE_SIZE_Y 500 + +#define MOVE_LIST_SIZE (MAX_MAZE_SIZE_X * MAX_MAZE_SIZE_Y) + +#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 SOLVER_VISIT 0x4 +#define START_SQUARE 0x2 +#define END_SQUARE 0x1 + +#define border_x (0) +#define border_y (0) + +#define get_random(x) (random() % (x)) + +static int logo_x, logo_y; + +#ifdef XROGER +# define logo_width 128 +# define logo_height 128 +#else +# include +# define logo_width xlogo64_width +# define logo_height xlogo64_height +# define logo_bits xlogo64_bits +#endif + +static unsigned short maze[MAX_MAZE_SIZE_X][MAX_MAZE_SIZE_Y]; + +static struct { + unsigned char x; + unsigned char y; + unsigned char dir; +} move_list[MOVE_LIST_SIZE], save_path[MOVE_LIST_SIZE], path[MOVE_LIST_SIZE]; + +static int maze_size_x, maze_size_y; +static int sqnum, cur_sq_x, cur_sq_y, path_length; +static int start_x, start_y, start_dir, end_x, end_y, end_dir; +static int grid_width, grid_height; +static int bw; + +static Display *dpy; +static Window win; +static GC gc, cgc, tgc, logo_gc, erase_gc; +static Pixmap logo_map; + +static int x = 0, y = 0, restart = 0, stop = 1, state = 1, max_length; +static int sync_p, bridge_p; + +static int +check_events (void) /* X event handler [ rhess ] */ +{ + XEvent e; + + if (XPending(dpy)) { + XNextEvent(dpy, &e); + switch (e.type) { + + case ButtonPress: + switch (e.xbutton.button) { + case 3: + exit (0); + break; + case 2: + stop = !stop ; + if (state == 5) state = 4 ; + else { + restart = 1; + stop = 0; + } + break; + default: + restart = 1 ; + stop = 0 ; + break; + } + break; + + case ConfigureNotify: + restart = 1; + break; + case UnmapNotify: + stop = 1; + XClearWindow (dpy, win); + XSync (dpy, False); + break; + case Expose: + restart = 1; + break; + } + return(1); + } + return(0); +} + + +static void +set_maze_sizes (int width, int height) +{ + maze_size_x = width / grid_width; + maze_size_y = height / grid_height; +} + + +static void +initialize_maze (void) /* draw the surrounding wall and start/end squares */ +{ + register int i, j, wall; + int logow = 1 + logo_width / grid_width; + int logoh = 1 + logo_height / grid_height; + + /* initialize all squares */ + for ( i=0; i> wall ); + maze[i][j] &= ~( WALL_TOP >> wall ); + cur_sq_x = i; + cur_sq_y = j; + start_x = i; + start_y = j; + start_dir = wall; + sqnum = 0; + + /* set end square */ + wall = (wall + 2)%4; + switch (wall) { + case 0: + i = get_random(maze_size_x); + j = 0; + break; + case 1: + i = maze_size_x - 1; + j = get_random(maze_size_y); + break; + case 2: + i = get_random(maze_size_x); + j = maze_size_y - 1; + break; + case 3: + i = 0; + j = get_random(maze_size_y); + break; + } + maze[i][j] |= END_SQUARE; + maze[i][j] |= ( DOOR_OUT_TOP >> wall ); + maze[i][j] &= ~( WALL_TOP >> wall ); + end_x = i; + end_y = j; + end_dir = wall; + + /* set logo */ + if ((maze_size_x-logow >= 6) && (maze_size_y-logoh >= 6)) + { + /* not closer than 3 grid units from a wall */ + logo_x = get_random (maze_size_x - logow - 5) + 3; + logo_y = get_random (maze_size_y - logoh - 5) + 3; + for (i=0; i=3 && logow>=3) + { + bridge_dir = 1+random()%2; + if(bridge_dir==1) + { + bridge_c = logo_y+random()%(logoh-2)+1; + } + else + { + bridge_c = logo_x+random()%(logow-2)+1; + } + } + else + { + bridge_dir = 0; + bridge_c = -1; + } + + for(x = logo_x; x < logo_x+logow; x++) + for(y = logo_y; y < logo_y+logoh; y++) + { + /* I should check for the bridge here, except that I join the + * bridge together below. + */ + hedges[2*(x+maze_size_x*y)+1] = -1; + hedges[2*(x+maze_size_x*y)] = -1; + } + for(x = logo_x; x < logo_x+logow; x++) + { + if(!(bridge_dir==2 && x==bridge_c)) + { + build_wall(x, logo_y, 0); + build_wall(x, logo_y+logoh, 0); + } + hedges[2*(x+maze_size_x*(logo_y-1))] = -1; + if(bridge_dir==1) + { + build_wall(x, bridge_c, 0); + build_wall(x, bridge_c, 2); + } + } + for(y = logo_y; y < logo_y+logoh; y++) + { + if(!(bridge_dir==1 && y==bridge_c)) + { + build_wall(logo_x, y, 3); + build_wall(logo_x+logow, y, 3); + } + hedges[2*(logo_x-1+maze_size_x*y)+1] = -1; + if(bridge_dir==2) + { + build_wall(bridge_c, y, 1); + build_wall(bridge_c, y, 3); + } + } + /* Join the whole bridge together. */ + if(bridge_p) + { + if(bridge_dir==1) + { + x = logo_x-1; + y = bridge_c; + for(i = logo_x; i < logo_x+logow+1; i++) + join_sets(x+y*maze_size_x, i+y*maze_size_x); + } + else + { + y = logo_y-1; + x = bridge_c; + for(i = logo_y; i < logo_y+logoh+1; i++) + join_sets(x+y*maze_size_x, x+i*maze_size_x); + } + } + } + + for(i = 0; i < maze_size_x*maze_size_y*2; i++) + { + t = hedges[i]; + r = random()%(maze_size_x*maze_size_y*2); + hedges[i] = hedges[r]; + hedges[r] = t; + } +} + +/* Get the representative of a set. */ +static int +get_set(int num) +{ + int s; + + if(sets[num]==num) + return num; + else + { + s = get_set(sets[num]); + sets[num] = s; + return s; + } +} + +/* Join two sets together. */ +static void +join_sets(num1, num2) + int num1, num2; +{ + int s1, s2; + + s1 = get_set(num1); + s2 = get_set(num2); + + if(s1>1)%maze_size_x; + y = (h>>1)/maze_size_x; + + v = x; + w = y; + switch(dir) + { + case 1: + v++; + break; + case 2: + w++; + break; + } + +#if DEBUG_SETS + show_set(x+y*maze_size_x, logo_gc); + show_set(v+w*maze_size_x, tgc); +#endif + if(get_set(x+y*maze_size_x)!=get_set(v+w*maze_size_x)) + { +#if DEBUG_SETS + printf("Join!"); +#endif + join_sets(x+y*maze_size_x, v+w*maze_size_x); + /* Don't draw the wall. */ + } + else + { +#if DEBUG_SETS + printf("Build."); +#endif + /* Don't join the sets. */ + build_wall(x, y, dir); + } +#if DEBUG_SETS + if(!cont) + { + XSync(dpy, False); + c = getchar(); + if(c=='c') + cont = 1; + } + show_set(x+y*maze_size_x, erase_gc); + show_set(v+w*maze_size_x, erase_gc); +#endif + } + + /* Free some memory. */ + exit_sets(); +} + +/* First alternative maze creator: Pick a random, empty corner in the maze. + * Pick a random direction. Draw a wall in that direction, from that corner + * until we hit a wall. Option: Only draw the wall if it's going to be + * shorter than a certain length. Otherwise we get lots of long walls. + */ +static void +alt_create_maze(void) +{ + char *corners; + int *c_idx; + int i, j, height, width, open_corners, k, dir, x, y; + + height = maze_size_y+1; + width = maze_size_x+1; + + /* Allocate and clear some mem. */ + corners = (char *)calloc(height*width, 1); + if(!corners) + return; + + /* Set up the indexing array. */ + c_idx = (int *)malloc(sizeof(int)*height*width); + if(!c_idx) + { + free(corners); + return; + } + for(i = 0; i < height*width; i++) + c_idx[i] = i; + for(i = 0; i < height*width; i++) + { + j = c_idx[i]; + k = random()%(height*width); + c_idx[i] = c_idx[k]; + c_idx[k] = j; + } + + /* Set up some initial walls. */ + /* Outside walls. */ + for(i = 0; i < width; i++) + { + corners[i] = 1; + corners[i+width*(height-1)] = 1; + } + for(i = 0; i < height; i++) + { + corners[i*width] = 1; + corners[i*width+width-1] = 1; + } + /* Walls around logo. In fact, inside the logo, too. */ + /* Also draw the walls. */ + if(logo_x!=-1) + { + int logow = 1 + logo_width / grid_width; + int logoh = 1 + logo_height / grid_height; + int bridge_dir, bridge_c; + + if(bridge_p && logoh>=3 && logow>=3) + { + bridge_dir = 1+random()%2; + if(bridge_dir==1) + { + bridge_c = logo_y+random()%(logoh-2)+1; + } + else + { + bridge_c = logo_x+random()%(logow-2)+1; + } + } + else + { + bridge_dir = 0; + bridge_c = -1; + } + for(i = logo_x; i <= logo_x + logow; i++) + { + for(j = logo_y; j <= logo_y + logoh; j++) + { + corners[i+width*j] = 1; + } + } + for(x = logo_x; x < logo_x+logow; x++) + { + if(!(bridge_dir==2 && x==bridge_c)) + { + build_wall(x, logo_y, 0); + build_wall(x, logo_y+logoh, 0); + } + if(bridge_dir==1) + { + build_wall(x, bridge_c, 0); + build_wall(x, bridge_c, 2); + } + } + for(y = logo_y; y < logo_y+logoh; y++) + { + if(!(bridge_dir==1 && y==bridge_c)) + { + build_wall(logo_x, y, 3); + build_wall(logo_x+logow, y, 3); + } + if(bridge_dir==2) + { + build_wall(bridge_c, y, 1); + build_wall(bridge_c, y, 3); + } + } + /* Connect one wall of the logo with an outside wall. */ + if(bridge_p) + dir = (bridge_dir+1)%4; + else + dir = random()%4; + switch(dir) + { + case 0: + x = logo_x+(random()%(logow+1)); + y = logo_y; + break; + case 1: + x = logo_x+logow; + y = logo_y+(random()%(logoh+1)); + break; + case 2: + x = logo_x+(random()%(logow+1)); + y = logo_y+logoh; + break; + case 3: + x = logo_x; + y = logo_y+(random()%(logoh+1)); + break; + } + do + { + corners[x+width*y] = 1; + switch(dir) + { + case 0: + build_wall(x-1, y-1, 1); + y--; + break; + case 1: + build_wall(x, y, 0); + x++; + break; + case 2: + build_wall(x, y, 3); + y++; + break; + case 3: + build_wall(x-1, y-1, 2); + x--; + break; + } + } + while(!corners[x+width*y]); + if(bridge_p) + { + dir = (dir+2)%4; + switch(dir) + { + case 0: + x = logo_x+(random()%(logow+1)); + y = logo_y; + break; + case 1: + x = logo_x+logow; + y = logo_y+(random()%(logoh+1)); + break; + case 2: + x = logo_x+(random()%(logow+1)); + y = logo_y+logoh; + break; + case 3: + x = logo_x; + y = logo_y+(random()%(logoh+1)); + break; + } + do + { + corners[x+width*y] = 1; + switch(dir) + { + case 0: + build_wall(x-1, y-1, 1); + y--; + break; + case 1: + build_wall(x, y, 0); + x++; + break; + case 2: + build_wall(x, y, 3); + y++; + break; + case 3: + build_wall(x-1, y-1, 2); + x--; + break; + } + } + while(!corners[x+width*y]); + } + } + + /* Count open gridpoints. */ + open_corners = 0; + for(i = 0; i < width; i++) + for(j = 0; j < height; j++) + if(!corners[i+width*j]) + open_corners++; + + /* Now do actual maze generation. */ + while(open_corners>0) + { + for(i = 0; i < width*height; i++) + { + if(!corners[c_idx[i]]) + { + x = c_idx[i]%width; + y = c_idx[i]/width; + /* Choose a random direction. */ + dir = random()%4; + + k = 0; + /* Measure the length of the wall we'd draw. */ + while(!corners[x+width*y]) + { + k++; + switch(dir) + { + case 0: + y--; + break; + case 1: + x++; + break; + case 2: + y++; + break; + case 3: + x--; + break; + } + } + + if(k<=max_length) + { + x = c_idx[i]%width; + y = c_idx[i]/width; + + /* Draw a wall until we hit something. */ + while(!corners[x+width*y]) + { + open_corners--; + corners[x+width*y] = 1; + switch(dir) + { + case 0: + build_wall(x-1, y-1, 1); + y--; + break; + case 1: + build_wall(x, y, 0); + x++; + break; + case 2: + build_wall(x, y, 3); + y++; + break; + case 3: + build_wall(x-1, y-1, 2); + x--; + break; + } + } + } + } + } + } + + /* Free some memory we used. */ + free(corners); + free(c_idx); +} + +/* The original maze creator. Start somewhere. Take a step in a random + * direction. Keep doing this until we hit a wall. Then, backtrack until + * we find a point where we can go in another direction. + */ +static void +create_maze (void) /* create a maze layout given the initialized maze */ +{ + register int i, newdoor = 0; + int logow = 1 + logo_width / grid_width; + int logoh = 1 + logo_height / grid_height; + + /* Maybe we should make a bridge? */ + if(bridge_p && logo_x>=0 && logow>=3 && logoh>=3) + { + int bridge_dir, bridge_c; + + bridge_dir = 1+random()%2; + if(bridge_dir==1) + { + if(logoh>=3) + bridge_c = logo_y+random()%(logoh-2)+1; + else + bridge_c = logo_y+random()%logoh; + } + else + { + if(logow>=3) + bridge_c = logo_x+random()%(logow-2)+1; + else + bridge_c = logo_x+random()%logow; + } + + if(bridge_dir==1) + { + for(i = logo_x; i < logo_x+logow; i++) + { + maze[i][bridge_c] &= ~DOOR_IN_TOP; + } + } + else + { + for(i = logo_y; i < logo_y+logoh; i++) + { + maze[bridge_c][i] &= ~DOOR_IN_TOP; + } + } + } + + do { + move_list[sqnum].x = cur_sq_x; + move_list[sqnum].y = cur_sq_y; + move_list[sqnum].dir = newdoor; + while ( ( newdoor = choose_door() ) == -1 ) { /* pick a door */ + if ( backup() == -1 ) { /* no more doors ... backup */ + return; /* done ... return */ + } + } + + /* mark the out door */ + maze[cur_sq_x][cur_sq_y] |= ( DOOR_OUT_TOP >> newdoor ); + + switch (newdoor) { + case 0: cur_sq_y--; + break; + case 1: cur_sq_x++; + break; + case 2: cur_sq_y++; + break; + case 3: cur_sq_x--; + break; + } + sqnum++; + + /* mark the in door */ + maze[cur_sq_x][cur_sq_y] |= ( DOOR_IN_TOP >> ((newdoor+2)%4) ); + + /* if end square set path length and save path */ + if ( maze[cur_sq_x][cur_sq_y] & END_SQUARE ) { + path_length = sqnum; + for ( i=0; i0) + maze[i][j-1] |= WALL_BOTTOM; + break; + case 1: + maze[i][j] |= WALL_RIGHT; + if(i0) + maze[i-1][j] |= WALL_RIGHT; + break; + } +} + +/* Break out a wall. */ +#if 0 +static void +break_wall(i, j, dir) + int i, j, dir; +{ + /* Draw it on the screen. */ + draw_wall(i, j, dir, erase_gc); + /* Put it in the maze. */ + switch(dir) + { + case 0: + maze[i][j] &= ~WALL_TOP; + if(j>0) + maze[i][j-1] &= ~WALL_BOTTOM; + break; + case 1: + maze[i][j] &= ~WALL_RIGHT; + if(i0) + maze[i-1][j] &= ~WALL_RIGHT; + break; + } +} +#endif /* 0 */ + + +static void +draw_solid_square(int i, int j, /* draw a solid square in a square */ + int dir, GC gc) +{ + switch (dir) { + case 0: XFillRectangle(dpy, win, gc, + border_x + bw + grid_width * i, + border_y - bw + grid_height * j, + grid_width - (bw+bw), grid_height); + break; + case 1: XFillRectangle(dpy, win, gc, + border_x + bw + grid_width * i, + border_y + bw + grid_height * j, + grid_width, grid_height - (bw+bw)); + break; + case 2: XFillRectangle(dpy, win, gc, + border_x + bw + grid_width * i, + border_y + bw + grid_height * j, + grid_width - (bw+bw), grid_height); + break; + case 3: XFillRectangle(dpy, win, gc, + border_x - bw + grid_width * i, + border_y + bw + grid_height * j, + grid_width, grid_height - (bw+bw)); + break; + } + XSync (dpy, False); +} + + +static void +solve_maze (void) /* solve it with graphical feedback */ +{ + int i; + int step_x[4] = { 0, 1, 0, -1 }; + int step_y[4] = { -1, 0, 1, 0 }; + + /* plug up the surrounding wall */ + maze[start_x][start_y] |= (WALL_TOP >> start_dir); + maze[end_x][end_y] |= (WALL_TOP >> end_dir); + + /* initialize search path */ + i = 0; + path[i].x = end_x; + path[i].y = end_y; + path[i].dir = -1; + maze[end_x][end_y] |= SOLVER_VISIT; + + /* do it */ + while (1) { + if ( ++path[i].dir >= 4 ) { + XFillRectangle(dpy, win, cgc, + border_x + bw + grid_width * (int)(path[i].x), + border_y + bw + grid_height * (int)(path[i].y), + grid_width - (bw+bw), grid_height - (bw+bw)); + i--; + if(i<0) /* Can't solve this maze. */ + { + printf("Unsolvable maze.\n"); + return; + } + draw_solid_square( (int)(path[i].x), (int)(path[i].y), + (int)(path[i].dir), cgc); + } + else if ( (! (maze[path[i].x][path[i].y] & (WALL_TOP >> path[i].dir))) && + (!( maze[path[i].x+step_x[path[i].dir]] + [path[i].y+step_y[path[i].dir]]&SOLVER_VISIT)) ) { + path[i+1].x = path[i].x+step_x[path[i].dir]; + path[i+1].y = path[i].y+step_y[path[i].dir]; + path[i+1].dir = -1; + draw_solid_square(path[i].x, path[i].y, path[i].dir, tgc); + i++; + maze[path[i].x][path[i].y] |= SOLVER_VISIT; + if ( maze[path[i].x][path[i].y] & START_SQUARE ) { + return; + } + } + if (check_events()) return; + /* Abort solve on expose - cheapo repaint strategy */ + if (solve_delay) usleep (solve_delay); + } +} + + +#if 0 +static void +enter_square (int n) /* move into a neighboring square */ +{ + draw_solid_square( (int)path[n].x, (int)path[n].y, + (int)path[n].dir, tgc); + + path[n+1].dir = -1; + switch (path[n].dir) { + case 0: path[n+1].x = path[n].x; + path[n+1].y = path[n].y - 1; + break; + case 1: path[n+1].x = path[n].x + 1; + path[n+1].y = path[n].y; + break; + case 2: path[n+1].x = path[n].x; + path[n+1].y = path[n].y + 1; + break; + case 3: path[n+1].x = path[n].x - 1; + path[n+1].y = path[n].y; + break; + } +} +#endif /* 0 */ + + +/* + * jmr additions for Jamie Zawinski's screensaver stuff, + * note that the code above this has probably been hacked about in some + * arbitrary way. + */ + +char *progclass = "Maze"; + +char *defaults[] = { + "Maze.background: black", /* to placate SGI */ + "Maze.foreground: white", /* to placate SGI */ + "*gridSize: 0", + "*solveDelay: 5000", + "*preDelay: 2000000", + "*postDelay: 4000000", + "*liveColor: green", + "*deadColor: red", + "*generator: -1", + "*maxLength: 5", + "*syncDraw: False", + "*bridge: False", +#ifdef XROGER + "*logoColor: red3", +#endif + 0 +}; + +XrmOptionDescRec options[] = { + { "-grid-size", ".gridSize", XrmoptionSepArg, 0 }, + { "-solve-delay", ".solveDelay", XrmoptionSepArg, 0 }, + { "-pre-delay", ".preDelay", XrmoptionSepArg, 0 }, + { "-post-delay", ".postDelay", XrmoptionSepArg, 0 }, + { "-live-color", ".liveColor", XrmoptionSepArg, 0 }, + { "-dead-color", ".deadColor", XrmoptionSepArg, 0 }, + { "-generator", ".generator", XrmoptionSepArg, 0 }, + { "-max-length", ".maxLength", XrmoptionSepArg, 0 }, + { "-bridge", ".bridge", XrmoptionNoArg, "True" }, + { "-no-bridge", ".bridge", XrmoptionNoArg, "False" }, + { 0, 0, 0, 0 } +}; + +#ifdef XROGER +extern void skull (Display *, Window, GC, GC, int, int, int, int); +#endif + +void +screenhack(Display *display, Window window) +{ + Pixmap gray; + int size, root, generator, this_gen; + XWindowAttributes xgwa; + unsigned long bg, fg, pfg, pbg, lfg; + + size = get_integer_resource ("gridSize", "Dimension"); + root = get_boolean_resource("root", "Boolean"); + solve_delay = get_integer_resource ("solveDelay", "Integer"); + pre_solve_delay = get_integer_resource ("preDelay", "Integer"); + post_solve_delay = get_integer_resource ("postDelay", "Integer"); + generator = get_integer_resource("generator", "Integer"); + max_length = get_integer_resource("maxLength", "Integer"); + bridge_p = get_boolean_resource("bridge", "Boolean"); + + if (size < 2) size = 7 + (random () % 30); + grid_width = grid_height = size; + bw = (size > 6 ? 3 : (size-1)/2); + + dpy = display; win = window; /* the maze stuff uses global variables */ + + XGetWindowAttributes (dpy, win, &xgwa); + + x = 0; + y = 0; + + set_maze_sizes (xgwa.width, xgwa.height); + + if (! root) + XSelectInput (dpy, win, ExposureMask|ButtonPressMask|StructureNotifyMask); + + gc = XCreateGC(dpy, win, 0, 0); + cgc = XCreateGC(dpy, win, 0, 0); + tgc = XCreateGC(dpy,win,0,0); + logo_gc = XCreateGC(dpy, win, 0, 0); + erase_gc = XCreateGC(dpy, win, 0, 0); + + gray = XCreateBitmapFromData (dpy,win,gray1_bits,gray1_width,gray1_height); + + bg = get_pixel_resource ("background","Background", dpy, xgwa.colormap); + fg = get_pixel_resource ("foreground","Foreground", dpy, xgwa.colormap); + lfg = get_pixel_resource ("logoColor", "Foreground", dpy, xgwa.colormap); + pfg = get_pixel_resource ("liveColor", "Foreground", dpy, xgwa.colormap); + pbg = get_pixel_resource ("deadColor", "Foreground", dpy, xgwa.colormap); + if (mono_p) lfg = pfg = fg; + + if (lfg == bg) + lfg = ((bg == WhitePixel (dpy, DefaultScreen (dpy))) + ? BlackPixel (dpy, DefaultScreen (dpy)) + : WhitePixel (dpy, DefaultScreen (dpy))); + + XSetForeground (dpy, gc, fg); + XSetBackground (dpy, gc, bg); + XSetForeground (dpy, cgc, pbg); + XSetBackground (dpy, cgc, bg); + XSetForeground (dpy, tgc, pfg); + XSetBackground (dpy, tgc, bg); + XSetForeground (dpy, logo_gc, lfg); + XSetBackground (dpy, logo_gc, bg); + XSetForeground (dpy, erase_gc, bg); + XSetBackground (dpy, erase_gc, bg); + + XSetStipple (dpy, cgc, gray); + XSetFillStyle (dpy, cgc, FillOpaqueStippled); + +#ifdef XROGER + { + int w, h; + XGCValues gcv; + GC draw_gc, erase_gc; + /* round up to grid size */ + w = ((logo_width / grid_width) + 1) * grid_width; + h = ((logo_height / grid_height) + 1) * grid_height; + logo_map = XCreatePixmap (dpy, win, w, h, 1); + gcv.foreground = 1L; + draw_gc = XCreateGC (dpy, logo_map, GCForeground, &gcv); + gcv.foreground = 0L; + erase_gc= XCreateGC (dpy, logo_map, GCForeground, &gcv); + XFillRectangle (dpy, logo_map, erase_gc, 0, 0, w, h); + skull (dpy, logo_map, draw_gc, erase_gc, 5, 0, w-10, h-10); + XFreeGC (dpy, draw_gc); + XFreeGC (dpy, erase_gc); + } +#else + if (!(logo_map = XCreateBitmapFromData (dpy, win, logo_bits, + logo_width, logo_height))) + { + fprintf (stderr, "Can't create logo pixmap\n"); + exit (1); + } +#endif + XMapRaised(dpy, win); + + restart = root; + + sync_p = !(random() % 10); + + while (1) { /* primary execution loop [ rhess ] */ + if (check_events()) continue ; + if (restart || stop) goto pop; + switch (state) { + case 1: + initialize_maze(); + break; + case 2: + XClearWindow(dpy, win); + draw_maze_border(); + break; + case 3: + this_gen = generator; + if(this_gen<0 || this_gen>2) + this_gen = random()%3; + + switch(this_gen) + { + case 0: + create_maze(); + break; + case 1: + alt_create_maze(); + break; + case 2: + set_create_maze(); + break; + } + break; + case 4: + XSync (dpy, False); + usleep (pre_solve_delay); + break; + case 5: + solve_maze(); + break; + case 6: + XSync (dpy, False); + usleep (post_solve_delay); + state = 0 ; + erase_full_window(display, window); + break; + default: + abort (); + } + ++state; + pop: + if (restart) + { + static XWindowAttributes wattr; + restart = 0; + stop = 0; + state = 1; + XGetWindowAttributes (dpy, win, &wattr); + set_maze_sizes (wattr.width, wattr.height); + XClearWindow (dpy, win); + XSync (dpy, False); + sync_p = !(random() % 10); + } + } +} diff --git a/hacks/maze.man b/hacks/maze.man new file mode 100644 index 00000000..1321995a --- /dev/null +++ b/hacks/maze.man @@ -0,0 +1,134 @@ +.TH XScreenSaver 1 "7-mar-93" "X Version 11" +.SH NAME +maze \- an automated X11 demo repeatedly creating and solving a random maze +.SH SYNOPSIS +.B maze +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-install] [\-visual \fIvisual\fP] [\-grid\-size \fIpixels\fP] [\-live\-color \fIcolor\fP] [\-dead\-color \fIcolor\fP] [\-solve\-delay \fIusecs\fP] [\-pre\-delay \fIusecs\fP] [\-post\-delay \fIusecs\fP] [\-generator \fIinteger\fP] [\-max\-length \fIinteger\fP] [\-bridge] [\-no\-bridge] +.SH DESCRIPTION +The \fImaze\fP program creates a "random" maze and then solves it with +graphical feedback. +.SH OPTIONS +.I maze +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-grid\-size \fIpixels\fP +The size of each block of the maze, in pixels; default is 0, meaning +pick a random grid size. +.TP 8 +.B \-live\-color \fIcolor\fP +The color of the path. +.TP 8 +.B \-dead\-color \fIcolor\fP +The color of the failed path (it is also stippled with a 50% pattern.) +.TP 8 +.B \-solve\-delay \fIinteger\fP +Delay (in microseconds) between each step of the solution path. +Default 5000, or about 1/200th second. +.TP 8 +.B \-pre\-delay \fIinteger\fP +Delay (in microseconds) between generating a maze and starting to solve it. +Default 2000000 (2 seconds.) +.TP 8 +.B \-post\-delay \fIinteger\fP +Delay (in microseconds) after solving a maze and before generating a new one. +Default 4000000 (4 seconds.) +.TP 8 +.B \-generator \fInum\fP +Sets the algorithm that will be used to generate the mazes. The +default is \-1, which randomly selects an algorithm for each maze that +is generated. Generator 0 is the original one, and works by walking +around randomly until we hit a place we've been before, then +backtracking and trying a new direction somewhere. Generator 1 picks a +random spot in the maze, then draws a straight wall from that spot in +a random direction until it hits another wall (and continues until the +maze is complete). Generator 2 is based on sets. Initially all cells +are in different sets. Then two neighboring cells are chosen and if +they are in different sets, their sets are joined. If they were in the +same set, a wall is built between them. This continues until the maze is +complete. + +All generators generate mazes with a certain 'characteristic'. See if you +can spot them! +.TP 8 +.B \-max\-length \fInum\fP +Controls the maximum length of walls drawn in one go by generator 1. +.TP 8 +.B \-bridge +.TP 8 +.B \-no\-bridge +Controls whether or not a 'bridge' will appear over the logo. +.PP +Clicking the mouse in the maze window controls it. +.TP 16 +.B "LeftButton +Clears the window and restarts maze. +.TP 16 +.B MiddleButton +Pause or unpause the program. +.TP 16 +.B RightButton +Exit. +.SH BUGS +Expose events force a restart of maze. + +Mouse actions are based on "raw" values (Button1, Button2 and Button3) +instead of using the pointer map. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +.PP +Copyright \(co 1988 by Sun Microsystems, Inc. Mountain View, CA. +.PP +All Rights Reserved +.PP +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. +.PP +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. +.SH AUTHOR(s) +.nf +Johannes Keukelaar [ Generators 1 and 2 ] johannes@nada.kth.se + Royal Institute of Technology, Stockholm, Sweden +Jim Randell [ XScreenSaver version ] jmr@mddjmr.fc.hp.com + HPLabs, Bristol +Richard Hess [ X11 extensions ] {...}!uunet!cimshop!rhess + Consilium, Mountain View, CA +Dave Lemke [ X11 version ] lemke@sun.COM + Sun MicroSystems, Mountain View, CA +Martin Weiss [ SunView version ] + Sun MicroSystems, Mountain View, CA +.fi diff --git a/hacks/moire.c b/hacks/moire.c new file mode 100644 index 00000000..7d9798c2 --- /dev/null +++ b/hacks/moire.c @@ -0,0 +1,193 @@ +/* xscreensaver, Copyright (c) 1997 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. + * + * Concept snarfed from Michael D. Bayne in + * http://www.go2net.com/internet/deep/1997/04/16/body.html + */ + +#include "screenhack.h" +#include +#include + +int offset = 0; +XColor *colors = 0; +int ncolors = 0; +GC gc = 0; +unsigned long fg_pixel = 0; +unsigned long bg_pixel = 0; + +static void +init_moire (Display *dpy, Window window) +{ + int oncolors; + int i; + int fgh, bgh; + double fgs, fgv, bgs, bgv; + XWindowAttributes xgwa; + XColor fgc, bgc; + XGCValues gcv; + XGetWindowAttributes (dpy, window, &xgwa); + + offset = get_integer_resource ("offset", "Integer"); + if (offset < 2) offset = 2; + + MONO: + if (colors) + { + for (i = 0; i < ncolors; i++) + XFreeColors (dpy, xgwa.colormap, &colors[i].pixel, 1, 0); + free(colors); + colors = 0; + } + + if (mono_p) + { + fg_pixel = WhitePixelOfScreen (DefaultScreenOfDisplay(dpy)); + bg_pixel = BlackPixelOfScreen (DefaultScreenOfDisplay(dpy)); + } + else + { + fg_pixel = get_pixel_resource ("foreground", "Foreground", dpy, + xgwa.colormap); + bg_pixel = get_pixel_resource ("background", "Background", dpy, + xgwa.colormap); + } + + if (mono_p) + { + offset *= 20; /* compensate for lack of shading */ + gcv.foreground = fg_pixel; + } + else + { + ncolors = get_integer_resource ("ncolors", "Integer"); + if (ncolors < 2) ncolors = 2; + oncolors = ncolors; + + fgc.flags = bgc.flags = DoRed|DoGreen|DoBlue; + if (get_boolean_resource("random","Boolean")) + { + fgc.red = random() & 0xFFFF; + fgc.green = random() & 0xFFFF; + fgc.blue = random() & 0xFFFF; + bgc.red = random() & 0xFFFF; + bgc.green = random() & 0xFFFF; + bgc.blue = random() & 0xFFFF; + } + else + { + fgc.pixel = fg_pixel; + bgc.pixel = bg_pixel; + XQueryColor (dpy, xgwa.colormap, &fgc); + XQueryColor (dpy, xgwa.colormap, &bgc); + } + rgb_to_hsv (fgc.red, fgc.green, fgc.blue, &fgh, &fgs, &fgv); + rgb_to_hsv (bgc.red, bgc.green, bgc.blue, &bgh, &bgs, &bgv); + + colors = (XColor *) malloc (sizeof (XColor) * (ncolors+2)); + memset(colors, 0, (sizeof (XColor) * (ncolors+2))); + make_color_ramp (dpy, xgwa.colormap, + fgh, fgs, fgv, bgh, bgs, bgv, + colors, &ncolors, + True, True, False); + if (ncolors != oncolors) + fprintf(stderr, "%s: got %d of %d requested colors.\n", + progname, ncolors, oncolors); + + if (ncolors <= 2) + { + mono_p = True; + goto MONO; + } + + gcv.foreground = colors[0].pixel; + } + gc = XCreateGC (dpy, window, GCForeground, &gcv); +} + + +static void +moire (Display *dpy, Window window, int offset, XColor *colors, int ncolors) +{ + long x, y, xo, yo; + int factor = (random() % offset) + 1; + XGCValues gcv; + XWindowAttributes xgwa; + XImage *image; + int depth; + XGetWindowAttributes (dpy, window, &xgwa); + + xo = (random() % xgwa.width) - xgwa.width/2; + yo = (random() % xgwa.height) - xgwa.height/2; + + depth = visual_depth(DefaultScreenOfDisplay(dpy), xgwa.visual); + image = XCreateImage (dpy, xgwa.visual, + depth, ZPixmap, 0, /* depth, format, offset */ + 0, xgwa.width, 1, 8, 0); /* data, w, h, pad, bpl */ + + image->data = (char *) malloc (((xgwa.width + 1) * depth / 8) + * 2 /* uh, I dunno... */ + ); + + for (y = 0; y < xgwa.height; y++) + { + for (x = 0; x < xgwa.width; x++) + { + double xx = x + xo; + double yy = y + yo; + double i = ((xx * xx) + (yy * yy)) / (double) factor; + if (mono_p) + gcv.foreground = ((((long) i) & 1) ? fg_pixel : bg_pixel); + else + gcv.foreground = colors[((long) i) % ncolors].pixel; + XPutPixel (image, x, 0, gcv.foreground); + } + XPutImage (dpy, window, gc, image, 0, 0, 0, y, xgwa.width, 1); + XSync(dpy, False); + } + if (image->data) free(image->data); + image->data = 0; + XDestroyImage (image); +} + + +char *progclass = "Moire"; + +char *defaults [] = { + "Moire.background: blue", /* to placate SGI */ + "Moire.foreground: red", + "*random: true", + "*delay: 5", + "*ncolors: 64", + "*offset: 50", + 0 +}; + +XrmOptionDescRec options [] = { + { "-random", ".random", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-ncolors", ".ncolors", XrmoptionSepArg, 0 }, + { "-offset", ".offset", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + int delay = get_integer_resource ("delay", "Integer"); + while (1) + { + init_moire (dpy, window); + moire (dpy, window, offset, colors, ncolors); + XSync (dpy, True); + if (delay) + sleep(delay); + } +} diff --git a/hacks/moire.man b/hacks/moire.man new file mode 100644 index 00000000..4304710d --- /dev/null +++ b/hacks/moire.man @@ -0,0 +1,64 @@ +.TH XScreenSaver 1 "27-Apr-97" "X Version 11" +.SH NAME +halo - draw circular interference patterns +.SH SYNOPSIS +.B halo +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-delay \fIseconds\fP] [\-random \fIboolean\fP] [\-ncolors \fIint\fP] [\-offset \fIint\fP] +.SH DESCRIPTION +The \fImoire\fP program draws cool circular interference patterns. +.SH OPTIONS +.I moire +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fIseconds\fP +How long to wait before starting over. Default 5 seconds. +.TP 8 +.B \-random \fIboolean\fP +Whether to ignore the foreground/background colors, and pick them randomly +instead. +.TP 8 +.B \-offset \fIinteger\fP +The maximum random radius increment to use. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be allocated in the color ramp (note that this +value interacts with \fIoffset\fP.) +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 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. +.SH AUTHOR +Jamie Zawinski , 27-Apr-97, based on code by +Michael D. Bayne . diff --git a/hacks/moire2.c b/hacks/moire2.c new file mode 100644 index 00000000..463478c6 --- /dev/null +++ b/hacks/moire2.c @@ -0,0 +1,278 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +#include "screenhack.h" +#include +#include + +static int ncolors, color_shift; +static XColor *colors = 0; +static int fg_pixel, bg_pixel; +static Pixmap p0 = 0, p1 = 0, p2 = 0, p3 = 0; +static GC copy_gc = 0, erase_gc = 0, window_gc = 0; +static int width, height, size; +static int x1, x2, y1, y2, x3, y3; +static int dx1, dx2, dx3, dy1, dy2, dy3; +static int othickness, thickness; +static Bool do_three; + +static void +init_moire2 (Display *dpy, Window window) +{ + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + + othickness = get_integer_resource("thickness", "Thickness"); + + if (mono_p) + ncolors = 2; + else + ncolors = get_integer_resource ("colors", "Colors"); + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + + if (mono_p) + colors = 0; + else + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + + if (mono_p) + ; + else + make_smooth_colormap (dpy, xgwa.visual, xgwa.colormap, colors, &ncolors, + True, 0, True); + + bg_pixel = get_pixel_resource("background", "Background", dpy, + xgwa.colormap); + fg_pixel = get_pixel_resource("foreground", "Foreground", dpy, + xgwa.colormap); +} + + +static void +reset_moire2 (Display *dpy, Window window) +{ + GC gc; + XWindowAttributes xgwa; + XGCValues gcv; + Bool xor; + XGetWindowAttributes (dpy, window, &xgwa); + + do_three = (0 == (random() % 3)); + + width = xgwa.width; + height = xgwa.height; + size = width > height ? width : height; + + if (p0) XFreePixmap(dpy, p0); + if (p1) XFreePixmap(dpy, p1); + if (p2) XFreePixmap(dpy, p2); + if (p3) XFreePixmap(dpy, p3); + + p0 = XCreatePixmap(dpy, window, width, height, 1); + p1 = XCreatePixmap(dpy, window, width*2, height*2, 1); + p2 = XCreatePixmap(dpy, window, width*2, height*2, 1); + if (do_three) + p3 = XCreatePixmap(dpy, window, width*2, height*2, 1); + else + p3 = 0; + + thickness = (othickness > 0 ? othickness : (1 + (random() % 4))); + + gcv.foreground = 0; + gcv.line_width = (thickness == 1 ? 0 : thickness); + gc = XCreateGC (dpy, p1, GCForeground|GCLineWidth, &gcv); + + XFillRectangle(dpy, p1, gc, 0, 0, width*2, height*2); + XFillRectangle(dpy, p2, gc, 0, 0, width*2, height*2); + if (do_three) + XFillRectangle(dpy, p3, gc, 0, 0, width*2, height*2); + + XSetForeground(dpy, gc, 1); + + xor = (do_three || (thickness == 1) || (random() & 1)); + + { + int i, ii, maxx, maxy; + +#define FROB(P) do { \ + maxx = (size*4); \ + maxy = (size*4); \ + if (0 == (random() % 5)) { \ + float f = 1.0 + frand(0.05); \ + if (random() & 1) maxx *= f; \ + else maxy *= f; \ + } \ + ii = (thickness + 1 + (xor ? 0 : 1) + (random() % (4 * thickness))); \ + for (i = 0; i < (size*2); i += ii) \ + XDrawArc(dpy, (P), gc, i-size, i-size, maxx-i-i, maxy-i-i, 0, 360*64); \ + if (0 == (random() % 5)) \ + { \ + XSetFunction(dpy, gc, GXxor); \ + XFillRectangle(dpy, (P), gc, 0, 0, width*2, height*2); \ + XSetFunction(dpy, gc, GXcopy); \ + } \ + } while(0) + + FROB(p1); + FROB(p2); + if (do_three) + FROB(p3); +#undef FROB + } + + XFreeGC(dpy, gc); + + if (copy_gc) XFreeGC(dpy, copy_gc); + gcv.function = (xor ? GXxor : GXor); + gcv.foreground = 1; + gcv.background = 0; + + copy_gc = XCreateGC (dpy, p0, GCFunction|GCForeground|GCBackground, &gcv); + + gcv.foreground = 0; + if (erase_gc) XFreeGC(dpy, erase_gc); + erase_gc = XCreateGC (dpy, p0, GCForeground, &gcv); + + gcv.foreground = fg_pixel; + gcv.background = bg_pixel; + if (window_gc) XFreeGC(dpy, window_gc); + window_gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + +#define FROB(N,DN,MAX) \ + N = (MAX/2) + (random() % MAX); \ + DN = ((1 + (random() % (7*thickness))) * ((random() & 1) ? 1 : -1)) + + FROB(x1,dx1,width); + FROB(x2,dx2,width); + FROB(x3,dx3,width); + FROB(y1,dy1,height); + FROB(y2,dy2,height); + FROB(y3,dy3,height); +#undef FROB +} + + + +static void +moire2 (Display *dpy, Window window) +{ +#define FROB(N,DN,MAX) \ + N += DN; \ + if (N <= 0) N = 0, DN = -DN; \ + else if (N >= MAX) N = MAX, DN = -DN; \ + else if (0 == (random() % 100)) DN = -DN; \ + else if (0 == (random() % 50)) \ + DN += (DN <= -20 ? 1 : (DN >= 20 ? -1 : ((random() & 1) ? 1 : -1))) + + FROB(x1,dx1,width); + FROB(x2,dx2,width); + FROB(x3,dx3,width); + FROB(y1,dy1,height); + FROB(y2,dy2,height); + FROB(y3,dy3,height); +#undef FROB + + XFillRectangle(dpy, p0, erase_gc, 0, 0, width, height); + XCopyArea(dpy, p1, p0, copy_gc, x1, y1, width, height, 0, 0); + XCopyArea(dpy, p2, p0, copy_gc, x2, y2, width, height, 0, 0); + if (do_three) + XCopyArea(dpy, p3, p0, copy_gc, x3, y3, width, height, 0, 0); + + XSync(dpy, False); + XCopyPlane(dpy, p0, window, window_gc, 0, 0, width, height, 0, 0, 1L); + XSync(dpy, False); + +#if 0 + XCopyPlane(dpy, p1, window, window_gc, (width*2)/3, (height*2)/3, + width/2, height/2, + 0, height/2, 1L); + XCopyPlane(dpy, p2, window, window_gc, (width*2)/3, (height*2)/3, + width/2, height/2, + width/2, height/2, 1L); +#endif +} + + + + +char *progclass = "Moire2"; + +char *defaults [] = { + "Moire2.background: black", /* to placate SGI */ + "Moire2.foreground: white", + "*delay: 50000", + "*thickness: 0", + "*colors: 150", + "*colorShift: 5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-ncolors", ".colors", XrmoptionSepArg, 0 }, + { "-thickness", ".thickness", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + int delay = get_integer_resource ("delay", "Integer"); + int color_shift = get_integer_resource ("colorShift", "Integer"); + int pix = 0; + Bool flip_a, flip_b; + + if (color_shift <= 0) color_shift = 1; + init_moire2 (dpy, window); + while (1) + { + int iterations = 30 + (random() % 70) + (random() % 70); + reset_moire2 (dpy, window); + + flip_a = mono_p ? False : (random() & 1); + flip_b = mono_p ? False : (random() & 1); + + if (flip_b) + { + XSetForeground(dpy, window_gc, bg_pixel); + XSetBackground(dpy, window_gc, fg_pixel); + } + else + { + XSetForeground(dpy, window_gc, fg_pixel); + XSetBackground(dpy, window_gc, bg_pixel); + } + + while (--iterations > 0) + { + int i; + + if (!mono_p) + { + pix++; + pix = pix % ncolors; + + if (flip_a) + XSetBackground(dpy, window_gc, colors[pix].pixel); + else + XSetForeground(dpy, window_gc, colors[pix].pixel); + } + + for (i = 0; i < color_shift; i++) + { + moire2 (dpy, window); + if (delay) + usleep(delay); + } + } + } +} diff --git a/hacks/mountain.c b/hacks/mountain.c new file mode 100644 index 00000000..1853b937 --- /dev/null +++ b/hacks/mountain.c @@ -0,0 +1,235 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* mountain -- square grid mountains */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)mountain.c 4.04 97/07/28 xlockmore"; + +#endif + +/*- + * Copyright (c) 1995 Pascal Pensa + * + * 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: 0 \n" \ + "*count: 30 \n" \ + "*cycles: 100 \n" \ + "*ncolors: 64 \n" +# define SMOOTH_COLORS +#include "xlockmore.h" /* in xscreensaver distribution */ +#else /* STANDALONE */ +#include "xlock.h" /* in xlockmore distribution */ +#endif /* STANDALONE */ + +ModeSpecOpt mountain_opts = +{0, NULL, 0, NULL, NULL}; + +/* ~ 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]; + int time; /* up time */ + int first; + 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_WIN_WHITE_PIXEL(mi)); + XFillPolygon(display, window, gc, p, 4, Complex, CoordModeOrigin); + + if (!mp->pixelmode) { + XSetForeground(display, gc, MI_WIN_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_WIN_WIDTH(mi); + mp->height = MI_WIN_HEIGHT(mi); + mp->pixelmode = (mp->width + mp->height < 200); + mp->stage = 0; + mp->time = 0; + mp->x = mp->y = 0; + if (!mp->first) { + mp->first = 1; + gcv.foreground = MI_WIN_WHITE_PIXEL(mi); + gcv.background = MI_WIN_BLACK_PIXEL(mi); + + mp->stippled_GC = XCreateGC(MI_DISPLAY(mi), MI_WINDOW(mi), + GCForeground | GCBackground, &gcv); + } + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + + for (y = 0; y < WORLDWIDTH; y++) + for (x = 0; x < WORLDWIDTH; x++) + mp->h[x][y] = 0; + + j = MI_BATCHCOUNT(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)]; + + switch (mp->stage) { + case 0: + drawamountain(mi); + break; + case 1: + MI_PAUSE(mi) = 2000000; + /*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]; + + XFreeGC(MI_DISPLAY(mi), mp->stippled_GC); + } + (void) free((void *) mountains); + mountains = NULL; + } +} + +void +refresh_mountain(ModeInfo * mi) +{ + mountainstruct *mp = &mountains[MI_SCREEN(mi)]; + + mp->x = 0; + mp->y = 0; +} diff --git a/hacks/munch.c b/hacks/munch.c new file mode 100644 index 00000000..d1f2ea6b --- /dev/null +++ b/hacks/munch.c @@ -0,0 +1,256 @@ +/* munch.c + * A munching squares implementation for X + * Tim Showalter + * + * 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 + * + * 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 + */ + +#include +/*#include */ +#include "screenhack.h" + +/* 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) + +char *progclass = "Munch"; + +char *defaults [] = { + "Munch.background: black", /* to placate SGI */ + "Munch.foreground: white", + "*delay: 5000", + "*hold: 100000", + "*clear: 50", + "*logminwidth: 7", + "*shift: True", + "*xor: True", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-hold", ".hold", XrmoptionSepArg, 0 }, + { "-clear", ".clear", XrmoptionSepArg, "true" }, + { "-shift", ".shift", XrmoptionNoArg, "true" }, + { "-no-shift", ".shift", XrmoptionNoArg, "false" }, + { "-logminwidth", ".logminwidth", XrmoptionSepArg, 0 }, + { "-xor", ".xor", XrmoptionNoArg, "true" }, + { "-no-xor", ".xor", XrmoptionNoArg, "false" }, + { 0, 0, 0, 0 } +}; + + +static GC gc; +/* only configurable things right now */ +static int delay, hold, clear, logminwidth, shiftk, xor; + +static void munchOnce (Display* dpy, Window w, + int width, /* pixels */ + int atX, int atY, /* pixels */ + int kX, int kT, int kY, /* pixels */ + int grav /* 0 or not */) { + + int x, y, t; + static Colormap cmap; + XWindowAttributes xgwa; + XColor fgc; + int drawX, drawY; + + /* + fprintf(stderr,"Doing width %d at %d %d shift %d %d %d grav %d\n", + width, atX, atY, kX, kT, kY, grav); + */ + + XGetWindowAttributes (dpy, w, &xgwa); + + if (!mono_p) { + /* XXX there are probably bugs with this. */ + cmap = xgwa.colormap; + + fgc.red = random() % 65535; + fgc.green = random() % 65535; + fgc.blue = random() % 65535; + + if (XAllocColor(dpy, cmap, &fgc)) { + XSetForeground(dpy, gc, fgc.pixel); + } + } + + /* Finally draw this munching square. */ + for(t = 0; t < width; t++) { + for(x = 0; x < width; x++) { + /* figure out the next point */ + y = ((x ^ ((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. + */ +/* assert(drawX >= 0 && drawX < xgwa.width); + assert(drawY >= 0 && drawY < xgwa.height); +*/ + + XDrawPoint(dpy, w, gc, drawX, drawY); + /* XXX may want to change this to XDrawPoints, + but it's fast enough without it for the moment. */ + + } + + /* we've drawn one pass' worth of points. let the server catch up + or this won't be interesting to watch at all. we call this here + in the hopes of having one whole sequence of dots appear at the + same time (one for each value of x, surprisingly enough) + */ + XSync(dpy, False); + if (delay) usleep(delay); + } +} + +/* + * 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; +} + +/* This parses arguments, initializes the window, etc., and finally starts + * calling munchOnce ad infinitum. + */ +void +screenhack (dpy, w) Display *dpy; Window w; +{ + int logmaxwidth; + int maxwidth; + XWindowAttributes xgwa; + Colormap cmap; + XGCValues gcv; + int n = 0; /* number of squares before we have to clear */ + int randflags; + int thiswidth; + + /* get the dimensions of the window */ + XGetWindowAttributes (dpy, w, &xgwa); + + /* We need a square; limit on screen size? */ + /* we want a power of 2 for the width or the munch doesn't fill up. + */ + logmaxwidth = (int) + dumb_log_2(xgwa.height < xgwa.width ? xgwa.height : xgwa.width); + + maxwidth = 1 << logmaxwidth; + + if (logmaxwidth < logminwidth) { + /* off-by-one error here? Anyone running on < 640x480? */ + fprintf(stderr, "munch: screen too small; use -logminwidth\n"); + fprintf(stderr, "\t(width is %d; log is %d; log must be at least " + "%d)\n", + (xgwa.height < xgwa.width ? xgwa.height : xgwa.width), + logmaxwidth, logminwidth); + exit(0); + } + + /* create the gc */ + cmap = xgwa.colormap; + gcv.foreground= get_pixel_resource("foreground","Foreground", + dpy, cmap); + gcv.background= get_pixel_resource("background","Background", + dpy, cmap); + + gc = XCreateGC(dpy, w, GCForeground|GCBackground, &gcv); + + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + + hold = get_integer_resource ("hold", "Integer"); + if (hold < 0) hold = 0; + + clear = get_integer_resource ("clear", "Integer"); + if (clear < 0) clear = 0; + + logminwidth = get_integer_resource ("logminwidth", "Integer"); + if (logminwidth < 2) logminwidth = 2; + + shiftk = get_boolean_resource("shift", "Boolean"); + + xor = get_boolean_resource("xor", "Boolean"); + + /* always draw xor on mono. */ + if (mono_p || xor) { + XSetFunction(dpy, gc, GXxor); + } + + for(;;) { + /* saves some calls to random. big deal */ + randflags = random(); + + /* choose size -- power of two */ + thiswidth = 1 << (logminwidth + + (random() % (1 + logmaxwidth - logminwidth))); + + munchOnce(dpy, w, + thiswidth, /* Width, in pixels */ + + /* draw at this location */ + (random() % (xgwa.width <= thiswidth ? 1 + : xgwa.width - thiswidth)), + (random() % (xgwa.height <= thiswidth ? 1 + : xgwa.width - thiswidth)), + + /* wrap-around by these values; no need to % + as we end up doing that later anyway*/ + ((shiftk && (randflags & SHIFT_KX)) + ? (random() % thiswidth) : 0), + ((shiftk && (randflags & SHIFT_KT)) + ? (random() % thiswidth) : 0), + ((shiftk && (randflags & SHIFT_KY)) + ? (random() % thiswidth) : 0), + + /* set the gravity of the munch, or rather, + which direction we draw stuff in. */ + (randflags & GRAV) + ); + + if (hold) usleep(hold); + + if (clear && ++n >= clear) { + XClearWindow(dpy, w); + n = 0; + } + } +} diff --git a/hacks/munch.man b/hacks/munch.man new file mode 100644 index 00000000..87721c02 --- /dev/null +++ b/hacks/munch.man @@ -0,0 +1,133 @@ +..de EX \"Begin example +.ne 5 +.if n .sp 1 +.if t .sp .5 +.nf +.in +.5i +.. +.de EE +.fi +.in -.5i +.if n .sp 1 +.if t .sp .5 +.. +.TH XScreenSaver 1 "17-Jun-97" "X Version 11" +.SH NAME +munch - munching squares screen hack +.SH SYNOPSIS +.B deco +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] +[\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] +[\-visual \fIvisual\fP] [\-delay \fIseconds\fP] [\-xor] [\-noxor] [\-shift] +[\-noshift] [\-logminwidth \fIminimum width\fP] +.SH DESCRIPTION +The +.I munch +program preforms the munching squares hack until killed. It picks square +size, position, and gravity randomly; configurable options are listed +below. +.PP +The munching squares hack cosists of drawing Y = X XOR T for a range of X +and T over and over until all the possible combinations of X and T have +come up. It was reportedly discovered by Jackson Wright in 1962 and took 5 +instructions of PDP-6 code. +.SH OPTIONS +.I munch +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fIseconds\fP +How long to wait before starting over. Default 5 seconds. +.TP 8 +.B \-xor +Use the XOR drawing function. (Default.) +.TP 8 +.B \-no\-xor +Don't use the XOR drawing function. +.TP 8 +.B \-shift +Start drawing the square at weird starting points. (Default.) +.TP 8 +.B \-no\-shift +Don't shift and start drawing the square at weird starting points. +.TP 8 +.B \-logminwidth \fIminimum\-width\fP +The logarithm (base 2) of the minimum with of a square (must be a power of +2, or some parts of the square aren't.) +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR http://www.inwap.com/pdp10/hbaker/hakmem/hakmem.html, +.BR http://www.comedia.com/Hot/jargon_3.0/JARGON_M/MUNCHSQR.HTML +.SH HISTORY +Quoted from HAKMEM, for historical interest. As that document says, "Unless +otherwise stated, all computer programs are in PDP-6/10 assembly language." +.TP 8 +ITEM 146: MUNCHING SQUARES +Another simple display program. It is thought that this was discovered by +Jackson Wright on the RLE PDP-1 circa 1962. + +.EX + DATAI 2 + ADDB 1,2 + ROTC 2,-22 + XOR 1,2 + JRST .-4 +.EE +.RS 8 +2=X, 3=Y. Try things like 1001002 in data switches. This also does +interesting things with operations other than XOR, and rotations other +than -22. (Try IOR; AND; TSC; FADR; FDV(!); ROT -14, -9, -20, ...) +.RE +.TP 8 +ITEM 147 (Schroeppel): +Munching squares is just views of the graph Y = X XOR T for consecutive +values of T = time. +.TP 8 +ITEM 148 (Cohen, Beeler): +A modification to munching squares which reveals them in frozen states +through opening and closing curtains: insert FADR 2,1 before the XOR. Try +data switches = + +.EX + 4000,,4 1000,,2002 2000,,4 0,,1002 +.EE +.RS 8 +(Notation: ,,) + +Also try the FADR after the XOR, switches = 1001,,1. +.SH COPYRIGHT +Copyright \(co 1997 by Tim Showalter. 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. +.SH AUTHOR +Tim Showalter , 17-Jun-97, based on what's in the +Jargon File and stealing stuff from existing xscreensaver modules. diff --git a/hacks/noseguy.c b/hacks/noseguy.c new file mode 100644 index 00000000..aa0f1c6c --- /dev/null +++ b/hacks/noseguy.c @@ -0,0 +1,720 @@ +/* xscreensaver, Copyright (c) 1992, 1996, 1997, 1998 + * 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. + */ + +/* Make a little guy with a big nose and a hat wanter around the screen, + spewing out messages. Derived from xnlock by Dan Heller . + */ + +#include "screenhack.h" +#include + +extern FILE *popen (const char *, const char *); +extern int pclose (FILE *); + +#define font_height(font) (font->ascent + font->descent) +#define FONT_NAME "-*-times-*-*-*-*-18-*-*-*-*-*-*-*" + +static Display *dpy; +static Window window; +static int Width, Height; +static GC fg_gc, bg_gc, text_fg_gc, text_bg_gc; +static char *words; +static char *get_words (void); +static int x, y; +static XFontStruct *font; +static char *def_words = "I'm out running around."; +static void walk (int dir); +static void talk (int erase); +static void talk_1 (void); +static int think (void); +static unsigned long interval; +static unsigned long look (void); +static Pixmap left1, left2, right1, right2; +static Pixmap left_front, right_front, front, down; + +static char *program, *orig_program, *filename, *text; + +#define FROM_ARGV 1 +#define FROM_PROGRAM 2 +#define FROM_FILE 3 +#define FROM_RESRC 4 +static int getwordsfrom; + +#define IS_MOVING 1 +#define GET_PASSWD 2 +static int state; /* indicates states: walking or getting passwd */ + +static void (*next_fn) (void); + +#ifdef HAVE_XPM +# include + +# include "images/noseguy/nose-f1.xpm" +# include "images/noseguy/nose-f2.xpm" +# include "images/noseguy/nose-f3.xpm" +# include "images/noseguy/nose-f4.xpm" +# include "images/noseguy/nose-l1.xpm" +# include "images/noseguy/nose-l2.xpm" +# include "images/noseguy/nose-r1.xpm" +# include "images/noseguy/nose-r2.xpm" +#else +# include "images/noseguy/nose-f1.xbm" +# include "images/noseguy/nose-f2.xbm" +# include "images/noseguy/nose-f3.xbm" +# include "images/noseguy/nose-f4.xbm" +# include "images/noseguy/nose-l1.xbm" +# include "images/noseguy/nose-l2.xbm" +# include "images/noseguy/nose-r1.xbm" +# include "images/noseguy/nose-r2.xbm" +#endif + +static void +init_images (void) +{ + static Pixmap *images[] = { + &left1, &left2, &right1, &right2, + &left_front, &right_front, &front, &down + }; + int i; +#ifdef HAVE_XPM + static char **bits[] = { + nose_l1_xpm, nose_l2_xpm, nose_r1_xpm, nose_r2_xpm, + nose_f2_xpm, nose_f3_xpm, nose_f1_xpm, nose_f4_xpm + }; + for (i = 0; i < sizeof (images) / sizeof(*images); i++) + { + XWindowAttributes xgwa; + XpmAttributes xpmattrs; + Pixmap pixmap = 0; + int result; + xpmattrs.valuemask = 0; + + XGetWindowAttributes (dpy, window, &xgwa); + +# ifdef XpmCloseness + xpmattrs.valuemask |= XpmCloseness; + xpmattrs.closeness = 40000; +# endif +# ifdef XpmVisual + xpmattrs.valuemask |= XpmVisual; + xpmattrs.visual = xgwa.visual; +# endif +# ifdef XpmDepth + xpmattrs.valuemask |= XpmDepth; + xpmattrs.depth = xgwa.depth; +# endif +# ifdef XpmColormap + xpmattrs.valuemask |= XpmColormap; + xpmattrs.colormap = xgwa.colormap; +# endif + + result = XpmCreatePixmapFromData(dpy, window, bits[i], + &pixmap, 0 /* mask */, &xpmattrs); + if (!pixmap || (result != XpmSuccess && result != XpmColorError)) + { + fprintf (stderr, "%s: Can't load nose images\n", progname); + exit (1); + } + *images[i] = pixmap; + } +#else + static unsigned char *bits[] = { + nose_l1_bits, nose_l2_bits, nose_r1_bits, nose_r2_bits, + nose_f2_bits, nose_f3_bits, nose_f1_bits, nose_f4_bits + }; + + for (i = 0; i < sizeof (images) / sizeof(*images); i++) + if (!(*images[i] = + XCreatePixmapFromBitmapData(dpy, window, + (char *) bits[i], 64, 64, 1, 0, 1))) + { + fprintf (stderr, "%s: Can't load nose images\n", progname); + exit (1); + } +#endif +} + +#define LEFT 001 +#define RIGHT 002 +#define DOWN 004 +#define UP 010 +#define FRONT 020 +#define X_INCR 3 +#define Y_INCR 2 + +static void +move (void) +{ + static int length, + dir; + + if (!length) + { + register int tries = 0; + dir = 0; + if ((random() & 1) && think()) + { + talk(0); /* sets timeout to itself */ + return; + } + if (!(random() % 3) && (interval = look())) + { + next_fn = move; + return; + } + interval = 20 + random() % 100; + do + { + if (!tries) + length = Width / 100 + random() % 90, tries = 8; + else + tries--; + switch (random() % 8) + { + case 0: + if (x - X_INCR * length >= 5) + dir = LEFT; + break; + case 1: + if (x + X_INCR * length <= Width - 70) + dir = RIGHT; + break; + case 2: + if (y - (Y_INCR * length) >= 5) + dir = UP, interval = 40; + break; + case 3: + if (y + Y_INCR * length <= Height - 70) + dir = DOWN, interval = 20; + break; + case 4: + if (x - X_INCR * length >= 5 && y - (Y_INCR * length) >= 5) + dir = (LEFT | UP); + break; + case 5: + if (x + X_INCR * length <= Width - 70 && + y - Y_INCR * length >= 5) + dir = (RIGHT | UP); + break; + case 6: + if (x - X_INCR * length >= 5 && + y + Y_INCR * length <= Height - 70) + dir = (LEFT | DOWN); + break; + case 7: + if (x + X_INCR * length <= Width - 70 && + y + Y_INCR * length <= Height - 70) + dir = (RIGHT | DOWN); + break; + default: + /* No Defaults */ + break; + } + } while (!dir); + } + walk(dir); + --length; + next_fn = move; +} + +#ifdef HAVE_XPM +# define COPY(dpy,frame,window,gc,x,y,w,h,x2,y2) \ + XCopyArea (dpy,frame,window,gc,x,y,w,h,x2,y2) +#else +# define COPY(dpy,frame,window,gc,x,y,w,h,x2,y2) \ + XCopyPlane(dpy,frame,window,gc,x,y,w,h,x2,y2,1L) +#endif + +static void +walk(int dir) +{ + register int incr = 0; + static int lastdir; + static int up = 1; + static Pixmap frame; + + if (dir & (LEFT | RIGHT)) + { /* left/right movement (mabye up/down too) */ + up = -up; /* bouncing effect (even if hit a wall) */ + if (dir & LEFT) + { + incr = X_INCR; + frame = (up < 0) ? left1 : left2; + } + else + { + incr = -X_INCR; + frame = (up < 0) ? right1 : right2; + } + if ((lastdir == FRONT || lastdir == DOWN) && dir & UP) + { + + /* + * workaround silly bug that leaves screen dust when guy is + * facing forward or down and moves up-left/right. + */ + COPY(dpy, frame, window, fg_gc, 0, 0, 64, 64, x, y); + XFlush(dpy); + } + /* note that maybe neither UP nor DOWN is set! */ + if (dir & UP && y > Y_INCR) + y -= Y_INCR; + else if (dir & DOWN && y < Height - 64) + y += Y_INCR; + } + /* Explicit up/down movement only (no left/right) */ + else if (dir == UP) + COPY(dpy, front, window, fg_gc, 0, 0, 64, 64, x, y -= Y_INCR); + else if (dir == DOWN) + COPY(dpy, down, window, fg_gc, 0, 0, 64, 64, x, y += Y_INCR); + else if (dir == FRONT && frame != front) + { + if (up > 0) + up = -up; + if (lastdir & LEFT) + frame = left_front; + else if (lastdir & RIGHT) + frame = right_front; + else + frame = front; + COPY(dpy, frame, window, fg_gc, 0, 0, 64, 64, x, y); + } + if (dir & LEFT) + while (--incr >= 0) + { + COPY(dpy, frame, window, fg_gc, 0, 0, 64, 64, --x, y + up); + XFlush(dpy); + } + else if (dir & RIGHT) + while (++incr <= 0) + { + COPY(dpy, frame, window, fg_gc, 0, 0, 64, 64, ++x, y + up); + XFlush(dpy); + } + lastdir = dir; +} + +static int +think (void) +{ + if (random() & 1) + walk(FRONT); + if (random() & 1) + { + if (getwordsfrom == FROM_PROGRAM) + words = get_words(); + return 1; + } + return 0; +} + +#define MAXLINES 40 + +static void +talk(int force_erase) +{ + int width = 0, + height, + Z, + total = 0; + static int X, + Y, + talking; + static struct + { + int x, + y, + width, + height; + } s_rect; + register char *p, + *p2; + char buf[BUFSIZ], + args[MAXLINES][256]; + + /* clear what we've written */ + if (talking || force_erase) + { + if (!talking) + return; + XFillRectangle(dpy, window, bg_gc, s_rect.x - 5, s_rect.y - 5, + s_rect.width + 10, s_rect.height + 10); + talking = 0; + if (!force_erase) + next_fn = move; + interval = 0; + { + /* might as well check the window for size changes now... */ + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + Width = xgwa.width + 2; + Height = xgwa.height + 2; + } + return; + } + talking = 1; + walk(FRONT); + p = strcpy(buf, words); + + if (!(p2 = strchr(p, '\n')) || !p2[1]) + { + total = strlen (words); + strcpy (args[0], words); + width = XTextWidth(font, words, total); + height = 0; + } + else + /* p2 now points to the first '\n' */ + for (height = 0; p; height++) + { + int w; + *p2 = 0; + if ((w = XTextWidth(font, p, p2 - p)) > width) + width = w; + total += p2 - p; /* total chars; count to determine reading + * time */ + (void) strcpy(args[height], p); + if (height == MAXLINES - 1) + { + puts("Message too long!"); + break; + } + p = p2 + 1; + if (!(p2 = strchr(p, '\n'))) + break; + } + height++; + + /* + * Figure out the height and width in pixels (height, width) extend the + * new box by 15 pixels on the sides (30 total) top and bottom. + */ + s_rect.width = width + 30; + s_rect.height = height * font_height(font) + 30; + if (x - s_rect.width - 10 < 5) + s_rect.x = 5; + else if ((s_rect.x = x + 32 - (s_rect.width + 15) / 2) + + s_rect.width + 15 > Width - 5) + s_rect.x = Width - 15 - s_rect.width; + if (y - s_rect.height - 10 < 5) + s_rect.y = y + 64 + 5; + else + s_rect.y = y - 5 - s_rect.height; + + XFillRectangle(dpy, window, text_bg_gc, + s_rect.x, s_rect.y, s_rect.width, s_rect.height); + + /* make a box that's 5 pixels thick. Then add a thin box inside it */ + XSetLineAttributes(dpy, text_fg_gc, 5, 0, 0, 0); + XDrawRectangle(dpy, window, text_fg_gc, + s_rect.x, s_rect.y, s_rect.width - 1, s_rect.height - 1); + XSetLineAttributes(dpy, text_fg_gc, 0, 0, 0, 0); + XDrawRectangle(dpy, window, text_fg_gc, + s_rect.x + 7, s_rect.y + 7, s_rect.width - 15, s_rect.height - 15); + + X = 15; + Y = 15 + font_height(font); + + /* now print each string in reverse order (start at bottom of box) */ + for (Z = 0; Z < height; Z++) + { + XDrawString(dpy, window, text_fg_gc, s_rect.x + X, s_rect.y + Y, + args[Z], strlen(args[Z])); + Y += font_height(font); + } + interval = (total / 15) * 1000; + if (interval < 2000) interval = 2000; + next_fn = talk_1; +} + +static void talk_1 (void) +{ + talk(0); +} + + +static unsigned long +look (void) +{ + if (random() % 3) + { + COPY(dpy, (random() & 1) ? down : front, window, fg_gc, + 0, 0, 64, 64, x, y); + return 1000L; + } + if (!(random() % 5)) + return 0; + if (random() % 3) + { + COPY(dpy, (random() & 1) ? left_front : right_front, + window, fg_gc, 0, 0, 64, 64, x, y); + return 1000L; + } + if (!(random() % 5)) + return 0; + COPY(dpy, (random() & 1) ? left1 : right1, window, fg_gc, + 0, 0, 64, 64, x, y); + return 1000L; +} + + +static void +init_words (void) +{ + char *mode = get_string_resource ("mode", "Mode"); + + program = get_string_resource ("program", "Program"); + filename = get_string_resource ("filename", "Filename"); + text = get_string_resource ("text", "Text"); + + if (program) /* get stderr on stdout, so it shows up on the window */ + { + orig_program = program; + program = (char *) malloc (strlen (program) + 10); + strcpy (program, "( "); + strcat (program, orig_program); + strcat (program, " ) 2>&1"); + } + + if (!mode || !strcmp (mode, "program")) + getwordsfrom = FROM_PROGRAM; + else if (!strcmp (mode, "file")) + getwordsfrom = FROM_FILE; + else if (!strcmp (mode, "string")) + getwordsfrom = FROM_RESRC; + else + { + fprintf (stderr, + "%s: mode must be program, file, or string, not %s\n", + progname, mode); + exit (1); + } + + if (getwordsfrom == FROM_PROGRAM && !program) + { + fprintf (stderr, "%s: no program specified.\n", progname); + exit (1); + } + if (getwordsfrom == FROM_FILE && !filename) + { + fprintf (stderr, "%s: no file specified.\n", progname); + exit (1); + } + + words = get_words(); +} + +static int first_time = 1; + +static char * +get_words (void) +{ + FILE *pp; + static char buf[BUFSIZ]; + register char *p = buf; + + buf[0] = '\0'; + + switch (getwordsfrom) + { + case FROM_PROGRAM: +#ifndef VMS + if ((pp = popen(program, "r"))) + { + while (fgets(p, sizeof(buf) - strlen(buf), pp)) + { + if (strlen(buf) + 1 < sizeof(buf)) + p = buf + strlen(buf); + else + break; + } + (void) pclose(pp); + if (! buf[0]) + sprintf (buf, "\"%s\" produced no output!", orig_program); + else if (!first_time && + (strstr (buf, ": not found") || + strstr (buf, ": Not found"))) + switch (random () % 20) + { + case 1: strcat (buf, "( Get with the program, bub. )\n"); + break; + case 2: strcat (buf, + "( I blow my nose at you, you silly person! ) \n"); break; + case 3: strcat (buf, + "\nThe resource you want to\nset is `noseguy.program'\n"); + break; + case 4: + strcat(buf,"\nHelp!! Help!!\nAAAAAAGGGGHHH!! \n\n"); break; + case 5: strcpy (buf, "You have new mail.\n"); break; + case 6: + strcat(buf,"( Hello? Are you paying attention? )\n");break; + case 7: + strcat (buf, "sh: what kind of fool do you take me for? \n"); + break; + } + first_time = 0; + p = buf; + } + else + { + perror(program); + p = def_words; + } + break; +#endif /* VMS */ + case FROM_FILE: + if ((pp = fopen(filename, "r"))) + { + while (fgets(p, sizeof(buf) - strlen(buf), pp)) + { + if (strlen(buf) + 1 < sizeof(buf)) + p = buf + strlen(buf); + else + break; + } + (void) fclose(pp); + if (! buf[0]) + sprintf (buf, "file \"%s\" is empty!", filename); + p = buf; + } + else + { + sprintf (buf, "couldn't read file \"%s\"!", filename); + p = buf; + } + break; + case FROM_RESRC: + p = text; + break; + default: + p = def_words; + break; + } + + if (!p || *p == '\0') + p = def_words; + return p; +} + + + +char *progclass = "Noseguy"; + +char *defaults [] = { + "Noseguy.background: black", /* to placate SGI */ + "Noseguy.foreground: gray80", +#ifndef VMS + "*mode: program", +#else + "*mode: string", +#endif + "*program: " ZIPPY_PROGRAM, + "noseguy.font: -*-new century schoolbook-*-r-*-*-*-180-*-*-*-*-*-*", + 0 +}; + +XrmOptionDescRec options [] = { + { "-mode", ".mode", XrmoptionSepArg, 0 }, + { "-program", ".program", XrmoptionSepArg, 0 }, + { "-text", ".text", XrmoptionSepArg, 0 }, + { "-filename", ".filename", XrmoptionSepArg, 0 }, + { "-font", ".font", XrmoptionSepArg, 0 }, + { "-text-foreground", ".textForeground", XrmoptionSepArg, 0 }, + { "-text-background", ".textBackground", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + + +static void +noseguy_init (Display *d, Window w) +{ + unsigned long fg, bg, text_fg, text_bg; + XWindowAttributes xgwa; + Colormap cmap; + char *fontname = get_string_resource ("font", "Font"); + char **list; + int foo, i; + XGCValues gcvalues; + dpy = d; + window = w; + XGetWindowAttributes (dpy, window, &xgwa); + Width = xgwa.width + 2; + Height = xgwa.height + 2; + cmap = xgwa.colormap; + + init_words(); + init_images(); + + if (!fontname || !(font = XLoadQueryFont(dpy, fontname))) + { + list = XListFonts(dpy, FONT_NAME, 32767, &foo); + for (i = 0; i < foo; i++) + if ((font = XLoadQueryFont(dpy, list[i]))) + break; + if (!font) + { + fprintf (stderr, "%s: Can't find a large font.", progname); + exit (1); + } + XFreeFontNames(list); + } + + fg = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + bg = get_pixel_resource ("background", "Background", dpy, cmap); + text_fg = get_pixel_resource ("textForeground", "Foreground", dpy, cmap); + text_bg = get_pixel_resource ("textBackground", "Background", dpy, cmap); + /* notice when unspecified */ + if (! get_string_resource ("textForeground", "Foreground")) + text_fg = bg; + if (! get_string_resource ("textBackground", "Background")) + text_bg = fg; + + gcvalues.font = font->fid; + gcvalues.graphics_exposures = False; + gcvalues.foreground = fg; + gcvalues.background = bg; + fg_gc = XCreateGC (dpy, window, + GCForeground|GCBackground|GCGraphicsExposures|GCFont, + &gcvalues); + gcvalues.foreground = bg; + gcvalues.background = fg; + bg_gc = XCreateGC (dpy, window, + GCForeground|GCBackground|GCGraphicsExposures|GCFont, + &gcvalues); + gcvalues.foreground = text_fg; + gcvalues.background = text_bg; + text_fg_gc = XCreateGC (dpy, window, + GCForeground|GCBackground|GCGraphicsExposures|GCFont, + &gcvalues); + gcvalues.foreground = text_bg; + gcvalues.background = text_fg; + text_bg_gc = XCreateGC (dpy, window, + GCForeground|GCBackground|GCGraphicsExposures|GCFont, + &gcvalues); + x = Width / 2; + y = Height / 2; + state = IS_MOVING; +} + +void +screenhack (Display *d, Window w) +{ + noseguy_init (d, w); + next_fn = move; + while (1) + { + next_fn(); + XSync (dpy, True); + usleep (interval * 1000); + } +} + diff --git a/hacks/noseguy.man b/hacks/noseguy.man new file mode 100644 index 00000000..fe18d8df --- /dev/null +++ b/hacks/noseguy.man @@ -0,0 +1,74 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +noseguy - a little guy with a big nose wanders around being witty +.SH SYNOPSIS +.B noseguy +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-text-foreground \fIcolor\fP] [\-text-background \fIcolor\fP] [\-font \fIfont\fP] [\-window] [\-root] [\-install] [\-visual \fIvisual\fP] [\-mode \fImode\fP] [\-program \fIprogram\fP] [\-filename \file\fP] [\-text \fItext\fP] +.SH DESCRIPTION +A little man with a big nose and a hat runs around spewing out messages to +the screen. This code (and its bitmaps) were extracted from the \fIxnlock\fP +program. +.SH OPTIONS +.I noseguy +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-font \fIfont\fP +The font used for the messages. +.TP 8 +.B \-mode [ program | file | string ] +In \fIprogram\fP mode, the messages are gotten by running a program. +The program used is controlled by the \fI\-program\fP option, and +the \fI.program\fP resource. + +In \fIfilename\fP mode, the message used is the contents of a file. +The file used is controlled by the \fI\-file\fP option, and +the \fI.filename\fP resource. + +In \fIstring\fP mode, the message is whatever was specified on the +command line as the \fI\-text\fP option, or in the resource database +as the \fI.text\fP resource. +.TP 8 +.B \-program \fIprogram\fP +If \fImode\fP is \fIprogram\fP (the default), then this program will be +run periodically, and its output will be the text of the messages. The +default program is \fI"fortune -s"\fP, but \fIyow\fP is also a good choice. +.TP 8 +.B \-filename \fIfile\fP +If \fImode\fP is \fIfile\fP, then the contents of this file will be used +for all messages. +.TP 8 +.B \-text \fIstring\fP +If \fImode\fP is \fIstring\fP, then this text will be used for all messages. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xnlock (1) +.SH COPYRIGHT +Copyright 1985, 1990 by Dan Heller . +.SH AUTHOR +Dan Heller , 1985. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 13-aug-92. diff --git a/hacks/pedal.c b/hacks/pedal.c new file mode 100644 index 00000000..ab9dccb0 --- /dev/null +++ b/hacks/pedal.c @@ -0,0 +1,380 @@ +/* + * pedal + * + * Based on a program for some old PDP-11 Graphics Display Processors + * at CMU. + * + * X version by + * + * Dale Moore + * 24-Jun-1994 + * + * Copyright (c) 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. + */ + +#include +#include +#include "screenhack.h" + +/* 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) +#define MAXPOINTS MAXLINES +XPoint *points; + +/* + * If the pedal has only this many lines, it must be ugly and we dont + * want to see it. + */ +#define MINLINES 7 + +static int sizex, sizey; +static int delay; +static int fadedelay; +static int maxlines; +static GC gc; +static XColor foreground, background; +static Colormap cmap; + +static Bool fade_p; + + +/* + * Routine (Macro actually) + * mysin + * 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 mysin(t, degrees) sin(t * 2 * M_PI / (degrees)) +#define mycos(t, degrees) cos(t * 2 * M_PI / (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 + random() % (b - a)) + + +static int +gcd(int m, int n) /* Greatest Common Divisor (also Greates 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_pedal(XPoint *points, int maxpoints) +/* + * 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 pedal */ + + double r; + int theta = 0; + XPoint *pp = points; + int count; + int numpoints; + + /* Just to make sure that this division is not done inside the loop */ + int h_width = sizex / 2, h_height = sizey / 2 ; + + for (;;) { + d = rand_range (MINLINES, maxlines); + + a = rand_range (1, d); + b = rand_range (1, d); + numpoints = numlines(a, b, d); + if (numpoints > 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 = numpoints; count-- ; ) + { + r = mysin (theta * a, d); + + /* Convert from polar to cartesian coordinates */ + /* We could round the results, but coercing seems just fine */ + pp->x = mysin (theta, d) * r * h_width + h_width; + pp->y = mycos (theta, d) * r * h_height + h_height; + + /* Advance index into array */ + pp++; + + /* Advance theta */ + theta += b; + theta %= d; + } + + return(numpoints); +} + +static void +init_pedal (Display *dpy, Window window) +{ + XGCValues gcv; + XWindowAttributes xgwa; + + fade_p = !mono_p; + + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + + fadedelay = get_integer_resource ("fadedelay", "Integer"); + if (fadedelay < 0) fadedelay = 0; + + maxlines = get_integer_resource ("maxlines", "Integer"); + if (maxlines < MINLINES) maxlines = MINLINES; + else if (maxlines > MAXLINES) maxlines = MAXLINES; + + points = (XPoint *)malloc(sizeof(XPoint) * maxlines); + + XGetWindowAttributes (dpy, window, &xgwa); + sizex = xgwa.width; + sizey = xgwa.height; + + if ((xgwa.visual->class != GrayScale) && (xgwa.visual->class != PseudoColor)) + fade_p = False; + + cmap = xgwa.colormap; + + gcv.function = GXcopy; + gcv.foreground = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + gcv.background = get_pixel_resource ("background", "Background", dpy, cmap); + gc = XCreateGC (dpy, window, GCForeground | GCBackground |GCFunction, &gcv); + + if (fade_p) + { + int status; + foreground.pixel = gcv.foreground; + XQueryColor (dpy, cmap, &foreground); + + status = XAllocColorCells ( + dpy, + cmap, + 0, + NULL, + 0, + &foreground.pixel, + 1); + if (status) + { + XStoreColor ( dpy, cmap, &foreground); + XSetForeground (dpy, gc, foreground.pixel); + + background.pixel = gcv.background; + XQueryColor (dpy, cmap, &background); + } + else + { + /* If we cant allocate a color cell, then just forget the + * whole fade business. + */ + fade_p = False; + } + } +} + +static void +fade_foreground (Display *dpy, Colormap cmap, + XColor from, XColor to, int steps) +/* + * This routine assumes that we have a writeable colormap. + * That means that the default colormap is not full, and that + * the visual class is PseudoColor or GrayScale. + */ +{ + int i; + XColor inbetween; + int udelay = fadedelay / (steps + 1); + + inbetween = foreground; + for (i = 0; i <= steps; i++ ) + { + inbetween.red = from.red + (to.red - from.red) * i / steps ; + inbetween.green = from.green + (to.green - from.green) * i / steps ; + inbetween.blue = from.blue + (to.blue - from.blue) * i / steps ; + XStoreColor (dpy, cmap, &inbetween); + /* If we don't sync, these can bunch up */ + XSync(dpy, 0); + usleep(udelay); + } +} + +static void +pedal (Display *dpy, Window window) +/* + * Since the XFillPolygon doesn't require that the last + * point == first point, the number of points is the same + * as the number of lines. We just let XFillPolygon supply + * the line from the last point to the first point. + * + */ +{ + int numpoints; + + numpoints = compute_pedal(points, maxlines); + + /* Fade out, make foreground the same as background */ + if (fade_p) + fade_foreground (dpy, cmap, foreground, background, 32); + + /* Clear the window of previous garbage */ + XClearWindow (dpy, window); + + XFillPolygon ( + dpy, + window, + gc, + points, + numpoints, + Complex, + CoordModeOrigin); + + /* Pick a new foreground color (added by jwz) */ + if (! mono_p) + { + XColor color; + hsv_to_rgb (random()%360, 1.0, 1.0, + &color.red, &color.green, &color.blue); + XSync(dpy, 0); + if (fade_p) + { + foreground.red = color.red; + foreground.green = color.green; + foreground.blue = color.blue; + /* don't do this here -- let fade_foreground() bring it up! */ + /* XStoreColor (dpy, cmap, &foreground); */ + } + else if (XAllocColor (dpy, cmap, &color)) + { + XSetForeground (dpy, gc, color.pixel); + XFreeColors (dpy, cmap, &foreground.pixel, 1, 0); + foreground.red = color.red; + foreground.green = color.green; + foreground.blue = color.blue; + foreground.pixel = color.pixel; + } + XSync(dpy, 0); + } + + /* Fade in by bringing the foreground back from background */ + if (fade_p) + fade_foreground (dpy, cmap, background, foreground, 32); +} + + +char *progclass = "Pedal"; + +/* + * If we are trying to save the screen, the background + * should be dark. + */ +char *defaults [] = { + "Pedal.background: black", /* to placate SGI */ + "Pedal.foreground: white", + "*delay: 5", + "*fadedelay: 200000", + "*maxlines: 1000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-fadedelay", ".fadedelay", XrmoptionSepArg, 0 }, + { "-maxlines", ".maxlines", XrmoptionSepArg, 0 }, + { "-foreground", ".foreground", XrmoptionSepArg, 0 }, + { "-background", ".background", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_pedal (dpy, window); + for (;;) { + pedal (dpy, window); + XSync(dpy, 0); + if (delay) sleep (delay); + } +} diff --git a/hacks/pedal.man b/hacks/pedal.man new file mode 100644 index 00000000..7a0c3e5b --- /dev/null +++ b/hacks/pedal.man @@ -0,0 +1,62 @@ +.TH XScreenSaver 1 "24-Jun-94" "X Version 11" +.SH NAME +pedal - pretty geometric picture program +.SH SYNOPSIS +.B pedal +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-delay \fIseconds\fP] [-maxlines \fInumber\fP] [-fadedelay \fIuseconds\fP] [-mono] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIpedal\fP program displays pretty geometric pictures. +.SH OPTIONS +.I pedal +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-foreground \fIcolor\fP +The color for the foreground. Default is white. +.TP 8 +.B \-background \fIcolor\fP +The color for the background. Default is black. +.TP 8 +.B \-delay \fIseconds\fP +The number of seconds to pause between each picture. +.TP 8 +.B \-maxlines \fInumber\fP +The maximum number of lines in the drawing. Good values are +between 20 and 2000. Maximum value is 16K. +.TP 8 +.B \-fadedelay \fImicroseconds\fP +The number of micro seconds to take when fading in and out. +.TP 8 +.B \-mono +Don't do fading. Pretend we're on a monochrome display. +.PP +To make your X server grunt under load, and to impress your +friends, try \fIpedal -mono -delay 0 -maxlines 100\fp. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH 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. +.SH AUTHOR +Dale Moore , 24-Jun-1994. diff --git a/hacks/penrose.c b/hacks/penrose.c new file mode 100644 index 00000000..6454e283 --- /dev/null +++ b/hacks/penrose.c @@ -0,0 +1,1285 @@ +/* -*- Mode: C; tab-width: 4 -*- + * penrose --- quasiperiodic tilings. + */ + +/* As reported in News of the Weird: + + In April, Sir Roger Penrose, a British math professor who has worked + with Stephen Hawking on such topics as relativity, black holes, and + whether time has a beginning, filed a copyright-infringement lawsuit + against the Kimberly-Clark Corporation, which Penrose said copied a + pattern he created (a pattern demonstrating that "a nonrepeating + pattern could exist in nature") for its Kleenex quilted toilet paper. + Penrose said he doesn't like litigation but, "When it comes to the + population of Great Britain being invited by a multinational to wipe + their bottoms on what appears to be the work of a Knight of the + Realm, then a last stand must be taken." + + NOTW #491, 4-jul-1997, by Chuck Shepherd. + http://www.nine.org/notw/notw.html + */ + + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)penrose.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1996 by Timo Korvola + * + * 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@netscape.com: turned into a standalone program. + * 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" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + + +/*- + * 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 31415927 /* This causes a pause, an error occurred. */ +#define COMPLETION 3141593 /* This causes a pause, an error occurred. */ + +#define MAX_TILES_PER_VERTEX 7 +#define N_VERTEX_RULES 8 +#define ALLOC_NODE( type) ((type *)malloc( sizeof( type))) +#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 = { 2, opts, 1, vars, desc }; + + +/*- + * 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; + int thick_color, thin_color; +} 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_WIN_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]); + } + MI_PAUSE(mi) = 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 XPoint +fived_to_loc(int fived[], tiling_c * tp) +{ + static fcoord_c fived_table[5] = + { + {.0, .0}}; + float fifth = 8 * atan(1.) / 5; + register int i; + register float r; + register fcoord_c offset = + {.0, .0}; + XPoint pt = tp->origin; + + 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); + return pt; +} + + +/* 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((char *) fp2); + } while (fp1 != tp->fringe.nodes); + tp->fringe.nodes = 0; + for (lp1 = tp->forced.first; lp1 != 0;) { + lp2 = lp1; + lp1 = lp1->next; + (void) free((char *) 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)]; + tp->done = False; + tp->failures = 0; + tp->width = MI_WIN_WIDTH(mi); + tp->height = MI_WIN_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_WIN_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_WIN_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_WIN_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; + fp->loc = fived_to_loc(fp->fived, tp); + /* 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_WIN_WHITE_PIXEL(mi)); + XFillPolygon(display, window, gc, pts, 4, Convex, CoordModeOrigin); + XSetForeground(display, gc, MI_WIN_BLACK_PIXEL(mi)); + XDrawLines(display, window, gc, pts, 5, CoordModeOrigin); + + if (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_WIN_WHITE_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_WIN_WHITE_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 MI_PAUSE 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_WIN_IS_VERBOSE(mi)) { + (void) fprintf(stderr, "Dislocation occured!\n"); + } + MI_PAUSE(mi) = 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; + free(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_WIN_IS_VERBOSE(mi)) { + (void) fprintf(stderr, "Weirdness in delete_penrose()\n"); + (void) fprintf(stderr, "tp->fringe.nodes == vertex\n"); + } + MI_PAUSE(mi) = 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; + free(node); + tp->forced.n_nodes--; + if (!vertex->off_screen) + tp->forced.n_visible--; + } + if (!vertex->off_screen) + tp->fringe.n_nodes--; + free(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_WIN_IS_VERBOSE(mi)) { + (void) fprintf(stderr, "Weirdness in alloc_vertex()\n"); + (void) fprintf(stderr, "v = 0\n"); + } + MI_PAUSE(mi) = CELEBRATE; + } + *v = *from; + add_unit_vec(dir, v->fived); + v->loc = fived_to_loc(v->fived, tp); + 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_WIN_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_WIN_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_WIN_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_WIN_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_WIN_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_WIN_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_WIN_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; + + 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 = VT_TOTAL_MASK & LRAND(); + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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; + MI_PAUSE(mi) = 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 *p = tp->fringe.nodes; + + n = NRAND(tp->fringe.n_nodes); + i = 0; + for (; i <= n; i++) + do { + p = p->next; + } while (p->off_screen); + add_random_tile(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; + } +} diff --git a/hacks/penrose.man b/hacks/penrose.man new file mode 100644 index 00000000..7460e39e --- /dev/null +++ b/hacks/penrose.man @@ -0,0 +1,93 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +penrose - draws quasiperiodic tilings +.SH SYNOPSIS +.B penrose +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-size \fIinteger\fP] [\-ammann] [\-no\-ammann] + +.SH DESCRIPTION +The \fIpenrose\fP program draws quasiperiodic tilings. + +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. + +.SH OPTIONS +.I penrose +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.TP 8 +.B \-size \fIinteger\fP +How big the tiles should be. Default 40 pixels. + +.TP 8 +.B \-ammann \fIinteger\fP +.TP 8 +.B \-no\-ammann \fIinteger\fP +Whether Ammann lines should be added. + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1996 by Timo Korvola. + +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. +.SH AUTHOR +Timo Korvola , 1996. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/puzzle.c b/hacks/puzzle.c new file mode 100644 index 00000000..f3647c4b --- /dev/null +++ b/hacks/puzzle.c @@ -0,0 +1,579 @@ +/* xscreensaver, Copyright (c) 1997, 1998 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. + */ + +/* + TODO: + + = Rather than just flickering the pieces before swapping them, + show them lifting up and moving to their new positions. + The path on which they move shouldn't be a straight line; + try to avoid having them cross each other by moving them in + oppositely-positioned arcs. + + = Rotate the pieces as well, so that we can swap the corner + and edge pieces with each other. + + = The shapes of the piece bitmaps still aren't quite right. + They should line up with no overlap. They don't... + + = Have it drop all pieces to the "floor" then pick them up to + reassemble the picture. + + = As a joke, maybe sometimes have one piece that doesn't fit? + Or lose a piece? + */ + +#include "screenhack.h" + +#define DEBUG + +#include "images/puzzle/puzzle_a_h.xbm" +#include "images/puzzle/puzzle_a_n_h.xbm" +#include "images/puzzle/puzzle_a_ne_h.xbm" +#include "images/puzzle/puzzle_a_e_h.xbm" +#include "images/puzzle/puzzle_a_se_h.xbm" +#include "images/puzzle/puzzle_a_s_h.xbm" +#include "images/puzzle/puzzle_a_sw_h.xbm" +#include "images/puzzle/puzzle_a_w_h.xbm" +#include "images/puzzle/puzzle_a_nw_h.xbm" + +#include "images/puzzle/puzzle_b_h.xbm" +#include "images/puzzle/puzzle_b_n_h.xbm" +#include "images/puzzle/puzzle_b_ne_h.xbm" +#include "images/puzzle/puzzle_b_e_h.xbm" +#include "images/puzzle/puzzle_b_se_h.xbm" +#include "images/puzzle/puzzle_b_s_h.xbm" +#include "images/puzzle/puzzle_b_sw_h.xbm" +#include "images/puzzle/puzzle_b_w_h.xbm" +#include "images/puzzle/puzzle_b_nw_h.xbm" + +#include "images/puzzle/puzzle_a_f.xbm" +#include "images/puzzle/puzzle_a_n_f.xbm" +#include "images/puzzle/puzzle_a_ne_f.xbm" +#include "images/puzzle/puzzle_a_e_f.xbm" +#include "images/puzzle/puzzle_a_se_f.xbm" +#include "images/puzzle/puzzle_a_s_f.xbm" +#include "images/puzzle/puzzle_a_sw_f.xbm" +#include "images/puzzle/puzzle_a_w_f.xbm" +#include "images/puzzle/puzzle_a_nw_f.xbm" + +#include "images/puzzle/puzzle_b_f.xbm" +#include "images/puzzle/puzzle_b_n_f.xbm" +#include "images/puzzle/puzzle_b_ne_f.xbm" +#include "images/puzzle/puzzle_b_e_f.xbm" +#include "images/puzzle/puzzle_b_se_f.xbm" +#include "images/puzzle/puzzle_b_s_f.xbm" +#include "images/puzzle/puzzle_b_sw_f.xbm" +#include "images/puzzle/puzzle_b_w_f.xbm" +#include "images/puzzle/puzzle_b_nw_f.xbm" + +#define GRID_WIDTH 66 +#define GRID_HEIGHT 66 + +#define CENTER 0 +#define NORTH 1 +#define NORTHEAST 2 +#define EAST 3 +#define SOUTHEAST 4 +#define SOUTH 5 +#define SOUTHWEST 6 +#define WEST 7 +#define NORTHWEST 8 + +struct piece { + int width, height; + int x, y; + Pixmap pixmap; +}; + +struct set { + struct piece pieces[9]; +}; + +#define PIECE_A_HOLLOW 0 +#define PIECE_A_FILLED 1 +#define PIECE_B_HOLLOW 2 +#define PIECE_B_FILLED 3 + +static struct set all_pieces[4]; + +static void +init_images(Display *dpy, Window window) +{ +# define LOAD_PIECE(PIECE,NAME) \ + PIECE.x = puzzle_##NAME##_x_hot; \ + PIECE.y = puzzle_##NAME##_y_hot; \ + PIECE.pixmap = \ + XCreatePixmapFromBitmapData(dpy, window, \ + (char *) puzzle_##NAME##_bits, \ + puzzle_##NAME##_width, \ + puzzle_##NAME##_height, \ + 1, 0, 1) + +# define LOAD_PIECES(SET,PREFIX,SUFFIX) \ + LOAD_PIECE(SET.pieces[CENTER], PREFIX##_##SUFFIX); \ + LOAD_PIECE(SET.pieces[NORTH], PREFIX##_n_##SUFFIX); \ + LOAD_PIECE(SET.pieces[NORTHEAST], PREFIX##_ne_##SUFFIX); \ + LOAD_PIECE(SET.pieces[EAST], PREFIX##_e_##SUFFIX); \ + LOAD_PIECE(SET.pieces[SOUTHEAST], PREFIX##_se_##SUFFIX); \ + LOAD_PIECE(SET.pieces[SOUTH], PREFIX##_s_##SUFFIX); \ + LOAD_PIECE(SET.pieces[SOUTHWEST], PREFIX##_sw_##SUFFIX); \ + LOAD_PIECE(SET.pieces[WEST], PREFIX##_w_##SUFFIX); \ + LOAD_PIECE(SET.pieces[NORTHWEST], PREFIX##_nw_##SUFFIX) + + LOAD_PIECES(all_pieces[PIECE_A_HOLLOW],a,h); + LOAD_PIECES(all_pieces[PIECE_A_FILLED],a,f); + LOAD_PIECES(all_pieces[PIECE_B_HOLLOW],b,h); + LOAD_PIECES(all_pieces[PIECE_B_FILLED],b,f); + +# undef LOAD_PIECE +# undef LOAD_PIECES +} + +static Pixmap +read_screen (Display *dpy, Window window, int *widthP, int *heightP) +{ + Pixmap p; + XWindowAttributes xgwa; + XGCValues gcv; + GC gc; + XGetWindowAttributes (dpy, window, &xgwa); + *widthP = xgwa.width; + *heightP = xgwa.height; + + XClearWindow(dpy, window); + grab_screen_image(xgwa.screen, window); + p = XCreatePixmap(dpy, window, *widthP, *heightP, xgwa.depth); + gcv.function = GXcopy; + gc = XCreateGC (dpy, window, GCFunction, &gcv); + XCopyArea (dpy, window, p, gc, 0, 0, *widthP, *heightP, 0, 0); + + XFreeGC (dpy, gc); + + return p; +} + + +static int width, height; +static int x_border, y_border; +static Pixmap source; +static GC gc; +static Bool tweak; +static int fg, bg; +static XPoint *state = 0; + +static void +puzzle_init(Display *dpy, Window window) +{ + XWindowAttributes xgwa; + int x, y; + XGCValues gcv; + Colormap cmap; + int source_w, source_h; + + tweak = random()&1; + + source = read_screen (dpy, window, &source_w, &source_h); + + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + width = xgwa.width / GRID_WIDTH; + height = xgwa.height / GRID_HEIGHT; + x_border = (xgwa.width - (width * GRID_WIDTH)) / 2; + y_border = (xgwa.height - (height * GRID_WIDTH)) / 2; + + if (!state) + state = (XPoint *) malloc(width * height * sizeof(XPoint)); + gc = XCreateGC (dpy, window, 0, &gcv); + + { + XColor fgc, bgc; + char *fgs = get_string_resource("foreground", "Foreground"); + char *bgs = get_string_resource("background", "Background"); + Bool fg_ok, bg_ok; + if (!XParseColor (dpy, cmap, fgs, &fgc)) + XParseColor (dpy, cmap, "gray", &fgc); + if (!XParseColor (dpy, cmap, bgs, &bgc)) + XParseColor (dpy, cmap, "black", &bgc); + + fg_ok = XAllocColor (dpy, cmap, &fgc); + bg_ok = XAllocColor (dpy, cmap, &bgc); + + /* If we weren't able to allocate the two colors we want from the + colormap (which is likely if the screen has been grabbed on an + 8-bit SGI visual -- don't ask) then just go through the map + and find the closest color to the ones we wanted, and use those + pixels without actually allocating them. + */ + if (fg_ok) + fg = fgc.pixel; + else + fg = 0; + + if (bg_ok) + bg = bgc.pixel; + else + bg = 1; + + if (!fg_ok || bg_ok) + { + int i; + unsigned long fgd = ~0; + unsigned long bgd = ~0; + int max = visual_cells (xgwa.screen, xgwa.visual); + XColor *all = (XColor *) calloc(sizeof (*all), max); + for (i = 0; i < max; i++) + { + all[i].flags = DoRed|DoGreen|DoBlue; + all[i].pixel = i; + } + XQueryColors (dpy, cmap, all, max); + for(i = 0; i < max; i++) + { + long rd, gd, bd; + unsigned long d; + if (!fg_ok) + { + rd = (all[i].red >> 8) - (fgc.red >> 8); + gd = (all[i].green >> 8) - (fgc.green >> 8); + bd = (all[i].blue >> 8) - (fgc.blue >> 8); + if (rd < 0) rd = -rd; + if (gd < 0) gd = -gd; + if (bd < 0) bd = -bd; + d = (rd << 1) + (gd << 2) + bd; + if (d < fgd) + { + fgd = d; + fg = all[i].pixel; + if (d == 0) + fg_ok = True; + } + } + + if (!bg_ok) + { + rd = (all[i].red >> 8) - (bgc.red >> 8); + gd = (all[i].green >> 8) - (bgc.green >> 8); + bd = (all[i].blue >> 8) - (bgc.blue >> 8); + if (rd < 0) rd = -rd; + if (gd < 0) gd = -gd; + if (bd < 0) bd = -bd; + d = (rd << 1) + (gd << 2) + bd; + if (d < bgd) + { + bgd = d; + bg = all[i].pixel; + if (d == 0) + bg_ok = True; + } + } + + if (fg_ok && bg_ok) + break; + } + XFree(all); + } + } + + /* Reset the window's background color... */ + XSetWindowBackground (dpy, window, bg); + XClearWindow(dpy, window); + + for (y = 0; y < height; y++) + for (x = 0; x < width; x++) + { + state[y * width + x].x = x; + state[y * width + x].y = y; + } +} + + +static void +get_piece(int x, int y, struct piece **hollow, struct piece **filled) +{ + int p; + Bool which = (x & 1) == (y & 1); + + if (x == 0 && y == 0) p = NORTHWEST; + else if (x == width-1 && y == 0) p = NORTHEAST; + else if (x == width-1 && y == height-1) p = SOUTHEAST; + else if (x == 0 && y == height-1) p = SOUTHWEST; + else if (y == 0) p = NORTH; + else if (x == width-1) p = EAST; + else if (y == height-1) p = SOUTH; + else if (x == 0) p = WEST; + else p = CENTER; + + if (tweak) which = !which; + if (hollow) + *hollow = (which + ? &all_pieces[PIECE_A_HOLLOW].pieces[p] + : &all_pieces[PIECE_B_HOLLOW].pieces[p]); + if (filled) + *filled = (which + ? &all_pieces[PIECE_A_FILLED].pieces[p] + : &all_pieces[PIECE_B_FILLED].pieces[p]); +} + + +static void +draw_piece(Display *dpy, Window window, int x, int y, int clear_p) +{ + struct piece *hollow, *filled; + int from_x = state[y * width + x].x; + int from_y = state[y * width + x].y; + + get_piece(x, y, &hollow, &filled); + + XSetClipMask(dpy, gc, filled->pixmap); + XSetClipOrigin(dpy, gc, + x_border + (x * GRID_WIDTH) - filled->x - 1, + y_border + (y * GRID_WIDTH) - filled->y - 1); + + if (clear_p) + { + XSetForeground(dpy, gc, bg); + XFillRectangle(dpy, window, gc, + x_border + (x * GRID_WIDTH) - GRID_WIDTH/2, + y_border + (y * GRID_HEIGHT) - GRID_HEIGHT/2, + GRID_WIDTH*2, GRID_HEIGHT*2); + } + else + XCopyArea(dpy, source, window, gc, + x_border + (from_x * GRID_WIDTH) - GRID_WIDTH/2, + y_border + (from_y * GRID_HEIGHT) - GRID_HEIGHT/2, + GRID_WIDTH*2, GRID_HEIGHT*2, + x_border + (x * GRID_WIDTH) - GRID_WIDTH/2, + y_border + (y * GRID_HEIGHT) - GRID_HEIGHT/2); + + if (clear_p > 1) + return; + + XSetForeground(dpy, gc, fg); + XSetClipMask(dpy, gc, hollow->pixmap); + XSetClipOrigin(dpy, gc, + x_border + (x * GRID_WIDTH) - hollow->x - 1, + y_border + (y * GRID_WIDTH) - hollow->y - 1); + XFillRectangle(dpy, window, gc, + x_border + (x * GRID_WIDTH) - GRID_WIDTH/2, + y_border + (y * GRID_HEIGHT) - GRID_HEIGHT/2, + GRID_WIDTH*2, GRID_HEIGHT*2); + + if (clear_p) + { + /* If the pieces lined up right, we could do this by just not drawing + the outline -- but that doesn't look right, since it eats the outlines + of the adjascent pieces. So draw the outline, then chop off the outer + edge if this is a border piece. + */ + XSetForeground(dpy, gc, bg); + if (x == 0) + XFillRectangle(dpy, window, gc, + x_border - 2, + y_border + (y * GRID_HEIGHT), + 3, GRID_HEIGHT); + else if (x == width-1) + XFillRectangle(dpy, window, gc, + x_border + ((x+1) * GRID_WIDTH) - 2, + y_border + (y * GRID_HEIGHT), + 3, GRID_HEIGHT); + + if (y == 0) + XFillRectangle(dpy, window, gc, + x_border + (x * GRID_WIDTH), + y_border - 2, + GRID_WIDTH, 3); + else if (y == height-1) + XFillRectangle(dpy, window, gc, + x_border + (x * GRID_WIDTH), + y_border + ((y+1) * GRID_HEIGHT) - 2, + GRID_WIDTH, 3); + } +} + + +static void +swap_pieces(Display *dpy, Window window, + int src_x, int src_y, int dst_x, int dst_y, + Bool draw_p) +{ + XPoint swap; + int i; + if (draw_p) + for (i = 0; i < 3; i++) + { + draw_piece(dpy, window, src_x, src_y, 1); + draw_piece(dpy, window, dst_x, dst_y, 1); + XSync(dpy, False); + usleep(50000); + draw_piece(dpy, window, src_x, src_y, 0); + draw_piece(dpy, window, dst_x, dst_y, 0); + XSync(dpy, False); + usleep(50000); + } + + swap = state[src_y * width + src_x]; + state[src_y * width + src_x] = state[dst_y * width + dst_x]; + state[dst_y * width + dst_x] = swap; + + if (draw_p) + { + draw_piece(dpy, window, src_x, src_y, 0); + draw_piece(dpy, window, dst_x, dst_y, 0); + XSync(dpy, False); + } +} + + +static void +shuffle(Display *dpy, Window window, Bool draw_p) +{ + struct piece *p1, *p2; + int src_x, src_y, dst_x = -1, dst_y = -1; + + AGAIN: + p1 = p2 = 0; + src_x = random() % width; + src_y = random() % height; + + get_piece(src_x, src_y, &p1, 0); + + /* Pick random coordinates until we find one that has the same kind of + piece as the first one we picked. Note that it's possible for there + to be only one piece of a particular shape on the board (this commonly + happens with the corner pieces.) + */ + while (p1 != p2) + { + dst_x = random() % width; + dst_y = random() % height; + get_piece(dst_x, dst_y, &p2, 0); + } + + if (src_x == dst_x && src_y == dst_y) + goto AGAIN; + + swap_pieces(dpy, window, src_x, src_y, dst_x, dst_y, draw_p); +} + + +static void +shuffle_all(Display *dpy, Window window) +{ + int i = (width * height * 10); + while (i > 0) + { + shuffle(dpy, window, False); + i--; + } +} + +static void +unshuffle(Display *dpy, Window window) +{ + int i; + for (i = 0; i < width * height * 4; i++) + { + int x = random() % width; + int y = random() % height; + int x2 = state[y * width + x].x; + int y2 = state[y * width + x].y; + if (x != x2 || y != y2) + { + swap_pieces(dpy, window, x, y, x2, y2, True); + break; + } + } +} + +static void +clear_all(Display *dpy, Window window) +{ + int n = width * height; + while (n > 0) + { + int x = random() % width; + int y = random() % height; + XPoint *p = &state[y * width + x]; + if (p->x == -1) + continue; + draw_piece(dpy, window, p->x, p->y, 2); + XSync(dpy, False); + usleep(1000); + p->x = p->y = -1; + n--; + } +} + +static Bool +done(void) +{ + int x, y; + for (y = 0; y < height; y++) + for (x = 0; x < width; x++) + { + int x2 = state[y * width + x].x; + int y2 = state[y * width + x].y; + if (x != x2 || y != y2) + return False; + } + return True; +} + + + +char *progclass = "Puzzle"; + +char *defaults [] = { + "Puzzle.background: Black", /* to placate SGI */ + "Puzzle.foreground: Gray40", + "*delay: 70000", + "*delay2: 5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + int delay = get_integer_resource("delay", "Integer"); + int delay2 = get_integer_resource("delay2", "Integer"); + + init_images(dpy, window); + + while (1) + { + int x, y; + puzzle_init (dpy, window); + shuffle_all(dpy, window); + + for (y = 0; y < height; y++) + for (x = 0; x < width; x++) + draw_piece(dpy, window, x, y, 0); + + while (!done()) + { + unshuffle(dpy, window); + XSync (dpy, True); + if (delay) usleep (delay); + } + + if (delay2) + usleep (delay2 * 1000000); + + clear_all(dpy, window); + } +} diff --git a/hacks/puzzle.man b/hacks/puzzle.man new file mode 100644 index 00000000..7e95a2df --- /dev/null +++ b/hacks/puzzle.man @@ -0,0 +1,74 @@ +.TH XScreenSaver 1 "25-Nov-97" "X Version 11" +.SH NAME +puzzle - permute the screen image like a jigsaw puzzle +.SH SYNOPSIS +.B puzzle +[\-display \fIhost:display.screen\fP] [\-background \fIcolor\fP] [\-delay \fIusecs\fP] [\-window] [\-root] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIpuzzle\fP program takes an image of the screen, carves it up into +a crossword puzzle, shuffles it, and then solves it. +.SH OPTIONS +.I puzzle +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fImicroseconds\fP +How long to wait between shuffling pieces; default 700000, or 0.7 seconds. +.SH RESOURCES +On some systems (currently, only SGIs), this program can, instead of grabbing +a desktop image, grab a frame of video from an external camera and manipulate +that instead. The following resources control that. +.PP +.TP 8 +.B grabVideoProbability \fR(Float)\fP +What portion of the time to grab video rather than a screen image, +between 0.0 and 1.0. Defaults to 0.5, or half the time. +.TP 8 +.B videoDevice \fR(Integer)\fP +The number of the default video input device to check first. If unspecified, +the default camera (from videopanel(1)) will be checked first. After that, all +other available video input devices will be checked in order. + +The first one which produces a non-black image will be used. If all images +are black, the others will be re-checked a few times before giving up and +falling back to simply grabbing a desktop image (but note that this takes a +few seconds, so if you don't actually have any video sources hooked up, you +should consider turning off video grabbing by setting +\fBgrabVideoProbability\fP to 0.0.) +.TP 8 +.B videoGain \fR(Float)\fP +The amount by which to brighten the grabbed image. This defaults to 2.2. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 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. +.SH AUTHOR +Jamie Zawinski , 25-Nov-97. diff --git a/hacks/pyro.c b/hacks/pyro.c new file mode 100644 index 00000000..3b0a1d2d --- /dev/null +++ b/hacks/pyro.c @@ -0,0 +1,248 @@ +/* xscreensaver, Copyright (c) 1992, 1994, 1996 + * 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. + */ + +/* Draw some fireworks. Inspired from TI Explorer Lisp code by + John S. Pezaris + */ + +#include "screenhack.h" + +struct projectile { + int x, y; /* position */ + int dx, dy; /* velocity */ + int decay; + int size; + int fuse; + Bool primary; + Bool dead; + XColor color; + struct projectile *next_free; +}; + +static struct projectile *projectiles, *free_projectiles; + +static struct projectile * +get_projectile (void) +{ + struct projectile *p; + if (free_projectiles) + { + p = free_projectiles; + free_projectiles = p->next_free; + p->next_free = 0; + p->dead = False; + return p; + } + else + return 0; +} + +static void +free_projectile (struct projectile *p) +{ + p->next_free = free_projectiles; + free_projectiles = p; + p->dead = True; +} + +static void +launch (int xlim, int ylim, int g, + Display *dpy, Colormap cmap) +{ + struct projectile *p = get_projectile (); + int x, dx, xxx; + if (! p) return; + + do { + x = (random () % xlim); + dx = 30000 - (random () % 60000); + xxx = x + (dx * 200); + } while (xxx <= 0 || xxx >= xlim); + + p->x = x; + p->y = ylim; + p->dx = dx; + p->size = 8000; + p->decay = 0; + p->dy = (random () % 4000) - 13000; + p->fuse = ((((random () % 500) + 500) * abs (p->dy / g)) / 1000); + p->primary = True; + + if (! mono_p) + { + hsv_to_rgb (random () % 360, 1.0, 1.0, + &p->color.red, &p->color.green, &p->color.blue); + p->color.flags = DoRed | DoGreen | DoBlue; + if (!XAllocColor (dpy, cmap, &p->color)) + { + p->color.pixel = WhitePixel (dpy, DefaultScreen (dpy)); + p->color.red = p->color.green = p->color.blue = 0xFFFF; + } + } +} + +static struct projectile * +shrapnel (struct projectile *parent, Display *dpy, Colormap cmap) +{ + struct projectile *p = get_projectile (); + if (! p) return 0; + p->x = parent->x; + p->y = parent->y; + p->dx = (random () % 5000) - 2500 + parent->dx; + p->dy = (random () % 5000) - 2500 + parent->dy; + p->decay = (random () % 50) - 60; + p->size = (parent->size * 2) / 3; + p->fuse = 0; + p->primary = False; + + p->color = parent->color; + if (! mono_p) + XAllocColor (dpy, cmap, &p->color); /* dup the lock */ + + return p; +} + +static GC draw_gc, erase_gc; +static unsigned int default_fg_pixel; + +static int how_many, frequency, scatter; + +static Colormap +init_pyro (Display *dpy, Window window) +{ + int i; + Colormap cmap; + XGCValues gcv; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + how_many = get_integer_resource ("count", "Integer"); + frequency = get_integer_resource ("frequency", "Integer"); + scatter = get_integer_resource ("scatter", "Integer"); + if (how_many <= 0) how_many = 100; + if (frequency <= 0) frequency = 30; + if (scatter <= 0) scatter = 20; + projectiles = 0; + free_projectiles = 0; + projectiles = (struct projectile *) + calloc (how_many, sizeof (struct projectile)); + for (i = 0; i < how_many; i++) + free_projectile (&projectiles [i]); + gcv.foreground = default_fg_pixel = + get_pixel_resource ("foreground", "Foreground", dpy, cmap); + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = get_pixel_resource ("background", "Background", dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + XClearWindow (dpy, window); + return cmap; +} + +static void +pyro (Display *dpy, Window window, Colormap cmap) +{ + XWindowAttributes xgwa; + static int xlim, ylim, real_xlim, real_ylim; + int g = 100; + int i; + + if ((random () % frequency) == 0) + { + XGetWindowAttributes (dpy, window, &xgwa); + real_xlim = xgwa.width; + real_ylim = xgwa.height; + xlim = real_xlim * 1000; + ylim = real_ylim * 1000; + launch (xlim, ylim, g, dpy, cmap); + } + + XSync (dpy, True); + usleep (10000); + + for (i = 0; i < how_many; i++) + { + struct projectile *p = &projectiles [i]; + int old_x, old_y, old_size; + int size, x, y; + if (p->dead) continue; + old_x = p->x >> 10; + old_y = p->y >> 10; + old_size = p->size >> 10; + size = (p->size += p->decay) >> 10; + x = (p->x += p->dx) >> 10; + y = (p->y += p->dy) >> 10; + p->dy += (p->size >> 6); + if (p->primary) p->fuse--; + + /* erase old one */ + XFillRectangle (dpy, window, erase_gc, old_x, old_y, + old_size, old_size); + + if ((p->primary ? (p->fuse > 0) : (p->size > 0)) && + x < real_xlim && + y < real_ylim && + x > 0 && + y > 0) + { + if (mono_p || p->primary) + XSetForeground (dpy, draw_gc, default_fg_pixel); + else + XSetForeground (dpy, draw_gc, p->color.pixel); + + if /*(p->primary)*/ (size > 2) + XFillArc (dpy, window, draw_gc, x, y, size, size, 0, 360*64); + else + XFillRectangle (dpy, window, draw_gc, x, y, size, size); + } + else + { + free_projectile (p); + if (! mono_p) + if (p->color.pixel != WhitePixel (dpy, DefaultScreen (dpy))) + XFreeColors (dpy, cmap, &p->color.pixel, 1, 0); + } + + if (p->primary && p->fuse <= 0) + { + int j = (random () % scatter) + (scatter/2); + while (j--) + shrapnel (p, dpy, cmap); + } + } +} + + +char *progclass = "Pyro"; + +char *defaults [] = { + "Pyro.background: black", /* to placate SGI */ + "Pyro.foreground: white", + "*count: 100", + "*frequency: 30", + "*scatter: 20", + "*geometry: 800x500", + 0 +}; + +XrmOptionDescRec options [] = { + { "-count", ".count", XrmoptionSepArg, 0 }, + { "-frequency", ".frequency", XrmoptionSepArg, 0 }, + { "-scatter", ".scatter", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + Colormap cmap = init_pyro (dpy, window); + while (1) + pyro (dpy, window, cmap); +} diff --git a/hacks/pyro.man b/hacks/pyro.man new file mode 100644 index 00000000..8edb9669 --- /dev/null +++ b/hacks/pyro.man @@ -0,0 +1,60 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +pyro - simulate fireworks +.SH SYNOPSIS +.B pyro +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-count \fIinteger\fP] [\-frequency \fIinteger\fP] [\-scatter \fIinteger\fP] +.SH DESCRIPTION +The \fIpyro\fP program simulates fireworks, in a way similar to a Macintosh +program of the same name. +.SH OPTIONS +.I pyro +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-count \fIinteger\fP +How many particles should be allowed on the screen at once. Default 100. +.TP 8 +.B \-frequency \fIinteger\fP +How often new missiles should launch. Default 30. +.TP 8 +.B \-scatter \fIinteger\fP +How many particles should appear when a missile explodes. Default 20. +The actual number used is between \fIN\fP and \fIN+(N/2)\fP. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. diff --git a/hacks/qix.c b/hacks/qix.c new file mode 100644 index 00000000..24ea10ba --- /dev/null +++ b/hacks/qix.c @@ -0,0 +1,510 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +#include "screenhack.h" +#include "alpha.h" +#include + +#define MAXPOLY 16 +#define SCALE 6 + +struct qpoint { + int x, y; + int dx, dy; +}; + +struct qline { + struct qpoint *p; + XColor color; + Bool dead; +}; + +struct qix { + int id; + int fp; + int nlines; + int npoly; + struct qline *lines; +}; + +static GC draw_gc, erase_gc; +static unsigned int default_fg_pixel; +static long maxx, maxy, max_spread, max_size; +static int color_shift; +static Bool random_p, solid_p, xor_p, transparent_p, gravity_p; +static int delay; +static int count; +static Colormap cmap; +static int npoly; + +static GC *gcs[2]; + +static void +get_geom (Display *dpy, Window window) +{ + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + maxx = ((long)(xgwa.width+1)<nlines = nlines; + qix->lines = (struct qline *) calloc (qix->nlines, sizeof (struct qline)); + qix->npoly = npoly; + for (i = 0; i < qix->nlines; i++) + qix->lines[i].p = (struct qpoint *) + calloc(qix->npoly, sizeof(struct qpoint)); + + if (!mono_p && !transparent_p) + { + hsv_to_rgb (random () % 360, frand (1.0), frand (0.5) + 0.5, + &qix->lines[0].color.red, &qix->lines[0].color.green, + &qix->lines[0].color.blue); + if (!XAllocColor (dpy, cmap, &qix->lines[0].color)) + { + qix->lines[0].color.pixel = default_fg_pixel; + XQueryColor (dpy, cmap, &qix->lines[0].color); + if (!XAllocColor (dpy, cmap, &qix->lines[0].color)) + abort (); + } + } + + if (max_size == 0) + { + for (i = 0; i < qix->npoly; i++) + { + qix->lines[0].p[i].x = random () % maxx; + qix->lines[0].p[i].y = random () % maxy; + } + } + else + { + /*assert(qix->npoly == 2);*/ + qix->lines[0].p[0].x = random () % maxx; + qix->lines[0].p[0].y = random () % maxy; + qix->lines[0].p[1].x = qix->lines[0].p[0].x + (random () % (max_size/2)); + qix->lines[0].p[1].y = qix->lines[0].p[0].y + (random () % (max_size/2)); + if (qix->lines[0].p[1].x > maxx) qix->lines[0].p[1].x = maxx; + if (qix->lines[0].p[1].y > maxy) qix->lines[0].p[1].y = maxy; + } + + for (i = 0; i < qix->npoly; i++) + { + qix->lines[0].p[i].dx = (random () % (max_spread + 1)) - (max_spread /2); + qix->lines[0].p[i].dy = (random () % (max_spread + 1)) - (max_spread /2); + } + qix->lines[0].dead = True; + + for (i = 1; i < qix->nlines; i++) + { + for(j=0; jnpoly; j++) + qix->lines[i].p[j] = qix->lines[0].p[j]; + qix->lines[i].color = qix->lines[0].color; + qix->lines[i].dead = qix->lines[0].dead; + + if (!mono_p && !transparent_p) + if (!XAllocColor (dpy, cmap, &qix->lines[i].color)) + abort (); + } + return qix; +} + + + + +static struct qix ** +init_qix (Display *dpy, Window window) +{ + int nlines; + struct qix **qixes; + XGCValues gcv; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + count = get_integer_resource ("count", "Integer"); + if (count <= 0) count = 1; + nlines = get_integer_resource ("segments", "Integer"); + if (nlines <= 0) nlines = 20; + npoly = get_integer_resource("poly", "Integer"); + if (npoly <= 2) npoly = 2; + if (npoly > MAXPOLY) npoly = MAXPOLY; + get_geom (dpy, window); + max_spread = get_integer_resource ("spread", "Integer"); + if (max_spread <= 0) max_spread = 10; + max_spread <<= SCALE; + max_size = get_integer_resource ("size", "Integer"); + if (max_size < 0) max_size = 0; + max_size <<= SCALE; + random_p = get_boolean_resource ("random", "Boolean"); + solid_p = get_boolean_resource ("solid", "Boolean"); + xor_p = get_boolean_resource ("xor", "Boolean"); + transparent_p = get_boolean_resource ("transparent", "Boolean"); + gravity_p = get_boolean_resource("gravity", "Boolean"); + delay = get_integer_resource ("delay", "Integer"); + color_shift = get_integer_resource ("colorShift", "Integer"); + if (color_shift < 0 || color_shift >= 360) color_shift = 5; + if (delay < 0) delay = 0; + + /* Clear up ambiguities regarding npoly */ + if (solid_p) + { + if (npoly != 2) + fprintf(stderr, "%s: Can't have -solid and -poly; using -poly 2\n", + progname); + npoly = 2; + } + if (npoly > 2) + { + if (max_size) + fprintf(stderr, "%s: Can't have -poly and -size; using -size 0\n", + progname); + max_size = 0; + } + + if (count == 1 && transparent_p) + transparent_p = False; /* it's a no-op */ + + if (transparent_p && CellsOfScreen (DefaultScreenOfDisplay (dpy)) <= 2) + { + fprintf (stderr, "%s: -transparent only works on color displays.\n", + progname); + transparent_p = False; + } + + if (xor_p && !transparent_p) + mono_p = True; + + gcs[0] = gcs[1] = 0; + gcv.foreground = default_fg_pixel = + get_pixel_resource ("foreground", "Foreground", dpy, cmap); + + if (transparent_p) + { + Bool additive_p = get_boolean_resource ("additive", "Boolean"); + unsigned long *plane_masks = 0; + unsigned long base_pixel; + int nplanes = count; + int i; + + allocate_alpha_colors (dpy, cmap, &nplanes, additive_p, &plane_masks, + &base_pixel); + + if (nplanes <= 1) + { + fprintf (stderr, + "%s: couldn't allocate any color planes; turning -transparent off.\n", + progname); + transparent_p = False; + if (xor_p) + goto NON_TRANSPARENT_XOR; + else + goto NON_TRANSPARENT; + } + else if (nplanes != count) + { + fprintf (stderr, + "%s: only allocated %d color planes (instead of %d).\n", + progname, nplanes, count); + count = nplanes; + } + + gcs[0] = (GC *) malloc (count * sizeof (GC)); + gcs[1] = xor_p ? gcs[0] : (GC *) malloc (count * sizeof (GC)); + + + for (i = 0; i < count; i++) + { + gcv.plane_mask = plane_masks [i]; + gcv.foreground = ~0; + if (xor_p) + { + gcv.function = GXxor; + gcs [0][i] = XCreateGC (dpy, window, + GCForeground|GCFunction|GCPlaneMask, + &gcv); + } + else + { + gcs [0][i] = XCreateGC (dpy, window, GCForeground|GCPlaneMask, + &gcv); + gcv.foreground = 0; + gcs [1][i] = XCreateGC (dpy, window, GCForeground|GCPlaneMask, + &gcv); + } + } + + XSetWindowBackground (dpy, window, base_pixel); + XClearWindow (dpy, window); + } + else if (xor_p) + { + NON_TRANSPARENT_XOR: + gcv.function = GXxor; + gcv.foreground = + (default_fg_pixel ^ get_pixel_resource ("background", "Background", + dpy, cmap)); + draw_gc = erase_gc = XCreateGC(dpy,window,GCForeground|GCFunction,&gcv); + } + else + { + NON_TRANSPARENT: + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = get_pixel_resource ("background", "Background", + dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + } + + qixes = (struct qix **) malloc ((count + 1) * sizeof (struct qix *)); + qixes [count] = 0; + while (count--) + { + qixes [count] = init_one_qix (dpy, window, nlines, npoly); + qixes [count]->id = count; + } + return qixes; +} + +static void +free_qline (Display *dpy, Window window, Colormap cmap, + struct qline *qline, + struct qline *prev, + struct qix *qix) +{ + int i; + if (qline->dead || !prev) + ; + else if (solid_p) + { + XPoint points [4]; + /*assert(qix->npoly == 2);*/ + points [0].x = qline->p[0].x >> SCALE; + points [0].y = qline->p[0].y >> SCALE; + points [1].x = qline->p[1].x >> SCALE; + points [1].y = qline->p[1].y >> SCALE; + points [2].x = prev->p[1].x >> SCALE; + points [2].y = prev->p[1].y >> SCALE; + points [3].x = prev->p[0].x >> SCALE; + points [3].y = prev->p[0].y >> SCALE; + XFillPolygon (dpy, window, (transparent_p ? gcs[1][qix->id] : erase_gc), + points, 4, Complex, CoordModeOrigin); + } + else + { + /* XDrawLine (dpy, window, (transparent_p ? gcs[1][qix->id] : erase_gc), + qline->p1.x, qline->p1.y, qline->p2.x, qline->p2.y);*/ + static XPoint points[MAXPOLY+1]; + for(i = 0; i < qix->npoly; i++) + { + points[i].x = qline->p[i].x >> SCALE; + points[i].y = qline->p[i].y >> SCALE; + } + points[qix->npoly] = points[0]; + XDrawLines(dpy, window, (transparent_p ? gcs[1][qix->id] : erase_gc), + points, qix->npoly+1, CoordModeOrigin); + } + + if (!mono_p && !transparent_p) + XFreeColors (dpy, cmap, &qline->color.pixel, 1, 0); + + qline->dead = True; +} + +static void +add_qline (Display *dpy, Window window, Colormap cmap, + struct qline *qline, + struct qline *prev_qline, + struct qix *qix) +{ + int i; + + for(i=0; inpoly; i++) + qline->p[i] = prev_qline->p[i]; + qline->color = prev_qline->color; + qline->dead = prev_qline->dead; + +#define wiggle(point,delta,max) \ + if (random_p) delta += (random () % (1 << (SCALE+1))) - (1 << SCALE); \ + if (delta > max_spread) delta = max_spread; \ + else if (delta < -max_spread) delta = -max_spread; \ + point += delta; \ + if (point < 0) point = 0, delta = -delta, point += delta<<1; \ + else if (point > max) point = max, delta = -delta, point += delta<<1; + + if (gravity_p) + for(i=0; inpoly; i++) + qline->p[i].dy += 3; + + for (i = 0; i < qix->npoly; i++) + { + wiggle (qline->p[i].x, qline->p[i].dx, maxx); + wiggle (qline->p[i].y, qline->p[i].dy, maxy); + } + + if (max_size) + { + /*assert(qix->npoly == 2);*/ + if (qline->p[0].x - qline->p[1].x > max_size) + qline->p[0].x = qline->p[1].x + max_size + - (random_p ? random() % max_spread : 0); + else if (qline->p[1].x - qline->p[0].x > max_size) + qline->p[1].x = qline->p[0].x + max_size + - (random_p ? random() % max_spread : 0); + if (qline->p[0].y - qline->p[1].y > max_size) + qline->p[0].y = qline->p[1].y + max_size + - (random_p ? random() % max_spread : 0); + else if (qline->p[1].y - qline->p[0].y > max_size) + qline->p[1].y = qline->p[0].y + max_size + - (random_p ? random() % max_spread : 0); + } + + if (!mono_p && !transparent_p) + { + XColor desired; + + int h; + double s, v; + rgb_to_hsv (qline->color.red, qline->color.green, qline->color.blue, + &h, &s, &v); + h = (h + color_shift) % 360; + hsv_to_rgb (h, s, v, + &qline->color.red, &qline->color.green, &qline->color.blue); + + qline->color.flags = DoRed | DoGreen | DoBlue; + desired = qline->color; + if (XAllocColor (dpy, cmap, &qline->color)) + { + /* XAllocColor returns the actual RGB that the hardware let us + allocate. Restore the requested values into the XColor struct + so that limited-resolution hardware doesn't cause the cycle to + get "stuck". */ + qline->color.red = desired.red; + qline->color.green = desired.green; + qline->color.blue = desired.blue; + } + else + { + qline->color = prev_qline->color; + if (!XAllocColor (dpy, cmap, &qline->color)) + abort (); /* same color should work */ + } + XSetForeground (dpy, draw_gc, qline->color.pixel); + } + if (! solid_p) + { + /* XDrawLine (dpy, window, (transparent_p ? gcs[0][qix->id] : draw_gc), + qline->p1.x, qline->p1.y, qline->p2.x, qline->p2.y);*/ + static XPoint points[MAXPOLY+1]; + for (i = 0; i < qix->npoly; i++) + { + points[i].x = qline->p[i].x >> SCALE; + points[i].y = qline->p[i].y >> SCALE; + } + points[qix->npoly] = points[0]; + XDrawLines(dpy, window, (transparent_p ? gcs[0][qix->id] : draw_gc), + points, qix->npoly+1, CoordModeOrigin); + } + else if (!prev_qline->dead) + { + XPoint points [4]; + points [0].x = qline->p[0].x >> SCALE; + points [0].y = qline->p[0].y >> SCALE; + points [1].x = qline->p[1].x >> SCALE; + points [1].y = qline->p[1].y >> SCALE; + points [2].x = prev_qline->p[1].x >> SCALE; + points [2].y = prev_qline->p[1].y >> SCALE; + points [3].x = prev_qline->p[0].x >> SCALE; + points [3].y = prev_qline->p[0].y >> SCALE; + XFillPolygon (dpy, window, (transparent_p ? gcs[0][qix->id] : draw_gc), + points, 4, Complex, CoordModeOrigin); + } + + qline->dead = False; +} + +static void +qix1 (Display *dpy, Window window, struct qix *qix) +{ + int ofp = qix->fp - 1; + static int gtick = 0; + if (ofp < 0) ofp = qix->nlines - 1; + if (gtick++ == 500) + get_geom (dpy, window), gtick = 0; + free_qline (dpy, window, cmap, &qix->lines [qix->fp], + &qix->lines[(qix->fp + 1) % qix->nlines], qix); + add_qline (dpy, window, cmap, &qix->lines[qix->fp], &qix->lines[ofp], qix); + if ((++qix->fp) >= qix->nlines) + qix->fp = 0; +} + + +char *progclass = "Qix"; + +char *defaults [] = { + "Qix.background: black", /* to placate SGI */ + "Qix.foreground: white", + "*count: 1", + "*segments: 50", + "*poly: 2", + "*spread: 8", + "*size: 0", + "*colorShift: 3", + "*solid: false", + "*delay: 10000", + "*random: true", + "*xor: false", + "*transparent:false", + "*gravity: false", + "*additive: true", + 0 +}; + +XrmOptionDescRec options [] = { + { "-count", ".count", XrmoptionSepArg, 0 }, + { "-segments", ".segments", XrmoptionSepArg, 0 }, + { "-poly", ".poly", XrmoptionSepArg, 0 }, + { "-spread", ".spread", XrmoptionSepArg, 0 }, + { "-size", ".size", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-color-shift", ".colorShift", XrmoptionSepArg, 0 }, + { "-random", ".random", XrmoptionNoArg, "true" }, + { "-linear", ".random", XrmoptionNoArg, "false" }, + { "-solid", ".solid", XrmoptionNoArg, "true" }, + { "-hollow", ".solid", XrmoptionNoArg, "false" }, + { "-xor", ".xor", XrmoptionNoArg, "true" }, + { "-no-xor", ".xor", XrmoptionNoArg, "false" }, + { "-transparent", ".transparent", XrmoptionNoArg, "true" }, + { "-non-transparent", ".transparent", XrmoptionNoArg, "false" }, + { "-gravity", ".gravity", XrmoptionNoArg, "true" }, + { "-no-gravity", ".gravity", XrmoptionNoArg, "false" }, + { "-additive", ".additive", XrmoptionNoArg, "true" }, + { "-subtractive", ".additive", XrmoptionNoArg, "false" }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + struct qix **q1 = init_qix (dpy, window); + struct qix **qn; + while (1) + for (qn = q1; *qn; qn++) + { + qix1 (dpy, window, *qn); + XSync (dpy, True); + if (delay) usleep (delay); + } +} diff --git a/hacks/qix.man b/hacks/qix.man new file mode 100644 index 00000000..7d046fbf --- /dev/null +++ b/hacks/qix.man @@ -0,0 +1,129 @@ +.TH XScreenSaver 1 "27-Apr-97" "X Version 11" +.SH NAME +qix - bounce colored lines around a window +.SH SYNOPSIS +.B qix +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-segments \fIint\fP] [\-spread \fIpixels\fP] [\-size \fIpixels\fP] [\-count \fIint\fP] [\-color-shift \fIdegrees\fP] [\-delay \fIusecs\fP] [\-random] [\-linear] [\-solid] [\-hollow] [\-xor] [\-no\-xor] [\-transparent] [\-non\-transparent] [\-additive] [\-subtractive] [\-poly \fIint\fP] [\-gravity] [\-no\-gravity] +.SH DESCRIPTION +The \fIqix\fP program bounces a series of line segments around its window. +This is truly the swiss army chainsaw of qix programs. If you know of one +with more display modes, I want to know about it. +.SH OPTIONS +.I qix +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-segments \fIinteger\fP +How many line segments should be drawn. Default 50. +.TP 8 +.B \-spread \fIinteger\fP +How far apart the endpoints of one segment should be from the next. +Default 8. +.TP 8 +.B \-size \fIinteger\fP +The maximum distance one endpoint of a segment is allowed to be from +the opposite end of that segment. Default 0, meaning unlimited. +.TP 8 +.B \-count \fIinteger\fP +How many qixes to draw. Default 1. +.TP 8 +.B \-color\-shift \fIdegrees\fP +If on a color display, the color of the line segments will cycle through +the spectrum. This specifies how far the hue of each segment should be +from the next, in degrees on the HSV wheel. Default 3. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 25000, or about 0.025 seconds. +.TP 8 +.B \-random +The \fIqix\fP will wander around the screen semi-randomly. This is the +default. +.TP 8 +.B \-linear +The opposite of \fI\-random\fP: the \fIqix\fP will travel in straight lines +until it reaches a wall, and then it will bounce. +.TP 8 +.B \-solid +If this is specified, then the area between the line segments will be filled +in with the appropriate color, instead of the \fIqix\fP simply being composed +of one-pixel-wide line segments. This option looks really good in color. +.TP 8 +.B \-hollow +The opposite of \fI\-solid\fP; this is the default. +.TP 8 +.B \-xor +If this is specified, then qix segments will be drawn and erased with xor, +instead of being drawn in some color and erased in the background color. +This implies \fI\-mono\fP, in that only two colors can be used. +.TP 8 +.B \-transparent +If this is specified, and \fI\-count\fP is greater than 1, then each qix +will be drawn in one color, and when they overlap, the colors will be mixed. +This only works on \fBPseudoColor\fP displays. This looks best in +conjuction with \fI\-solid\fP. +.TP 8 +.B \-non\-transparent +Turns off \fI\-transparent\fP. +.TP 8 +.B \-additive +If \fI\-transparent\fP is specified, then this option means that the colors +will be mixed using an additive color model, as if the qixes were projected +light. This is the default. +.TP 8 +.B \-subtractive +If \fI\-transparent\fP is specified, then this option means that the +colors will be mixed using a subtractive color model, as if the qixes were +translucent filters. +.TP 8 +.B \-poly \fIint\fP +How many vertices each qix-line should have: the default is 2, meaning the +traditional qix line shape. Three will yield triangles, and so on. +.TP 8 +.B \-gravity +.TP 8 +.B \-no\-gravity +Whether there should be downward attraction. For example, the +options +.B \-gravity \-linear +will make everything move in nice smooth parabolas. +Gravity is off by default. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. + +Thanks to Ariel Scolnicov for the \-poly and \-gravity options. diff --git a/hacks/rd-bomb.c b/hacks/rd-bomb.c new file mode 100644 index 00000000..0a7cee75 --- /dev/null +++ b/hacks/rd-bomb.c @@ -0,0 +1,514 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1997 + * Jamie Zawinski + * + * reaction/diffusion textures + * Copyright (c) 1997 Scott Draves spot@transmeta.com + * this code is derived from Bomb + * see http://www.cs.cmu.edu/~spot/bomb.html + * + * 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. + * + * And remember: X Windows is to graphics hacking as roman numerals are to + * the square root of pi. + */ + +#include + +#include "screenhack.h" + +/* costs ~6% speed */ +#define dither_when_mapped 1 + +int verbose; +int ncolors = 0; +XColor *colors = 0; +Display *display; +Visual *visual; +#if dither_when_mapped +unsigned char *mc = 0; +#endif +Colormap cmap = 0; +Window window; +int mapped; +int pdepth; +void random_colors(void); + +/* ----------------------------------------------------------- + pixel hack, 8-bit pixel grid, first/next frame interface + + pixack_init(int *size_h, int *size_v) + pixack_frame(char *pix_buf) + */ + + +#define bps 16 +#define mx ((1<<16)-1) + +/* you can replace integer mults wish shift/adds with these, + but it doesn't help on my 586 */ +#define x5(n) ((n<<2)+n) +#define x7(n) ((n<<3)-n) + +/* why strip bit? */ +#define R (ya_random()&((1<<30)-1)) + +int frame = 0, epoch_time; +ushort *r1, *r2, *r1b, *r2b; +int width, height, npix; +int radius; +int reaction = 0; +int diffusion = 0; + +/* returns number of pixels that the pixack produces. called once. */ +void +pixack_init(int *size_h, int *size_v) { + int sz_base; + width = get_integer_resource ("width", "Integer"); + height = get_integer_resource ("height", "Integer"); + sz_base = 80 + (R%40); + if (width <= 0) width = (R%20) ? sz_base : (28 + R%10); + if (height <= 0) height = (R%20) ? sz_base : (28 + R%10); + /* don't go there */ + if (width < 10) width = 10; + if (height < 10) height = 10; + epoch_time = get_integer_resource ("epoch", "Integer"); + npix = (width + 2) * (height + 2); + r1 = (ushort *) malloc(sizeof(ushort) * npix); + r2 = (ushort *) malloc(sizeof(ushort) * npix); + r1b = (ushort *) malloc(sizeof(ushort) * npix); + r2b = (ushort *) malloc(sizeof(ushort) * npix); + + if (!r1 || !r2 || !r1b || !r2b) { + fprintf(stderr, "not enough memory for %d pixels.\n", npix); + exit(1); + } + + *size_h = width; + *size_v = height; +} + +#define test_pattern_hyper 0 + + +/* returns the pixels. called many times. */ +void +pixack_frame(char *pix_buf) { + int i, j; + int w2 = width + 2; + ushort *t; +#if test_pattern_hyper + if (frame&0x100) + sleep(1); +#endif + if (verbose) { + double tm = 0; + struct timeval tp; + if (!(frame%100)) { + double tm2; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; + gettimeofday(&tp, &tzp); +#else + gettimeofday(&tp); +#endif + tm2 = tp.tv_sec + tp.tv_usec * 1e-6; + if (frame > 0) + printf("fps = %2.4g\n", 100.0 / (tm2 - tm)); + tm = tm2; + } + } + if (!(frame%epoch_time)) { + int s; + if (0 != frame) { + int t = epoch_time / 500; + if (t > 15) + t = 15; + sleep(t); + } + + for (i = 0; i < npix; i++) { + /* equilibrium */ + r1[i] = 65500; + r2[i] = 11; + } + + random_colors(); + + XSetWindowBackground(display, window, colors[255 % ncolors].pixel); + XClearWindow(display, window); + + s = w2 * (height/2) + width/2; + radius = get_integer_resource ("radius", "Integer"); + { + int maxr = width/2-2; + int maxr2 = height/2-2; + if (maxr2 < maxr) maxr = maxr2; + + if (radius < 0) + radius = 1 + ((R%10) ? (R%5) : (R % maxr)); + if (radius > maxr) radius = maxr; + } + for (i = -radius; i < (radius+1); i++) + for (j = -radius; j < (radius+1); j++) + r2[s + i + j*w2] = mx - (R&63); + reaction = get_integer_resource ("reaction", "Integer"); + if (reaction < 0 || reaction > 2) reaction = R&1; + diffusion = get_integer_resource ("diffusion", "Integer"); + if (diffusion < 0 || diffusion > 2) + diffusion = (R%5) ? ((R%3)?0:1) : 2; + if (2 == reaction && 2 == diffusion) + reaction = diffusion = 0; + + if (verbose) + printf("reaction = %d\ndiffusion = %d\nradius = %d\n", + reaction, diffusion, radius); + } + for (i = 0; i <= width+1; i++) { + r1[i] = r1[i + w2 * height]; + r2[i] = r2[i + w2 * height]; + r1[i + w2 * (height + 1)] = r1[i + w2]; + r2[i + w2 * (height + 1)] = r2[i + w2]; + } + for (i = 0; i <= height+1; i++) { + r1[w2 * i] = r1[width + w2 * i]; + r2[w2 * i] = r2[width + w2 * i]; + r1[w2 * i + width + 1] = r1[w2 * i + 1]; + r2[w2 * i + width + 1] = r2[w2 * i + 1]; + } + for (i = 0; i < height; i++) { + int ii = i + 1; + char *q = pix_buf + width * i; + short *qq = ((short *) pix_buf) + width * i; + long *qqq = ((long *) pix_buf) + width * i; + ushort *i1 = r1 + 1 + w2 * ii; + ushort *i2 = r2 + 1 + w2 * ii; + ushort *o1 = r1b + 1 + w2 * ii; + ushort *o2 = r2b + 1 + w2 * ii; + for (j = 0; j < width; j++) { +#if test_pattern_hyper + int r1 = (i * j + (frame&127)*frame)&65535; +#else + int uvv, r1 = 0, r2 = 0; + switch (diffusion) { + case 0: + r1 = i1[j] + i1[j+1] + i1[j-1] + i1[j+w2] + i1[j-w2]; + r1 = r1 / 5; + r2 = (i2[j]<<3) + i2[j+1] + i2[j-1] + i2[j+w2] + i2[j-w2]; + r2 = r2 / 12; + break; + case 1: + r1 = i1[j+1] + i1[j-1] + i1[j+w2] + i1[j-w2]; + r1 = r1 >> 2; + r2 = (i2[j]<<2) + i2[j+1] + i2[j-1] + i2[j+w2] + i2[j-w2]; + r2 = r2 >> 3; + break; + case 2: + r1 = (i1[j]<<1) + (i1[j+1]<<1) + (i1[j-1]<<1) + i1[j+w2] + i1[j-w2]; + r1 = r1 >> 3; + r2 = (i2[j]<<2) + i2[j+1] + i2[j-1] + i2[j+w2] + i2[j-w2]; + r2 = r2 >> 3; + break; + } + + /* John E. Pearson "Complex Patterns in a Simple System" + Science, July 1993 */ + + uvv = (((r1 * r2) >> bps) * r2) >> bps; + switch (reaction) { /* costs 4% */ + case 0: + r1 += 4 * (((28 * (mx-r1)) >> 10) - uvv); + r2 += 4 * (uvv - ((80 * r2) >> 10)); + break; + case 1: + r1 += 3 * (((27 * (mx-r1)) >> 10) - uvv); + r2 += 3 * (uvv - ((80 * r2) >> 10)); + break; + case 2: + r1 += 2 * (((28 * (mx-r1)) >> 10) - uvv); + r2 += 3 * (uvv - ((80 * r2) >> 10)); + break; + } + if (r1 > mx) r1 = mx; + if (r2 > mx) r2 = mx; + if (r1 < 0) r1 = 0; + if (r2 < 0) r2 = 0; + o1[j] = r1; + o2[j] = r2; +#endif + + /* this is terrible. here i want to assume ncolors = 256. + should lose double indirection */ + + if (mapped) +#if dither_when_mapped + q[j] = colors[mc[r1] % ncolors].pixel; +#else + q[j] = colors[(r1>>8) % ncolors].pixel; +#endif + else if (pdepth == 8) + q[j] = colors[(r1>>8) % ncolors].pixel; + else if (pdepth == 16) +#if dither_when_mapped + qq[j] = colors[mc[r1] % ncolors].pixel; +#else + qq[j] = colors[(r1>>8) % ncolors].pixel; +#endif + else if (pdepth == 32) +#if dither_when_mapped + qqq[j] = colors[mc[r1] % ncolors].pixel; +#else + qqq[j] = colors[(r1>>8) % ncolors].pixel; +#endif + else + abort(); + } + } + t = r1; r1 = r1b; r1b = t; + t = r2; r2 = r2b; r2b = t; +} + + +/* ------------- xscreensaver rendering -------------- */ + + + +char *progclass = "RD"; + + +char *defaults [] = { + "RD.background: black", /* to placate SGI */ + "RD.foreground: white", + "*width: 0", /* tried to use -1 but it complained */ + "*height: 0", + "*epoch: 40000", + "*reaction: -1", + "*diffusion: -1", + "*verbose: off", + "*radius: -1", + "*speed: 0.0", + "*size: 0.66", + "*delay: 1", + "*colors: -1", + 0 +}; + +XrmOptionDescRec options [] = { + { "-width", ".width", XrmoptionSepArg, 0 }, + { "-height", ".height", XrmoptionSepArg, 0 }, + { "-epoch", ".epoch", XrmoptionSepArg, 0 }, + { "-reaction", ".reaction", XrmoptionSepArg, 0 }, + { "-diffusion", ".diffusion", XrmoptionSepArg, 0 }, + { "-verbose", ".verbose", XrmoptionNoArg, "True" }, + { "-radius", ".radius", XrmoptionSepArg, 0 }, + { "-speed", ".speed", XrmoptionSepArg, 0 }, + { "-size", ".size", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-ncolors", ".colors", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + + +/* why doesn't this work??? and more importantly, do i really still have + to do this in X? */ + +#ifdef HAVE_XSHM_EXTENSION +#include +#include +#include +#endif + + +void +random_colors() { + memset(colors, 0, ncolors*sizeof(*colors)); + make_smooth_colormap (display, visual, cmap, colors, &ncolors, + True, 0, True); + if (ncolors <= 2) { + mono_p = True; + ncolors = 2; + colors[0].flags = DoRed|DoGreen|DoBlue; + colors[0].red = colors[0].green = colors[0].blue = 0; + XAllocColor(display, cmap, &colors[0]); + colors[1].flags = DoRed|DoGreen|DoBlue; + colors[1].red = colors[1].green = colors[1].blue = 0xFFFF; + XAllocColor(display, cmap, &colors[1]); + } + + /* Scale it up so that there are exactly 255 colors -- that keeps the + animation speed consistent, even when there aren't many allocatable + colors, and prevents the -mono mode from looking like static. */ + if (ncolors != 255) { + int i, n = 255; + double scale = (double) ncolors / (double) (n+1); + XColor *c2 = (XColor *) malloc(sizeof(*c2) * (n+1)); + for (i = 0; i < n; i++) + c2[i] = colors[(int) (i * scale)]; + free(colors); + colors = c2; + ncolors = n; + } + +} + +/* should factor into RD-specfic and compute-every-pixel general */ +void +screenhack (Display *dpy, Window win) +{ + GC gc; + XGCValues gcv; + XWindowAttributes xgwa; + XImage *image; + int array_width, array_height; + double array_x, array_y; + double array_dx, array_dy; + int w2; + char *p; + int vdepth; + int npix; + int *m = 0; +#ifdef HAVE_XSHM_EXTENSION + int use_shm = 0; + XShmSegmentInfo shm_info; +#endif + + double delay = get_float_resource ("delay", "Float"); + + display = dpy; + window = win; + + + XGetWindowAttributes (dpy, win, &xgwa); + visual = xgwa.visual; + pixack_init(&width, &height); + { + double s = get_float_resource ("size", "Float"); + double p = get_float_resource ("speed", "Float"); + if (s < 0.0 || s > 1.0) + s = 1.0; + s = sqrt(s); + array_width = xgwa.width * s; + array_height = xgwa.height * s; + if (s < 0.99) { + array_width = (array_width / width) * width; + array_height = (array_height / height) * height; + } + if (array_width < width) array_width = width; + if (array_height < height) array_height = height; + array_x = (xgwa.width - array_width)/2; + array_y = (xgwa.height - array_height)/2; + array_dx = p; + array_dy = .31415926 * p; + } + verbose = get_boolean_resource ("verbose", "Boolean"); + npix = (width + 2) * (height + 2); + w2 = width + 2; + gcv.function = GXcopy; + gc = XCreateGC(dpy, win, GCFunction, &gcv); + vdepth = visual_depth(DefaultScreenOfDisplay(dpy), xgwa.visual); + + /* This code only deals with pixmap depths of 1, 8, 16, and 32. + Therefore, we assume that those depths will be supported by the + coresponding visual depths (that depth-24 displays accept depth-32 + pixmaps, and that depth-12 displays accept depth-16 pixmaps.) */ + pdepth = (vdepth == 1 ? 1 : + vdepth <= 8 ? 8 : + vdepth <= 16 ? 16 : + 32); + + cmap = xgwa.colormap; + ncolors = get_integer_resource ("colors", "Integer"); + + if (ncolors <= 0) { + if (vdepth > 8) + ncolors = 2047; + else + ncolors = 255; + } + + if (mono_p || ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + + mapped = (vdepth <= 8 && + has_writable_cells(xgwa.screen, xgwa.visual)); + + { + int i, di; + mc = (unsigned char *) malloc(1<<16); + for (i = 0; i < (1<<16); i++) { + di = (i + (ya_random()&255))>>8; + if (di > 255) di = 255; + mc[i] = di; + } + } + + p = malloc(npix * (pdepth == 1 ? 1 : (pdepth / 8))); + if (!p) { + fprintf(stderr, "not enough memory for %d pixels.\n", npix); + exit(1); + } + +#ifdef HAVE_XSHM_EXTENSION + if (use_shm) { + printf("p=%X\n", p); + free(p); + image = XShmCreateImage(dpy, xgwa.visual, vdepth, + ZPixmap, 0, &shm_info, width, height); + shm_info.shmid = shmget(IPC_PRIVATE, + image->bytes_per_line * image->height, + IPC_CREAT | 0777); + if (shm_info.shmid == -1) + printf ("shmget failed!"); + shm_info.readOnly = False; + p = shmat(shm_info.shmid, 0, 0); + printf("p=%X %d\n", p, image->bytes_per_line); + XShmAttach(dpy, &shm_info); + XSync(dpy, False); + } else +#endif + image = XCreateImage(dpy, xgwa.visual, vdepth, + ZPixmap, 0, p, + width, height, 8, 0); + + while (1) { + int i, j; + pixack_frame(p); + for (i = 0; i < array_width; i += width) + for (j = 0; j < array_height; j += height) +#ifdef HAVE_XSHM_EXTENSION + if (use_shm) + XShmPutImage(dpy, win, gc, image, 0, 0, i, j, + width, height, False); + else +#endif + XPutImage(dpy, win, gc, image, 0, 0, i+array_x, j+array_y, width, height); + + array_x += array_dx; + array_y += array_dy; + if (array_x < 0) { + array_x = 0; + array_dx = -array_dx; + } else if (array_x > (xgwa.width - array_width)) { + array_x = (xgwa.width - array_width); + array_dx = -array_dx; + } + if (array_y < 0) { + array_y = 0; + array_dy = -array_dy; + } else if (array_y > (xgwa.height - array_height)) { + array_y = (xgwa.height - array_height); + array_dy = -array_dy; + } + frame++; + + XSync(dpy, False); + if (delay > 0) + usleep(1000 * delay); + } +} diff --git a/hacks/rd-bomb.man b/hacks/rd-bomb.man new file mode 100644 index 00000000..161c4783 --- /dev/null +++ b/hacks/rd-bomb.man @@ -0,0 +1,98 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +rd-bomb - reaction/diffusion textures +.SH SYNOPSIS +.B rd-bomb +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] +[\-background \fIcolor\fP] [\-window] [\-root] [\-install] +[\-visual \fIvisual\fP] [\-width \fIn\fP] [\-height \fIn\fP] +[\-reaction \fIn\fP] [\-diffusion \fIn\fP] +[\-size \fIf\fP] [\-speed \fIf\fP] [\-delay \fIusecs\fP] +.SH DESCRIPTION + +The \fIrd-bomb\fP program draws reaction/diffusion textures. The code +is derived from the 'd' mode of the "bomb" visual musical instrument +(see http://www.cs.cmu.edu/~spot/bomb.html). I got the equations from +xmorphia (http://www.ccsf.caltech.edu/ismap/image.html), which is +based on a version of the Gray-Scott model taken from: + John E. Pearson "Complex Patterns in a Simple System" + Science, 261,189, 9 July 1993. + +If the frame-rate is too low, consider decreasing the width and height +of the tile, or decreasing the size of the active part of the screen. + +.SH OPTIONS + +If one of the reaction, diffusion, radius, and palette options is set +to a negative value, then that option will be set to a random +appropriate value. + +Be sure to try "-speed 1 -size 0.1 -epoch 3000". + +.I rd-bomb +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-width \fIn\fP +.TP 8 +.B \-height \fIn\fP +Specify the size of the tile, in pixels. +.TP 8 +.B \-reaction \fIn\fP +.TP 8 +.B \-diffusion \fIn\fP +These are constants in the equations that effect its visual nature. +Each may be one of 0, 1, or 2. +.TP 8 +.B \-radius \fIn\fP +Size of the seed. +.TP 8 +.B \-palette \fIn\fP +Selects a palette. Must be between 0 and 80, inclusive. +.TP 8 +.B \-size \fIf\fP +What fraction of the window is actively drawn, a floating point number +between 0 (exclusive) and 1 (inclusive). Default is 0.66. +.TP 8 +.B \-speed \fIf\fP +When a fraction of the screen is active, the active area moves at this +rate (a floating point number). Default is zero. Suggested value: 1.0. +.TP 8 +.B \-delay \fIusecs\fP +How many microseconds to delay between frames; default 1000, or +about 1/1000th of a second. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1997 by Scott Draves. + +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. +.SH AUTHOR +Scott Draves , 9/97 diff --git a/hacks/rocks.c b/hacks/rocks.c new file mode 100644 index 00000000..8b12fa76 --- /dev/null +++ b/hacks/rocks.c @@ -0,0 +1,533 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +/* 18-Sep-97: Johannes Keukelaar : Added some color. + * Using -mono gives the old behaviour. (Modified by jwz.) + */ +/* Flying through an asteroid field. Based on TI Explorer Lisp code by + John Nguyen + */ + +#include +#include +#include "screenhack.h" + +#define MIN_ROCKS 1 +#define MIN_DEPTH 2 /* rocks disappear when they get this close */ +#define MAX_DEPTH 60 /* this is where rocks appear */ +#define MIN_SIZE 3 /* how small where pixmaps are not used */ +#define MAX_SIZE 200 /* how big (in pixels) rocks are at depth 1 */ +#define DEPTH_SCALE 100 /* how many ticks there are between depths */ +#define SIN_RESOLUTION 1000 + +#define MAX_DEP 0.3 /* how far the displacement can be (percent) */ +#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 rocks that are moving (1) + or the rocks source (0). */ + +/* 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. + */ + +static double sins [SIN_RESOLUTION]; +static double coss [SIN_RESOLUTION]; +static double depths [(MAX_DEPTH + 1) * DEPTH_SCALE]; + +static Display *dpy; +static Window window; +static int width, height, midx, midy; +static int dep_x, dep_y; +static int ncolors; +static XColor *colors; +static float max_dep; +static GC erase_gc; +static GC *draw_gcs; +static Bool rotate_p; +static Bool move_p; +static int speed; +static Bool threed; +static GC threed_left_gc, threed_right_gc; +static double threed_delta; + +#define GETZDIFF(z) \ + (threed_delta * 40.0 * \ + (1.0 - ((MAX_DEPTH * DEPTH_SCALE / 2) / \ + ((z) + 20.0 * DEPTH_SCALE)))) + +struct rock { + int real_size; + int r; + int theta; + int depth; + int size, x, y; + int diff; + int color; +}; + +static struct rock *rocks; +static int nrocks; +static Pixmap pixmaps [MAX_SIZE]; +static int delay; + +static void rock_compute (struct rock *); +static void rock_draw (struct rock *, Bool draw_p); + +static void +rock_reset (struct rock *rock) +{ + rock->real_size = MAX_SIZE; + rock->r = (SIN_RESOLUTION * 0.7) + (random () % (30 * SIN_RESOLUTION)); + rock->theta = random () % SIN_RESOLUTION; + rock->depth = MAX_DEPTH * DEPTH_SCALE; + rock->color = random() % ncolors; + rock_compute (rock); + rock_draw (rock, True); +} + +static void +rock_tick (struct rock *rock, int d) +{ + if (rock->depth > 0) + { + rock_draw (rock, False); + rock->depth -= speed; + if (rotate_p) + { + rock->theta = (rock->theta + d) % SIN_RESOLUTION; + } + while (rock->theta < 0) + rock->theta += SIN_RESOLUTION; + if (rock->depth < (MIN_DEPTH * DEPTH_SCALE)) + rock->depth = 0; + else + { + rock_compute (rock); + rock_draw (rock, True); + } + } + else if ((random () % 40) == 0) + rock_reset (rock); +} + +static void +rock_compute (struct rock *rock) +{ + double factor = depths [rock->depth]; + double rsize = rock->real_size * factor; + + rock->size = (int) (rsize + 0.5); + rock->diff = (int) GETZDIFF(rock->depth); + rock->x = midx + (coss [rock->theta] * rock->r * factor); + rock->y = midy + (sins [rock->theta] * rock->r * factor); + + if (move_p) + { + double move_factor = (((double) MOVE_STYLE) - + (((double) rock->depth) / + (((double) (MAX_DEPTH + 1)) * + ((double) DEPTH_SCALE)))); + /* move_factor is 0 when the rock is close, 1 when far */ + rock->x += (((double) dep_x) * move_factor); + rock->y += (((double) dep_y) * move_factor); + } +} + +static void +rock_draw (rock, draw_p) + struct rock *rock; + Bool draw_p; +{ + GC gc = (draw_p + ? (threed ? erase_gc : draw_gcs[rock->color]) + : erase_gc); + + if (rock->x <= 0 || rock->y <= 0 || rock->x >= width || rock->y >= height) + { + /* this means that if a rock 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 rock would have been visible again. + Oh well. + */ + if (!move_p) + rock->depth = 0; + return; + } + if (rock->size <= 1) + { + if (threed) + { + if (draw_p) gc = threed_left_gc; + XDrawPoint (dpy, window, gc, rock->x - rock->diff, rock->y); + if (draw_p) gc = threed_right_gc; + XDrawPoint (dpy, window, gc, rock->x + rock->diff, rock->y); + } + else + { + XDrawPoint (dpy, window, gc, rock->x, rock->y); + } + } + else if (rock->size <= MIN_SIZE || !draw_p) + { + if (threed) + { + if (draw_p) gc = threed_left_gc; + XFillRectangle(dpy, window, gc, + rock->x - rock->size / 2 - rock->diff, + rock->y - rock->size / 2, + rock->size, rock->size); + if (draw_p) gc = threed_right_gc; + XFillRectangle(dpy, window, gc, + rock->x - rock->size / 2 + rock->diff, + rock->y - rock->size / 2, + rock->size, rock->size); + } + else + { + XFillRectangle (dpy, window, gc, + rock->x - rock->size/2, rock->y - rock->size/2, + rock->size, rock->size); + } + } + else if (rock->size < MAX_SIZE) + { + if (threed) + { + gc = threed_left_gc; + XCopyPlane(dpy, pixmaps[rock->size], window, gc, + 0, 0, rock->size, rock->size, + rock->x - rock->size / 2 - rock->diff, + rock->y - rock->size / 2, 1L); + gc = threed_right_gc; + XCopyPlane(dpy, pixmaps[rock->size], window, gc, + 0, 0, rock->size, rock->size, + rock->x - rock->size / 2 + rock->diff, + rock->y - rock->size / 2, 1L); + } + else + { + XCopyPlane (dpy, pixmaps [rock->size], window, gc, + 0, 0, rock->size, rock->size, + rock->x - rock->size/2, rock->y - rock->size/2, + 1L); + } + } +} + + +static void +init_pixmaps (Display *dpy, Window window) +{ + int i; + XGCValues gcv; + GC fg_gc = 0, bg_gc = 0; + pixmaps [0] = pixmaps [1] = 0; + for (i = MIN_DEPTH; i < MAX_SIZE; i++) + { + int w = (1+(i/32))<<5; /* server might be faster if word-aligned */ + int h = i; + Pixmap p = XCreatePixmap (dpy, window, w, h, 1); + XPoint points [7]; + pixmaps [i] = p; + if (! p) + { + fprintf (stderr, "%s: couldn't allocate pixmaps", progname); + exit (1); + } + if (! fg_gc) + { /* must use drawable of pixmap, not window (fmh) */ + gcv.foreground = 1; + fg_gc = XCreateGC (dpy, p, GCForeground, &gcv); + gcv.foreground = 0; + bg_gc = XCreateGC (dpy, p, GCForeground, &gcv); + } + XFillRectangle (dpy, p, bg_gc, 0, 0, w, h); + points [0].x = i * 0.15; points [0].y = i * 0.85; + points [1].x = i * 0.00; points [1].y = i * 0.20; + points [2].x = i * 0.30; points [2].y = i * 0.00; + points [3].x = i * 0.40; points [3].y = i * 0.10; + points [4].x = i * 0.90; points [4].y = i * 0.10; + points [5].x = i * 1.00; points [5].y = i * 0.55; + points [6].x = i * 0.45; points [6].y = i * 1.00; + XFillPolygon (dpy, p, fg_gc, points, 7, Nonconvex, CoordModeOrigin); + } + XFreeGC (dpy, fg_gc); + XFreeGC (dpy, bg_gc); +} + + +static int +compute_move(int axe) /* 0 for x, 1 for y */ +{ + static int current_dep[2] = {0, 0}; + static int speed[2] = {0, 0}; + static short direction[2] = {0, 0}; + static int limit[2] = {0, 0}; + int change = 0; + + limit[0] = midx; + limit[1] = midy; + + current_dep[axe] += speed[axe]; /* We adjust the displacement */ + + if (current_dep[axe] > (int) (limit[axe] * max_dep)) + { + if (current_dep[axe] > limit[axe]) + current_dep[axe] = limit[axe]; + direction[axe] = -1; + } /* This is when we reach the upper screen limit */ + if (current_dep[axe] < (int) (-limit[axe] * max_dep)) + { + if (current_dep[axe] < -limit[axe]) + current_dep[axe] = -limit[axe]; + direction[axe] = 1; + } /* This is when we reach the lower screen limit */ + if (direction[axe] == 1) /* We adjust the speed */ + speed[axe] += 1; + else if (direction[axe] == -1) + speed[axe] -= 1; + + if (speed[axe] > MAX_DEP_SPEED) + speed[axe] = MAX_DEP_SPEED; + else if (speed[axe] < -MAX_DEP_SPEED) + speed[axe] = -MAX_DEP_SPEED; + + if (move_p && !(random() % DIRECTION_CHANGE_RATE)) + { + /* We change direction */ + change = random() & 1; + if (change != 1) + { + if (direction[axe] == 0) + direction[axe] = change - 1; /* 0 becomes either 1 or -1 */ + else + direction[axe] = 0; /* -1 or 1 become 0 */ + } + } + return (current_dep[axe]); +} + +static void +tick_rocks (int d) +{ + int i; + + if (move_p) + { + dep_x = compute_move(0); + dep_y = compute_move(1); + } + + for (i = 0; i < nrocks; i++) + rock_tick (&rocks [i], d); +} + + +static void +rocks_once (void) +{ + static int current_delta = 0; /* observer Z rotation */ + static int window_tick = 50; + static int new_delta = 0; + static int dchange_tick = 0; + + if (window_tick++ == 50) + { + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + window_tick = 0; + width = xgwa.width; + height = xgwa.height; + midx = width/2; + midy = height/2; + } + + if (current_delta != new_delta) + { + if (dchange_tick++ == 5) + { + dchange_tick = 0; + if (current_delta < new_delta) + current_delta++; + else + current_delta--; + } + } + else + { + if (! (random() % 50)) + { + new_delta = ((random() % 11) - 5); + if (! (random() % 10)) + new_delta *= 5; + } + } + tick_rocks (current_delta); +} + +static void +init_rocks (Display *d, Window w) +{ + int i; + XGCValues gcv; + Colormap cmap; + XWindowAttributes xgwa; + unsigned int bg; + dpy = d; + window = w; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + delay = get_integer_resource ("delay", "Integer"); + if (delay < 0) delay = 0; + speed = get_integer_resource ("speed", "Integer"); + if (speed < 1) speed = 1; + if (speed > 100) speed = 100; + rotate_p = get_boolean_resource ("rotate", "Boolean"); + move_p = get_boolean_resource ("move", "Boolean"); + if (mono_p) + ncolors = 2; + else + ncolors = get_integer_resource ("colors", "Colors"); + + if (ncolors < 2) + { + ncolors = 2; + mono_p = True; + } + + colors = (XColor *) malloc(ncolors * sizeof(*colors)); + draw_gcs = (GC *) malloc(ncolors * sizeof(*draw_gcs)); + + bg = get_pixel_resource ("background", "Background", dpy, cmap); + colors[0].pixel = bg; + colors[0].flags = DoRed|DoGreen|DoBlue; + XQueryColor(dpy, cmap, &colors[0]); + + ncolors--; + make_random_colormap(dpy, xgwa.visual, cmap, colors+1, &ncolors, True, + True, 0, True); + ncolors++; + + if (ncolors < 2) + { + ncolors = 2; + mono_p = True; + } + + if (mono_p) + { + unsigned int fg = get_pixel_resource("foreground", "Foreground", + dpy, cmap); + colors[1].pixel = fg; + colors[1].flags = DoRed|DoGreen|DoBlue; + XQueryColor(dpy, cmap, &colors[1]); + gcv.foreground = fg; + gcv.background = bg; + draw_gcs[0] = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + draw_gcs[1] = draw_gcs[0]; + } + else + for( i = 0; i < ncolors; i++ ) + { + gcv.foreground = colors[i].pixel; + gcv.background = bg; + draw_gcs[i] = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + } + + gcv.foreground = bg; + erase_gc = XCreateGC (dpy, window, GCForeground|GCBackground, &gcv); + + max_dep = (move_p ? MAX_DEP : 0); + + for (i = 0; i < SIN_RESOLUTION; i++) + { + sins [i] = sin ((((double) i) / (SIN_RESOLUTION / 2)) * M_PI); + coss [i] = cos ((((double) i) / (SIN_RESOLUTION / 2)) * M_PI); + } + /* we actually only need i/speed of these, but wtf */ + for (i = 1; i < (sizeof (depths) / sizeof (depths[0])); i++) + depths [i] = atan (((double) 0.5) / (((double) i) / DEPTH_SCALE)); + depths [0] = M_PI/2; /* avoid division by 0 */ + + threed = get_boolean_resource("use3d", "Boolean"); + if (threed) + { + gcv.background = bg; + gcv.foreground = get_pixel_resource ("left3d", "Foreground", dpy, cmap); + threed_left_gc = XCreateGC (dpy, window, GCForeground|GCBackground,&gcv); + gcv.foreground = get_pixel_resource ("right3d", "Foreground", dpy, cmap); + threed_right_gc = XCreateGC (dpy, window,GCForeground|GCBackground,&gcv); + threed_delta = get_float_resource("delta3d", "Integer"); + } + + /* don't want any exposure events from XCopyPlane */ + for( i = 0; i < ncolors; i++) + XSetGraphicsExposures (dpy, draw_gcs[i], False); + XSetGraphicsExposures (dpy, erase_gc, False); + + nrocks = get_integer_resource ("count", "Count"); + if (nrocks < 1) nrocks = 1; + rocks = (struct rock *) calloc (nrocks, sizeof (struct rock)); + init_pixmaps (dpy, window); + XClearWindow (dpy, window); +} + + + +char *progclass = "Rocks"; + +char *defaults [] = { + "Rocks.background: Black", /* to placate SGI */ + "Rocks.foreground: #E9967A", + "*colors: 5", + "*count: 100", + "*delay: 50000", + "*speed: 100", + "*rotate: true", + "*move: true", + "*use3d: False", + "*left3d: Blue", + "*right3d: Red", + "*delta3d: 1.5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-count", ".count", XrmoptionSepArg, 0 }, + { "-rotate", ".rotate", XrmoptionNoArg, "true" }, + { "-norotate", ".rotate", XrmoptionNoArg, "false" }, + { "-move", ".move", XrmoptionNoArg, "true" }, + { "-nomove", ".move", XrmoptionNoArg, "false" }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-speed", ".speed", XrmoptionSepArg, 0 }, + {"-3d", ".use3d", XrmoptionNoArg, "True"}, + {"-no-3d", ".use3d", XrmoptionNoArg, "False"}, + {"-left3d", ".left3d", XrmoptionSepArg, 0 }, + {"-right3d", ".right3d", XrmoptionSepArg, 0 }, + {"-delta3d", ".delta3d", XrmoptionSepArg, 0 }, + { "-colors", ".colors", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_rocks (dpy, window); + while (1) + { + rocks_once (); + XSync (dpy, True); + if (delay) usleep (delay); + } +} diff --git a/hacks/rocks.man b/hacks/rocks.man new file mode 100644 index 00000000..18d16ab4 --- /dev/null +++ b/hacks/rocks.man @@ -0,0 +1,86 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +rocks - animation of flying through an asteroid field +.SH SYNOPSIS +.B rocks +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-ncolors \fIn\fP] [\-install] [\-visual \fIvisual\fP] [\-count \fIinteger\fP] [\-delay \fIusecs\fP] [\-speed \fIinteger\fP] [\-norotate] [\-nomove] [\-3d] +.SH DESCRIPTION +The \fIrocks\fP program draws an animation of an asteroid field moving past +the observer (or vice versa). Sometimes the observer picks up spin on Z axis. +.SH OPTIONS +.I rocks +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +Make all the rocks the same color. +.TP 8 +.B \-ncolors colors +How many different colors to use. Default 5. Colors are chosen randomly. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-count \fIinteger\fP +Maximum number of rocks to draw on the screen at once. Default 100. +.TP 8 +.B \-speed \fIinteger\fP +A measure of the speed with which the observer and the rocks pass each other, +from 1 to 100. Default 100, meaning ``very fast.'' If you're on a slow +display connection (the animation looks jerky) then try making this number +smaller, and/or decreasing the number of rocks. +.TP 8 +.B \-delay \fImicroseconds\fP +Number of microseconds to delay between each frame. Default 50000, meaning +about 1/20th second. Compare and contrast with \fI\-speed\fP, above. +.TP 8 +.B \-norotate +Don't rotate the observer; just fly through the field on the level. +.TP 8 +.B \-nomove +Don't turn the observer; just fly straight ahead through the field. +.TP 8 +.B \-3d +Do red/blue 3d separations: if you look at the screen with 3d glasses, +the rocks will be \fIjumping\fP right \fIout\fP at you. Oooooh, scaaary! +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH BUGS +There should be an option to display doppler shift (a gravity rainbow.) + +Speed of rotation should be settable. + +Default speed of rotation should be relative to forward velocity. +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Based on Lisp Machine code copyright 1988 John Nguyen . + +Ported to C and X by Jamie Zawinski , 13-aug-92. + +Steering code by Jeremie Petit; 3D code by theiling@coli.uni-sb.de. diff --git a/hacks/rorschach.c b/hacks/rorschach.c new file mode 100644 index 00000000..627f1eb6 --- /dev/null +++ b/hacks/rorschach.c @@ -0,0 +1,138 @@ +/* xscreensaver, Copyright (c) 1992, 1996 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. + * + * 19971004: Johannes Keukelaar : Use helix screen + * eraser. + */ + +#include "screenhack.h" +#include "erase.h" + +static GC draw_gc, erase_gc; +static unsigned int default_fg_pixel; +static int iterations, offset; +static Bool xsym, ysym; +static int sleep_time; + +static void +init_rorschach (Display *dpy, Window window) +{ + XGCValues gcv; + Colormap cmap; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + gcv.foreground = default_fg_pixel = + get_pixel_resource ("foreground", "Foreground", dpy, cmap); + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + gcv.foreground = get_pixel_resource ("background", "Background", dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + iterations = get_integer_resource ("iterations", "Integer"); + offset = get_integer_resource ("offset", "Integer"); + if (offset <= 0) offset = 3; + if (iterations < 10) iterations = 10; + xsym = get_boolean_resource ("xsymmetry", "Symmetry"); + ysym = get_boolean_resource ("ysymmetry", "Symmetry"); +} + +static void +hurm (Display *dpy, Window window) +{ + Colormap cmap; + XWindowAttributes xgwa; + int xlim, ylim, x, y, i, got_color = 0; + XPoint points [4]; + XColor color; + XClearWindow (dpy, window); + XGetWindowAttributes (dpy, window, &xgwa); + xlim = xgwa.width; + ylim = xgwa.height; + cmap = xgwa.colormap; + + if (! mono_p) + hsv_to_rgb (random()%360, 1.0, 1.0, &color.red, &color.green, &color.blue); + if ((!mono_p) && (got_color = XAllocColor (dpy, cmap, &color))) + XSetForeground (dpy, draw_gc, color.pixel); + else + XSetForeground (dpy, draw_gc, default_fg_pixel); + + x = xlim/2; + y = ylim/2; + for (i = 0; i < iterations; i++) + { + int j = 0; + x += ((random () % (1 + (offset << 1))) - offset); + y += ((random () % (1 + (offset << 1))) - offset); + points [j].x = x; + points [j].y = y; + j++; + if (xsym) + { + points [j].x = xlim - x; + points [j].y = y; + j++; + } + if (ysym) + { + points [j].x = x; + points [j].y = ylim - y; + j++; + } + if (xsym && ysym) + { + points [j].x = xlim - x; + points [j].y = ylim - y; + j++; + } + XDrawPoints (dpy, window, draw_gc, points, j, CoordModeOrigin); + XSync (dpy, True); + } + sleep ( sleep_time ); + + erase_full_window(dpy, window); + + XClearWindow (dpy, window); + if (got_color) XFreeColors (dpy, cmap, &color.pixel, 1, 0); + XSync (dpy, True); + sleep (1); +} + + +char *progclass = "Rorschach"; + +char *defaults [] = { + "Rorschach.background: black", /* to placate SGI */ + "Rorschach.foreground: white", + "*xsymmetry: true", + "*ysymmetry: false", + "*iterations: 4000", + "*offset: 4", + "*delay: 5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-iterations", ".iterations", XrmoptionSepArg, 0 }, + { "-offset", ".offset", XrmoptionSepArg, 0 }, + { "-xsymmetry", ".xsymmetry", XrmoptionNoArg, "true" }, + { "-ysymmetry", ".ysymmetry", XrmoptionNoArg, "true" }, + { "-erase-speed", ".eraseSpeed", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + sleep_time = get_integer_resource("delay", "Integer"); + init_rorschach (dpy, window); + while (1) + hurm (dpy, window); +} diff --git a/hacks/rorschach.man b/hacks/rorschach.man new file mode 100644 index 00000000..c89b1704 --- /dev/null +++ b/hacks/rorschach.man @@ -0,0 +1,75 @@ +.TH XScreenSaver 1 "13-aug-92" "X Version 11" +.SH NAME +rorschach - simulate ink-blot patterns +.SH SYNOPSIS +.B rorschach +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-iterations \fIinteger\fP] [\-offset \fIinteger\fP] [\-xsymmetry] [\-ysymmetry] [\-erase\-mode \fIinteger\fP] [\-erase\-speed \fIusecs\fP] [\-delay \fIsecs\fP] +.SH DESCRIPTION +The \fIrorschach\fP program draws random patterns reminiscent of the +psychological test of same name. +.SH OPTIONS +.I rorschach +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-iterations \fIinteger\fP +How many dots should be drawn each time. Default 4000. +.TP 8 +.B \-offset \fIinteger\fP +How far apart the dots should be. Default 4 pixels. +.TP 8 +.B \-xsymmetry +Whether the images should be horizontally symmetrical. Default true. +.TP 8 +.B \-ysymmetry +Whether the images should be vertically symmetrical. Default false. +.TP 8 +.B \-erase\-mode \fIinteger\fP +This sets the erase mode. Mode \-1 chooses a random mode each time. There +are currently 6 modes defined (0\-5). +.TP 8 +.B \-erase\-speed \fIusecs\fP +This controls the speed at which the screen will be erased. (Delay between +erasing of individual lines.) +.TP 8 +.B \-delay \fIseconds\fP +This sets the number of seconds that the figure will be on the screen. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH BUGS +May call your sanity into question. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. diff --git a/hacks/rotor.c b/hacks/rotor.c new file mode 100644 index 00000000..135159e3 --- /dev/null +++ b/hacks/rotor.c @@ -0,0 +1,348 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* rotor --- a swirly rotor */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)rotor.c 4.04 97/07/28 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 + * + * 11-Nov-90: put into xlock by Steve Zellers + * 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" \ + "*size: -6 \n" \ + "*cycles: 20 \n" \ + "*ncolors: 200 \n" +# define SMOOTH_COLORS +# include "xlockmore.h" /* in xscreensaver distribution */ +#else /* STANDALONE */ +# include "xlock.h" /* in xlockmore distribution */ +#endif /* STANDALONE */ + +ModeSpecOpt rotor_opts = +{0, NULL, 0, NULL, NULL}; + +/*- + * A 'batchcount' of 3 or 4 works best! + */ + +#define MAXANGLE 3000.0 /* irrectangular (jwz: 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; +} 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_WIN_WIDTH(mi) / 2; + rp->centery = MI_WIN_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_WIN_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_BATCHCOUNT(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 *) calloc(rp->nsave, sizeof (XPoint)); + + 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; + } + + { + int line_width = MI_SIZE(mi); + if (line_width == 0) + line_width = -5; + if (line_width < 0) + line_width = NRAND(-line_width)+1; + XSetLineAttributes(MI_DISPLAY(mi), MI_GC(mi), line_width, + LineSolid, CapButt, JoinMiter); + } + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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; + + if (!rp->iconifiedscreen) { + thisx = rp->centerx; + thisy = rp->centery; + } else { + thisx = rp->prevcenterx; + thisy = rp->prevcentery; + } + 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_WIN_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_WIN_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; + } + } + } +} + +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)]; + + rp->redrawing = 1; + rp->redrawpos = 1; +} diff --git a/hacks/screenhack.c b/hacks/screenhack.c new file mode 100644 index 00000000..8462d4e7 --- /dev/null +++ b/hacks/screenhack.c @@ -0,0 +1,325 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1997 + * 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. + * + * And remember: X Windows is to graphics hacking as roman numerals are to + * the square root of pi. + */ + +/* This file contains simple code to open a window or draw on the root. + The idea being that, when writing a graphics hack, you can just link + with this .o to get all of the uninteresting junk out of the way. + + - create a procedure `screenhack(dpy, window)' + + - create a variable `char *progclass' which names this program's + resource class. + + - create a variable `char defaults []' for the default resources, and + null-terminate it. + + - create a variable `XrmOptionDescRec options[]' for the command-line, + and null-terminate it. + + And that's it... + */ + +#include +#include +#include +#include +#include +#include +#ifdef HAVE_XMU +# ifndef VMS +# include +# else /* VMS */ +# include +# endif +#else +# include "xmu.h" +#endif +#include "screenhack.h" +#include "version.h" +#include "vroot.h" + +char *progname; +XrmDatabase db; +Bool mono_p; + +static XrmOptionDescRec default_options [] = { + { "-root", ".root", XrmoptionNoArg, "True" }, + { "-window", ".root", XrmoptionNoArg, "False" }, + { "-mono", ".mono", XrmoptionNoArg, "True" }, + { "-install", ".installColormap", XrmoptionNoArg, "True" }, + { "-noinstall",".installColormap", XrmoptionNoArg, "False" }, + { "-visual", ".visualID", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +static char *default_defaults[] = { + "*root: false", + "*geometry: 600x480", /* this should be .geometry, but nooooo... */ + "*mono: false", + "*installColormap: false", + "*visualID: default", + 0 +}; + +static XrmOptionDescRec *merged_options; +static int merged_options_size; +static char **merged_defaults; + +static void +merge_options (void) +{ + int def_opts_size, opts_size; + int def_defaults_size, defaults_size; + + for (def_opts_size = 0; default_options[def_opts_size].option; + def_opts_size++) + ; + for (opts_size = 0; options[opts_size].option; opts_size++) + ; + + merged_options_size = def_opts_size + opts_size; + merged_options = (XrmOptionDescRec *) + malloc ((merged_options_size + 1) * sizeof(*default_options)); + memcpy (merged_options, default_options, + (def_opts_size * sizeof(*default_options))); + memcpy (merged_options + def_opts_size, options, + ((opts_size + 1) * sizeof(*default_options))); + + for (def_defaults_size = 0; default_defaults[def_defaults_size]; + def_defaults_size++) + ; + for (defaults_size = 0; defaults[defaults_size]; defaults_size++) + ; + merged_defaults = (char **) + malloc ((def_defaults_size + defaults_size + 1) * sizeof (*defaults));; + memcpy (merged_defaults, default_defaults, + def_defaults_size * sizeof(*defaults)); + memcpy (merged_defaults + def_defaults_size, defaults, + (defaults_size + 1) * sizeof(*defaults)); +} + + +/* Make the X errors print out the name of this program, so we have some + clue which one has a bug when they die under the screensaver. + */ + +static int +screenhack_ehandler (Display *dpy, XErrorEvent *error) +{ + fprintf (stderr, "\nX error in %s:\n", progname); + if (XmuPrintDefaultErrorMessage (dpy, error, stderr)) + exit (-1); + else + fprintf (stderr, " (nonfatal.)\n"); + return 0; +} + +static Bool +MapNotify_event_p (Display *dpy, XEvent *event, XPointer window) +{ + return (event->xany.type == MapNotify && + event->xvisibility.window == (Window) window); +} + + +#ifdef USE_GL +extern Visual *get_gl_visual (Screen *, const char *, const char *); +#endif + +#ifdef XLOCKMORE +extern void pre_merge_options (void); +#endif + + + +int +main (int argc, char **argv) +{ + XtAppContext app; + Widget toplevel; + Display *dpy; + Window window; + Visual *visual; + Colormap cmap; + Bool root_p; + XEvent event; + Boolean dont_clear /*, dont_map */; + char version[255]; + +#ifdef XLOCKMORE + pre_merge_options (); +#endif + merge_options (); + toplevel = XtAppInitialize (&app, progclass, merged_options, + merged_options_size, &argc, argv, + merged_defaults, 0, 0); + dpy = XtDisplay (toplevel); + db = XtDatabase (dpy); + XtGetApplicationNameAndClass (dpy, &progname, &progclass); + XSetErrorHandler (screenhack_ehandler); + + { + char *v = (char *) strdup(strchr(screensaver_id, ' ')); + char *s = (char *) strchr(v, ','); + *s = 0; + sprintf (version, "%s: from the XScreenSaver%s distribution.", + progclass, v); + free(v); + } + + if (argc > 1) + { + const char *s; + int i; + int x = 18; + int end = 78; + Bool help_p = !strcmp(argv[1], "-help"); + fprintf (stderr, "%s\n", version); + for (s = progclass; *s; s++) fprintf(stderr, " "); + fprintf (stderr, " http://people.netscape.com/jwz/xscreensaver/\n\n"); + + if (!help_p) + fprintf(stderr, "Unrecognised option: %s\n", argv[1]); + fprintf (stderr, "Options include: "); + for (i = 0; i < merged_options_size; i++) + { + char *sw = merged_options [i].option; + Bool argp = (merged_options [i].argKind == XrmoptionSepArg); + int size = strlen (sw) + (argp ? 6 : 0) + 2; + if (x + size >= end) + { + fprintf (stderr, "\n\t\t "); + x = 18; + } + x += size; + fprintf (stderr, "%s", sw); + if (argp) fprintf (stderr, " "); + if (i != merged_options_size - 1) fprintf (stderr, ", "); + } + fprintf (stderr, ".\n"); + exit (help_p ? 0 : 1); + } + + dont_clear = get_boolean_resource ("dontClearRoot", "Boolean"); +/*dont_map = get_boolean_resource ("dontMapWindow", "Boolean"); */ + mono_p = get_boolean_resource ("mono", "Boolean"); + if (CellsOfScreen (DefaultScreenOfDisplay (dpy)) <= 2) + mono_p = True; + + root_p = get_boolean_resource ("root", "Boolean"); + if (root_p) + { + XWindowAttributes xgwa; + window = RootWindowOfScreen (XtScreen (toplevel)); + XtDestroyWidget (toplevel); + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + visual = xgwa.visual; + } + else + { + Boolean def_visual_p; + Screen *screen = XtScreen (toplevel); + +#ifdef USE_GL + visual = get_gl_visual (screen, "visualID", "VisualID"); +#else + visual = get_visual_resource (screen, "visualID", "VisualID", False); +#endif + + if (toplevel->core.width <= 0) + toplevel->core.width = 600; + if (toplevel->core.height <= 0) + toplevel->core.height = 480; + + def_visual_p = (visual == DefaultVisualOfScreen (screen)); + + if (!def_visual_p) + { + unsigned int bg, bd; + Widget new; + + cmap = XCreateColormap (dpy, RootWindowOfScreen(screen), + visual, AllocNone); + bg = get_pixel_resource ("background", "Background", dpy, cmap); + bd = get_pixel_resource ("borderColor", "Foreground", dpy, cmap); + + new = XtVaAppCreateShell (progname, progclass, + topLevelShellWidgetClass, dpy, + XtNmappedWhenManaged, False, + XtNvisual, visual, + XtNdepth, visual_depth (screen, visual), + XtNwidth, toplevel->core.width, + XtNheight, toplevel->core.height, + XtNcolormap, cmap, + XtNbackground, (Pixel) bg, + XtNborderColor, (Pixel) bd, + 0); + XtDestroyWidget (toplevel); + toplevel = new; + XtRealizeWidget (toplevel); + window = XtWindow (toplevel); + } + else + { + XtVaSetValues (toplevel, XtNmappedWhenManaged, False, 0); + XtRealizeWidget (toplevel); + window = XtWindow (toplevel); + + if (get_boolean_resource ("installColormap", "InstallColormap")) + { + cmap = XCreateColormap (dpy, window, + DefaultVisualOfScreen (XtScreen (toplevel)), + AllocNone); + XSetWindowColormap (dpy, window, cmap); + } + else + { + cmap = DefaultColormap (dpy, DefaultScreen (dpy)); + } + } + +/* + if (dont_map) + { + XtVaSetValues (toplevel, XtNmappedWhenManaged, False, 0); + XtRealizeWidget (toplevel); + } + else +*/ + { + XtPopup (toplevel, XtGrabNone); + } + + XtVaSetValues(toplevel, XtNtitle, version, 0); + } + + if (!dont_clear) + { + XSetWindowBackground (dpy, window, + get_pixel_resource ("background", "Background", + dpy, cmap)); + XClearWindow (dpy, window); + } + + if (!root_p) + /* wait for it to be mapped */ + XIfEvent (dpy, &event, MapNotify_event_p, (XPointer) window); + + XSync (dpy, False); + srandom ((int) time ((time_t *) 0)); + screenhack (dpy, window); /* doesn't return */ + return 0; +} diff --git a/hacks/screenhack.h b/hacks/screenhack.h new file mode 100644 index 00000000..a92cf70d --- /dev/null +++ b/hacks/screenhack.h @@ -0,0 +1,98 @@ +/* xscreensaver, Copyright (c) 1992-1997 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. + */ + +/* Found in Don Hopkins' .plan file: + * + * The color situation is a total flying circus. The X approach to + * device independence is to treat everything like a MicroVax framebuffer + * on acid. A truely portable X application is required to act like the + * persistent customer in the Monty Python ``Cheese Shop'' sketch. Even + * the simplest applications must answer many difficult questions, like: + * + * WHAT IS YOUR DISPLAY? + * display = XOpenDisplay("unix:0"); + * WHAT IS YOUR ROOT? + * root = RootWindow(display, DefaultScreen(display)); + * AND WHAT IS YOUR WINDOW? + * win = XCreateSimpleWindow(display, root, 0, 0, 256, 256, 1, + * BlackPixel(display, DefaultScreen(display)), + * WhitePixel(display, DefaultScreen(display))) + * OH ALL RIGHT, YOU CAN GO ON. + * + * WHAT IS YOUR DISPLAY? + * display = XOpenDisplay("unix:0"); + * WHAT IS YOUR COLORMAP? + * cmap = DefaultColormap(display, DefaultScreen(display)); + * AND WHAT IS YOUR FAVORITE COLOR? + * favorite_color = 0; / * Black. * / + * / * Whoops! No, I mean: * / + * favorite_color = BlackPixel(display, DefaultScreen(display)); + * / * AAAYYYYEEEEE!! (client dumps core & falls into the chasm) * / + * + * WHAT IS YOUR DISPLAY? + * display = XOpenDisplay("unix:0"); + * WHAT IS YOUR VISUAL? + * struct XVisualInfo vinfo; + * if (XMatchVisualInfo(display, DefaultScreen(display), + * 8, PseudoColor, &vinfo) != 0) + * visual = vinfo.visual; + * AND WHAT IS THE NET SPEED VELOCITY OF AN XConfigureWindow REQUEST? + * / * Is that a SubStructureRedirectMask or a ResizeRedirectMask? * / + * WHAT?! HOW AM I SUPPOSED TO KNOW THAT? + * AAAAUUUGGGHHH!!!! (server dumps core & falls into the chasm) + */ + +#ifndef __SCREENHACK_H__ +#define __SCREENHACK_H__ + +#include + +#include "config.h" + +#ifdef __hpux + /* Which of the ten billion standards does values.h belong to? + What systems always have it? */ +# include +#endif + +#include + +#include +#include +#include + +/* M_PI ought to have been defined in math.h, but... */ +#ifndef M_PI +# define M_PI 3.1415926535 +#endif + +#ifndef M_PI_2 +# define M_PI_2 1.5707963267 +#endif + +#include "yarandom.h" +#include "usleep.h" +#include "resources.h" +#include "hsv.h" +#include "colors.h" +#include "grabscreen.h" +#include "visual.h" + +extern Bool mono_p; +extern char *progname; +extern char *progclass; +extern XrmDatabase db; +extern XrmOptionDescRec options []; +extern char *defaults []; + +extern void screenhack (Display*,Window); + +#endif /* __SCREENHACK_H__ */ diff --git a/hacks/sierpinski.c b/hacks/sierpinski.c new file mode 100644 index 00000000..de108a70 --- /dev/null +++ b/hacks/sierpinski.c @@ -0,0 +1,184 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* sierpinski --- Sierpinski's triangle fractal */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)sierpinski.c 4.05 97/09/19 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. + * + * Revision History: + * 18-Sep-97: 3D version Antti Kuntsi . + * 20-May-97: Changed the name tri to sierpinski for more compatiblity + * 10-May-97: jwz@netscape.com: turned into a standalone program. + * 05-Sep-96: Desmond Daignault Datatimes Incorporated + * . + */ + +#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" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt sierpinski_opts = +{0, NULL, 0, NULL, NULL}; + +#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; + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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_WIN_WIDTH(mi); + sp->height = MI_WIN_HEIGHT(mi); + + sp->total_npoints = MI_BATCHCOUNT(mi); + if (sp->total_npoints < 1) + sp->total_npoints = 1; + sp->corners = MI_SIZE(mi); + if (sp->corners < 3 || sp->corners > 4) { + sp->corners = (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; + + if (MI_NPIXELS(mi) <= 2) + XSetForeground(display, gc, MI_WIN_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) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/sierpinski.man b/hacks/sierpinski.man new file mode 100644 index 00000000..e2bc41a6 --- /dev/null +++ b/hacks/sierpinski.man @@ -0,0 +1,65 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +sierpinski - draws Sierpinski triangle fractals +.SH SYNOPSIS +.B sierpinski +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIsierpinski\fP program draws Sierpinski triangle fractals. +.SH OPTIONS +.I sierpinski +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Desmond Daignault , 05-Sep-96. (Original +xlock version was called tri.c.) + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. (Renamed to sierpinski.) diff --git a/hacks/slidescreen.c b/hacks/slidescreen.c new file mode 100644 index 00000000..f910dbe7 --- /dev/null +++ b/hacks/slidescreen.c @@ -0,0 +1,362 @@ +/* xscreensaver, Copyright (c) 1992, 1993, 1994, 1996, 1997 + * 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. + */ + +#include "screenhack.h" + +static int grid_size; +static int pix_inc; +static int hole_x, hole_y; +static int bitmap_w, bitmap_h; +static int xoff, yoff; +static int grid_w, grid_h; +static int delay, delay2; +static GC gc; +static int max_width, max_height; + +static void +init_slide (Display *dpy, Window window) +{ + int i; + XGCValues gcv; + XWindowAttributes xgwa; + long gcflags; + int border; + unsigned long fg, bg; + Drawable d; + Colormap cmap; + Visual *visual; + + XGetWindowAttributes (dpy, window, &xgwa); + grab_screen_image (xgwa.screen, window); + + XGetWindowAttributes (dpy, window, &xgwa); /* re-retrieve colormap */ + cmap = xgwa.colormap; + visual = xgwa.visual; + max_width = xgwa.width; + max_height = xgwa.height; + + delay = get_integer_resource ("delay", "Integer"); + delay2 = get_integer_resource ("delay2", "Integer"); + grid_size = get_integer_resource ("gridSize", "Integer"); + pix_inc = get_integer_resource ("pixelIncrement", "Integer"); + border = get_integer_resource ("internalBorderWidth", "InternalBorderWidth"); + + { + XColor fgc, bgc; + char *fgs = get_string_resource("background", "Background"); + char *bgs = get_string_resource("foreground", "Foreground"); + Bool fg_ok, bg_ok; + if (!XParseColor (dpy, cmap, fgs, &fgc)) + XParseColor (dpy, cmap, "black", &bgc); + if (!XParseColor (dpy, cmap, bgs, &bgc)) + XParseColor (dpy, cmap, "gray", &fgc); + + fg_ok = XAllocColor (dpy, cmap, &fgc); + bg_ok = XAllocColor (dpy, cmap, &bgc); + + /* If we weren't able to allocate the two colors we want from the + colormap (which is likely if the screen has been grabbed on an + 8-bit SGI visual -- don't ask) then just go through the map + and find the closest color to the ones we wanted, and use those + pixels without actually allocating them. + */ + if (fg_ok) + fg = fgc.pixel; + else + fg = 0; + + if (bg_ok) + bg = bgc.pixel; + else + bg = 1; + + if (!fg_ok || bg_ok) + { + unsigned long fgd = ~0; + unsigned long bgd = ~0; + int max = visual_cells (xgwa.screen, visual); + XColor *all = (XColor *) calloc(sizeof (*all), max); + for (i = 0; i < max; i++) + { + all[i].flags = DoRed|DoGreen|DoBlue; + all[i].pixel = i; + } + XQueryColors (dpy, cmap, all, max); + for(i = 0; i < max; i++) + { + long rd, gd, bd; + unsigned long d; + if (!fg_ok) + { + rd = (all[i].red >> 8) - (fgc.red >> 8); + gd = (all[i].green >> 8) - (fgc.green >> 8); + bd = (all[i].blue >> 8) - (fgc.blue >> 8); + if (rd < 0) rd = -rd; + if (gd < 0) gd = -gd; + if (bd < 0) bd = -bd; + d = (rd << 1) + (gd << 2) + bd; + if (d < fgd) + { + fgd = d; + fg = all[i].pixel; + if (d == 0) + fg_ok = True; + } + } + + if (!bg_ok) + { + rd = (all[i].red >> 8) - (bgc.red >> 8); + gd = (all[i].green >> 8) - (bgc.green >> 8); + bd = (all[i].blue >> 8) - (bgc.blue >> 8); + if (rd < 0) rd = -rd; + if (gd < 0) gd = -gd; + if (bd < 0) bd = -bd; + d = (rd << 1) + (gd << 2) + bd; + if (d < bgd) + { + bgd = d; + bg = all[i].pixel; + if (d == 0) + bg_ok = True; + } + } + + if (fg_ok && bg_ok) + break; + } + XFree(all); + } + } + + + if (delay < 0) delay = 0; + if (delay2 < 0) delay2 = 0; + if (pix_inc < 1) pix_inc = 1; + if (grid_size < 1) grid_size = 1; + + gcv.foreground = fg; + gcv.function = GXcopy; + gcv.subwindow_mode = IncludeInferiors; + gcflags = GCForeground |GCFunction; + if (use_subwindow_mode_p(xgwa.screen, window)) /* see grabscreen.c */ + gcflags |= GCSubwindowMode; + gc = XCreateGC (dpy, window, gcflags, &gcv); + + XGetWindowAttributes (dpy, window, &xgwa); + bitmap_w = xgwa.width; + bitmap_h = xgwa.height; + + grid_w = bitmap_w / grid_size; + grid_h = bitmap_h / grid_size; + hole_x = random () % grid_w; + hole_y = random () % grid_h; + xoff = (bitmap_w - (grid_w * grid_size)) / 2; + yoff = (bitmap_h - (grid_h * grid_size)) / 2; + + d = window; + + if (border) + { + int half = border/2; + int half2 = (border & 1 ? half+1 : half); + XSetForeground(dpy, gc, bg); + for (i = 0; i < bitmap_w; i += grid_size) + { + int j; + for (j = 0; j < bitmap_h; j += grid_size) + XDrawRectangle (dpy, d, gc, + xoff+i+half2, yoff+j+half2, + grid_size-border-1, grid_size-border-1); + } + + XSetForeground(dpy, gc, fg); + for (i = 0; i <= bitmap_w; i += grid_size) + XFillRectangle (dpy, d, gc, xoff+i-half, yoff, border, bitmap_h); + for (i = 0; i <= bitmap_h; i += grid_size) + XFillRectangle (dpy, d, gc, xoff, yoff+i-half, bitmap_w, border); + } + + if (xoff) + { + XFillRectangle (dpy, d, gc, 0, 0, xoff, bitmap_h); + XFillRectangle (dpy, d, gc, bitmap_w - xoff, 0, xoff, bitmap_h); + } + if (yoff) + { + XFillRectangle (dpy, d, gc, 0, 0, bitmap_w, yoff); + XFillRectangle (dpy, d, gc, 0, bitmap_h - yoff, bitmap_w, yoff); + } + + XSync (dpy, True); + if (delay2) usleep (delay2 * 2); + for (i = 0; i < grid_size; i += pix_inc) + { + XPoint points [3]; + points[0].x = xoff + grid_size * hole_x; + points[0].y = yoff + grid_size * hole_y; + points[1].x = points[0].x + grid_size; + points[1].y = points[0].y; + points[2].x = points[0].x; + points[2].y = points[0].y + i; + XFillPolygon (dpy, window, gc, points, 3, Convex, CoordModeOrigin); + + points[1].x = points[0].x; + points[1].y = points[0].y + grid_size; + points[2].x = points[0].x + i; + points[2].y = points[0].y + grid_size; + XFillPolygon (dpy, window, gc, points, 3, Convex, CoordModeOrigin); + + points[0].x = points[1].x + grid_size; + points[0].y = points[1].y; + points[2].x = points[0].x; + points[2].y = points[0].y - i; + XFillPolygon (dpy, window, gc, points, 3, Convex, CoordModeOrigin); + + points[1].x = points[0].x; + points[1].y = points[0].y - grid_size; + points[2].x = points[1].x - i; + points[2].y = points[1].y; + XFillPolygon (dpy, window, gc, points, 3, Convex, CoordModeOrigin); + + XSync (dpy, True); + if (delay) usleep (delay); + } + + XFillRectangle (dpy, window, gc, + xoff + grid_size * hole_x, + yoff + grid_size * hole_y, + grid_size, grid_size); +} + +static void +slide1 (Display *dpy, Window window) +{ + /* this code is a total kludge, but who cares, it works... */ + int i, x, y, ix, iy, dx, dy, dir, w, h, size, inc; + static int last = -1; + do { + dir = random () % 4; + switch (dir) + { + case 0: dx = 0, dy = 1; break; + case 1: dx = -1, dy = 0; break; + case 2: dx = 0, dy = -1; break; + case 3: dx = 1, dy = 0; break; + default: abort (); + } + } while (dir == last || + hole_x + dx < 0 || hole_x + dx >= grid_w || + hole_y + dy < 0 || hole_y + dy >= grid_h); + if (grid_w > 1 && grid_h > 1) + last = (dir == 0 ? 2 : dir == 2 ? 0 : dir == 1 ? 3 : 1); + + switch (dir) + { + case 0: size = 1 + (random()%(grid_h - hole_y - 1)); h = size; w = 1; break; + case 1: size = 1 + (random()%hole_x); w = size; h = 1; break; + case 2: size = 1 + (random()%hole_y); h = size; w = 1; break; + case 3: size = 1 + (random()%(grid_w - hole_x - 1)); w = size; h = 1; break; + default: abort (); + } + + if (dx == -1) hole_x -= (size - 1); + else if (dy == -1) hole_y -= (size - 1); + + ix = x = xoff + (hole_x + dx) * grid_size; + iy = y = yoff + (hole_y + dy) * grid_size; + inc = pix_inc; + for (i = 0; i < grid_size; i += inc) + { + int fx, fy, tox, toy; + if (inc + i > grid_size) + inc = grid_size - i; + tox = x - dx * inc; + toy = y - dy * inc; + + fx = (x < 0 ? 0 : x > max_width ? max_width : x); + fy = (y < 0 ? 0 : y > max_height ? max_height : y); + tox = (tox < 0 ? 0 : tox > max_width ? max_width : tox); + toy = (toy < 0 ? 0 : toy > max_height ? max_height : toy); + + XCopyArea (dpy, window, window, gc, + fx, fy, + grid_size * w, grid_size * h, + tox, toy); + + x -= dx * inc; + y -= dy * inc; + switch (dir) + { + case 0: XFillRectangle (dpy, window, gc, + ix, y + grid_size * h, grid_size * w, iy - y); + break; + case 1: XFillRectangle (dpy, window, gc, ix, iy, x - ix, grid_size * h); + break; + case 2: XFillRectangle (dpy, window, gc, ix, iy, grid_size * w, y - iy); + break; + case 3: XFillRectangle (dpy, window, gc, + x + grid_size * w, iy, ix - x, grid_size * h); + break; + } + + XSync (dpy, True); + if (delay) usleep (delay); + } + switch (dir) + { + case 0: hole_y += size; break; + case 1: hole_x--; break; + case 2: hole_y--; break; + case 3: hole_x += size; break; + } +} + + +char *progclass = "SlidePuzzle"; + +char *defaults [] = { + "*dontClearRoot: True", + +#ifdef __sgi /* really, HAVE_READ_DISPLAY_EXTENSION */ + "*visualID: Best", +#endif + + "SlidePuzzle.background: Black", + "SlidePuzzle.foreground: Gray", + "*gridSize: 70", + "*pixelIncrement: 10", + "*internalBorderWidth: 4", + "*delay: 50000", + "*delay2: 1000000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-grid-size", ".gridSize", XrmoptionSepArg, 0 }, + { "-ibw", ".internalBorderWidth", XrmoptionSepArg, 0 }, + { "-increment", ".pixelIncrement", XrmoptionSepArg, 0 }, + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + init_slide (dpy, window); + while (1) + { + slide1 (dpy, window); + if (delay2) usleep (delay2); + } +} diff --git a/hacks/slidescreen.man b/hacks/slidescreen.man new file mode 100644 index 00000000..fac50033 --- /dev/null +++ b/hacks/slidescreen.man @@ -0,0 +1,92 @@ +.TH XScreenSaver 1 "24-Nov-97" "X Version 11" +.SH NAME +slidescreen - permute the screen image like an 8-puzzle +.SH SYNOPSIS +.B slidescreen +[\-display \fIhost:display.screen\fP] [\-background \fIcolor\fP] [\-grid-size \fIpixels\fP] [\-ibw \fIpixels\fP] [\-increment \fIpixels\fP] [\-delay \fIusecs\fP] [\-delay2 \fIusecs\fP] [\-window] [\-root] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIslidescreen\fP program takes an image of the screen, divides it into +a grid, deletes a random square of that grid, and then randomly slides +one of the neighbors of this "hole" into the hole (and repeat.) +.SH OPTIONS +.I slidescreen +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-grid-size \fIpixels\fP +The size of the grid cells. Default 70 pixels. +.TP 8 +.B \-ibw \fIpixels\fP +The size of the "gutter" between grid cells. Default 1 pixel. +.TP 8 +.B \-increment \fIpixels\fP +How many pixels by which a piece should be moved when sliding to a new +location. Default 10 pixels. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation of +the motion of each segment. Default 50000, which is 0.05 seconds. This +is closely related to the \fI\-increment\fP parameter. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between the end of the motion of +one segment and the beginning of the motion of another. Default 1000000, +which is one second. +.SH RESOURCES +On some systems (currently, only SGIs), this program can, instead of grabbing +a desktop image, grab a frame of video from an external camera and manipulate +that instead. The following resources control that. +.PP +.TP 8 +.B grabVideoProbability \fR(Float)\fP +What portion of the time to grab video rather than a screen image, +between 0.0 and 1.0. Defaults to 0.5, or half the time. +.TP 8 +.B videoDevice \fR(Integer)\fP +The number of the default video input device to check first. If unspecified, +the default camera (from videopanel(1)) will be checked first. After that, all +other available video input devices will be checked in order. + +The first one which produces a non-black image will be used. If all images +are black, the others will be re-checked a few times before giving up and +falling back to simply grabbing a desktop image (but note that this takes a +few seconds, so if you don't actually have any video sources hooked up, you +should consider turning off video grabbing by setting +\fBgrabVideoProbability\fP to 0.0.) +.TP 8 +.B videoGain \fR(Float)\fP +The amount by which to brighten the grabbed image. This defaults to 2.2. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Jamie Zawinski , 3-dec-92. diff --git a/hacks/slip.c b/hacks/slip.c new file mode 100644 index 00000000..e21bd2c4 --- /dev/null +++ b/hacks/slip.c @@ -0,0 +1,301 @@ +/* -*- Mode: C; tab-width: 4 -*- + * slip --- lots of blits. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)slip.c 4.00 97/01/01 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. + * + * Revision History: + * 12-May-97: jwz@netscape.com: turned into a standalone program. + * 01-Dec-95: Patched for VMS . + */ + +#ifdef STANDALONE +# define PROGCLASS "Slip" +# define HACK_INIT init_slip +# define HACK_DRAW draw_slip +# define slip_opts xlockmore_opts +# define DEFAULTS "*count: 35 \n" \ + "*cycles: 50 \n" \ + "*delay: 50000 \n" \ + "*ncolors: 200 \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt slip_opts = { + 0, NULL, 0, NULL, NULL }; + +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 = 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 = 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) + { + grab_screen_image(DefaultScreenOfDisplay (MI_DISPLAY(mi)), + MI_WINDOW(mi)); + return; + } +#endif + + s->backwards = LRAND() & 1; /* jwz: go the other way sometimes */ + + if (s->first_time || (0 == halfrandom(10))) { + XClearWindow(display, MI_WINDOW(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_WIN_WHITE_PIXEL(mi)); + else + XSetForeground(display, gc, MI_WIN_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_WIN_WHITE_PIXEL(mi)); + else + XSetForeground(display, gc, MI_WIN_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_WIN_WIDTH(mi); + sp->height = MI_WIN_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_BATCHCOUNT(mi) * MI_CYCLES(mi); + + 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 lut[] = + {0, 0, 0, 1, 1, 1, 2}; + + prepare_screen(mi, s); + s->nblits_remaining = MI_BATCHCOUNT(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; + } +} diff --git a/hacks/slip.man b/hacks/slip.man new file mode 100644 index 00000000..f18d367f --- /dev/null +++ b/hacks/slip.man @@ -0,0 +1,93 @@ +.TH XScreenSaver 1 "24-Nov-97" "X Version 11" +.SH NAME +slip - sucks your screen into a jet engine +.SH SYNOPSIS +.B slip +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-iterations \fIinteger\fP] [\-points \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-delay2 \fImicroseconds\fP] +.SH DESCRIPTION +The \fIslip\fP program does lots of blits and chews up your screen image. +.SH OPTIONS +.I slip +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 128. +The colors used cycle through the hue, making N stops around +the color wheel. +.TP 8 +.B \-count \fIinteger\fP +How many whooziwhatsis to generate. Default 35. +.TP 8 +.B \-cycles \fIinteger\fP +How long to frobnicate. Default 50. +.TP 8 +.B \-delay \fImicroseconds\fP +How long we should wait between drawing each step. Default 50000, +or about 1/20th second. + +.SH RESOURCES +On some systems (currently, only SGIs), this program can, instead of grabbing +a desktop image, grab a frame of video from an external camera and manipulate +that instead. The following resources control that. +.PP +.TP 8 +.B grabVideoProbability \fR(Float)\fP +What portion of the time to grab video rather than a screen image, +between 0.0 and 1.0. Defaults to 0.5, or half the time. +.TP 8 +.B videoDevice \fR(Integer)\fP +The number of the default video input device to check first. If unspecified, +the default camera (from videopanel(1)) will be checked first. After that, all +other available video input devices will be checked in order. + +The first one which produces a non-black image will be used. If all images +are black, the others will be re-checked a few times before giving up and +falling back to simply grabbing a desktop image (but note that this takes a +few seconds, so if you don't actually have any video sources hooked up, you +should consider turning off video grabbing by setting +\fBgrabVideoProbability\fP to 0.0.) +.TP 8 +.B videoGain \fR(Float)\fP +The amount by which to brighten the grabbed image. This defaults to 2.2. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1992 by Scott Draves. + +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. +.SH AUTHOR +Scott Graves . + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 18-Oct-93. diff --git a/hacks/sphere.c b/hacks/sphere.c new file mode 100644 index 00000000..728c7240 --- /dev/null +++ b/hacks/sphere.c @@ -0,0 +1,246 @@ +/* -*- Mode: C; tab-width: 4 -*- + * sphere.c --- draw a bunch of shaded spheres + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)sphere.c 4.00 97/01/01 xlockmore"; +#endif + +/* 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. + * *************************************************************************** + * + * Revision History: + * 30-May-97: jwz@netscape.com: made it go vertically as well as horizontally. + * 27-May-97: jwz@netscape.com: turned into a standalone program. + * 2-Sep-93: xlock version (David Bagley bagleyd@bigfoot.com) + * 1988: Revised to use SunView canvas instead of gfxsw Sun Microsystems + * 1982: Orignal Algorithm Tom Duff Lucasfilm Ltd. + */ + +#ifdef STANDALONE +# define PROGCLASS "Sphere" +# define HACK_INIT init_sphere +# define HACK_DRAW draw_sphere +# define sphere_opts xlockmore_opts +# define DEFAULTS "*delay: 1000 \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 */ + +ModeSpecOpt sphere_opts = { + 0, NULL, 0, NULL, NULL }; + +/*- + * (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 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_WIN_WIDTH(mi); + sp->height = MI_WIN_HEIGHT(mi); + sp->points = (XPoint *) malloc(sp->height * sizeof (XPoint)); + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + + sp->dirx = 1; +} + +void +draw_sphere(ModeInfo * mi) +{ + Display *display = MI_DISPLAY(mi); + GC gc = MI_GC(mi); + spherestruct *sp = &spheres[MI_SCREEN(mi)]; + register minx = 0, maxx = 0, miny = 0, maxy = 0, npts = 0; + + 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 = (LRAND() & 1) * 2 - 1; + sp->diry = 0; + } else { + sp->dirx = 0; + sp->diry = (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_WIN_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_WIN_WHITE_PIXEL(mi)); + + if (sp->dirx) + for (sp->y = miny; sp->y <= maxy; sp->y++) + if ((NRAND(sp->radius * NR)) <= + (NX * sp->x + NY * sp->y + NZ * + SQRT(sp->radius * sp->radius - sp->x * sp->x - sp->y * sp->y))) { + sp->points[npts].x = sp->x + sp->x0; + sp->points[npts].y = sp->y + sp->y0; + npts++; + } + if (sp->diry) + for (sp->x = minx; sp->x <= maxx; sp->x++) + if ((NRAND(sp->radius * NR)) <= + (NX * sp->x + NY * sp->y + NZ * + SQRT(sp->radius * sp->radius - sp->x * sp->x - sp->y * sp->y))) { + 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)]; + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + sp->x = -sp->radius; +} diff --git a/hacks/sphere.man b/hacks/sphere.man new file mode 100644 index 00000000..89189884 --- /dev/null +++ b/hacks/sphere.man @@ -0,0 +1,58 @@ +.TH XScreenSaver 1 "27-May-97" "X Version 11" +.SH NAME +sphere - draws shaded spheres +.SH SYNOPSIS +.B sphere +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] + +.SH DESCRIPTION +The \fIsphere\fP program draws shaded spheres. +.SH OPTIONS +.I sphere +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1988 by Sun Microsystems, Inc. + +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. +.SH AUTHOR +Sun Microsystems, Inc, 1988. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 27-May-97. diff --git a/hacks/spiral.c b/hacks/spiral.c new file mode 100644 index 00000000..24b2b73c --- /dev/null +++ b/hacks/spiral.c @@ -0,0 +1,300 @@ +/* -*- Mode: C; tab-width: 4 -*- + * spiral --- low cpu screen design. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)spiral.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1994 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. + * + * Idea based on a graphics demo I saw a *LONG* time ago. + * + * See xlock.c for copying information. + * + * Revision History: + * 10-May-97: jwz@netscape.com: 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. + * Copyright (c) 1994 by Darrick Brown. + * + * 03-Mar-95: Cleaned up code. + * 12-Jul-94: Written. + */ + +#ifdef STANDALONE +# define PROGCLASS "Spiral" +# define HACK_INIT init_spiral +# define HACK_DRAW draw_spiral +# define spiral_opts xlockmore_opts +# define DEFAULTS "*count: 40 \n" \ + "*cycles: 350 \n" \ + "*delay: 50000 \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 */ + +ModeSpecOpt spiral_opts = { + 0, NULL, 0, NULL, NULL }; + +#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_WIN_WIDTH(mi); + sp->height = MI_WIN_HEIGHT(mi); + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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_BATCHCOUNT(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; + + if (sp->erase == 1) { + XSetForeground(display, gc, MI_WIN_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_WIN_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)]; + + sp->redrawing = 1; + sp->redrawpos = 0; +} diff --git a/hacks/spiral.man b/hacks/spiral.man new file mode 100644 index 00000000..eeb8850b --- /dev/null +++ b/hacks/spiral.man @@ -0,0 +1,67 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +spiral - draws moving circular spiral patterns +.SH SYNOPSIS +.B spiral +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIspiral\fP program draws moving circular spiral patterns +.SH OPTIONS +.I spiral +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.TP 8 +.B \-count \fIinteger\fP +Default 40. +.TP 8 +.B \-cycles \fIinteger\fP +Default 350. + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 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. +.SH AUTHOR +Darrick Brown, 1994. + +Improved by Peter Schmitzberger , 24-Jul-95. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/starfish.c b/hacks/starfish.c new file mode 100644 index 00000000..fa5a7124 --- /dev/null +++ b/hacks/starfish.c @@ -0,0 +1,535 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +#include +#include /* for gettimeofday() */ +#include "screenhack.h" +#include "spline.h" + + +static Colormap cmap; +static Bool cycle_p; +static XColor *colors; +static int ncolors; +static int fg_index; +static GC gc; + +#define SCALE 1000 /* fixed-point math, for sub-pixel motion */ + + +#define RAND(n) ((long) ((random() & 0x7fffffff) % ((long) (n)))) +#define RANDSIGN() ((random() & 1) ? 1 : -1) + +enum starfish_mode { + pulse, + zoom +}; + + +struct starfish { + 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 */ + long 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 *spline; + XPoint *prev; + int n_prev; +}; + +static struct starfish * +make_starfish (int maxx, int maxy, int size) +{ + struct starfish *s = (struct starfish *) calloc(1, sizeof(*s)); + int i; + int mid; + + s->blob_p = get_boolean_resource ("blob", "Blob"); + s->elasticity = SCALE * get_float_resource ("thickness", "Thickness"); + + if (s->elasticity == 0) + /* bell curve from 0-15, avg 7.5 */ + s->elasticity = RAND(5*SCALE) + RAND(5*SCALE) + RAND(5*SCALE); + + s->rotv = get_float_resource ("rotation", "Rotation"); + if (s->rotv == -1) + /* bell curve from 0-12 degrees, avg 6 */ + s->rotv = frand(4) + frand(4) + frand(4); + + s->rotv /= 360; /* convert degrees to ratio */ + + if (s->blob_p) + { + s->elasticity *= 3; + s->rotv *= 3; + } + + s->rot_max = s->rotv * 2; + s->rota = 0.0004 + frand(0.0002); + + + if (! (random() % 20)) + size *= frand(0.35) + frand(0.35) + 0.3; + + { + static char skips[] = { 2, 2, 2, 2, + 3, 3, 3, + 6, 6, + 12 }; + s->skip = skips[random() % sizeof(skips)]; + } + + if (! (random() % (s->skip == 2 ? 3 : 12))) + s->mode = zoom; + else + s->mode = pulse; + + maxx *= SCALE; + maxy *= SCALE; + size *= SCALE; + + s->max_r = size; + s->min_r = 0; + + if (s->min_r < (5*SCALE)) s->min_r = (5*SCALE); + mid = ((s->min_r + s->max_r) / 2); + + s->x = maxx/2; + s->y = maxy/2; + + s->th = frand(M_PI+M_PI) * 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 (s->skip > 3) + nsizes -= 4; + s->npoints = s->skip * sizes[random() % nsizes]; + } + + s->spline = make_spline (s->npoints); + s->r = (long *) malloc (sizeof(*s->r) * s->npoints); + + for (i = 0; i < s->npoints; i++) + s->r[i] = ((i % s->skip) == 0) ? 0 : size; + + return s; +} + + +static void +free_starfish (struct starfish *s) +{ + if (s->r) free (s->r); + if (s->prev) free (s->prev); + if (s->spline) + { + if (s->spline->control_x) free (s->spline->control_x); + if (s->spline->control_y) free (s->spline->control_y); + if (s->spline->points) free (s->spline->points); + free (s->spline); + } + free (s); +} + + +static void +throb_starfish (struct starfish *s) +{ + int i; + double frac = ((M_PI+M_PI) / s->npoints); + + for (i = 0; i < s->npoints; i++) + { + long r = s->r[i]; + long ra = (r > 0 ? r : -r); + double th = (s->th > 0 ? s->th : -s->th); + long x, y; + long elasticity = s->elasticity; + + /* place control points evenly around perimiter, shifted by theta */ + x = s->x + ra * cos (i * frac + th); + y = s->y + ra * sin (i * frac + th); + + s->spline->control_x[i] = x / SCALE; + s->spline->control_y[i] = y / SCALE; + + if (s->mode == zoom && ((i % s->skip) == 0)) + continue; + + /* Slow down near the end points: move fastest in the middle. */ + { + double ratio = (double)ra / (double)(s->max_r - s->min_r); + if (ratio > 0.5) ratio = 1-ratio; /* flip */ + ratio *= 2; /* normalize */ + ratio = (ratio * 0.9) + 0.1; /* fudge */ + elasticity *= ratio; + } + + + /* Increase/decrease radius by elasticity */ + ra += (r >= 0 ? elasticity : -elasticity); + if ((i % s->skip) == 0) + ra += (elasticity / 2); + + r = ra * (r >= 0 ? 1 : -1); + + /* If we've reached the end (too long or too short) reverse direction. */ + if ((ra > s->max_r && r >= 0) || + (ra < s->min_r && r < 0)) + r = -r; + + s->r[i] = r; + } +} + + +static void +spin_starfish (struct starfish *s) +{ + double th = s->th; + if (th < 0) + th = -(th + s->rotv); + else + th += s->rotv; + + if (th > (M_PI+M_PI)) + th -= (M_PI+M_PI); + else if (th < 0) + th += (M_PI+M_PI); + + s->th = (s->th > 0 ? th : -th); + + s->rotv += s->rota; + + if (s->rotv > s->rot_max || + s->rotv < -s->rot_max) + { + s->rota = -s->rota; + } + /* If it stops, start it going in the other direction. */ + else if (s->rotv < 0) + { + if (random() & 1) + { + /* keep going in the same direction */ + s->rotv = 0; + if (s->rota < 0) + s->rota = -s->rota; + } + else + { + /* reverse gears */ + s->rotv = -s->rotv; + s->rota = -s->rota; + s->th = -s->th; + } + } + + + /* Alter direction of rotational acceleration randomly. */ + if (! (random() % 120)) + s->rota = -s->rota; + + /* Change acceleration very occasionally. */ + if (! (random() % 200)) + { + if (random() & 1) + s->rota *= 1.2; + else + s->rota *= 0.8; + } +} + + +static void +draw_starfish (Display *dpy, Drawable drawable, GC gc, struct starfish *s, + Bool fill_p) +{ + compute_closed_spline (s->spline); + if (s->prev) + { + XPoint *points = (XPoint *) + malloc (sizeof(XPoint) * (s->n_prev + s->spline->n_points + 2)); + int i = s->spline->n_points; + int j = s->n_prev; + memcpy (points, s->spline->points, (i * sizeof(*points))); + memcpy (points+i, s->prev, (j * sizeof(*points))); + + if (s->blob_p) + XClearWindow (dpy, drawable); + XFillPolygon (dpy, drawable, gc, points, i+j, Complex, CoordModeOrigin); + free (points); + + free (s->prev); + s->prev = 0; + } + + s->prev = (XPoint *) malloc (s->spline->n_points * sizeof(XPoint)); + memcpy (s->prev, s->spline->points, s->spline->n_points * sizeof(XPoint)); + s->n_prev = s->spline->n_points; + +#ifdef DEBUG + if (s->blob_p) + { + int i; + for (i = 0; i < s->npoints; i++) + XDrawLine (dpy, drawable, gc, s->x/SCALE, s->y/SCALE, + s->spline->control_x[i], s->spline->control_y[i]); + } +#endif +} + + +static struct starfish * +make_window_starfish (Display *dpy, Window window) +{ + XWindowAttributes xgwa; + int size; + Bool blob_p = get_boolean_resource ("blob", "Blob"); + XGetWindowAttributes (dpy, window, &xgwa); + size = (xgwa.width < xgwa.height ? xgwa.width : xgwa.height); + if (blob_p) size /= 2; + else size *= 1.3; + return make_starfish (xgwa.width, xgwa.height, size); +} + + +static struct starfish * +init_starfish (Display *dpy, Window window) +{ + static Bool first_time = True; + XGCValues gcv; + XWindowAttributes xgwa; + Bool blob_p = get_boolean_resource ("blob", "Blob"); + XGetWindowAttributes (dpy, window, &xgwa); + + cmap = xgwa.colormap; + cycle_p = get_boolean_resource ("cycle", "Cycle"); + + if (!first_time) + { + if (colors && ncolors) + free_colors (dpy, cmap, colors, ncolors); + if (colors) + free (colors); + colors = 0; + } + + ncolors = get_integer_resource ("colors", "Colors"); + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + + if (mono_p) + colors = 0; + else + colors = (XColor *) malloc(sizeof(*colors) * (ncolors+1)); + + if (mono_p || blob_p) + cycle_p = False; + + if (mono_p) + ; + else if (random() % 3) + make_smooth_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, &cycle_p, True); + else + make_uniform_colormap (dpy, xgwa.visual, cmap, colors, &ncolors, + True, &cycle_p, True); + + if (ncolors < 2) ncolors = 2; + if (ncolors <= 2) mono_p = True; + + if (mono_p) cycle_p = False; + + fg_index = 0; + + if (!mono_p && !blob_p) + { + gcv.foreground = colors[fg_index].pixel; + XSetWindowBackground (dpy, window, gcv.foreground); + } + + if (first_time) + { + XClearWindow (dpy, window); + first_time = False; + } + + gcv.fill_rule = EvenOddRule; + gc = XCreateGC (dpy, window, GCForeground | GCFillRule, &gcv); + + return make_window_starfish (dpy, window); +} + + + +static void +run_starfish (Display *dpy, Window window, struct starfish *s) +{ + throb_starfish (s); + spin_starfish (s); + draw_starfish (dpy, window, gc, s, False); + + if (mono_p) + { + static Bool init = False; + static unsigned long black, white; + if (!init) + { + black = get_pixel_resource ("background", "Background", dpy, cmap); + white = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + init = True; + fg_index = white; + XSetForeground (dpy, gc, fg_index); + } + else if (!s->blob_p) + { + fg_index = (fg_index == black ? white : black); + XSetForeground (dpy, gc, fg_index); + } + } + else + { + fg_index = (fg_index + 1) % ncolors; + XSetForeground (dpy, gc, colors [fg_index].pixel); + } +} + + + + +char *progclass = "Starfish"; + +char *defaults [] = { + "Starfish.background: black", /* to placate SGI */ + "Starfish.foreground: white", + "*delay: 10000", + "*cycleDelay: 100000", + "*thickness: 0", /* pixels, 0 = random */ + "*rotation: -1", /* degrees, -1 = "random" */ + "*colors: 200", + "*cycle: true", + "*duration: 30", + "*delay2: 5", + "*blob: false", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-delay2", ".delay2", XrmoptionSepArg, 0 }, + { "-cycle-delay", ".cycleDelay", XrmoptionSepArg, 0 }, + { "-thickness", ".thickness", XrmoptionSepArg, 0 }, + { "-rotation", ".rotation", XrmoptionSepArg, 0 }, + { "-colors", ".colors", XrmoptionSepArg, 0 }, + { "-cycle", ".cycle", XrmoptionNoArg, "True" }, + { "-no-cycle", ".cycle", XrmoptionNoArg, "False" }, + { "-duration", ".duration", XrmoptionSepArg, 0 }, + { "-blob", ".blob", XrmoptionNoArg, "True" }, + { "-no-blob", ".blob", XrmoptionNoArg, "False" }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + struct starfish *s = init_starfish (dpy, window); + int delay = get_integer_resource ("delay", "Delay"); + int delay2 = get_integer_resource ("delay2", "Delay") * 1000000; + int cycle_delay = get_integer_resource ("cycleDelay", "Delay"); + int duration = get_seconds_resource ("duration", "Seconds"); + Bool blob_p = get_boolean_resource ("blob", "Blob"); + time_t start = time ((time_t) 0); + time_t now; + int direction = (random() % 1) ? 1 : -1; + + if (blob_p) + delay *= 3; + + while (1) + { + run_starfish (dpy, window, s); + XSync (dpy, True); + + if (cycle_p && cycle_delay) + { + if (cycle_delay <= delay) + { + int i = 0; + while (i < delay) + { + rotate_colors (dpy, cmap, colors, ncolors, direction); + usleep(cycle_delay); + i += cycle_delay; + } + } + else + { + static long tick = 0; + if (tick >= cycle_delay) + { + rotate_colors (dpy, cmap, colors, ncolors, direction); + tick = 0; + } + if (delay) + usleep(delay); + tick += delay; + } + + if (! (random() % 1000)) + direction = -direction; + } + else if (delay) + usleep (delay); + + if (duration > 0) + { + now = time ((time_t) 0); + if (start + duration < now) + { + start = now; + + free_starfish (s); + + if (delay2 && !blob_p && cycle_p) + { + int i = 0; + while (i < delay2) + { + rotate_colors (dpy, cmap, colors, ncolors, direction); + usleep(cycle_delay); + i += cycle_delay; + } + } + + /* Every now and then, pick new colors; otherwise, just build + a new starfish with the current colors. */ + if (! (random () % 10)) + s = init_starfish (dpy, window); + else + s = make_window_starfish(dpy, window); + } + } + } +} diff --git a/hacks/starfish.man b/hacks/starfish.man new file mode 100644 index 00000000..461349fe --- /dev/null +++ b/hacks/starfish.man @@ -0,0 +1,89 @@ +.TH XScreenSaver 1 "14-Jun-97" "X Version 11" +.SH NAME +starfish - radially-symmetric throbbing colormap-hacking graphics demo +.SH SYNOPSIS +.B starfish +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-delay \fIusecs\fP] [\-delay2 \fIsecs\fP] [\-cycle\-delay2 \fIusecs\fP] [\-thickness \fIpixels\fP] [\-rotation \fIdegrees\fP] [\-duration \fIseconds\fP] [\-colors \fIint\fP] [\-cycle] [\-no\-cycle] [\-blob] [\-no\-blob] +.SH DESCRIPTION +The \fIstarfish\fP program draws radially symmetric objects, which expand, +contract, rotate, and turn inside out. It uses these shapes to lay down a +field of smooth colors, and then rotates the colormap. +.SH OPTIONS +.I starfish +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-delay \fImicroseconds\fP +How much of a delay should be introduced between steps of the animation. +Default 10000, or about 1/100th second. +.TP 8 +.B \-cycle\-delay \fImicroseconds\fP +How long to wait between shifing the colormap by one step. +Default 100000, or about 1/10th second. +.TP 8 +.B \-thickness \fIpixels\fP +How wide each color band should be. Default 0, meaning random (the chosen +value will be between 0 and 15.) +.TP 8 +.B \-rotation \fIdegrees\fP +How quickly the objects should rotate at each step. Default 0, meaning +random (the chosen value will be between 0 and 12 degrees.) +.TP 8 +.B \-colors \fIint\fP +How many colors to use. Default 200. The more colors, the smoother the +transitions will be, and the nicer the resultant images. +.TP 8 +.B \-cycle +.TP 8 +.B \-no\-cycle +Whether to do colormap cycling. Default true. +.TP 8 +.B \-duration \fIseconds\fP +How long to run before choosing a new shape. Default 30 seconds. +.TP 8 +.B \-delay2 \fIseconds\fP +When \fIduration\fP expires, how long to wait before starting a new run. +Default 5 seconds. +.TP 8 +.B \-blob +.TP 8 +.B \-no\-blob +If \fIblob\fP option is specified, then the raw shapes will be shown, +instead of a field of colors generated from them. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 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. +.SH AUTHOR +Jamie Zawinski , 14-Jun-97. diff --git a/hacks/strange.c b/hacks/strange.c new file mode 100644 index 00000000..71cd89cd --- /dev/null +++ b/hacks/strange.c @@ -0,0 +1,404 @@ +/* -*- Mode: C; tab-width: 4 -*- + * strange --- Strange attractors are not so hard to find... + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)strange.c 4.02 97/04/01 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@netscape.com: 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 "Strange" +# define HACK_INIT init_strange +# define HACK_DRAW draw_strange +# define strange_opts xlockmore_opts +# define DEFAULTS "*delay: 2000 \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 */ + +ModeSpecOpt strange_opts = { + 0, NULL, 0, NULL, NULL }; + +/*****************************************************/ +/*****************************************************/ + +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 ? -Fold[ (-(a))&(UNIT2-1) ] : Fold[ (a)&(UNIT2-1) ] + +/* + #define DO_FOLD(a) (a)<-UNIT2 ? -Fold[(-(a))%UNIT2] : (a)<0 ? -Fold[ -(a) ] + + : \ (a)>UNIT2 ? Fold[ (a)%UNIT2 ] : 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 ) ) */ + +/******************************************************************/ + +#define MAX_PRM 3*5 + +typedef struct { + DBL Prm1[MAX_PRM], Prm2[MAX_PRM]; + void (*Iterate) (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 PRM xmin, xmax, ymin, ymax; +static PRM Prm[MAX_PRM]; +static PRM *Fold = NULL; + +/******************************************************************/ +/******************************************************************/ + +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(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 = Prm[1] * xx + Prm[2] * xy + Prm[3] * yy + Prm[4] * x2y; + Tmp = Prm[0] - y + (Tmp / UNIT); + *xo = DO_FOLD(Tmp); + Tmp = Prm[6] * xx + Prm[7] * xy + Prm[8] * yy + Prm[9] * y2x; + Tmp = Prm[5] + x + (Tmp / UNIT); + *yo = DO_FOLD(Tmp); +} + +static void +Iterate_X3(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 = Prm[1] * xx + Prm[2] * xy + Prm[3] * yy + Prm[4] * x2y; + Tmp_x = Prm[0] - y + (Tmp_x / UNIT); + Tmp_x = DO_FOLD(Tmp_x); + + Tmp_y = Prm[6] * xx + Prm[7] * xy + Prm[8] * yy + Prm[9] * y2x; + Tmp_y = Prm[5] + x + (Tmp_y / UNIT); + + Tmp_y = DO_FOLD(Tmp_y); + + Tmp_z = Prm[11] * xx + Prm[12] * xy + Prm[13] * yy + Prm[14] * y2x; + Tmp_z = 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]) (PRM, PRM, PRM *, PRM *) = { + Iterate_X2, Iterate_X3 +}; + +/***************************************************************/ + +void +draw_strange(ModeInfo * mi) +{ + int i, j, n, Max_Colors, Cur_Pt; + PRM x, y, xo, yo; + DBL u; + ATTRACTOR *A; + XPoint *Buf; + Display *display; + GC gc; + Window window; + DBL Lx, Ly; + void (*Iterate) (PRM, PRM, PRM *, PRM *); + + display = MI_DISPLAY(mi); + window = MI_WINDOW(mi); + gc = MI_GC(mi); + Max_Colors = MI_NPIXELS(mi); + + A = &Root[MI_SCREEN(mi)]; + + Cur_Pt = A->Cur_Pt; + Iterate = A->Iterate; + + u = (DBL) (A->Count) / 1000.0; + for (j = MAX_PRM - 1; j >= 0; --j) + 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) (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) (x, y, &xo, &yo); + Buf->x = (short) (Lx * (x + DBL_To_PRM(1.1))); + Buf->y = (short) (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; + } + + XSetForeground(display, gc, MI_WIN_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 (Max_Colors < 2) + XSetForeground(display, gc, MI_WIN_WHITE_PIXEL(mi)); + else + XSetForeground(display, gc, MI_PIXEL(mi, A->Col % Max_Colors)); + + 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) +{ + ATTRACTOR *Attractor; + + if (Root == NULL) { + Root = (ATTRACTOR *) calloc( + MI_NUM_SCREENS(mi), sizeof (ATTRACTOR)); + if (Root == NULL) + return; + } + if (Fold == NULL) { + int i; + + Fold = (PRM *) calloc(UNIT2 + 1, sizeof (PRM)); + if (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); + Fold[i] = DBL_To_PRM(x); + } + } + Attractor = &Root[MI_SCREEN(mi)]; + + Attractor->Buffer1 = (XPoint *) calloc(MAX_POINTS, sizeof (XPoint)); + if (Attractor->Buffer1 == NULL) + goto Abort; + Attractor->Buffer2 = (XPoint *) calloc(MAX_POINTS, sizeof (XPoint)); + if (Attractor->Buffer2 == NULL) + goto Abort; + Attractor->Max_Pt = MAX_POINTS; + + Attractor->Width = MI_WIN_WIDTH(mi); + Attractor->Height = MI_WIN_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); + + Attractor->dbuf = XCreatePixmap(MI_DISPLAY(mi), MI_WINDOW(mi), + Attractor->Width, Attractor->Height, 1); + if (Attractor->dbuf) + { + XGCValues gcv; + gcv.foreground = 0; + gcv.background = 0; + gcv.function = GXcopy; + Attractor->dbuf_gc = XCreateGC(MI_DISPLAY(mi), Attractor->dbuf, + GCForeground|GCBackground|GCFunction, + &gcv); + XFillRectangle(MI_DISPLAY(mi), Attractor->dbuf, + Attractor->dbuf_gc, 0,0, Attractor->Width, + Attractor->Height); + XSetBackground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + XSetFunction(MI_DISPLAY(mi), MI_GC(mi), GXcopy); + } + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + return; + + Abort: + if (Attractor->Buffer1 != NULL) + free(Attractor->Buffer1); + if (Attractor->Buffer2 != NULL) + free(Attractor->Buffer2); + Attractor->Buffer1 = NULL; + Attractor->Buffer2 = NULL; + Attractor->Cur_Pt = 0; + return; +} + +/***************************************************************/ + +void +release_strange(ModeInfo * mi) +{ + int i; + + if (Root == NULL) + return; + + for (i = 0; i < MI_NUM_SCREENS(mi); ++i) { + if (Root[i].Buffer1 != NULL) + free(Root[i].Buffer1); + if (Root[i].Buffer2 != NULL) + free(Root[i].Buffer2); + if (Root[i].dbuf) + XFreePixmap(MI_DISPLAY(mi), Root[i].dbuf); + if (Root[i].dbuf_gc) + XFreeGC(MI_DISPLAY(mi), Root[i].dbuf_gc); + } + free(Root); + Root = NULL; + if (Fold != NULL) + free(Fold); + Fold = NULL; +} diff --git a/hacks/strange.man b/hacks/strange.man new file mode 100644 index 00000000..ff278d39 --- /dev/null +++ b/hacks/strange.man @@ -0,0 +1,58 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +strange - draws strange attractors +.SH SYNOPSIS +.B strange +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] + +.SH DESCRIPTION +The \fIstrange\fP program draws strange attractors +.SH OPTIONS +.I strange +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 64. +The colors are chosen randomly. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1997 by Massimino Pascal. + +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. +.SH AUTHOR +Massimino Pascal , 1997. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/swirl.c b/hacks/swirl.c new file mode 100644 index 00000000..0d0f5abf --- /dev/null +++ b/hacks/swirl.c @@ -0,0 +1,1456 @@ +/* -*- Mode: C; tab-width: 4 -*- + * swirl --- swirly color-cycling patterns. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)swirl.c 4.00 97/01/01 xlockmore"; +#endif + +/* Copyright (c) 1994 M.Dobie + * + * 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. + * + * 13-May-97: jwz@netscape.com: turned into a standalone program. + * 21-Apr-95: improved startup time for TrueColour displays + * (limited to 16bpp to save memory) S.Early + * 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 . + * 1994: written. Copyright (c) 1994 M.Dobie + * 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 "*count: 5 \n" \ + "*delay: 10000 \n" \ + "*ncolors: 200 \n" +# define SMOOTH_COLORS +# define WRITABLE_COLORS +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt swirl_opts = { + 0, NULL, 0, NULL, NULL }; + +#include + +/****************************************************************/ + +#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 */ +#ifndef STANDALONE + Bool fixed_colourmap; /* fixed colourmap? */ +#endif /* !STANDALONE */ + Bool monochrome; /* monochrome? */ + Colormap cmap; /* colour map for the window */ + XColor *rgb_values; /* colour definitions array */ +#ifndef STANDALONE + int current_map; /* current colour map, 0..dcolours-1 */ + unsigned long fg, bg, white, black; /* black and white pixel values */ + int shift; /* colourmap shift */ + int dshift; /* colourmap shift while drawing */ + XColor fgcol, bgcol; /* foreground and background colour specs */ +#endif /* !STANDALONE */ + Bool off_screen; +} SWIRL , *SWIRL_P; + +#define SWIRLCOLOURS 13 + +#ifndef STANDALONE +/* 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(ModeInfo * mi, SWIRL_P swirl) +{ +#ifndef STANDALONE + Display *display = MI_DISPLAY(mi); +#endif /* !STANDALONE */ + + 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 */ +#ifndef STANDALONE + swirl->current_map = 0; /* current colour map, 0..dcolours-1 */ + + /* set up fg fb colour specs */ + swirl->white = MI_WIN_WHITE_PIXEL(mi); + swirl->black = MI_WIN_BLACK_PIXEL(mi); +#endif /* !STANDALONE */ + + +#ifdef STANDALONE +# define MI_COLORMAP MI_WIN_COLORMAP +#else /* !STANDALONE */ + swirl->fg = MI_FG_COLOR(mi); + swirl->bg = MI_BG_COLOR(mi); + swirl->fgcol.pixel = swirl->fg; + swirl->bgcol.pixel = swirl->bg; + XQueryColor(display, MI_COLORMAP(mi), &(swirl->fgcol)); + XQueryColor(display, MI_COLORMAP(mi), &(swirl->bgcol)); +#endif /* !STANDALONE */ +} + +/****************************************************************/ + +/* + * initialise_image + * + * Initialise the image for drawing to + * + * - swirl is the swirl data + */ +static void +initialise_image(ModeInfo * mi, SWIRL_P swirl) +{ + Display *dpy = MI_DISPLAY(mi); + + if (swirl->ximage != NULL) + XDestroyImage(swirl->ximage); + + swirl->ximage = XCreateImage(dpy, swirl->visual, swirl->rdepth, ZPixmap, + 0, 0, swirl->width, swirl->height, + 8, 0); + swirl->ximage->data = swirl->image = + (unsigned char *) calloc(swirl->height, swirl->ximage->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)); + } +} +#endif /* !STANDALONE */ + +/****************************************************************/ + +#ifndef STANDALONE +/* + * 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->fg] = swirl->fgcol; + values[swirl->bg] = swirl->bgcol; +} + +/****************************************************************/ + +/* + * 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 fg, bg, white, black; + + /* where are foreground, background, white, and black? */ + fg = swirl->fg; + bg = swirl->bg; + white = swirl->white; + black = swirl->black; + + /* haven't set it yet */ + done = False; + + /* try and set the colour */ + while (!done) { + (**value).flags = DoRed | DoGreen | DoBlue; + (**value).pixel = *pixel; + + /* white, black, fg, bg, or a colour? */ + if ((*pixel != fg) && (*pixel != bg) && + (*pixel != white) && (*pixel != black)) { + (**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 fg, bg, white, black; + + /* where is white and black? */ + fg = swirl->fg; + bg = swirl->bg; + white = swirl->white; + black = swirl->black; + + /* haven't set it yet */ + done = False; + + /* try and set the colour */ + while (!done) { + /* black, white or a colour? */ + if (((*value)->pixel != fg) && ((*value)->pixel != bg) && + ((*value)->pixel != white) && ((*value)->pixel != black)) { + c->r = (*value)->red; + c->g = (*value)->green; + c->b = (*value)->blue; + + /* now we've done it */ + done = True; + } + /* next value */ + (*value)++; + } +} +#endif /* !STANDALONE */ + +/****************************************************************/ + +#ifndef STANDALONE +/* + * 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; + int n_rotations; + int i; + Bool truecolor; + unsigned long redmask, greenmask, bluemask; + + swirl->fixed_colourmap = !setupColormap(mi, &(swirl->colours), + &truecolor, &redmask, &greenmask, &bluemask); + preserve = preserveColors(swirl->fg, swirl->bg, swirl->white, swirl->black); + + /* how many colours should we animate? */ + swirl->dcolours = (swirl->colours > preserve + 1) ? + swirl->colours - preserve : swirl->colours; + + 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; + + /* 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) { + swirl->rgb_values = (XColor *) calloc((swirl->colours + 3) * n_rotations, + sizeof (XColor)); + + /* create a colour map */ + if (!swirl->fixed_colourmap) + swirl->cmap = + XCreateColormap(display, swirl->win, swirl->visual, AllocAll); + } + /* 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, value, add; + 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) + value = (value % dcolours) + 2; + else + value = dcolours - (abs(value) % (dcolours - 1)); + +#ifndef STANDALONE + /* if fg and bg are 1 and 0 we should be OK, but just in case */ + while ((dcolours > 2) && + (((value % swirl->colours) == (int) swirl->fg) || + ((value % swirl->colours) == (int) swirl->bg) || + ((value % swirl->colours) == (int) swirl->white) || + ((value % swirl->colours) == (int) swirl->black))) { + value++; + } +#endif /* !STANDALONE */ + + /* definitely make sure it is in range */ + value = value % swirl->colours; + + /* lookup the pixel value if necessary */ +#ifndef STANDALONE + if (swirl->fixed_colourmap && swirl->dcolours > 2) +#endif + value = swirl->rgb_values[value].pixel; + + /* return it */ + return ((unsigned long) 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. */ + 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(mi, &swirls[i]); + } + /* get a pointer to this swirl */ + swirl = &(swirls[MI_SCREEN(mi)]); + + /* get window parameters */ + swirl->win = window; + swirl->width = MI_WIN_WIDTH(mi); + swirl->height = MI_WIN_HEIGHT(mi); + swirl->depth = MI_WIN_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(mi, swirl); + + /* clear the window (before setting the colourmap) */ + XClearWindow(display, MI_WINDOW(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_WIN_IS_INWINDOW(mi)); +#else + XSetWindowColormap(display, window, swirl->cmap); + (void) 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_BATCHCOUNT(mi) / 2) + + MI_BATCHCOUNT(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)]); + + /* 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! */ + XClearWindow (MI_DISPLAY(mi), MI_WINDOW(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, True); + 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 != (Colormap) NULL) + XFreeColormap(MI_DISPLAY(mi), swirl->cmap); + if (swirl->rgb_values != NULL) + XFree((void *) swirl->rgb_values); + if (swirl->ximage != NULL) + 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) { + if (swirl->drawing) + swirl->resolution = swirl->resolution + 1; + swirl->drawing = False; + } +} diff --git a/hacks/swirl.man b/hacks/swirl.man new file mode 100644 index 00000000..76374613 --- /dev/null +++ b/hacks/swirl.man @@ -0,0 +1,64 @@ +.TH XScreenSaver 1 "13-May-97" "X Version 11" +.SH NAME +swirl - draws swirly color-cycling patterns +.SH SYNOPSIS +.B swirl +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP] + +.SH DESCRIPTION +The \fIswirl\fP program draws swirly color-cycling patterns. +.SH OPTIONS +.I swirl +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +.TP 8 +.B \-cycles \fIinteger\fP + +.TP 8 +.B \-count \fIinteger\fP + +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1994 M. Dobie. + +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. + +.SH AUTHOR +M.Dobie , 1994. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 13-May-97. diff --git a/hacks/triangle.c b/hacks/triangle.c new file mode 100644 index 00000000..d8be189a --- /dev/null +++ b/hacks/triangle.c @@ -0,0 +1,362 @@ +/* -*- Mode: C; tab-width: 4 -*- */ +/* triangle --- create a triangle-mountain */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)triangle.c 4.04 97/07/28 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: + * 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 + * 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 + * 27-Feb-96: Undid the changes listed below. Added ModeInfo argument. + * Implemented delay between scenes using the MI_PAUSE(mi) + * scheme. Ron Hitchens + * 27-Dec-95: Ron Hitchens + * 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" +# define SMOOTH_COLORS +# include "xlockmore.h" /* in xscreensaver distribution */ +#else /* STANDALONE */ +# include "xlock.h" /* in xlockmore distribution */ +#endif /* STANDALONE */ + +ModeSpecOpt triangle_opts = +{0, NULL, 0, NULL, NULL}; + +#define MAX_STEPS 8 +#define MAX_SIZE (1< 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))); + XFillPolygon(display, window, gc, p, 3, Convex, CoordModeOrigin); + } else { + /* mono */ +#ifdef BACKFACE_REMOVAL + XSetForeground(display, gc, MI_WIN_BLACK_PIXEL(mi)); + XFillPolygon(display, window, gc, p, 3, Convex, CoordModeOrigin); +#endif + XSetForeground(display, gc, MI_WIN_WHITE_PIXEL(mi)); + XDrawLine(display, window, gc, p[0].x, p[0].y, p[1].x, p[1].y); + XDrawLine(display, window, gc, p[1].x, p[1].y, p[2].x, p[2].y); + XDrawLine(display, window, gc, p[2].x, p[2].y, p[0].x, p[0].y); + } +} + +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; +} + +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; +} + + +static +void +draw_mesh(ModeInfo * mi, trianglestruct * tp, int d, int count) +{ + XPoint p[3]; + int first = 1; + int y_0, y_1, y_2; + double dinv = 0.2 / d; + + if ((tp->j == 0) && (tp->i == 0)) { +#if 0 /* jwz */ + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); +#else + { + int x = 0; + int y = 0; + int x2 = MI_WIN_WIDTH(mi); + int y2 = tp->ypos[0]; + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_WIN_BLACK_PIXEL(mi)); + XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + x, y, x2, y2); + } +#endif + } + 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->init_now = 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_WIN_WIDTH(mi); + tp->height = MI_WIN_HEIGHT(mi); + tp->init_now = 1; + tp->fast = 2; + + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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; + + if (!tp->init_now) { + draw_mesh(mi, tp, tp->d / 2, MAX_SIZE / tp->d); + + /* The init_now flag will pop up when the scene is complete. + * Cycles specifies how long to wait, in 1/10 secs. + TODO: This is wrong for multi-screens *** + */ + if (tp->init_now) { +#ifndef STANDALONE + MI_PAUSE(mi) = 2000000; +#else + if (tp->stage == -1) + { + XSync(MI_DISPLAY(mi), False); + usleep(2000000); + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); +# if 1 + if (!mono_p) + { + free_colors(mi->dpy, mi->xgwa.colormap, mi->colors, + mi->npixels); + make_smooth_colormap (mi->dpy, + mi->xgwa.visual, mi->xgwa.colormap, + mi->colors, &mi->npixels, + True, &mi->writable_p, True); + } +# endif /* 0 */ + } +#endif + } + 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->init_now = 0; + tp->i = 0; + tp->j = 0; + tp->d = d; + } + } + } + if (tp->stage == tp->steps) { + tp->stage = -1; + } +} + +void +release_triangle(ModeInfo * mi) +{ + if (triangles != NULL) { + (void) free((void *) triangles); + triangles = NULL; + } +} + +void +refresh_triangle(ModeInfo * mi) +{ + /* Do nothing, it will refresh by itself */ +} diff --git a/hacks/vidwhacker b/hacks/vidwhacker new file mode 100755 index 00000000..44521963 --- /dev/null +++ b/hacks/vidwhacker @@ -0,0 +1,264 @@ +#!/bin/sh +# +# vidwhacker, for xscreensaver. Copyright (c) 1998 Jamie Zawinski. +# +# This script grabs a frame of video, then uses various pbm filters to +# munge the image in random nefarious ways, then uses xv to put it on +# the root window. This works out really nicely if you just feed some +# random TV station into it... +# +# The video grabbing part is SGI-specific -- if you want to use this on +# another system, add a new clause to the grab() procedure. + + +# Process command-line args... + +onroot=false +verbose=false +delay=3 + +if [ "$1" = "-root" ]; then + onroot=true + shift +fi + +if [ "$1" = "-verbose" ]; then + verbose=true + shift +fi + +if [ "$1" != "" ]; then + echo "usage: $0 [-root] [-verbose]" >&2 + exit 1 +fi + + +xvargs="-quick24" + +if [ "$onroot" = true ]; then + xvargs="$xvargs -root -rmode 5 -quit" +else + xvargs="$xvargs -geom +0+0" +fi + +screen_width=`xdpyinfo | sed -n 's/.* dimensions: *\([0-9]*\).*/\1/p'` + +# global vars... + +tmp=/tmp/vd$$ +tmp_rgb=$tmp-00000.rgb +tmp_ppm=$tmp.ppm +tmp_ppm2=$tmp-2.ppm +tmp_ppm3=$tmp-3.ppm + +clean() { + rm -f $tmp_rgb $tmp_ppm $tmp_ppm2 $tmp_ppm3 +} + + +# Grab a frame of video. +# +grab() { + if [ `uname` = IRIX ]; then + # + # SGI's "vidtomem" returns an SGI RGB image of the default video input, + # and has stupid non-overridable ouput-file-naming conventions. So, let + # it write its file; and then convert it to a pgm. + # + vidtomem -f $tmp + sgitopnm $tmp_rgb > $tmp_ppm + # Cut off the close-captioning blips in the NTSC overscan region. YMMV. + # | pnmcut 12 7 695 477 + + else + echo "$0: don't know how to grab video on this OS." >&2 + clean + exit 1 + fi + + + # I got this message from Marcus Herbert . + # I'm not sure of the best way to make the presence of qcam be + # auto-detected, but here's what he said, FYI... + # + # i am using a black/white Connectix Qcam on linux and its very simple + # to adept the script: + # + # # qcam: Version 0.91 + # # Options: + # # O -x width Set width + # # O y height Setheight + # # O B bpp Setbits per pixel + # # O W Auto-set white balance + # # O E "vals" Autoexposure mode, parameters required + # # O D Remove dark speckling + # # O s val Set scaling factor (1, 2, or 4) + # # + # qcam -x 320 -y 240 -B 6 -W -E 1 -D -s 1 > $tmp_ppm + # + # You dont really need the parameters for qcam as it reads out a system + # config file where you store the values for brightnes, contrast and + # white balance. But with this parameters you are independant of the + # light ratios at the place the cam is set up. + # + # Other versions of qcam (0.7, 0.96..) don't support the autoexposure and + # auto- whitebalance commandline parameters. On such systems (and on + # color-qcam systems) a simple qcam > $tmp_ppm (or cqcam > $tmp_ppm) is + # enough. + # + # I dont know about other systems but afaik fBSD uses the Qcam in this way: + # + # qcamcontrol -bla -foo -bar > picture.pgm + # +} + + +# Use perl to pick a random foreground/background color in pbm's syntax. +# +randcolor() { + perl -e 'srand; + printf("#%02x%02x%02x-#%02x%02x%02x", + int(rand()*60), + int(rand()*60), + int(rand()*60), + 120+int(rand()*135), + 120+int(rand()*135), + 120+int(rand()*135))' +} + +# Frobnicate the image in some random way. +# +frob() { + + N=`perl -e 'srand; print int(rand() * 10)'` + + if [ "$verbose" = true ]; then + echo "mode $N..." >&2 + fi + + if [ $N = 0 ]; then + ppmtopgm $tmp_ppm | pgmedge | pgmtoppm `randcolor` | ppmnorm + + elif [ $N = 1 ]; then + ppmtopgm $tmp_ppm | + pgmenhance | + pgmtoppm `randcolor` + + elif [ $N = 2 ]; then + ppmtopgm $tmp_ppm | pgmoil | pgmtoppm `randcolor` + + elif [ $N = 3 ]; then + ppmrelief $tmp_ppm | ppmtopgm | pgmedge | ppmrelief | ppmtopgm | + pgmedge | pnminvert | pgmtoppm `randcolor` + + elif [ $N = 4 ]; then + ppmspread 71 $tmp_ppm > $tmp_ppm2 + pnmarith -add $tmp_ppm $tmp_ppm2 + + elif [ $N = 5 ]; then + pnmflip -lr $tmp_ppm > $tmp_ppm2 + pnmarith -multiply $tmp_ppm $tmp_ppm2 > $tmp_ppm3 + pnmflip -tb $tmp_ppm3 | ppmnorm > $tmp_ppm2 + pnmarith -multiply $tmp_ppm $tmp_ppm2 + + elif [ $N = 6 ]; then + N2=`perl -e 'srand; print int(rand() * 3)'` + if [ $N2 = 0 ]; then + pnmflip -lr $tmp_ppm > $tmp_ppm2 + elif [ $N2 = 1 ]; then + pnmflip -tb $tmp_ppm > $tmp_ppm2 + else + pnmflip -lr $tmp_ppm > $tmp_ppm2 + pnmflip -tb $tmp_ppm2 > $tmp_ppm3 + cp $tmp_ppm3 $tmp_ppm2 + fi + + pnmarith -difference $tmp_ppm $tmp_ppm2 + + elif [ $N = 7 ]; then + + for i in 1 2 3 ; do + ppmtopgm $tmp_ppm | pgmedge > $tmp_ppm2 + pnmarith -difference $tmp_ppm $tmp_ppm2 > $tmp_ppm3 + cp $tmp_ppm3 $tmp_ppm + done + ppmnorm < $tmp_ppm + + elif [ $N = 8 ]; then + pnmflip -lr $tmp_ppm > $tmp_ppm2 + pnmarith -multiply $tmp_ppm $tmp_ppm2 | ppmrelief | ppmnorm | pnminvert + + elif [ $N = 9 ]; then + pnmflip -lr $tmp_ppm > $tmp_ppm2 + pnmarith -subtract $tmp_ppm $tmp_ppm2 | ppmrelief | ppmtopgm | pgmedge + + else cat $tmp_ppm + fi +} + + + +# Grab a frame and frob it. leave it in $tmp_ppm3. +# +whack() { + clean + + while [ ! -f $tmp_ppm ]; do + grab + done + + rm -f $tmp_rgb + frob | pnmscale -width $screen_width > $tmp_ppm3 + rm -f $tmp_ppm $tmp_ppm2 +} + + +pid="" + +if [ "$onroot" != true ]; then + trap "kill \$pid; clean; exit 1" 2 15 +fi + +while true; do + + # Loop grabbing and frobbing images. + # + # If we're running on the root, run xv in the foreground (with -exit) + # and then wait. + # + # If we're running in a window, spawn xv in the background; then when + # it's time to put up the new image, kill off the currently-running xv. + + if [ "$verbose" = true ]; then + whack + else + whack >&- 2>&- + fi + + if [ "$pid" != "" ]; then + kill $pid + pid="" + fi + + if [ ! -s $tmp_ppm3 ]; then + echo "$0: no image grabbed" >&2 + else + + pnmtosgi < $tmp_ppm3 > $tmp_ppm2 + rm -f $tmp_ppm3 + + if [ "$onroot" = true ]; then + xv $xvargs $tmp_ppm2 + else + xv $xvargs $tmp_ppm2 & + pid=$! + fi + + #xv -geom =320x220 $tmp_ppm3 & + #pid= + fi + + clean + sleep $delay + +done diff --git a/hacks/vines.c b/hacks/vines.c new file mode 100644 index 00000000..2002946e --- /dev/null +++ b/hacks/vines.c @@ -0,0 +1,142 @@ +/* -*- Mode: C; tab-width: 4 -*- + * vines --- another geometric pattern generator. + */ +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)vines.c 4.02 97/04/01 xlockmore"; +#endif + +/* xlockmore mode written by Tracy Camp + * campt@hurrah.com 1997 + * released to the public domain + * + * 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. + * + * Revision History: + * 10-May-97: jwz@netscape.com: turned into a standalone program. + * 21-Mar-97: David Hansen + * 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. + */ + +#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" \ + "*ncolors: 64 \n" \ + "*eraseSpeed: 400 \n" \ + "*eraseMode: -1 \n" +# include "xlockmore.h" /* from the xscreensaver distribution */ +# include "erase.h" +#else /* !STANDALONE */ +# include "xlock.h" /* from the xlockmore distribution */ +#endif /* !STANDALONE */ + +ModeSpecOpt vines_opts = { + 0, NULL, 0, NULL, NULL }; + +typedef struct { + int a; + int x1; + int y1; + int x2; + int y2; + int length; + int iterations; + int constant; + int ang; + int centerx; + int centery; +} vinestruct; + +static vinestruct *vines = NULL; + +void +refresh_vines(ModeInfo * mi) +{ +} + +void +init_vines(ModeInfo * mi) +{ + Display *display = MI_DISPLAY(mi); + vinestruct *fp; + + if (vines == NULL) { + if ((vines = (vinestruct *) calloc(MI_NUM_SCREENS(mi), sizeof (vinestruct))) == NULL) { + return; + } + } + fp = &vines[MI_SCREEN(mi)]; + + fp->iterations = 30 + NRAND(100); + + XClearWindow(display, MI_WINDOW(mi)); +} + +void +draw_vines(ModeInfo * mi) +{ + vinestruct *fp = &vines[MI_SCREEN(mi)]; + Display *display = MI_DISPLAY(mi); + GC gc = MI_GC(mi); + int i; + + if (--(fp->iterations) == 0) { +#ifdef STANDALONE + erase_full_window(MI_DISPLAY(mi), MI_WINDOW(mi)); +#endif /* STANDALONE */ + init_vines(mi); + } + + fp->centerx = NRAND(MI_WIN_WIDTH(mi)); + fp->centery = NRAND(MI_WIN_HEIGHT(mi)); + + fp->ang = 60 + NRAND(720); + fp->length = 100 + NRAND(3000); + fp->constant = fp->length * (10 + NRAND(10)); + + 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_WIN_WHITE_PIXEL(mi)); + + + for (i = 0; i < fp->length; i++) { + 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 * i); + + fp->x1 = fp->x2; + fp->y1 = fp->y2; + + fp->x2 += (int) (i * ((cos(fp->a) * 360) / (2 * M_PI))); + fp->y2 += (int) (i * ((sin(fp->a) * 360) / (2 * M_PI))); + } +} + +void +release_vines(ModeInfo * mi) +{ + if (vines != NULL) { + (void) free((void *) vines); + vines = NULL; + } +} diff --git a/hacks/vines.man b/hacks/vines.man new file mode 100644 index 00000000..0245cdc7 --- /dev/null +++ b/hacks/vines.man @@ -0,0 +1,62 @@ +.TH XScreenSaver 1 "10-May-97" "X Version 11" +.SH NAME +vines - draws pseudo-fractal geometric patterns +.SH SYNOPSIS +.B vines +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] + +.SH DESCRIPTION +The \fIvines\fP program is yet another geometric pattern generator, this +one's claim to fame being a pseudo-fractal looking vine like pattern that +creates nifty whorls and loops. +.SH OPTIONS +.I vines +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.TP 8 +.B \-ncolors \fIinteger\fP +How many colors should be used (if possible). Default 200. +The colors are chosen randomly. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1), +.BR xlock (1) +.SH COPYRIGHT +Copyright \(co 1997 by Tracy Camp. + +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. +.SH AUTHOR +Tracy Camp , 1997. + +Tweaked by David Hansen , 21-Mar-97. + +Ability to run standalone or with \fIxscreensaver\fP added by +Jamie Zawinski , 10-May-97. diff --git a/hacks/vms_axp.opt b/hacks/vms_axp.opt new file mode 100644 index 00000000..64461591 --- /dev/null +++ b/hacks/vms_axp.opt @@ -0,0 +1,4 @@ +[-.UTILS]UTILS.OLB_AXP/LIB +SYS$SHARE:DECW$XMULIBSHR.EXE/SHARE +SYS$SHARE:DECW$XTSHR.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/hacks/vms_axp_12.opt b/hacks/vms_axp_12.opt new file mode 100644 index 00000000..10f94267 --- /dev/null +++ b/hacks/vms_axp_12.opt @@ -0,0 +1,4 @@ +[-.UTILS]UTILS.OLB_AXP/LIB +SYS$SHARE:DECW$XMULIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XTLIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/hacks/vms_decc.opt b/hacks/vms_decc.opt new file mode 100644 index 00000000..43d6858f --- /dev/null +++ b/hacks/vms_decc.opt @@ -0,0 +1,4 @@ +[-.UTILS]UTILS.OLB_DECC/LIB +SYS$SHARE:DECW$XMULIBSHR.EXE/SHARE +SYS$SHARE:DECW$XTSHR.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/hacks/vms_decc_12.opt b/hacks/vms_decc_12.opt new file mode 100644 index 00000000..dd6d2f37 --- /dev/null +++ b/hacks/vms_decc_12.opt @@ -0,0 +1,4 @@ +[-.UTILS]UTILS.OLB_DECC/LIB +SYS$SHARE:DECW$XMULIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XTLIBSHRR5.EXE/SHARE +SYS$SHARE:DECW$XLIBSHR.EXE/SHARE diff --git a/hacks/worm.c b/hacks/worm.c new file mode 100644 index 00000000..7eb5fdf2 --- /dev/null +++ b/hacks/worm.c @@ -0,0 +1,441 @@ + +/* -*- Mode: C; tab-width: 4 -*- */ +/* worm --- draw wiggly worms */ + +#if !defined( lint ) && !defined( SABER ) +static const char sccsid[] = "@(#)worm.c 4.04 97/07/28 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 + * 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 + * X11 version: Dave Lemke + * xlock version: Boris Putanec + */ + +#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: 150 \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 */ + +ModeSpecOpt worm_opts = +{0, NULL, 0, NULL, NULL}; + +#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; /* [NUMCOLORS * batchcount/NUMCOLORS+1] */ + 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_WIN_IS_USE3D(mi)) { + diff = ws->diffcirc[ws->tail]; + if (MI_WIN_IS_INSTALL(mi)) { + XSetForeground(display, gc, MI_NONE_COLOR(mi)); + XFillRectangle(display, window, gc, x - diff, y, + wp->circsize, wp->circsize); + XFillRectangle(display, window, gc, x + diff, y, + wp->circsize, wp->circsize); + } else { + XClearArea(display, window, x - diff, y, + wp->circsize, wp->circsize, False); + XClearArea(display, window, x + diff, y, + wp->circsize, wp->circsize, False); + } + } else + XClearArea(display, window, x, y, wp->circsize, wp->circsize, False); + + 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_WIN_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_WIN_IS_USE3D(mi)) + wp->nc = 2; + else + wp->nc = MI_NPIXELS(mi); + if (wp->nc > NUMCOLORS) + wp->nc = NUMCOLORS; + + free_worms(wp); + wp->nw = MI_BATCHCOUNT(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(NUMCOLORS * sizeof (int)); + + wp->maxsize = (REDRAWSTEP + 1) * wp->nw; /* / wp->nc + 1; */ + if (!wp->rects) + wp->rects = + (XRectangle *) malloc(wp->maxsize * NUMCOLORS * 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_WIN_WIDTH(mi); + wp->ysize = MI_WIN_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_WIN_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_WIN_IS_INSTALL(mi) && MI_WIN_IS_USE3D(mi)) { + XSetForeground(MI_DISPLAY(mi), MI_GC(mi), MI_NONE_COLOR(mi)); + XFillRectangle(MI_DISPLAY(mi), MI_WINDOW(mi), MI_GC(mi), + 0, 0, wp->xsize, wp->ysize); + } else + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(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)); + + 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_WIN_IS_USE3D(mi)) { + if (MI_WIN_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_WIN_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_WIN_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_WIN_IS_USE3D(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. */ + XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)); + else if (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; + } + } +} diff --git a/hacks/xjack.c b/hacks/xjack.c new file mode 100644 index 00000000..98649199 --- /dev/null +++ b/hacks/xjack.c @@ -0,0 +1,361 @@ +/* xscreensaver, Copyright (c) 1997 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. + * + * 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? + */ + +#include +#include "screenhack.h" + +char *progclass = "XJack"; + +char *defaults [] = { + "XJack.background: black", /* to placate SGI */ + "XJack.foreground: #00EE00", + "XJack.font: -*-courier-medium-r-*-*-*-240-*-*-m-*-*-*", + "*delay: 50000", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { "-font", ".font", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +void +screenhack (Display *dpy, Window window) +{ + static const char *source = "All work and no play makes Jack a dull boy. "; + const char *s = source; + int columns, rows; /* characters */ + int left, right; /* characters */ + int char_width, line_height; /* pixels */ + int x, y; /* characters */ + int mode = 0; + int hspace = 15; /* pixels */ + int vspace = 15; /* pixels */ + Bool break_para = True; + Bool caps = False; + int sentences = 0; + int paras = 0; + + XWindowAttributes xgwa; + XGCValues gcv; + GC gc; + int delay = get_integer_resource ("delay", "Integer"); + char *fontname = get_string_resource ("font", "Font"); + XFontStruct *font = XLoadQueryFont (dpy, fontname); + + if (!font) + font = XLoadQueryFont (dpy, "-*-*-medium-r-*-*-*-240-*-*-m-*-*-*"); + if (!font) + font = XLoadQueryFont (dpy, "-*-courier-medium-r-*-*-*-180-*-*-m-*-*-*"); + if (!font) + font = XLoadQueryFont (dpy, "-*-*-*-r-*-*-*-240-*-*-m-*-*-*"); + if (!font) + { + fprintf(stderr, "no big fixed-width font like \"%s\"\n", fontname); + exit(1); + } + + XGetWindowAttributes (dpy, window, &xgwa); + + gcv.font = font->fid; + gcv.foreground = get_pixel_resource ("foreground", "Foreground", dpy, + xgwa.colormap); + gcv.background = get_pixel_resource ("background", "Background", dpy, + xgwa.colormap); + gc = XCreateGC (dpy, window, (GCFont | GCForeground | GCBackground), &gcv); + + char_width = (font->per_char + ? font->per_char['n'-font->min_char_or_byte2].rbearing + : font->min_bounds.rbearing); + line_height = font->ascent + font->descent + 1; + + columns = (xgwa.width - hspace - hspace) / char_width; + rows = (xgwa.height - vspace - vspace) / line_height; + + left = 0xFF & (random() % ((columns / 2)+1)); + right = left + (0xFF & (random() % (columns - left - 10)+10)); + x = 0; + y = 0; + + while (1) + { + int word_length = 0; + const char *s2; + for (s2 = s; *s2 && *s2 != ' '; s2++) + word_length++; + + if (break_para || + (*s != ' ' && + (x + word_length) >= right)) + { + x = left; + y++; + + if (break_para) + y++; + + if (mode == 1 || mode == 2) + { + /* 1 = left margin goes southwest; 2 = southeast */ + left += (mode == 1 ? 1 : -1); + if (left >= right - 10) + { + if ((right < (columns - 10)) && (random() & 1)) + right += (0xFF & (random() % (columns - right))); + else + mode = 2; + } + else if (left <= 0) + { + left = 0; + mode = 1; + } + } + else if (mode == 3 || mode == 4) + { + /* 3 = right margin goes southeast; 4 = southwest */ + right += (mode == 3 ? 1 : -1); + if (right >= columns) + { + right = columns; + mode = 4; + } + else if (right <= left + 10) + mode = 3; + } + + if (y >= rows) /* bottom of page */ + { + /* scroll by 1-5 lines */ + int lines = (random() % 5 ? 0 : (0xFF & (random() % 5))) + 1; + if (break_para) + lines++; + + /* but sometimes scroll by a whole page */ + if (0 == (random() % 100)) + lines += rows; + + while (lines > 0) + { + XCopyArea (dpy, window, window, gc, + 0, hspace + line_height, + xgwa.width, + xgwa.height - vspace - vspace - line_height, + 0, vspace); + XClearArea (dpy, window, + 0, xgwa.height - vspace - line_height, + xgwa.width, + line_height + vspace + vspace, + False); + XClearArea (dpy, window, 0, 0, xgwa.width, vspace, False); + /* See? It's OK. He saw it on the television. */ + XClearArea (dpy, window, 0, 0, hspace, xgwa.height, False); + XClearArea (dpy, window, xgwa.width - vspace, 0, + hspace, xgwa.height, False); + y--; + lines--; + XSync (dpy, True); + if (delay) usleep (delay * 10); + } + if (y < 0) y = 0; + } + + break_para = False; + } + + if (*s != ' ') + { + char c = *s; + int xshift = 0, yshift = 0; + if (0 == random() % 50) + { + xshift = random() % ((char_width / 3) + 1); /* mis-strike */ + yshift = random() % ((line_height / 6) + 1); + if (0 == (random() % 3)) + yshift *= 2; + if (random() & 1) + xshift = -xshift; + if (random() & 1) + yshift = -yshift; + } + + if (0 == (random() % 250)) /* introduce adjascent-key typo */ + { + static const char * const typo[] = { + "asqw", "ASQW", "bgvhn", "cxdfv", "dserfcx", "ewsdrf", + "Jhuikmn", "kjiol,m", "lkop;.,", "mnjk,", "nbhjm", "oiklp09", + "pol;(-0", "redft54", "sawedxz", "uyhji87", "wqase32", + "yuhgt67", ".,l;/", 0 }; + int i = 0; + while (typo[i] && typo[i][0] != c) + i++; + if (typo[i]) + c = typo[i][0xFF & (random() % strlen(typo[i]+1))]; + } + + /* caps typo */ + if (c >= 'a' && c <= 'z' && (caps || 0 == (random() % 350))) + { + c -= ('a'-'A'); + if (c == 'O' && random() & 1) + c = '0'; + } + + OVERSTRIKE: + XDrawString (dpy, window, gc, + (x * char_width) + hspace + xshift, + (y * line_height) + vspace + font->ascent + yshift, + &c, 1); + if (xshift == 0 && yshift == 0 && (0 == (random() & 3000))) + { + if (random() & 1) + xshift--; + else + yshift--; + goto OVERSTRIKE; + } + + if ((tolower(c) != tolower(*s)) + ? (0 == (random() % 10)) /* backup to correct */ + : (0 == (random() % 400))) /* fail to advance */ + { + x--; + s--; + XSync (dpy, True); + if (delay) usleep (0xFFFF & (delay + (random() % (delay * 10)))); + } + } + + x++; + s++; + + if (0 == random() % 200) + { + if (random() & 1 && s != source) + s--; /* duplicate character */ + else if (*s) + s++; /* skip character */ + } + + if (*s == 0) + { + sentences++; + caps = (0 == random() % 40); /* capitalize sentence */ + + if (0 == (random() % 10) || /* randomly break paragraph */ + (mode == 0 && + ((0 == (random() % 10)) || sentences > 20))) + { + break_para = True; + sentences = 0; + paras++; + + if (random() & 1) /* mode=0 50% of the time */ + mode = 0; + else + mode = (0xFF & (random() % 5)); + + if (0 == (random() % 2)) /* re-pick margins */ + { + left = 0xFF & (random() % (columns / 3)); + right = columns - (0xFF & (random() % (columns / 3))); + + if (0 == random() % 3) /* sometimes be wide */ + right = left + ((right - left) / 2); + } + + if (right - left <= 10) /* introduce sanity */ + { + left = 0; + right = columns; + } + + if (right - left > 50) /* if wide, shrink and move */ + { + left += (0xFF & (random() % ((columns - 50) + 1))); + right = left + (0xFF & ((random() % 40) + 10)); + } + + /* oh, gag. */ + if (mode == 0 && + right - left < 25 && + columns > 40) + { + right += 20; + if (right > columns) + left -= (right - columns); + } + } + s = source; + } + + XSync (dpy, True); + if (delay) + { + usleep (delay); + if (0 == random() % 3) + usleep(0xFFFFFF & ((random() % (delay * 5)) + 1)); + + if (break_para) + usleep(0xFFFFFF & ((random() % (delay * 15)) + 1)); + } + + if (paras > 5 && + (0 == (random() % 1000)) && + y < rows-5) + { + int i; + int n = random() & 3; + 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 (dpy, window, gc, + (x * char_width) + hspace, + (y * line_height) + vspace + font->ascent, + n1, 1); + x++; + if (x >= columns) x = 0, y++; + n1++; + } + XSync (dpy, True); + usleep (5000000); + while (*n2) + { + XDrawString (dpy, window, gc, + (x * char_width) + hspace, + (y * line_height) + vspace + font->ascent, + n2, 1); + x++; + if (x >= columns) x = 0, y++; + n2++; + } + y++; + XSync (dpy, True); + usleep (500000); + } + } + } +} diff --git a/hacks/xjack.man b/hacks/xjack.man new file mode 100644 index 00000000..4d31fe25 --- /dev/null +++ b/hacks/xjack.man @@ -0,0 +1,51 @@ +.TH XScreenSaver 1 "18-sep-97" "X Version 11" +.SH NAME +xjack - all work and no play makes jack a dull boy +.SH SYNOPSIS +.B xjack +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-delay \fIusecs\fP] +.SH DESCRIPTION +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. All work and no play makes jack a dull boy. All work and no +play makes jack a dull boy. All work and no play makes jack a dull boy. +All work and no play makes jack a dull boy. +.PP +.RS 8 +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. All work and no play makes jack a dull boy. All work and no +play makes jack a dull boy. All work and no play makes jack a dull boy. +All work and no play makes jack a dull boy. +.PP +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. All work and no play makes jack a dull boy. All work and no +play makes jack a dull boy. All work and no play makes jack a dull boy. All +work and no play makes jack a dull boy. All work and no play makes jack a +dull boy. All work and no play makes jack a dull boy. +.PP +.RE +All work and no play makes jack a dull boy. +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. All work and no play makes jack a dull boy. All work and no +play makes jack a dull boy. All work and no play makes jack a dull boy. +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +All work and no play makes jack a dull boy. +.TP 8 +.B XENVIRONMENT +All work and no play makes jack a dull boy. All work and no play makes jack +a dull boy. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1997 by Jamie Zawinski. All work and no play makes jack a +dull boy. All work and no play makes jack a dull boy. All work and no play +makes jack a dull boy. All work and no play makes jack a dull boy. All work +and no play makes jack a fnord dull boy. All work and no play makes jack a +dull boy. +.SH AUTHOR +Jamie Zawinski , 15-Nov-97. diff --git a/hacks/xlock.h b/hacks/xlock.h new file mode 100644 index 00000000..d509f563 --- /dev/null +++ b/hacks/xlock.h @@ -0,0 +1,192 @@ +/* +** Helpful definitions for porting xlock modes to xscreensaver. +** by Charles Hannum, mycroft@ai.mit.edu +** +** for xlock 2.3 and xscreensaver 1.2, 28AUG92 +** +** Modified for xlockmore 3.0 by Anthony Thyssen +** on August 1995. +** +** Tweaked by jwz to work with both ANSI and K&R compilers, 10-May-97. +** +** Note: this file no longer works as of (at least) xlockmore 4.03a10: +** see jwz's new xlockmore.h file for a similar hack that works with +** code written for that version. +** +** To use, just copy the appropriate file from xlock, add a target +** for it in the Imakefile, and do the following: +** +** 1) If you include math.h, make sure it is before xlock.h. +** 2) Make sure the first thing you do in initfoo() is to call +** XGetWindowAttributes. This is what actually sets up the +** colormap and whatnot. +** 3) Add an appropriate PROGRAM() line at the end of the .c file. +** The information you need for this comes from xlock's file +** resource.c. +** +** That's about all there is to it. +** +** As an added bonus, if you put an empty definition of PROGRAM() in +** xlock's xlock.h, you can now use the code with either xlock or +** xscreensaver. +** +** +** If you make any improvements to this code, please send them to me! +** It could certainly use some more work. +*/ + +#include "screenhack.h" + +#define MAXSCREENS 1 + +static GC gc; +static unsigned long *pixels = 0, fg_pixel, bg_pixel; +static int npixels; +static Colormap cmap; + +static int batchcount; +static unsigned int delay; +static unsigned int cycles; +static double saturation; + +#ifndef min +#define min(a,b) ((a)<(b)?(a):(b)) +#endif + +typedef struct { + GC gc; + int npixels; + u_long *pixels; +} perscreen; + +static perscreen Scr[MAXSCREENS]; +static Display *dsp; + +static int screen = 0; + +static void +#ifdef __STDC__ +My_XGetWindowAttributes (Display *dpy, Window win, XWindowAttributes *xgwa) +#else /* !__STDC__ */ +My_XGetWindowAttributes (dpy, win, xgwa) + Display *dpy; + Window win; + XWindowAttributes *xgwa; +#endif /* !__STDC__ */ +{ + XGetWindowAttributes (dpy, win, xgwa); + + if (! pixels) { + XGCValues gcv; + XColor color; + int n; + int i, shift; + + cmap = xgwa->colormap; + + i = get_integer_resource ("ncolors", "Integer"); + if (i <= 2) i = 2, mono_p = True; + shift = 360 / i; + pixels = (unsigned long *) calloc (i, sizeof (unsigned long)); + fg_pixel = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + bg_pixel = get_pixel_resource ("background", "Background", dpy, cmap); + if (! mono_p) { + for (npixels = 0; npixels < i; npixels++) { + hsv_to_rgb ((360*npixels)/i, saturation, 1.0, + &color.red, &color.green, &color.blue); + if (! XAllocColor (dpy, cmap, &color)) + break; + pixels[npixels] = color.pixel; + } + } + n = get_integer_resource ("delay", "Usecs"); + if (n >= 0) delay = n; + n = get_integer_resource ("count", "Integer"); + if (n > 0) batchcount = n; + + n = get_integer_resource ("cycles", "Integer"); + if (n >= 0) cycles = n; + + gcv.foreground = fg_pixel; + gcv.background = bg_pixel; + gc = XCreateGC (dpy, win, GCForeground|GCBackground, &gcv); + + XClearWindow (dpy, win); + + Scr[screen].gc = gc; + Scr[screen].npixels = npixels; + Scr[screen].pixels = pixels; + } +} + +#define XGetWindowAttributes(a,b,c) My_XGetWindowAttributes(a,b,c) + +#undef BlackPixel +#define BlackPixel(a,b) bg_pixel +#undef WhitePixel +#define WhitePixel(a,b) fg_pixel +#define mono mono_p + +#define seconds() time((time_t*)0) + +char *defaults[] = { + "*background: black", + "*foreground: white", + "*ncolors: 64", + "*delay: -1", + "*count: -1", + "*cycles: -1", + 0 +}; + +XrmOptionDescRec options[] = { + {"-count", ".count", XrmoptionSepArg, 0}, + {"-ncolors", ".ncolors", XrmoptionSepArg, 0}, + {"-delay", ".delay", XrmoptionSepArg, 0}, + {"-cycles", ".cycles", XrmoptionSepArg, 0}, + { 0, 0, 0, 0 } +}; + +#if defined(__STDC__) || defined(__ANSI_CPP__) +# define XLOCK_INIT(Z) init##Z +# define XLOCK_DRAW(Z) draw##Z +#else /* K&R CPP */ +# define XLOCK_INIT(Z) init/**/Z +# define XLOCK_DRAW(Z) draw/**/Z +#endif /* K&R CPP */ + +#ifdef __STDC__ +# define XLOCK_SCREENHACK_PROTOTYPE() \ + screenhack(Display *dpy, Window window) +# define XLOCK_PROTOS(Z) /* */ +#else /* K&R C */ +# define XLOCK_SCREENHACK_PROTOTYPE() \ + screenhack(dpy, window) \ + Display *dpy; \ + Window window; +# define XLOCK_PROTOS(Z) \ + void init##Z(Window); \ + void draw##Z(Window); \ + +#endif /* K&R C */ + +#define PROGRAM(Y,Z,D,B,C,S) \ + char *progclass = Y; \ + XLOCK_PROTOS(Z) \ + \ + void XLOCK_SCREENHACK_PROTOTYPE() \ + { \ + batchcount = B; \ + delay = D; \ + cycles = C; \ + saturation = S; \ + dsp = dpy; \ + \ + XLOCK_INIT(Z) (window); \ + while (1) \ + { \ + XLOCK_DRAW(Z) (window); \ + XSync (dpy, True); \ + if (delay) usleep (delay); \ + } \ + } diff --git a/hacks/xlockmore.c b/hacks/xlockmore.c new file mode 100644 index 00000000..a1e71aa2 --- /dev/null +++ b/hacks/xlockmore.c @@ -0,0 +1,356 @@ +/* xlockmore.c --- xscreensaver compatibility layer for xlockmore modules. + * xscreensaver, Copyright (c) 1997 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. + * + * This file, along with xlockmore.h, make it possible to compile an xlockmore + * module into a standalone program, and thus use it with xscreensaver. + * By Jamie Zawinski on 10-May-97; based on the ideas + * in the older xlock.h by Charles Hannum . (I had + * to redo it, since xlockmore has diverged so far from xlock...) + */ + +#include +#include +#include +#include "screenhack.h" +#include "xlockmoreI.h" + +#define countof(x) (sizeof((x))/sizeof(*(x))) + +extern ModeSpecOpt xlockmore_opts[]; +extern const char *app_defaults; + +void +pre_merge_options (void) +{ + int i, j; + char *s; + + /* Translate the xlockmore `opts[]' argument to a form that + screenhack.c expects. + */ + for (i = 0; i < xlockmore_opts->numopts; i++) + { + XrmOptionDescRec *old = &xlockmore_opts->opts[i]; + XrmOptionDescRec *new = &options[i]; + + if (old->option[0] == '-') + new->option = old->option; + else + { + /* Convert "+foo" to "-no-foo". */ + new->option = (char *) malloc (strlen(old->option) + 5); + strcpy (new->option, "-no-"); + strcat (new->option, old->option + 1); + } + + new->specifier = strrchr (old->specifier, '.'); + if (!new->specifier) abort(); + + new->argKind = old->argKind; + new->value = old->value; + } + + /* Add extra args, if they're mentioned in the defaults... */ + { + char *args[] = { "-count", "-cycles", "-delay", "-ncolors", + "-size", "-wireframe", "-use3d" }; + for (j = 0; j < countof(args); j++) + if (strstr(app_defaults, args[j]+1)) + { + XrmOptionDescRec *new = &options[i++]; + new->option = args[j]; + new->specifier = strdup(args[j]); + new->specifier[0] = '.'; + if (!strcmp(new->option, "-wireframe")) + { + new->argKind = XrmoptionNoArg; + new->value = "True"; + new = &options[i++]; + new->option = "-no-wireframe"; + new->specifier = options[i-1].specifier; + new->argKind = XrmoptionNoArg; + new->value = "False"; + } + else if (!strcmp(new->option, "-use3d")) + { + new->option = "-3d"; + new->argKind = XrmoptionNoArg; + new->value = "True"; + new = &options[i++]; + new->option = "-no-3d"; + new->specifier = options[i-1].specifier; + new->argKind = XrmoptionNoArg; + new->value = "False"; + } + else + { + new->argKind = XrmoptionSepArg; + new->value = 0; + } + } + } + + + /* Construct the kind of `defaults' that screenhack.c expects from + the xlockmore `vars[]' argument. + */ + i = 0; + + /* Put on the PROGCLASS.background/foreground resources. */ + s = (char *) malloc(50); + strcpy (s, progclass); + strcat (s, ".background: black"); + defaults [i++] = s; + + s = (char *) malloc(50); + strcpy (s, progclass); + strcat (s, ".foreground: white"); + defaults [i++] = s; + + /* Copy the lines out of the `app_defaults' var and into this array. */ + s = strdup (app_defaults); + while (s && *s) + { + defaults [i++] = s; + s = strchr(s, '\n'); + if (s) + *s++ = 0; + } + + /* Copy the defaults out of the `xlockmore_opts->' variable. */ + for (j = 0; j < xlockmore_opts->numvarsdesc; j++) + { + const char *def = xlockmore_opts->vars[j].def; + if (!def) def = "False"; + if (def == ((char*) 1)) def = "True"; + s = (char *) malloc (strlen (xlockmore_opts->vars[j].name) + + strlen (def) + 10); + strcpy (s, "*"); + strcat (s, xlockmore_opts->vars[j].name); + strcat (s, ": "); + strcat (s, def); + defaults [i++] = s; + } + + defaults [i] = 0; +} + + +static void +xlockmore_read_resources (void) +{ + int i; + for (i = 0; i < xlockmore_opts->numvarsdesc; i++) + { + void *var = xlockmore_opts->vars[i].var; + Bool *var_b = (Bool *) var; + char **var_c = (char **) var; + int *var_i = (int *) var; + float *var_f = (float *) var; + + switch (xlockmore_opts->vars[i].type) + { + case t_String: + *var_c = get_string_resource (xlockmore_opts->vars[i].name, + xlockmore_opts->vars[i].classname); + break; + case t_Float: + *var_f = get_float_resource (xlockmore_opts->vars[i].name, + xlockmore_opts->vars[i].classname); + break; + case t_Int: + *var_i = get_integer_resource (xlockmore_opts->vars[i].name, + xlockmore_opts->vars[i].classname); + break; + case t_Bool: + *var_b = get_boolean_resource (xlockmore_opts->vars[i].name, + xlockmore_opts->vars[i].classname); + break; + default: + abort (); + } + } +} + + + +void +xlockmore_screenhack (Display *dpy, Window window, + Bool want_writable_colors, + Bool want_uniform_colors, + Bool want_smooth_colors, + Bool want_bright_colors, + void (*hack_init) (ModeInfo *), + void (*hack_draw) (ModeInfo *), + void (*hack_free) (ModeInfo *)) +{ + ModeInfo mi; + XGCValues gcv; + XColor color; + int i; + time_t start, now; + int orig_pause; + + memset(&mi, 0, sizeof(mi)); + mi.dpy = dpy; + mi.window = window; + XGetWindowAttributes (dpy, window, &mi.xgwa); + + color.flags = DoRed|DoGreen|DoBlue; + color.red = color.green = color.blue = 0; + if (!XAllocColor(dpy, mi.xgwa.colormap, &color)) + abort(); + mi.black = color.pixel; + color.red = color.green = color.blue = 0xFFFF; + if (!XAllocColor(dpy, mi.xgwa.colormap, &color)) + abort(); + mi.white = color.pixel; + + if (mono_p) + { + static unsigned long pixels[2]; + static XColor colors[2]; + MONO: + mi.npixels = 2; + mi.pixels = pixels; + mi.colors = colors; + pixels[0] = mi.black; + pixels[1] = mi.white; + colors[0].flags = DoRed|DoGreen|DoBlue; + colors[1].flags = DoRed|DoGreen|DoBlue; + colors[0].red = colors[0].green = colors[0].blue = 0; + colors[1].red = colors[1].green = colors[1].blue = 0xFFFF; + mi.writable_p = False; + } + else + { + mi.npixels = get_integer_resource ("ncolors", "Integer"); + if (mi.npixels <= 0) + mi.npixels = 64; + else if (mi.npixels > 256) + mi.npixels = 256; + + mi.colors = (XColor *) calloc (mi.npixels, sizeof (*mi.colors)); + + mi.writable_p = want_writable_colors; + + if (want_uniform_colors) + make_uniform_colormap (dpy, mi.xgwa.visual, mi.xgwa.colormap, + mi.colors, &mi.npixels, + True, &mi.writable_p, True); + else if (want_smooth_colors) + make_smooth_colormap (dpy, mi.xgwa.visual, mi.xgwa.colormap, + mi.colors, &mi.npixels, + True, &mi.writable_p, True); + else + make_random_colormap (dpy, mi.xgwa.visual, mi.xgwa.colormap, + mi.colors, &mi.npixels, + want_bright_colors, + True, &mi.writable_p, True); + + if (mi.npixels <= 2) + goto MONO; + else + { + int i; + mi.pixels = (unsigned long *) + calloc (mi.npixels, sizeof (*mi.pixels)); + for (i = 0; i < mi.npixels; i++) + mi.pixels[i] = mi.colors[i].pixel; + } + } + + gcv.foreground = mi.white; + gcv.background = mi.black; + mi.gc = XCreateGC(dpy, window, GCForeground|GCBackground, &gcv); + + mi.fullrandom = True; + + mi.pause = get_integer_resource ("delay", "Usecs"); + + mi.cycles = get_integer_resource ("cycles", "Int"); + mi.batchcount = get_integer_resource ("count", "Int"); + mi.size = get_integer_resource ("size", "Int"); + +#if 0 + decay = get_boolean_resource ("decay", "Boolean"); + if (decay) mi.fullrandom = False; + + trail = get_boolean_resource ("trail", "Boolean"); + if (trail) mi.fullrandom = False; + + grow = get_boolean_resource ("grow", "Boolean"); + if (grow) mi.fullrandom = False; + + liss = get_boolean_resource ("liss", "Boolean"); + if (liss) mi.fullrandom = False; + + ammann = get_boolean_resource ("ammann", "Boolean"); + if (ammann) mi.fullrandom = False; + + jong = get_boolean_resource ("jong", "Boolean"); + if (jong) mi.fullrandom = False; + + sine = get_boolean_resource ("sine", "Boolean"); + if (sine) mi.fullrandom = False; +#endif + + mi.threed = get_boolean_resource ("use3d", "Boolean"); + mi.threed_delta = get_float_resource ("delta3d", "Boolean"); + mi.threed_right_color = get_pixel_resource ("right3d", "Color", dpy, + mi.xgwa.colormap); + mi.threed_left_color = get_pixel_resource ("left3d", "Color", dpy, + mi.xgwa.colormap); + mi.threed_both_color = get_pixel_resource ("both3d", "Color", dpy, + mi.xgwa.colormap); + mi.threed_none_color = get_pixel_resource ("none3d", "Color", dpy, + mi.xgwa.colormap); + + mi.wireframe_p = get_boolean_resource ("wireframe", "Boolean"); + mi.root_p = (window == RootWindowOfScreen (mi.xgwa.screen)); + + + if (mi.pause < 0) + mi.pause = 0; + else if (mi.pause > 100000000) + mi.pause = 100000000; + orig_pause = mi.pause; + + xlockmore_read_resources (); + + XClearWindow (dpy, window); + + i = 0; + start = time((time_t) 0); + + hack_init (&mi); + do { + hack_draw (&mi); + XSync(dpy, False); + if (mi.pause) + usleep(mi.pause); + mi.pause = orig_pause; + + if (hack_free) + { + if (i++ > (mi.batchcount / 4) && + (start + 5) < (now = time((time_t) 0))) + { + i = 0; + start = now; + hack_free (&mi); + hack_init (&mi); + XSync(dpy, False); + } + } + + } while (1); +} diff --git a/hacks/xlockmore.h b/hacks/xlockmore.h new file mode 100644 index 00000000..91790554 --- /dev/null +++ b/hacks/xlockmore.h @@ -0,0 +1,152 @@ +/* xlockmore.h --- xscreensaver compatibility layer for xlockmore modules. + * xscreensaver, Copyright (c) 1997, 1998 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. + * + * The definitions in this file make it possible to compile an xlockmore + * module into a standalone program, and thus use it with xscreensaver. + * By Jamie Zawinski on 10-May-97; based on the ideas + * in the older xlock.h by Charles Hannum . (I had + * to redo it, since xlockmore has diverged so far from xlock...) + */ + +#if !defined(PROGCLASS) || !defined(HACK_INIT) || !defined(HACK_DRAW) +ERROR! Define PROGCLASS, HACK_INIT, and HACK_DRAW before including xlockmore.h +#endif + +#include "config.h" + +#ifndef __STDC__ +ERROR! Sorry, xlockmore.h requires ANSI C (gcc, for example.) + /* (The ansi dependency is that we use string concatenation, + and cpp-based stringification of tokens.) */ +#endif + +#include +#include +#include "xlockmoreI.h" + +#ifdef USE_GL +# include + extern GLXContext *init_GL (ModeInfo *); +# define FreeAllGL(dpy) /* */ +#endif + +/* Accessor macros for the ModeInfo structure + */ + +#define MI_DISPLAY(MI) ((MI)->dpy) +#define MI_WINDOW(MI) ((MI)->window) +#define MI_NUM_SCREENS(MI) (1) /* Only manage one screen at a time; */ +#define MI_SCREEN(MI) (0) /* this might be fragile... */ +#define MI_WIN_WHITE_PIXEL(MI) ((MI)->white) +#define MI_WIN_BLACK_PIXEL(MI) ((MI)->black) +#define MI_NPIXELS(MI) ((MI)->npixels) +#define MI_PIXEL(MI,N) ((MI)->pixels[(N)]) +#define MI_WIN_WIDTH(MI) ((MI)->xgwa.width) +#define MI_WIN_HEIGHT(MI) ((MI)->xgwa.height) +#define MI_WIN_DEPTH(MI) ((MI)->xgwa.depth) +#define MI_WIN_COLORMAP(MI) ((MI)->xgwa.colormap) +#define MI_VISUAL(MI) ((MI)->xgwa.visual) +#define MI_GC(MI) ((MI)->gc) +#define MI_PAUSE(MI) ((MI)->pause) +#define MI_WIN_IS_FULLRANDOM(MI)((MI)->fullrandom) +#define MI_WIN_IS_VERBOSE(MI) (False) +#define MI_WIN_IS_INSTALL(MI) (True) +#define MI_WIN_IS_MONO(MI) (mono_p) +#define MI_WIN_IS_INROOT(MI) ((MI)->root_p) +#define MI_WIN_IS_INWINDOW(MI) (!(MI)->root_p) +#define MI_WIN_IS_ICONIC(MI) (False) +#define MI_WIN_IS_WIREFRAME(MI) ((MI)->wireframe_p) +#define MI_WIN_IS_USE3D(MI) ((MI)->threed) +#define MI_LEFT_COLOR(MI) ((MI)->threed_left_color) +#define MI_RIGHT_COLOR(MI) ((MI)->threed_right_color) +#define MI_BOTH_COLOR(MI) ((MI)->threed_both_color) +#define MI_NONE_COLOR(MI) ((MI)->threed_none_color) +#define MI_DELTA3D(MI) ((MI)->threed_delta) +#define MI_CYCLES(MI) ((MI)->cycles) +#define MI_BATCHCOUNT(MI) ((MI)->batchcount) +#define MI_SIZE(MI) ((MI)->size) + +#define MI_CLEARWINDOW(mi) XClearWindow(MI_DISPLAY(mi), MI_WINDOW(mi)) + +/* Some other utility macros. + */ +#define SINF(n) ((float)sin((double)(n))) +#define COSF(n) ((float)cos((double)(n))) +#define FABSF(n) ((float)fabs((double)(n))) + +#undef MAX +#undef MIN +#undef ABS +#define MAX(a,b)((a)>(b)?(a):(b)) +#define MIN(a,b)((a)<(b)?(a):(b)) +#define ABS(a)((a)<0 ? -(a) : (a)) + +/* Maximum possible number of colors (*not* default number of colors.) */ +#define NUMCOLORS 256 + +/* The globals that screenhack.c expects (initialized by xlockmore.c). + */ +char *defaults[100]; +XrmOptionDescRec options[100]; + +/* Prototypes for the actual drawing routines... + */ +extern void HACK_INIT(ModeInfo *); +extern void HACK_DRAW(ModeInfo *); + +#ifdef HACK_FREE + extern void HACK_FREE(ModeInfo *); +#else +# define HACK_FREE 0 +#endif + + +/* Emit code for the entrypoint used by screenhack.c, and pass control + down into xlockmore.c with the appropriate parameters. + */ + +char *progclass = PROGCLASS; + +void screenhack (Display *dpy, Window window) +{ + xlockmore_screenhack (dpy, window, + +#ifdef WRITABLE_COLORS + True, +#else + False, +#endif + +#ifdef UNIFORM_COLORS + True, +#else + False, +#endif + +#ifdef SMOOTH_COLORS + True, +#else + False, +#endif + +#ifdef BRIGHT_COLORS + True, +#else + False, +#endif + + HACK_INIT, + HACK_DRAW, + HACK_FREE); +} + + +const char *app_defaults = DEFAULTS ; diff --git a/hacks/xlockmoreI.h b/hacks/xlockmoreI.h new file mode 100644 index 00000000..48279640 --- /dev/null +++ b/hacks/xlockmoreI.h @@ -0,0 +1,104 @@ +/* xlockmore.h --- xscreensaver compatibility layer for xlockmore modules. + * xscreensaver, Copyright (c) 1997 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. + * + * See xlockmore.h and xlockmore.c. + */ + +#ifndef __XLOCKMORE_INTERNAL_H__ +#define __XLOCKMORE_INTERNAL_H__ + +#include "screenhack.h" + +/* I'm told that the Sun version of OpenGL needs to have the constant + SUN_OGL_NO_VERTEX_MACROS defined in order for morph3d to compile + (the number of arguments to the glNormal3f macro changes...) + Verified with gcc 2.7.2.2 and Sun cc 4.2 with OpenGL 1.1.1 dev 4 + on Solaris 2.5.1. + */ +#ifndef HAVE_MESA_GL +# if defined(__sun) && defined(__SVR4) /* Solaris */ +# define SUN_OGL_NO_VERTEX_MACROS 1 +# endif /* Solaris */ +#endif /* !HAVE_MESA_GL */ + + +/* Compatibility with the xlockmore RNG API + (note that the xlockmore hacks never expect negative numbers.) + */ +#define LRAND() ((long) (random() & 0x7fffffff)) +#define NRAND(n) ((int) (LRAND() % (n))) +#define MAXRAND (2147483648.0) /* unsigned 1<<31 as a float */ +#define SRAND(n) /* already seeded by screenhack.c */ + + +typedef struct ModeInfo { + Display *dpy; + Window window; + Bool root_p; + int npixels; + unsigned long *pixels; + XColor *colors; + Bool writable_p; + unsigned long white; + unsigned long black; + XWindowAttributes xgwa; + GC gc; + long pause; + Bool fullrandom; + long cycles; + long batchcount; + long size; + Bool threed; + long threed_left_color; + long threed_right_color; + long threed_both_color; + long threed_none_color; + long threed_delta; + Bool wireframe_p; +} ModeInfo; + +typedef enum { t_String, t_Float, t_Int, t_Bool } xlockmore_type; + +typedef struct { + void *var; + char *name; + char *classname; + char *def; + xlockmore_type type; +} argtype; + +typedef struct { + char *opt; + char *desc; +} OptionStruct; + +typedef struct { + int numopts; + XrmOptionDescRec *opts; + int numvarsdesc; + argtype *vars; + OptionStruct *desc; +} ModeSpecOpt; + +extern void xlockmore_screenhack (Display *dpy, Window window, + Bool want_writable_colors, + Bool want_uniform_colors, + Bool want_smooth_colors, + Bool want_bright_colors, + void (*hack_init) (ModeInfo *), + void (*hack_draw) (ModeInfo *), + void (*hack_free) (ModeInfo *)); + +#ifdef USE_GL +extern Visual *get_gl_visual (Screen *screen, char *name, char *class); +#endif + +#endif /* __XLOCKMORE_INTERNAL_H__ */ diff --git a/hacks/xlyap.c b/hacks/xlyap.c new file mode 100644 index 00000000..26dae592 --- /dev/null +++ b/hacks/xlyap.c @@ -0,0 +1,1973 @@ +/* Lyap - calculate and display Lyapunov exponents */ + +/* Written by Ron Record (rr@sco) 03 Sep 1991 */ + +/* The idea here is to calculate the Lyapunov exponent for a periodically + * forced logistic map (later i added several other nonlinear maps of the unit + * interval). In order to turn the 1-dimensional parameter space of the + * logistic map into a 2-dimensional parameter space, select two parameter + * values ('a' and 'b') then alternate the iterations of the logistic map using + * first 'a' then 'b' as the parameter. This program accepts an argument to + * specify a forcing function, so instead of just alternating 'a' and 'b', you + * can use 'a' as the parameter for say 6 iterations, then 'b' for 6 iterations + * and so on. An interesting forcing function to look at is abbabaab (the + * Morse-Thue sequence, an aperiodic self-similar, self-generating sequence). + * Anyway, step through all the values of 'a' and 'b' in the ranges you want, + * calculating the Lyapunov exponent for each pair of values. The exponent + * is calculated by iterating out a ways (specified by the variable "settle") + * then on subsequent iterations calculating an average of the logarithm of + * the absolute value of the derivative at that point. Points in parameter + * space with a negative Lyapunov exponent are colored one way (using the + * value of the exponent to index into a color map) while points with a + * non-negative exponent are colored differently. + * + * The algorithm was taken from the September 1991 Scientific American article + * by A. K. Dewdney who gives credit to Mario Markus of the Max Planck Institute + * for its creation. Additional information and ideas were gleaned from the + * discussion on alt.fractals involving Stephen Hall, Ed Kubaitis, Dave Platt + * and Baback Moghaddam. Assistance with colormaps and spinning color wheels + * and X was gleaned from Hiram Clawson. Rubber banding code was adapted from + * an existing Mandelbrot program written by Stacey Campbell. + */ + +#define LYAP_PATCHLEVEL 4 +#define LYAP_VERSION "#(@) lyap 2.3 2/20/92" + +#include +#include + +#include "screenhack.h" +#include "yarandom.h" +#include "hsv.h" +#include "vroot.h" + +#include +#include + +char *progclass = "XLyap"; + +char *defaults [] = { + "XLyap.background: black", /* to placate SGI */ + "*randomize: false", + "*builtin: -1", + "*minColor: 1", + "*maxColor: 256", + "*dwell: 50", + "*useLog: false", + "*colorExponent: 1.0", + "*colorOffset: 0", + "*randomForce: ", /* 0.5 */ + "*settle: 50", + "*minA: 2.0", + "*minB: 2.0", + "*wheels: 7", + "*function: 10101010", + "*forcingFunction: abbabaab", + "*bRange: ", /* 2.0 */ + "*startX: 0.65", + "*mapIndex: ", /* 0 */ + "*outputFile: ", + "*beNegative: false", + "*rgbMax: 65000", + "*spinLength: 256", + "*show: false", + "*aRange: ", /* 2.0 */ + 0 +}; + +XrmOptionDescRec options [] = { + { "-randomize", ".randomize", XrmoptionNoArg, "true" }, + { "-builtin", ".builtin", XrmoptionSepArg, 0 }, + { "-C", ".minColor", XrmoptionSepArg, 0 }, /* n */ + { "-D", ".dwell", XrmoptionSepArg, 0 }, /* n */ + { "-L", ".useLog", XrmoptionNoArg, "true" }, + { "-M", ".colorExponent", XrmoptionSepArg, 0 }, /* r */ + { "-O", ".colorOffset", XrmoptionSepArg, 0 }, /* n */ + { "-R", ".randomForce", XrmoptionSepArg, 0 }, /* p */ + { "-S", ".settle", XrmoptionSepArg, 0 }, /* n */ + { "-a", ".minA", XrmoptionSepArg, 0 }, /* r */ + { "-b", ".minB", XrmoptionSepArg, 0 }, /* n */ + { "-c", ".wheels", XrmoptionSepArg, 0 }, /* n */ + { "-F", ".function", XrmoptionSepArg, 0 }, /* 10101010 */ + { "-f", ".forcingFunction", XrmoptionSepArg, 0 }, /* abbabaab */ + { "-h", ".bRange", XrmoptionSepArg, 0 }, /* r */ + { "-i", ".startX", XrmoptionSepArg, 0 }, /* r */ + { "-m", ".mapIndex", XrmoptionSepArg, 0 }, /* n */ + { "-o", ".outputFile", XrmoptionSepArg, 0 }, /* filename */ + { "-p", ".beNegative", XrmoptionNoArg, "true" }, + { "-r", ".rgbMax", XrmoptionSepArg, 0 }, /* n */ + { "-s", ".spinLength", XrmoptionSepArg, 0 }, /* n */ + { "-v", ".show", XrmoptionNoArg, "true" }, + { "-w", ".aRange", XrmoptionSepArg, 0 }, /* r */ + { 0, 0, 0, 0 } +}; + + +#define ABS(a) (((a)<0) ? (0-(a)) : (a) ) +#define Min(x,y) ((x < y)?x:y) +#define Max(x,y) ((x > y)?x:y) + +#ifdef SIXTEEN_COLORS +#define MAXPOINTS 128 +#ifdef BIGMEM +#define MAXFRAMES 4 +#else +#define MAXFRAMES 2 +#endif +#define MAXCOLOR 16 +static int maxcolor=16, startcolor=0, color_offset=0, mincolindex=1; +static int dwell=50, settle=25; +static int width=128, height=128, xposition=128, yposition=128; +#else +#define MAXPOINTS 256 +#ifdef BIGMEM +#define MAXFRAMES 8 +#else +#define MAXFRAMES 2 +#endif +#define MAXCOLOR 256 +static int maxcolor=256, startcolor=17, color_offset=96, mincolindex=33; +static int dwell=100, settle=50; +static int width=256, height=256; +#endif + +#ifndef TRUE +#define TRUE 1 +#define FALSE 0 +#endif + +static int screen; +static Display* dpy; +static Visual *visual; + +static unsigned long foreground, background; + +static Window canvas; + +typedef struct { + int x, y; +} xy_t; + +typedef struct { + int start_x, start_y; + int last_x, last_y; + } rubber_band_data_t; + +typedef struct { + Cursor band_cursor; + double p_min, p_max, q_min, q_max; + rubber_band_data_t rubber_band; + } image_data_t; + +typedef struct points_t { + XPoint data[MAXCOLOR][MAXPOINTS]; + int npoints[MAXCOLOR]; + } points_t; + +static points_t Points; +static image_data_t rubber_data; + +#ifndef TRUE +#define TRUE 1 +#define FALSE 0 +#endif + +static GC Data_GC[MAXCOLOR], RubberGC; + +#define MAXINDEX 64 +#define FUNCMAXINDEX 16 +#define MAXWHEELS 7 +#define NUMMAPS 5 + +typedef double (*PFD)(double,double); + +static double logistic(double,double), circle(double,double), leftlog(double,double), rightlog(double,double), doublelog(double,double); +static double dlogistic(double,double), dcircle(double,double), dleftlog(double,double), drightlog(double,double), ddoublelog(double,double); +static PFD map, deriv; +static PFD Maps[NUMMAPS] = { logistic, circle, leftlog, rightlog, doublelog }; +static PFD Derivs[NUMMAPS] = { dlogistic, dcircle, dleftlog, drightlog, ddoublelog }; + +static int aflag=0, bflag=0, wflag=0, hflag=0, Rflag=0; +static double pmins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double pmaxs[NUMMAPS] = { 4.0, 1.0, 6.75, 6.75, 16.0 }; +static double amins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double aranges[NUMMAPS] = { 2.0, 1.0, 6.75, 6.75, 16.0 }; +static double bmins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double branges[NUMMAPS] = { 2.0, 1.0, 6.75, 6.75, 16.0 }; + +static int forcing[MAXINDEX] = { 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1, + 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1, + 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1 }; +static int Forcing[FUNCMAXINDEX] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }; + +static int maxindex = MAXINDEX; +static int funcmaxindex = FUNCMAXINDEX; +static double min_a=2.0, min_b=2.0, a_range=2.0, b_range=2.0, minlyap=1.0; +static double max_a=4.0, max_b=4.0; +static double start_x=0.65, lyapunov, a_inc, b_inc, a, b; +static int numcolors=16, numfreecols, displayplanes, lowrange; +static xy_t point; +static Pixmap pixmap; +static Colormap cmap; +static XColor Colors[MAXCOLOR]; +static double *exponents[MAXFRAMES]; +static double a_minimums[MAXFRAMES], b_minimums[MAXFRAMES]; +static double a_maximums[MAXFRAMES], b_maximums[MAXFRAMES]; +static double minexp, maxexp, prob=0.5; +static int expind[MAXFRAMES]={0}, resized[MAXFRAMES]={0}; +static int numwheels=MAXWHEELS, force=0, Force=0, negative=1; +static int rgb_max=65000, nostart=1, stripe_interval=7; +static int save=1, show=0, useprod=1, spinlength=256, savefile=0; +static int maxframe=0, frame=0, dorecalc=0, mapindex=0, run=1; +static char *outname="lyap.out"; + + +const char * const version = LYAP_VERSION; + +static void resize(void); +static void redisplay(Window w, XExposeEvent *event); +static void Spin(Window w); +static void show_defaults(void); +static void StartRubberBand(Window w, image_data_t *data, XEvent *event); +static void TrackRubberBand(Window w, image_data_t *data, XEvent *event); +static void EndRubberBand(Window w, image_data_t *data, XEvent *event); +static void CreateXorGC(void); +static void InitBuffer(void); +static void BufferPoint(Display *display, Window window, int color, + int x, int y); +static void FlushBuffer(void); +static void init_canvas(void); +static void init_data(void); +static void init_color(void); +static void parseargs(void); +static void Clear(void); +static void setupmem(void); +static void main_event(void); +static int complyap(void); +static void Getkey(XKeyEvent *event); +static int sendpoint(double expo); +static void save_to_file(void); +static void setforcing(void); +static void check_params(int mapnum, int parnum); +static void usage(void); +static void Destroy_frame(void); +static void freemem(void); +static void Redraw(void); +static void redraw(double *exparray, int index, int cont); +static void recalc(void); +static void SetupCorners(XPoint *corners, image_data_t *data); +static void set_new_params(Window w, image_data_t *data); +static void go_down(void); +static void go_back(void); +static void go_init(void); +static void jumpwin(void); +static void print_help(void); +static void print_values(void); + + +void +screenhack (Display *d, Window window) +{ + XWindowAttributes xgwa; + int builtin = -1; + dpy = d; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + visual = xgwa.visual; + cmap = xgwa.colormap; + + parseargs(); + + if (get_boolean_resource("randomize", "Boolean")) + builtin = random() % 22; + else { + char *s = get_string_resource("builtin", "Integer"); + if (s && *s) + builtin = atoi(s); + if (s) free (s); + } + + if (builtin >= 0) + { + char *ff = 0; + switch (builtin) { + case 0: + min_a = 3.75; aflag++; + min_b = 3.299999; bflag++; + a_range = 0.05; wflag++; + b_range = 0.05; hflag++; + dwell = 200; + settle = 100; + ff = "abaabbaaabbb"; + break; + + case 1: + min_a = 3.8; aflag++; + min_b = 3.2; bflag++; + b_range = .05; hflag++; + a_range = .05; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 2: + min_a = 3.4; aflag++; + min_b = 3.04; bflag++; + a_range = .5; wflag++; + b_range = .5; hflag++; + ff = "abbbbbbbbb"; + settle = 500; + dwell = 1000; + break; + + case 3: + min_a = 3.5; aflag++; + min_b = 3.0; bflag++; + a_range = 0.2; wflag++; + b_range = 0.2; hflag++; + dwell = 600; + settle = 300; + ff = "aaabbbab"; + break; + + case 4: + min_a = 3.55667; aflag++; + min_b = 3.2; bflag++; + b_range = .05; hflag++; + a_range = .05; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 5: + min_a = 3.79; aflag++; + min_b = 3.22; bflag++; + b_range = .02999; hflag++; + a_range = .02999; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 6: + min_a = 3.7999; aflag++; + min_b = 3.299999; bflag++; + a_range = 0.2; wflag++; + b_range = 0.2; hflag++; + dwell = 300; + settle = 150; + ff = "abaabbaaabbb"; + break; + + case 7: + min_a = 3.89; aflag++; + min_b = 3.22; bflag++; + b_range = .028; hflag++; + a_range = .02999; wflag++; + ff = "bbbbbaaaaa"; + settle = 600; + dwell = 1000; + break; + + case 8: + min_a = 3.2; aflag++; + min_b = 3.7; bflag++; + a_range = 0.05; wflag++; + b_range = .005; hflag++; + ff = "abbbbaa"; + break; + + case 9: + ff = "aaaaaabbbbbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 10: + ff = "aaaaaabbbbbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 11: + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 12: + ff = "abbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 13: + ff = "abbabaab"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 14: + ff = "abbabaab"; + dwell = 800; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + /* #### -x 0.05 */ + min_a = 3.91; aflag++; + a_range = 0.0899999999; wflag++; + min_b = 3.28; bflag++; + b_range = 0.35; hflag++; + break; + + case 15: + ff = "aaaaaabbbbbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 16: + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 17: + ff = "abbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 18: + ff = "abbabaab"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 19: + mapindex = 2; + ff = "aaaaaabbbbbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 20: + mapindex = 2; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 21: + mapindex = 2; + ff = "abbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 22: + mapindex = 2; + ff = "abbabaab"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + } + + if (ff) { + char *ch; + int bindex = 0; + maxindex = strlen(ff); + if (maxindex > MAXINDEX) + usage(); + ch = ff; + force++; + while (bindex < maxindex) { + if (*ch == 'a') + forcing[bindex++] = 0; + else if (*ch == 'b') + forcing[bindex++] = 1; + else + usage(); + ch++; + } + } + } + + screen = DefaultScreen(dpy); + background = BlackPixel(dpy, screen); + setupmem(); + init_data(); + if (displayplanes > 1) + foreground = startcolor; + else + foreground = WhitePixel(dpy, screen); + + /* + * Create the window to display the Lyapunov exponents + */ + canvas = window; + init_canvas(); + + if (window != DefaultRootWindow(dpy)) + XSelectInput(dpy,canvas,KeyPressMask|ButtonPressMask|ButtonMotionMask| + ButtonReleaseMask|ExposureMask|StructureNotifyMask); + if (displayplanes > 1) { + init_color(); + } else { + XQueryColors(dpy, DefaultColormap(dpy, DefaultScreen(dpy)), + Colors, numcolors); + } + pixmap = XCreatePixmap(dpy, DefaultRootWindow(dpy), + width, height, DefaultDepth(dpy, screen)); + rubber_data.band_cursor = XCreateFontCursor(dpy, XC_hand2); + CreateXorGC(); + Clear(); + for(;;) + main_event(); +} + +static void +main_event(void) +{ + int n; + XEvent event; + + if (complyap() == TRUE) + run=0; + n = XEventsQueued(dpy, QueuedAfterFlush); + while (n--) { + XNextEvent(dpy, &event); + switch(event.type) + { + case KeyPress: + Getkey(&event.xkey); + break; + case Expose: + redisplay(canvas, &event.xexpose); + break; + case ConfigureNotify: + resize(); + break; + case ButtonPress: + StartRubberBand(canvas, &rubber_data, &event); + break; + case MotionNotify: + TrackRubberBand(canvas, &rubber_data, &event); + break; + case ButtonRelease: + EndRubberBand(canvas, &rubber_data, &event); + break; + } + } +} + +/* complyap() is the guts of the program. This is where the Lyapunov exponent + * is calculated. For each iteration (past some large number of iterations) + * calculate the logarithm of the absolute value of the derivative at that + * point. Then average them over some large number of iterations. Some small + * speed up is achieved by utilizing the fact that log(a*b) = log(a) + log(b). + */ +static int +complyap(void) +{ + register i, bindex; + double total, prod, x, r; + + if (!run) + return TRUE; + a += a_inc; + if (a >= max_a) + if (sendpoint(lyapunov) == TRUE) + return FALSE; + else { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } + if (b >= max_b) { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } + prod = 1.0; + total = 0.0; + bindex = 0; + x = start_x; + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + findex = 0; + map = Maps[Forcing[findex]]; +#endif + for (i=0;i= maxindex) { /* some initial "noise" in the */ + bindex = 0; /* iterations. How can we optimize */ + if (Rflag) /* the value of settle ??? */ + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; +#endif + } +#ifdef MAPS + deriv = Derivs[Forcing[findex]]; +#endif + if (useprod) { /* using log(a*b) */ + for (i=0;i 1.0e12) || (prod < 1.0e-12)) { + total += log(prod); + prod = 1.0; + } + if (++bindex >= maxindex) { + bindex = 0; + if (Rflag) + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; + deriv = Derivs[Forcing[findex]]; +#endif + } + total += log(prod); + lyapunov = (total * M_LOG2E) / (double)dwell; + } + else { /* use log(a) + log(b) */ + for (i=0;i= maxindex) { + bindex = 0; + if (Rflag) + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; + deriv = Derivs[Forcing[findex]]; +#endif + } + lyapunov = (total * M_LOG2E) / (double)dwell; + } + if (sendpoint(lyapunov) == TRUE) + return FALSE; + else { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } +} + +static double +logistic(double x, double r) /* the familiar logistic map */ +{ + return(r * x * (1.0 - x)); +} + +static double +dlogistic(double x, double r) /* the derivative of logistic map */ +{ + return(r - (2.0 * r * x)); +} + +static double +circle(double x, double r) /* sin() hump or sorta like the circle map */ +{ + return(r * sin(M_PI * x)); +} + +static double +dcircle(double x, double r) /* derivative of the "sin() hump" */ +{ + return(r * M_PI * cos(M_PI * x)); +} + +static double +leftlog(double x, double r) /* left skewed logistic */ +{ + double d; + + d = 1.0 - x; + return(r * x * d * d); +} + +static double +dleftlog(double x, double r) /* derivative of the left skewed logistic */ +{ + return(r * (1.0 - (4.0 * x) + (3.0 * x * x))); +} + +static double +rightlog(double x, double r) /* right skewed logistic */ +{ + return(r * x * x * (1.0 - x)); +} + +static double +drightlog(double x, double r) /* derivative of the right skewed logistic */ +{ + return(r * ((2.0 * x) - (3.0 * x * x))); +} + +static double +doublelog(double x, double r) /* double logistic */ +{ + double d; + + d = 1.0 - x; + return(r * x * x * d * d); +} + +static double +ddoublelog(double x, double r) /* derivative of the double logistic */ +{ + double d; + + d = x * x; + return(r * ((2.0 * x) - (6.0 * d) + (4.0 * x * d))); +} + +static void +init_data(void) +{ + numcolors = XDisplayCells(dpy, XDefaultScreen(dpy)); + displayplanes = DisplayPlanes(dpy, XDefaultScreen(dpy)); + if (numcolors > maxcolor) + numcolors = maxcolor; + numfreecols = numcolors - mincolindex; + lowrange = mincolindex - startcolor; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + a = rubber_data.p_min = min_a; + b = rubber_data.q_min = min_b; + rubber_data.p_max = max_a; + rubber_data.q_max = max_b; + if (show) + show_defaults(); + InitBuffer(); + ya_rand_init(0); +} + +static void +init_canvas(void) +{ + static int i; + + /* + * create default, writable, graphics contexts for the canvas. + */ + for (i=0; i 0-360 */ + (int) ((hue_light_sat[2]/1000.0) * 64435), /* 0-1000 -> 0-65535 */ + (int) ((hue_light_sat[1]/1000.0) * 64435), /* 0-1000 -> 0-65535 */ + &r, &g, &b); + rgb[0] = r; + rgb[1] = g; + rgb[2] = b; +} +#endif /* 0 */ + + +static void +init_color(void) +{ +#if 1 + + int i; + XColor colors[256]; + int ncolors = maxcolor; + Bool writable = False; + make_smooth_colormap(dpy, visual, cmap, + colors, &ncolors, True, &writable, True); + + for (i = 0; i < maxcolor; i++) + XSetForeground(dpy, Data_GC[i], + colors[((int) ((i / ((float)maxcolor)) * ncolors))].pixel); + +#else + static int i, j, colgap, leg, step; + static Visual *visual; + Colormap def_cmap; + int hls[3], rgb[3]; + + def_cmap = DefaultColormap(dpy, DefaultScreen(dpy)); + for (i=0; i FUNCMAXINDEX) + usage(); + ch = optarg; + Force++; + for (findex=0;findex= NUMMAPS) + usage(); + } + } +#endif + if (get_boolean_resource("useLog", "Boolean")) + useprod=0; + + minlyap=ABS(get_float_resource("colorExponent", "Float")); + maxexp=minlyap; + minexp= -1.0 * minlyap; + + color_offset = get_integer_resource("colorOffset", "Integer"); + + maxcolor=ABS(get_integer_resource("maxColor", "Integer")); + if ((maxcolor - startcolor) <= 0) + startcolor = 0; + if ((maxcolor - mincolindex) <= 0) { + mincolindex = 1; + color_offset = 0; + } + + s = get_string_resource("randomForce", "Float"); + if (s && *s) { + prob=atof(s); Rflag++; setforcing(); + } + + settle = get_integer_resource("settle", "Integer"); + + s = get_string_resource("minA", "Float"); + if (s && *s) { + min_a = atof(s); + aflag++; + } + + s = get_string_resource("minB", "Float"); + if (s && *s) { + min_b=atof(s); bflag++; + } + + numwheels = get_integer_resource("wheels", "Integer"); + + s = get_string_resource("forcingFunction", "String"); + if (s && *s) { + maxindex = strlen(s); + if (maxindex > MAXINDEX) + usage(); + ch = s; + force++; + while (bindex < maxindex) { + if (*ch == 'a') + forcing[bindex++] = 0; + else if (*ch == 'b') + forcing[bindex++] = 1; + else + usage(); + ch++; + } + } + + s = get_string_resource("bRange", "Float"); + if (s && *s) { + b_range = atof(s); + hflag++; + } + + start_x = get_float_resource("startX", "Float"); + + s = get_string_resource("mapIndex", "Integer"); + if (s && *s) { + mapindex=atoi(s); + if ((mapindex >= NUMMAPS) || (mapindex < 0)) + usage(); + map = Maps[mapindex]; + deriv = Derivs[mapindex]; + if (!aflag) + min_a = amins[mapindex]; + if (!wflag) + a_range = aranges[mapindex]; + if (!bflag) + min_b = bmins[mapindex]; + if (!hflag) + b_range = branges[mapindex]; + if (!Force) + for (i=0;i pmaxs[mapnum]) || (min_a < pmins[mapnum])) { + fprintf(stderr, "Warning! Parameter 'a' out of range.\n"); + fprintf(stderr, "You have requested a range of (%f,%f).\n", + min_a,max_a); + fprintf(stderr, "Valid range is (%f,%f).\n", + pmins[mapnum],pmaxs[mapnum]); + } + } + if (parnum != 0) { + if ((max_b > pmaxs[mapnum]) || (min_b < pmins[mapnum])) { + fprintf(stderr, "Warning! Parameter 'b' out of range.\n"); + fprintf(stderr, "You have requested a range of (%f,%f).\n", + min_b,max_b); + fprintf(stderr, "Valid range is (%f,%f).\n", + pmins[mapnum],pmaxs[mapnum]); + } + } +} + +static void +usage(void) +{ + fprintf(stderr,"lyap [-BLs][-W#][-H#][-a#][-b#][-w#][-h#][-x xstart]\n"); + fprintf(stderr,"\t[-M#][-S#][-D#][-f string][-r#][-O#][-C#][-c#][-m#]\n"); +#ifdef MAPS + fprintf(stderr,"\t[-F string]\n"); +#endif + fprintf(stderr,"\tWhere: -C# specifies the minimum color index\n"); + fprintf(stderr,"\t -r# specifies the maxzimum rgb value\n"); + fprintf(stderr,"\t -u displays this message\n"); + fprintf(stderr,"\t -a# specifies the minimum horizontal parameter\n"); + fprintf(stderr,"\t -b# specifies the minimum vertical parameter\n"); + fprintf(stderr,"\t -w# specifies the horizontal parameter range\n"); + fprintf(stderr,"\t -h# specifies the vertical parameter range\n"); + fprintf(stderr,"\t -D# specifies the dwell\n"); + fprintf(stderr,"\t -S# specifies the settle\n"); + fprintf(stderr,"\t -H# specifies the initial window height\n"); + fprintf(stderr,"\t -W# specifies the initial window width\n"); + fprintf(stderr,"\t -O# specifies the color offset\n"); + fprintf(stderr,"\t -c# specifies the desired color wheel\n"); + fprintf(stderr,"\t -m# specifies the desired map (0-4)\n"); + fprintf(stderr,"\t -f aabbb specifies a forcing function of 00111\n"); +#ifdef MAPS + fprintf(stderr,"\t -F 00111 specifies the function forcing function\n"); +#endif + fprintf(stderr,"\t -L indicates use log(x)+log(y) rather than log(xy)\n"); + fprintf(stderr,"\tDuring display :\n"); + fprintf(stderr,"\t Use the mouse to zoom in on an area\n"); + fprintf(stderr,"\t e or E recalculates color indices\n"); + fprintf(stderr,"\t f or F saves exponents to a file\n"); + fprintf(stderr,"\t KJmn increase/decrease minimum negative exponent\n"); + fprintf(stderr,"\t r or R redraws\n"); + fprintf(stderr,"\t s or S spins the colorwheel\n"); + fprintf(stderr,"\t w or W changes the color wheel\n"); + fprintf(stderr,"\t x or X clears the window\n"); + fprintf(stderr,"\t q or Q exits\n"); + exit(1); +} + +static void +Cycle_frames(void) +{ + static int i; + for (i=0;i<=maxframe;i++) + redraw(exponents[i], expind[i], 1); +} + +static void +Spin(Window w) +{ + static int i, j; + long tmpxcolor; + + if (displayplanes > 1) { + for (j=0;jmincolindex;i--) + Colors[i].pixel = Colors[i-1].pixel; + Colors[mincolindex].pixel = tmpxcolor; + XStoreColors(dpy, cmap, Colors, numcolors); + } + } +} + +static void +Getkey(XKeyEvent *event) +{ + unsigned char key; + static int i; + if (XLookupString(event, (char *)&key, sizeof(key), (KeySym *)0, + (XComposeStatus *) 0) > 0) + switch (key) { + case '<': dwell /= 2; if (dwell < 1) dwell = 1; break; + case '>': dwell *= 2; break; + case '[': settle /= 2; if (settle < 1) settle = 1; break; + case ']': settle *= 2; break; + case 'd': go_down(); break; + case 'D': FlushBuffer(); break; + case 'e': + case 'E': FlushBuffer(); + dorecalc = (!dorecalc); + if (dorecalc) + recalc(); + else { + maxexp = minlyap; minexp = -1.0 * minlyap; + } + redraw(exponents[frame], expind[frame], 1); + break; + case 'f': + case 'F': save_to_file(); break; + case 'i': if (stripe_interval > 0) { + stripe_interval--; + if (displayplanes > 1) { + init_color(); + } + } + break; + case 'I': stripe_interval++; + if (displayplanes > 1) { + init_color(); + } + break; + case 'K': if (minlyap > 0.05) + minlyap -= 0.05; + break; + case 'J': minlyap += 0.05; + break; + case 'm': mapindex++; + if (mapindex >= NUMMAPS) + mapindex=0; + map = Maps[mapindex]; + deriv = Derivs[mapindex]; + if (!aflag) + min_a = amins[mapindex]; + if (!wflag) + a_range = aranges[mapindex]; + if (!bflag) + min_b = bmins[mapindex]; + if (!hflag) + b_range = branges[mapindex]; + if (!Force) + for (i=0;i 0.005) + minlyap -= 0.005; + break; + case 'N': minlyap += 0.005; + break; + case 'p': + case 'P': negative = (!negative); + FlushBuffer(); redraw(exponents[frame], expind[frame], 1); + break; + case 'r': FlushBuffer(); redraw(exponents[frame], expind[frame], 1); + break; + case 'R': FlushBuffer(); Redraw(); break; + case 's': + spinlength=spinlength/2; + case 'S': if (displayplanes > 1) + Spin(canvas); + spinlength=spinlength*2; break; + case 'u': go_back(); break; + case 'U': go_init(); break; + case 'v': + case 'V': print_values(); break; + case 'W': if (numwheels < MAXWHEELS) + numwheels++; + else + numwheels = 0; + if (displayplanes > 1) { + init_color(); + } + break; + case 'w': if (numwheels > 0) + numwheels--; + else + numwheels = MAXWHEELS; + if (displayplanes > 1) { + init_color(); + } + break; + case 'x': Clear(); break; + case 'X': Destroy_frame(); break; + case 'z': Cycle_frames(); redraw(exponents[frame], expind[frame], 1); + break; + case 'Z': while (!XPending(dpy)) Cycle_frames(); + redraw(exponents[frame], expind[frame], 1); break; + case 'q': + case 'Q': exit(0); break; + case '?': + case 'h': + case 'H': print_help(); break; + default: break; + } +} + +/* Here's where we index into a color map. After the Lyapunov exponent is + * calculated, it is used to determine what color to use for that point. + * I suppose there are a lot of ways to do this. I used the following : + * if it's non-negative then there's a reserved area at the lower range + * of the color map that i index into. The ratio of some "minimum exponent + * value" and the calculated value is used as a ratio of how high to index + * into this reserved range. Usually these colors are dark red (see init_color). + * If the exponent is negative, the same ratio (expo/minlyap) is used to index + * into the remaining portion of the colormap (which is usually some light + * shades of color or a rainbow wheel). The coloring scheme can actually make + * a great deal of difference in the quality of the picture. Different colormaps + * bring out different details of the dynamics while different indexing + * algorithms also greatly effect what details are seen. Play around with this. + */ +static int +sendpoint(double expo) +{ + static int index; + static double tmpexpo; + + point.x++; + tmpexpo = (negative) ? expo : -1.0 * expo; + if (tmpexpo > 0) { + if (displayplanes >1) { + index = (int)(tmpexpo*lowrange/maxexp); + index = (index % lowrange) + startcolor; + } + else + index = 0; + } + else { + if (displayplanes >1) { + index = (int)(tmpexpo*numfreecols/minexp); + index = (index % numfreecols) + mincolindex; + } + else + index = 1; + } + BufferPoint(dpy, canvas, index, point.x, point.y); + if (save) + exponents[frame][expind[frame]++] = expo; + if (point.x >= width) { + point.y++; + point.x = 0; + if (save) { + b += b_inc; + a = min_a; + } + if (point.y >= height) + return FALSE; + else + return TRUE; + } + return TRUE; +} + +static void +redisplay (Window w, XExposeEvent *event) +{ + /* + * Extract the exposed area from the event and copy + * from the saved pixmap to the window. + */ + XCopyArea(dpy, pixmap, canvas, Data_GC[0], + event->x, event->y, event->width, event->height, + event->x, event->y); +} + +static void +resize(void) +{ + Window r; + int n, x, y; + unsigned int bw, d, new_w, new_h; + + XGetGeometry(dpy,canvas,&r,&x,&y,&new_w,&new_h,&bw,&d); + if ((new_w == width) && (new_h == height)) + return; + width = new_w; height = new_h; + XClearWindow(dpy, canvas); + if (pixmap) + XFreePixmap(dpy, pixmap); + pixmap = XCreatePixmap(dpy, DefaultRootWindow(dpy), + width, height, DefaultDepth(dpy, screen)); + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + run = 1; + a = rubber_data.p_min = min_a; + b = rubber_data.q_min = min_b; + rubber_data.p_max = max_a; + rubber_data.q_max = max_b; + freemem(); + setupmem(); + for (n=0;n 1) { + for (i=0;i> 8); + colormap[i].green=(unsigned char)(Colors[i].green >> 8); + colormap[i].blue =(unsigned char)(Colors[i].blue >> 8); + } + fprintf(outfile,"P%d %d %d\n",6,width,height); + } + else + fprintf(outfile,"P%d %d %d\n",5,width,height); + fprintf(outfile,"# settle=%d dwell=%d start_x=%f\n",settle,dwell, + start_x); + fprintf(outfile,"# min_a=%f a_rng=%f max_a=%f\n",min_a,a_range,max_a); + fprintf(outfile,"# min_b=%f b_rng=%f max_b=%f\n",min_b,b_range,max_b); + if (Rflag) + fprintf(outfile,"# pseudo-random forcing\n"); + else if (force) { + fprintf(outfile,"# periodic forcing="); + for (i=0;i 1) + fwrite((char *)&colormap[c],sizeof colormap[0],1,outfile); + else + fwrite((char *)&c,sizeof c,1,outfile); + } + fclose(outfile); +} + +static void +recalc(void) +{ + static int i, x, y; + + minexp = maxexp = 0.0; + x = y = 0; + for (i=0;i maxexp) + maxexp = exponents[frame][i]; + } +} + +static void +Clear(void) +{ + XClearWindow(dpy, canvas); + XCopyArea(dpy, canvas, pixmap, Data_GC[0], + 0, 0, width, height, 0, 0); + InitBuffer(); +} + +static void +show_defaults(void) +{ + + printf("Width=%d Height=%d numcolors=%d settle=%d dwell=%d\n", + width,height,numcolors,settle,dwell); + printf("min_a=%f a_range=%f max_a=%f\n", min_a,a_range,max_a); + printf("min_b=%f b_range=%f max_b=%f\n", min_b,b_range,max_b); + printf("minlyap=%f minexp=%f maxexp=%f\n", minlyap,minexp,maxexp); + exit(0); +} + +static void +CreateXorGC(void) +{ + XGCValues values; + + values.foreground = foreground; + values.line_style = LineSolid; + values.function = GXxor; + RubberGC = XCreateGC(dpy, DefaultRootWindow(dpy), + GCForeground | GCBackground | GCFunction | GCLineStyle, &values); +} + +static void +StartRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + + nostart = 0; + data->rubber_band.last_x = data->rubber_band.start_x = event->xbutton.x; + data->rubber_band.last_y = data->rubber_band.start_y = event->xbutton.y; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); +} + +static void +SetupCorners(XPoint *corners, image_data_t *data) +{ + corners[0].x = data->rubber_band.start_x; + corners[0].y = data->rubber_band.start_y; + corners[1].x = data->rubber_band.start_x; + corners[1].y = data->rubber_band.last_y; + corners[2].x = data->rubber_band.last_x; + corners[2].y = data->rubber_band.last_y; + corners[3].x = data->rubber_band.last_x; + corners[3].y = data->rubber_band.start_y; + corners[4] = corners[0]; +} + +static void +TrackRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + int xdiff, ydiff; + + if (nostart) + return; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); + ydiff = event->xbutton.y - data->rubber_band.start_y; + xdiff = event->xbutton.x - data->rubber_band.start_x; + data->rubber_band.last_x = data->rubber_band.start_x + xdiff; + data->rubber_band.last_y = data->rubber_band.start_y + ydiff; + if (data->rubber_band.last_y < data->rubber_band.start_y || + data->rubber_band.last_x < data->rubber_band.start_x) + { + data->rubber_band.last_y = data->rubber_band.start_y; + data->rubber_band.last_x = data->rubber_band.start_x; + } + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); +} + +static void +EndRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + XPoint top, bot; + double delta, diff; + + nostart = 1; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); + if (data->rubber_band.start_x >= data->rubber_band.last_x || + data->rubber_band.start_y >= data->rubber_band.last_y) + return; + top.x = data->rubber_band.start_x; + bot.x = data->rubber_band.last_x; + top.y = data->rubber_band.start_y; + bot.y = data->rubber_band.last_y; + diff = data->q_max - data->q_min; + delta = (double)top.y / (double)height; + data->q_min += diff * delta; + delta = (double)(height - bot.y) / (double)height; + data->q_max -= diff * delta; + diff = data->p_max - data->p_min; + delta = (double)top.x / (double)width; + data->p_min += diff * delta; + delta = (double)(width - bot.x) / (double)width; + data->p_max -= diff * delta; + fflush(stdout); + set_new_params(w, data); +} + +static void +set_new_params(Window w, image_data_t *data) +{ + frame = (maxframe + 1) % MAXFRAMES; + if (frame > maxframe) + maxframe = frame; + a_range = data->p_max - data->p_min; + b_range = data->q_max - data->q_min; + a_minimums[frame] = min_a = data->p_min; + b_minimums[frame] = min_b = data->q_min; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + run = 1; + a = min_a; + b = min_b; + a_maximums[frame] = max_a = data->p_max; + b_maximums[frame] = max_b = data->q_max; + expind[frame] = 0;; + Clear(); +} + +static void +go_down(void) +{ + frame++; + if (frame > maxframe) + frame = 0; + jumpwin(); +} + +static void +go_back(void) +{ + frame--; + if (frame < 0) + frame = maxframe; + jumpwin(); +} + +static void +jumpwin(void) +{ + rubber_data.p_min = min_a = a_minimums[frame]; + rubber_data.q_min = min_b = b_minimums[frame]; + rubber_data.p_max = max_a = a_maximums[frame]; + rubber_data.q_max = max_b = b_maximums[frame]; + a_range = max_a - min_a; + b_range = max_b - min_b; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + a = min_a; + b = min_b; + Clear(); + if (resized[frame]) + Redraw(); + else + redraw(exponents[frame], expind[frame], 0); +} + +static void +go_init(void) +{ + frame = 0; + jumpwin(); +} + +static void +Destroy_frame(void) +{ + static int i; + + for (i=frame; i doubles the 'dwell'\n"); + printf("[ halves the 'settle', ] doubles the 'settle'\n"); + printf("D flushes the drawing buffer\n"); + printf("e or E recalculates color indices\n"); + printf("f or F saves exponents to a file\n"); + printf("h or H or ? displays this message\n"); + printf("i decrements, I increments the stripe interval\n"); + printf("KJMN increase/decrease minimum negative exponent\n"); + printf("m increments the map index, changing maps\n"); + printf("p or P reverses the colormap for negative/positive exponents\n"); + printf("r redraws without recalculating\n"); + printf("R redraws, recalculating with new dwell and settle values\n"); + printf("s or S spins the colorwheel\n"); + printf("u pops back up to the last zoom\n"); + printf("U pops back up to the first picture\n"); + printf("v or V displays the values of various settings\n"); + printf("w decrements, W increments the color wheel index\n"); + printf("x or X clears the window\n"); + printf("q or Q exits\n"); +} + +static void +print_values(void) +{ + static int i; + + printf("\nminlyap=%f minexp=%f maxexp=%f\n",minlyap,minexp,maxexp); + printf("width=%d height=%d\n",width,height); + printf("settle=%d dwell=%d start_x=%f\n",settle,dwell, start_x); + printf("min_a=%f a_rng=%f max_a=%f\n",min_a,a_range,max_a); + printf("min_b=%f b_rng=%f max_b=%f\n",min_b,b_range,max_b); + if (Rflag) + printf("pseudo-random forcing\n"); + else if (force) { + printf("periodic forcing="); + for (i=0;i prob) ? 0 : 1; +} diff --git a/hacks/xlyap.c.00 b/hacks/xlyap.c.00 new file mode 100644 index 00000000..350888d0 --- /dev/null +++ b/hacks/xlyap.c.00 @@ -0,0 +1,1965 @@ +/* Lyap - calculate and display Lyapunov exponents */ + +/* Written by Ron Record (rr@sco) 03 Sep 1991 */ + +/* The idea here is to calculate the Lyapunov exponent for a periodically + * forced logistic map (later i added several other nonlinear maps of the unit + * interval). In order to turn the 1-dimensional parameter space of the + * logistic map into a 2-dimensional parameter space, select two parameter + * values ('a' and 'b') then alternate the iterations of the logistic map using + * first 'a' then 'b' as the parameter. This program accepts an argument to + * specify a forcing function, so instead of just alternating 'a' and 'b', you + * can use 'a' as the parameter for say 6 iterations, then 'b' for 6 iterations + * and so on. An interesting forcing function to look at is abbabaab (the + * Morse-Thue sequence, an aperiodic self-similar, self-generating sequence). + * Anyway, step through all the values of 'a' and 'b' in the ranges you want, + * calculating the Lyapunov exponent for each pair of values. The exponent + * is calculated by iterating out a ways (specified by the variable "settle") + * then on subsequent iterations calculating an average of the logarithm of + * the absolute value of the derivative at that point. Points in parameter + * space with a negative Lyapunov exponent are colored one way (using the + * value of the exponent to index into a color map) while points with a + * non-negative exponent are colored differently. + * + * The algorithm was taken from the September 1991 Scientific American article + * by A. K. Dewdney who gives credit to Mario Markus of the Max Planck Institute + * for its creation. Additional information and ideas were gleaned from the + * discussion on alt.fractals involving Stephen Hall, Ed Kubaitis, Dave Platt + * and Baback Moghaddam. Assistance with colormaps and spinning color wheels + * and X was gleaned from Hiram Clawson. Rubber banding code was adapted from + * an existing Mandelbrot program written by Stacey Campbell. + */ + +#define LYAP_PATCHLEVEL 4 +#define LYAP_VERSION "#(@) lyap 2.3 2/20/92" + +#include +#include + +#include "screenhack.h" +#include "yarandom.h" +#include "hsv.h" +#include "vroot.h" + +#include +#include + +char *progclass = "XLyap"; + +char *defaults [] = { + "XLyap.background: black", /* to placate SGI */ + "*randomize: false", + "*builtin: -1", + "*minColor: 1", + "*maxColor: 256", + "*dwell: 50", + "*useLog: false", + "*colorExponent: 1.0", + "*colorOffset: 0", + "*randomForce: ", /* 0.5 */ + "*settle: 50", + "*minA: 2.0", + "*minB: 2.0", + "*wheels: 7", + "*function: 10101010", + "*forcingFunction: abbabaab", + "*bRange: ", /* 2.0 */ + "*startX: 0.65", + "*mapIndex: ", /* 0 */ + "*outputFile: ", + "*beNegative: false", + "*rgbMax: 65000", + "*spinLength: 256", + "*show: false", + "*aRange: ", /* 2.0 */ + 0 +}; + +XrmOptionDescRec options [] = { + { "-randomize", ".randomize", XrmoptionNoArg, "true" }, + { "-builtin", ".builtin", XrmoptionSepArg, 0 }, + { "-C", ".minColor", XrmoptionSepArg, 0 }, /* n */ + { "-D", ".dwell", XrmoptionSepArg, 0 }, /* n */ + { "-L", ".useLog", XrmoptionNoArg, "true" }, + { "-M", ".colorExponent", XrmoptionSepArg, 0 }, /* r */ + { "-O", ".colorOffset", XrmoptionSepArg, 0 }, /* n */ + { "-R", ".randomForce", XrmoptionSepArg, 0 }, /* p */ + { "-S", ".settle", XrmoptionSepArg, 0 }, /* n */ + { "-a", ".minA", XrmoptionSepArg, 0 }, /* r */ + { "-b", ".minB", XrmoptionSepArg, 0 }, /* n */ + { "-c", ".wheels", XrmoptionSepArg, 0 }, /* n */ + { "-F", ".function", XrmoptionSepArg, 0 }, /* 10101010 */ + { "-f", ".forcingFunction", XrmoptionSepArg, 0 }, /* abbabaab */ + { "-h", ".bRange", XrmoptionSepArg, 0 }, /* r */ + { "-i", ".startX", XrmoptionSepArg, 0 }, /* r */ + { "-m", ".mapIndex", XrmoptionSepArg, 0 }, /* n */ + { "-o", ".outputFile", XrmoptionSepArg, 0 }, /* filename */ + { "-p", ".beNegative", XrmoptionNoArg, "true" }, + { "-r", ".rgbMax", XrmoptionSepArg, 0 }, /* n */ + { "-s", ".spinLength", XrmoptionSepArg, 0 }, /* n */ + { "-v", ".show", XrmoptionNoArg, "true" }, + { "-w", ".aRange", XrmoptionSepArg, 0 }, /* r */ + { 0, 0, 0, 0 } +}; + + +#define ABS(a) (((a)<0) ? (0-(a)) : (a) ) +#define Min(x,y) ((x < y)?x:y) +#define Max(x,y) ((x > y)?x:y) + +#ifdef SIXTEEN_COLORS +#define MAXPOINTS 128 +#define MAXFRAMES 4 +#define MAXCOLOR 16 +static int maxcolor=16, startcolor=0, color_offset=0, mincolindex=1; +static int dwell=50, settle=25; +static int width=128, height=128, xposition=128, yposition=128; +#else +#define MAXPOINTS 256 +#define MAXFRAMES 8 +#define MAXCOLOR 256 +static int maxcolor=256, startcolor=17, color_offset=96, mincolindex=33; +static int dwell=100, settle=50; +static int width=256, height=256; +#endif + +#ifndef TRUE +#define TRUE 1 +#define FALSE 0 +#endif + +static int screen; +static Display* dpy; +static Visual *visual; + +static unsigned long foreground, background; + +static Window canvas; + +typedef struct { + int x, y; +} xy_t; + +typedef struct { + int start_x, start_y; + int last_x, last_y; + } rubber_band_data_t; + +typedef struct { + Cursor band_cursor; + double p_min, p_max, q_min, q_max; + rubber_band_data_t rubber_band; + } image_data_t; + +typedef struct points_t { + XPoint data[MAXCOLOR][MAXPOINTS]; + int npoints[MAXCOLOR]; + } points_t; + +static points_t Points; +static image_data_t rubber_data; + +#ifndef TRUE +#define TRUE 1 +#define FALSE 0 +#endif + +static GC Data_GC[MAXCOLOR], RubberGC; + +#define MAXINDEX 64 +#define FUNCMAXINDEX 16 +#define MAXWHEELS 7 +#define NUMMAPS 5 + +typedef double (*PFD)(double,double); + +static double logistic(double,double), circle(double,double), leftlog(double,double), rightlog(double,double), doublelog(double,double); +static double dlogistic(double,double), dcircle(double,double), dleftlog(double,double), drightlog(double,double), ddoublelog(double,double); +static PFD map, deriv; +static PFD Maps[NUMMAPS] = { logistic, circle, leftlog, rightlog, doublelog }; +static PFD Derivs[NUMMAPS] = { dlogistic, dcircle, dleftlog, drightlog, ddoublelog }; + +static int aflag=0, bflag=0, wflag=0, hflag=0, Rflag=0; +static double pmins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double pmaxs[NUMMAPS] = { 4.0, 1.0, 6.75, 6.75, 16.0 }; +static double amins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double aranges[NUMMAPS] = { 2.0, 1.0, 6.75, 6.75, 16.0 }; +static double bmins[NUMMAPS] = { 2.0, 0.0, 0.0, 0.0, 0.0 }; +static double branges[NUMMAPS] = { 2.0, 1.0, 6.75, 6.75, 16.0 }; + +static int forcing[MAXINDEX] = { 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1, + 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1, + 0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1 }; +static int Forcing[FUNCMAXINDEX] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }; + +static int maxindex = MAXINDEX; +static int funcmaxindex = FUNCMAXINDEX; +static double min_a=2.0, min_b=2.0, a_range=2.0, b_range=2.0, minlyap=1.0; +static double max_a=4.0, max_b=4.0; +static double start_x=0.65, lyapunov, a_inc, b_inc, a, b; +static int numcolors=16, numfreecols, displayplanes, lowrange; +static xy_t point; +static Pixmap pixmap; +static Colormap cmap; +static XColor Colors[MAXCOLOR]; +static double *exponents[MAXFRAMES]; +static double a_minimums[MAXFRAMES], b_minimums[MAXFRAMES]; +static double a_maximums[MAXFRAMES], b_maximums[MAXFRAMES]; +static double minexp, maxexp, prob=0.5; +static int expind[MAXFRAMES]={0}, resized[MAXFRAMES]={0}; +static int numwheels=MAXWHEELS, force=0, Force=0, negative=1; +static int rgb_max=65000, nostart=1, stripe_interval=7; +static int save=1, show=0, useprod=1, spinlength=256, savefile=0; +static int maxframe=0, frame=0, dorecalc=0, mapindex=0, run=1; +static char *outname="lyap.out"; + + +const char * const version = LYAP_VERSION; + +static void resize(void); +static void redisplay(Window w, XExposeEvent *event); +static void Spin(Window w); +static void show_defaults(void); +static void StartRubberBand(Window w, image_data_t *data, XEvent *event); +static void TrackRubberBand(Window w, image_data_t *data, XEvent *event); +static void EndRubberBand(Window w, image_data_t *data, XEvent *event); +static void CreateXorGC(void); +static void InitBuffer(void); +static void BufferPoint(Display *display, Window window, int color, + int x, int y); +static void FlushBuffer(void); +static void init_canvas(void); +static void init_data(void); +static void init_color(void); +static void parseargs(void); +static void Clear(void); +static void setupmem(void); +static void main_event(void); +static int complyap(void); +static void Getkey(XKeyEvent *event); +static int sendpoint(double expo); +static void save_to_file(void); +static void setforcing(void); +static void check_params(int mapnum, int parnum); +static void usage(void); +static void Destroy_frame(void); +static void freemem(void); +static void Redraw(void); +static void redraw(double *exparray, int index, int cont); +static void recalc(void); +static void SetupCorners(XPoint *corners, image_data_t *data); +static void set_new_params(Window w, image_data_t *data); +static void go_down(void); +static void go_back(void); +static void go_init(void); +static void jumpwin(void); +static void print_help(void); +static void print_values(void); + + +void +screenhack (Display *d, Window window) +{ + XWindowAttributes xgwa; + int builtin = -1; + dpy = d; + XGetWindowAttributes (dpy, window, &xgwa); + width = xgwa.width; + height = xgwa.height; + visual = xgwa.visual; + cmap = xgwa.colormap; + + parseargs(); + + if (get_boolean_resource("randomize", "Boolean")) + builtin = random() % 22; + else { + char *s = get_string_resource("builtin", "Integer"); + if (s && *s) + builtin = atoi(s); + if (s) free (s); + } + + if (builtin >= 0) + { + char *ff = 0; + switch (builtin) { + case 0: + min_a = 3.75; aflag++; + min_b = 3.299999; bflag++; + a_range = 0.05; wflag++; + b_range = 0.05; hflag++; + dwell = 200; + settle = 100; + ff = "abaabbaaabbb"; + break; + + case 1: + min_a = 3.8; aflag++; + min_b = 3.2; bflag++; + b_range = .05; hflag++; + a_range = .05; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 2: + min_a = 3.4; aflag++; + min_b = 3.04; bflag++; + a_range = .5; wflag++; + b_range = .5; hflag++; + ff = "abbbbbbbbb"; + settle = 500; + dwell = 1000; + break; + + case 3: + min_a = 3.5; aflag++; + min_b = 3.0; bflag++; + a_range = 0.2; wflag++; + b_range = 0.2; hflag++; + dwell = 600; + settle = 300; + ff = "aaabbbab"; + break; + + case 4: + min_a = 3.55667; aflag++; + min_b = 3.2; bflag++; + b_range = .05; hflag++; + a_range = .05; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 5: + min_a = 3.79; aflag++; + min_b = 3.22; bflag++; + b_range = .02999; hflag++; + a_range = .02999; wflag++; + ff = "bbbbbaaaaa"; + break; + + case 6: + min_a = 3.7999; aflag++; + min_b = 3.299999; bflag++; + a_range = 0.2; wflag++; + b_range = 0.2; hflag++; + dwell = 300; + settle = 150; + ff = "abaabbaaabbb"; + break; + + case 7: + min_a = 3.89; aflag++; + min_b = 3.22; bflag++; + b_range = .028; hflag++; + a_range = .02999; wflag++; + ff = "bbbbbaaaaa"; + settle = 600; + dwell = 1000; + break; + + case 8: + min_a = 3.2; aflag++; + min_b = 3.7; bflag++; + a_range = 0.05; wflag++; + b_range = .005; hflag++; + ff = "abbbbaa"; + break; + + case 9: + ff = "aaaaaabbbbbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 10: + ff = "aaaaaabbbbbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 11: + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 12: + ff = "abbb"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 13: + ff = "abbabaab"; + mapindex = 1; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 14: + ff = "abbabaab"; + dwell = 800; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + /* #### -x 0.05 */ + min_a = 3.91; aflag++; + a_range = 0.0899999999; wflag++; + min_b = 3.28; bflag++; + b_range = 0.35; hflag++; + break; + + case 15: + ff = "aaaaaabbbbbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 16: + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 17: + ff = "abbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 18: + ff = "abbabaab"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 19: + mapindex = 2; + ff = "aaaaaabbbbbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 20: + mapindex = 2; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 21: + mapindex = 2; + ff = "abbb"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + + case 22: + mapindex = 2; + ff = "abbabaab"; + dwell = 400; + settle = 200; + minlyap = maxexp = ABS(-0.85); + minexp = -1.0 * minlyap; + break; + } + + if (ff) { + char *ch; + int bindex = 0; + maxindex = strlen(ff); + if (maxindex > MAXINDEX) + usage(); + ch = ff; + force++; + while (bindex < maxindex) { + if (*ch == 'a') + forcing[bindex++] = 0; + else if (*ch == 'b') + forcing[bindex++] = 1; + else + usage(); + ch++; + } + } + } + + screen = DefaultScreen(dpy); + background = BlackPixel(dpy, screen); + setupmem(); + init_data(); + if (displayplanes > 1) + foreground = startcolor; + else + foreground = WhitePixel(dpy, screen); + + /* + * Create the window to display the Lyapunov exponents + */ + canvas = window; + init_canvas(); + + if (window != DefaultRootWindow(dpy)) + XSelectInput(dpy,canvas,KeyPressMask|ButtonPressMask|ButtonMotionMask| + ButtonReleaseMask|ExposureMask|StructureNotifyMask); + if (displayplanes > 1) { + init_color(); + } else { + XQueryColors(dpy, DefaultColormap(dpy, DefaultScreen(dpy)), + Colors, numcolors); + } + pixmap = XCreatePixmap(dpy, DefaultRootWindow(dpy), + width, height, DefaultDepth(dpy, screen)); + rubber_data.band_cursor = XCreateFontCursor(dpy, XC_hand2); + CreateXorGC(); + Clear(); + for(;;) + main_event(); +} + +static void +main_event(void) +{ + int n; + XEvent event; + + if (complyap() == TRUE) + run=0; + n = XEventsQueued(dpy, QueuedAfterFlush); + while (n--) { + XNextEvent(dpy, &event); + switch(event.type) + { + case KeyPress: + Getkey(&event.xkey); + break; + case Expose: + redisplay(canvas, &event.xexpose); + break; + case ConfigureNotify: + resize(); + break; + case ButtonPress: + StartRubberBand(canvas, &rubber_data, &event); + break; + case MotionNotify: + TrackRubberBand(canvas, &rubber_data, &event); + break; + case ButtonRelease: + EndRubberBand(canvas, &rubber_data, &event); + break; + } + } +} + +/* complyap() is the guts of the program. This is where the Lyapunov exponent + * is calculated. For each iteration (past some large number of iterations) + * calculate the logarithm of the absolute value of the derivative at that + * point. Then average them over some large number of iterations. Some small + * speed up is achieved by utilizing the fact that log(a*b) = log(a) + log(b). + */ +static int +complyap(void) +{ + register i, bindex; + double total, prod, x, r; + + if (!run) + return TRUE; + a += a_inc; + if (a >= max_a) + if (sendpoint(lyapunov) == TRUE) + return FALSE; + else { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } + if (b >= max_b) { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } + prod = 1.0; + total = 0.0; + bindex = 0; + x = start_x; + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + findex = 0; + map = Maps[Forcing[findex]]; +#endif + for (i=0;i= maxindex) { /* some initial "noise" in the */ + bindex = 0; /* iterations. How can we optimize */ + if (Rflag) /* the value of settle ??? */ + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; +#endif + } +#ifdef MAPS + deriv = Derivs[Forcing[findex]]; +#endif + if (useprod) { /* using log(a*b) */ + for (i=0;i 1.0e12) || (prod < 1.0e-12)) { + total += log(prod); + prod = 1.0; + } + if (++bindex >= maxindex) { + bindex = 0; + if (Rflag) + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; + deriv = Derivs[Forcing[findex]]; +#endif + } + total += log(prod); + lyapunov = (total * M_LOG2E) / (double)dwell; + } + else { /* use log(a) + log(b) */ + for (i=0;i= maxindex) { + bindex = 0; + if (Rflag) + setforcing(); + } + r = (forcing[bindex]) ? b : a; +#ifdef MAPS + if (++findex >= funcmaxindex) + findex = 0; + map = Maps[Forcing[findex]]; + deriv = Derivs[Forcing[findex]]; +#endif + } + lyapunov = (total * M_LOG2E) / (double)dwell; + } + if (sendpoint(lyapunov) == TRUE) + return FALSE; + else { + FlushBuffer(); + if (savefile) + save_to_file(); + return TRUE; + } +} + +static double +logistic(double x, double r) /* the familiar logistic map */ +{ + return(r * x * (1.0 - x)); +} + +static double +dlogistic(double x, double r) /* the derivative of logistic map */ +{ + return(r - (2.0 * r * x)); +} + +static double +circle(double x, double r) /* sin() hump or sorta like the circle map */ +{ + return(r * sin(M_PI * x)); +} + +static double +dcircle(double x, double r) /* derivative of the "sin() hump" */ +{ + return(r * M_PI * cos(M_PI * x)); +} + +static double +leftlog(double x, double r) /* left skewed logistic */ +{ + double d; + + d = 1.0 - x; + return(r * x * d * d); +} + +static double +dleftlog(double x, double r) /* derivative of the left skewed logistic */ +{ + return(r * (1.0 - (4.0 * x) + (3.0 * x * x))); +} + +static double +rightlog(double x, double r) /* right skewed logistic */ +{ + return(r * x * x * (1.0 - x)); +} + +static double +drightlog(double x, double r) /* derivative of the right skewed logistic */ +{ + return(r * ((2.0 * x) - (3.0 * x * x))); +} + +static double +doublelog(double x, double r) /* double logistic */ +{ + double d; + + d = 1.0 - x; + return(r * x * x * d * d); +} + +static double +ddoublelog(double x, double r) /* derivative of the double logistic */ +{ + double d; + + d = x * x; + return(r * ((2.0 * x) - (6.0 * d) + (4.0 * x * d))); +} + +static void +init_data(void) +{ + numcolors = XDisplayCells(dpy, XDefaultScreen(dpy)); + displayplanes = DisplayPlanes(dpy, XDefaultScreen(dpy)); + if (numcolors > maxcolor) + numcolors = maxcolor; + numfreecols = numcolors - mincolindex; + lowrange = mincolindex - startcolor; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + a = rubber_data.p_min = min_a; + b = rubber_data.q_min = min_b; + rubber_data.p_max = max_a; + rubber_data.q_max = max_b; + if (show) + show_defaults(); + InitBuffer(); + ya_rand_init(0); +} + +static void +init_canvas(void) +{ + static int i; + + /* + * create default, writable, graphics contexts for the canvas. + */ + for (i=0; i 0-360 */ + (int) ((hue_light_sat[2]/1000.0) * 64435), /* 0-1000 -> 0-65535 */ + (int) ((hue_light_sat[1]/1000.0) * 64435), /* 0-1000 -> 0-65535 */ + &r, &g, &b); + rgb[0] = r; + rgb[1] = g; + rgb[2] = b; +} +#endif /* 0 */ + + +static void +init_color(void) +{ +#if 1 + + int i; + XColor colors[256]; + int ncolors = maxcolor; + Bool writable = False; + make_smooth_colormap(dpy, visual, cmap, + colors, &ncolors, True, &writable, True); + + for (i = 0; i < maxcolor; i++) + XSetForeground(dpy, Data_GC[i], + colors[((int) ((i / ((float)maxcolor)) * ncolors))].pixel); + +#else + static int i, j, colgap, leg, step; + static Visual *visual; + Colormap def_cmap; + int hls[3], rgb[3]; + + def_cmap = DefaultColormap(dpy, DefaultScreen(dpy)); + for (i=0; i FUNCMAXINDEX) + usage(); + ch = optarg; + Force++; + for (findex=0;findex= NUMMAPS) + usage(); + } + } +#endif + if (get_boolean_resource("useLog", "Boolean")) + useprod=0; + + minlyap=ABS(get_float_resource("colorExponent", "Float")); + maxexp=minlyap; + minexp= -1.0 * minlyap; + + color_offset = get_integer_resource("colorOffset", "Integer"); + + maxcolor=ABS(get_integer_resource("maxColor", "Integer")); + if ((maxcolor - startcolor) <= 0) + startcolor = 0; + if ((maxcolor - mincolindex) <= 0) { + mincolindex = 1; + color_offset = 0; + } + + s = get_string_resource("randomForce", "Float"); + if (s && *s) { + prob=atof(s); Rflag++; setforcing(); + } + + settle = get_integer_resource("settle", "Integer"); + + s = get_string_resource("minA", "Float"); + if (s && *s) { + min_a = atof(s); + aflag++; + } + + s = get_string_resource("minB", "Float"); + if (s && *s) { + min_b=atof(s); bflag++; + } + + numwheels = get_integer_resource("wheels", "Integer"); + + s = get_string_resource("forcingFunction", "String"); + if (s && *s) { + maxindex = strlen(s); + if (maxindex > MAXINDEX) + usage(); + ch = s; + force++; + while (bindex < maxindex) { + if (*ch == 'a') + forcing[bindex++] = 0; + else if (*ch == 'b') + forcing[bindex++] = 1; + else + usage(); + ch++; + } + } + + s = get_string_resource("bRange", "Float"); + if (s && *s) { + b_range = atof(s); + hflag++; + } + + start_x = get_float_resource("startX", "Float"); + + s = get_string_resource("mapIndex", "Integer"); + if (s && *s) { + mapindex=atoi(s); + if ((mapindex >= NUMMAPS) || (mapindex < 0)) + usage(); + map = Maps[mapindex]; + deriv = Derivs[mapindex]; + if (!aflag) + min_a = amins[mapindex]; + if (!wflag) + a_range = aranges[mapindex]; + if (!bflag) + min_b = bmins[mapindex]; + if (!hflag) + b_range = branges[mapindex]; + if (!Force) + for (i=0;i pmaxs[mapnum]) || (min_a < pmins[mapnum])) { + fprintf(stderr, "Warning! Parameter 'a' out of range.\n"); + fprintf(stderr, "You have requested a range of (%f,%f).\n", + min_a,max_a); + fprintf(stderr, "Valid range is (%f,%f).\n", + pmins[mapnum],pmaxs[mapnum]); + } + } + if (parnum != 0) { + if ((max_b > pmaxs[mapnum]) || (min_b < pmins[mapnum])) { + fprintf(stderr, "Warning! Parameter 'b' out of range.\n"); + fprintf(stderr, "You have requested a range of (%f,%f).\n", + min_b,max_b); + fprintf(stderr, "Valid range is (%f,%f).\n", + pmins[mapnum],pmaxs[mapnum]); + } + } +} + +static void +usage(void) +{ + fprintf(stderr,"lyap [-BLs][-W#][-H#][-a#][-b#][-w#][-h#][-x xstart]\n"); + fprintf(stderr,"\t[-M#][-S#][-D#][-f string][-r#][-O#][-C#][-c#][-m#]\n"); +#ifdef MAPS + fprintf(stderr,"\t[-F string]\n"); +#endif + fprintf(stderr,"\tWhere: -C# specifies the minimum color index\n"); + fprintf(stderr,"\t -r# specifies the maxzimum rgb value\n"); + fprintf(stderr,"\t -u displays this message\n"); + fprintf(stderr,"\t -a# specifies the minimum horizontal parameter\n"); + fprintf(stderr,"\t -b# specifies the minimum vertical parameter\n"); + fprintf(stderr,"\t -w# specifies the horizontal parameter range\n"); + fprintf(stderr,"\t -h# specifies the vertical parameter range\n"); + fprintf(stderr,"\t -D# specifies the dwell\n"); + fprintf(stderr,"\t -S# specifies the settle\n"); + fprintf(stderr,"\t -H# specifies the initial window height\n"); + fprintf(stderr,"\t -W# specifies the initial window width\n"); + fprintf(stderr,"\t -O# specifies the color offset\n"); + fprintf(stderr,"\t -c# specifies the desired color wheel\n"); + fprintf(stderr,"\t -m# specifies the desired map (0-4)\n"); + fprintf(stderr,"\t -f aabbb specifies a forcing function of 00111\n"); +#ifdef MAPS + fprintf(stderr,"\t -F 00111 specifies the function forcing function\n"); +#endif + fprintf(stderr,"\t -L indicates use log(x)+log(y) rather than log(xy)\n"); + fprintf(stderr,"\tDuring display :\n"); + fprintf(stderr,"\t Use the mouse to zoom in on an area\n"); + fprintf(stderr,"\t e or E recalculates color indices\n"); + fprintf(stderr,"\t f or F saves exponents to a file\n"); + fprintf(stderr,"\t KJmn increase/decrease minimum negative exponent\n"); + fprintf(stderr,"\t r or R redraws\n"); + fprintf(stderr,"\t s or S spins the colorwheel\n"); + fprintf(stderr,"\t w or W changes the color wheel\n"); + fprintf(stderr,"\t x or X clears the window\n"); + fprintf(stderr,"\t q or Q exits\n"); + exit(1); +} + +static void +Cycle_frames(void) +{ + static int i; + for (i=0;i<=maxframe;i++) + redraw(exponents[i], expind[i], 1); +} + +static void +Spin(Window w) +{ + static int i, j; + long tmpxcolor; + + if (displayplanes > 1) { + for (j=0;jmincolindex;i--) + Colors[i].pixel = Colors[i-1].pixel; + Colors[mincolindex].pixel = tmpxcolor; + XStoreColors(dpy, cmap, Colors, numcolors); + } + } +} + +static void +Getkey(XKeyEvent *event) +{ + unsigned char key; + static int i; + if (XLookupString(event, (char *)&key, sizeof(key), (KeySym *)0, + (XComposeStatus *) 0) > 0) + switch (key) { + case '<': dwell /= 2; if (dwell < 1) dwell = 1; break; + case '>': dwell *= 2; break; + case '[': settle /= 2; if (settle < 1) settle = 1; break; + case ']': settle *= 2; break; + case 'd': go_down(); break; + case 'D': FlushBuffer(); break; + case 'e': + case 'E': FlushBuffer(); + dorecalc = (!dorecalc); + if (dorecalc) + recalc(); + else { + maxexp = minlyap; minexp = -1.0 * minlyap; + } + redraw(exponents[frame], expind[frame], 1); + break; + case 'f': + case 'F': save_to_file(); break; + case 'i': if (stripe_interval > 0) { + stripe_interval--; + if (displayplanes > 1) { + init_color(); + } + } + break; + case 'I': stripe_interval++; + if (displayplanes > 1) { + init_color(); + } + break; + case 'K': if (minlyap > 0.05) + minlyap -= 0.05; + break; + case 'J': minlyap += 0.05; + break; + case 'm': mapindex++; + if (mapindex >= NUMMAPS) + mapindex=0; + map = Maps[mapindex]; + deriv = Derivs[mapindex]; + if (!aflag) + min_a = amins[mapindex]; + if (!wflag) + a_range = aranges[mapindex]; + if (!bflag) + min_b = bmins[mapindex]; + if (!hflag) + b_range = branges[mapindex]; + if (!Force) + for (i=0;i 0.005) + minlyap -= 0.005; + break; + case 'N': minlyap += 0.005; + break; + case 'p': + case 'P': negative = (!negative); + FlushBuffer(); redraw(exponents[frame], expind[frame], 1); + break; + case 'r': FlushBuffer(); redraw(exponents[frame], expind[frame], 1); + break; + case 'R': FlushBuffer(); Redraw(); break; + case 's': + spinlength=spinlength/2; + case 'S': if (displayplanes > 1) + Spin(canvas); + spinlength=spinlength*2; break; + case 'u': go_back(); break; + case 'U': go_init(); break; + case 'v': + case 'V': print_values(); break; + case 'W': if (numwheels < MAXWHEELS) + numwheels++; + else + numwheels = 0; + if (displayplanes > 1) { + init_color(); + } + break; + case 'w': if (numwheels > 0) + numwheels--; + else + numwheels = MAXWHEELS; + if (displayplanes > 1) { + init_color(); + } + break; + case 'x': Clear(); break; + case 'X': Destroy_frame(); break; + case 'z': Cycle_frames(); redraw(exponents[frame], expind[frame], 1); + break; + case 'Z': while (!XPending(dpy)) Cycle_frames(); + redraw(exponents[frame], expind[frame], 1); break; + case 'q': + case 'Q': exit(0); break; + case '?': + case 'h': + case 'H': print_help(); break; + default: break; + } +} + +/* Here's where we index into a color map. After the Lyapunov exponent is + * calculated, it is used to determine what color to use for that point. + * I suppose there are a lot of ways to do this. I used the following : + * if it's non-negative then there's a reserved area at the lower range + * of the color map that i index into. The ratio of some "minimum exponent + * value" and the calculated value is used as a ratio of how high to index + * into this reserved range. Usually these colors are dark red (see init_color). + * If the exponent is negative, the same ratio (expo/minlyap) is used to index + * into the remaining portion of the colormap (which is usually some light + * shades of color or a rainbow wheel). The coloring scheme can actually make + * a great deal of difference in the quality of the picture. Different colormaps + * bring out different details of the dynamics while different indexing + * algorithms also greatly effect what details are seen. Play around with this. + */ +static int +sendpoint(double expo) +{ + static int index; + static double tmpexpo; + + point.x++; + tmpexpo = (negative) ? expo : -1.0 * expo; + if (tmpexpo > 0) { + if (displayplanes >1) { + index = (int)(tmpexpo*lowrange/maxexp); + index = (index % lowrange) + startcolor; + } + else + index = 0; + } + else { + if (displayplanes >1) { + index = (int)(tmpexpo*numfreecols/minexp); + index = (index % numfreecols) + mincolindex; + } + else + index = 1; + } + BufferPoint(dpy, canvas, index, point.x, point.y); + if (save) + exponents[frame][expind[frame]++] = expo; + if (point.x >= width) { + point.y++; + point.x = 0; + if (save) { + b += b_inc; + a = min_a; + } + if (point.y >= height) + return FALSE; + else + return TRUE; + } + return TRUE; +} + +static void +redisplay (Window w, XExposeEvent *event) +{ + /* + * Extract the exposed area from the event and copy + * from the saved pixmap to the window. + */ + XCopyArea(dpy, pixmap, canvas, Data_GC[0], + event->x, event->y, event->width, event->height, + event->x, event->y); +} + +static void +resize(void) +{ + Window r; + int n, x, y; + unsigned int bw, d, new_w, new_h; + + XGetGeometry(dpy,canvas,&r,&x,&y,&new_w,&new_h,&bw,&d); + if ((new_w == width) && (new_h == height)) + return; + width = new_w; height = new_h; + XClearWindow(dpy, canvas); + if (pixmap) + XFreePixmap(dpy, pixmap); + pixmap = XCreatePixmap(dpy, DefaultRootWindow(dpy), + width, height, DefaultDepth(dpy, screen)); + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + run = 1; + a = rubber_data.p_min = min_a; + b = rubber_data.q_min = min_b; + rubber_data.p_max = max_a; + rubber_data.q_max = max_b; + freemem(); + setupmem(); + for (n=0;n 1) { + for (i=0;i> 8); + colormap[i].green=(unsigned char)(Colors[i].green >> 8); + colormap[i].blue =(unsigned char)(Colors[i].blue >> 8); + } + fprintf(outfile,"P%d %d %d\n",6,width,height); + } + else + fprintf(outfile,"P%d %d %d\n",5,width,height); + fprintf(outfile,"# settle=%d dwell=%d start_x=%f\n",settle,dwell, + start_x); + fprintf(outfile,"# min_a=%f a_rng=%f max_a=%f\n",min_a,a_range,max_a); + fprintf(outfile,"# min_b=%f b_rng=%f max_b=%f\n",min_b,b_range,max_b); + if (Rflag) + fprintf(outfile,"# pseudo-random forcing\n"); + else if (force) { + fprintf(outfile,"# periodic forcing="); + for (i=0;i 1) + fwrite((char *)&colormap[c],sizeof colormap[0],1,outfile); + else + fwrite((char *)&c,sizeof c,1,outfile); + } + fclose(outfile); +} + +static void +recalc(void) +{ + static int i, x, y; + + minexp = maxexp = 0.0; + x = y = 0; + for (i=0;i maxexp) + maxexp = exponents[frame][i]; + } +} + +static void +Clear(void) +{ + XClearWindow(dpy, canvas); + XCopyArea(dpy, canvas, pixmap, Data_GC[0], + 0, 0, width, height, 0, 0); + InitBuffer(); +} + +static void +show_defaults(void) +{ + + printf("Width=%d Height=%d numcolors=%d settle=%d dwell=%d\n", + width,height,numcolors,settle,dwell); + printf("min_a=%f a_range=%f max_a=%f\n", min_a,a_range,max_a); + printf("min_b=%f b_range=%f max_b=%f\n", min_b,b_range,max_b); + printf("minlyap=%f minexp=%f maxexp=%f\n", minlyap,minexp,maxexp); + exit(0); +} + +static void +CreateXorGC(void) +{ + XGCValues values; + + values.foreground = foreground; + values.line_style = LineSolid; + values.function = GXxor; + RubberGC = XCreateGC(dpy, DefaultRootWindow(dpy), + GCForeground | GCBackground | GCFunction | GCLineStyle, &values); +} + +static void +StartRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + + nostart = 0; + data->rubber_band.last_x = data->rubber_band.start_x = event->xbutton.x; + data->rubber_band.last_y = data->rubber_band.start_y = event->xbutton.y; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); +} + +static void +SetupCorners(XPoint *corners, image_data_t *data) +{ + corners[0].x = data->rubber_band.start_x; + corners[0].y = data->rubber_band.start_y; + corners[1].x = data->rubber_band.start_x; + corners[1].y = data->rubber_band.last_y; + corners[2].x = data->rubber_band.last_x; + corners[2].y = data->rubber_band.last_y; + corners[3].x = data->rubber_band.last_x; + corners[3].y = data->rubber_band.start_y; + corners[4] = corners[0]; +} + +static void +TrackRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + int xdiff, ydiff; + + if (nostart) + return; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); + ydiff = event->xbutton.y - data->rubber_band.start_y; + xdiff = event->xbutton.x - data->rubber_band.start_x; + data->rubber_band.last_x = data->rubber_band.start_x + xdiff; + data->rubber_band.last_y = data->rubber_band.start_y + ydiff; + if (data->rubber_band.last_y < data->rubber_band.start_y || + data->rubber_band.last_x < data->rubber_band.start_x) + { + data->rubber_band.last_y = data->rubber_band.start_y; + data->rubber_band.last_x = data->rubber_band.start_x; + } + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); +} + +static void +EndRubberBand(Window w, image_data_t *data, XEvent *event) +{ + XPoint corners[5]; + XPoint top, bot; + double delta, diff; + + nostart = 1; + SetupCorners(corners, data); + XDrawLines(dpy, canvas, RubberGC, + corners, sizeof(corners) / sizeof(corners[0]), CoordModeOrigin); + if (data->rubber_band.start_x >= data->rubber_band.last_x || + data->rubber_band.start_y >= data->rubber_band.last_y) + return; + top.x = data->rubber_band.start_x; + bot.x = data->rubber_band.last_x; + top.y = data->rubber_band.start_y; + bot.y = data->rubber_band.last_y; + diff = data->q_max - data->q_min; + delta = (double)top.y / (double)height; + data->q_min += diff * delta; + delta = (double)(height - bot.y) / (double)height; + data->q_max -= diff * delta; + diff = data->p_max - data->p_min; + delta = (double)top.x / (double)width; + data->p_min += diff * delta; + delta = (double)(width - bot.x) / (double)width; + data->p_max -= diff * delta; + fflush(stdout); + set_new_params(w, data); +} + +static void +set_new_params(Window w, image_data_t *data) +{ + frame = (maxframe + 1) % MAXFRAMES; + if (frame > maxframe) + maxframe = frame; + a_range = data->p_max - data->p_min; + b_range = data->q_max - data->q_min; + a_minimums[frame] = min_a = data->p_min; + b_minimums[frame] = min_b = data->q_min; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + run = 1; + a = min_a; + b = min_b; + a_maximums[frame] = max_a = data->p_max; + b_maximums[frame] = max_b = data->q_max; + expind[frame] = 0;; + Clear(); +} + +static void +go_down(void) +{ + frame++; + if (frame > maxframe) + frame = 0; + jumpwin(); +} + +static void +go_back(void) +{ + frame--; + if (frame < 0) + frame = maxframe; + jumpwin(); +} + +static void +jumpwin(void) +{ + rubber_data.p_min = min_a = a_minimums[frame]; + rubber_data.q_min = min_b = b_minimums[frame]; + rubber_data.p_max = max_a = a_maximums[frame]; + rubber_data.q_max = max_b = b_maximums[frame]; + a_range = max_a - min_a; + b_range = max_b - min_b; + a_inc = a_range / (double)width; + b_inc = b_range / (double)height; + point.x = -1; + point.y = 0; + a = min_a; + b = min_b; + Clear(); + if (resized[frame]) + Redraw(); + else + redraw(exponents[frame], expind[frame], 0); +} + +static void +go_init(void) +{ + frame = 0; + jumpwin(); +} + +static void +Destroy_frame(void) +{ + static int i; + + for (i=frame; i doubles the 'dwell'\n"); + printf("[ halves the 'settle', ] doubles the 'settle'\n"); + printf("D flushes the drawing buffer\n"); + printf("e or E recalculates color indices\n"); + printf("f or F saves exponents to a file\n"); + printf("h or H or ? displays this message\n"); + printf("i decrements, I increments the stripe interval\n"); + printf("KJMN increase/decrease minimum negative exponent\n"); + printf("m increments the map index, changing maps\n"); + printf("p or P reverses the colormap for negative/positive exponents\n"); + printf("r redraws without recalculating\n"); + printf("R redraws, recalculating with new dwell and settle values\n"); + printf("s or S spins the colorwheel\n"); + printf("u pops back up to the last zoom\n"); + printf("U pops back up to the first picture\n"); + printf("v or V displays the values of various settings\n"); + printf("w decrements, W increments the color wheel index\n"); + printf("x or X clears the window\n"); + printf("q or Q exits\n"); +} + +static void +print_values(void) +{ + static int i; + + printf("\nminlyap=%f minexp=%f maxexp=%f\n",minlyap,minexp,maxexp); + printf("width=%d height=%d\n",width,height); + printf("settle=%d dwell=%d start_x=%f\n",settle,dwell, start_x); + printf("min_a=%f a_rng=%f max_a=%f\n",min_a,a_range,max_a); + printf("min_b=%f b_rng=%f max_b=%f\n",min_b,b_range,max_b); + if (Rflag) + printf("pseudo-random forcing\n"); + else if (force) { + printf("periodic forcing="); + for (i=0;i prob) ? 0 : 1; +} diff --git a/hacks/xlyap.man b/hacks/xlyap.man new file mode 100644 index 00000000..6f69cade --- /dev/null +++ b/hacks/xlyap.man @@ -0,0 +1,237 @@ +.TH XLYAP 6X +.SH NAME +xlyap \- display an array of Lyapunov exponents graphically +.SH SYNOPSIS +.in +8n +.ti -8n +\fIxlyap\fR +[-BLps][-W width][-H height][-o filename][-a +\fIn\fR ] +[-b +\fIn\fR ] +[-w +\fIn\fR ] +[-h +\fIn\fR ] +[-i xstart] +[-M +\fIn\fR ] +[-R +\fIp\fR ] +[-S +\fIn\fR ] +[-D +\fIn\fR ] +[-F string][-f string][-r +\fIn\fR ] +[-O +\fIn\fR ] +[-C +\fIn\fR ] +[-c +\fIn\fR ] +[-m +\fIn\fR ] +[-x xpos] +[-y ypos] +.in -8n +.SH DESCRIPTION +\fIxlyap\fR +generates and graphically displays an array of Lyapunov exponents for a +variety of iterated periodically forced non-linear maps of the unit interval. +.SH OPTIONS +.TP 8 +-random +A good choice for use with xscreensaver: picks random parameters from +a built-in list. +.TP 8 +-C \fIn\fP +Specifies the minimum color index to be used for negative exponents +.TP +-D \fIn\fP +Specifies the "dwell" or number of iterations over which to average in order +to calculate the Lyapunov exponent. Default is 400. +.TP +-B +Causes the stop, go, spin and quit buttons to be displayed. +.TP +-H \fIn\fP +Specifies the height of the window. Default is 256. +.TP +-L +Indicates use log(x) + log(y) rather than log(xy). +.TP +-M \fIr\fP +Specifies the real value to compare exponent values to for indexing into +a color wheel. The default value is 1.0. +.TP +-O \fIn\fP +Specifies the minimum color index to be used for positive exponents +.TP +-R \fIp\fP +Specifies pseudo-random forcing with probability \fIp\fP of using parameter +value 'a'. +.TP +-S \fIn\fP +Specifies the "settle" or number of iterations prior to the beginning of +the calculation of the Lyapunov exponent. Default is 200. +.TP +-W \fIn\fP +Specifies the width of the window. Default is 256. +.TP +-a \fIr\fP +Specifies the real value to use as the minimum parameter value of the +horizontal axis. Default is 3.0 for the logistic map. +.TP +-b \fIn\fP +Specifies the real value to use as the minimum parameter value of the +vertical axis. Default is 3.0 for the logistic map. +.TP +-c \fIn\fP +Selects one of six different color wheels to use. The default color +wheel is a rainbow palette. +.TP +-F \fI10101010\fP +Specifies the "Function" forcing function to use. The example above would +alternate between iterating the circle and logistic maps. An argument of +"-F 2323" would alternate between left and right logistic maps. The default +is to only use the single specified map (see the description of -m). +.TP +-f \fIabbabaab\fP +Specifies the forcing function to use. The default is to alternate between +the "a" parameter and the "b" parameter. +.TP +-h \fIr\fP +Specifies the real value to be used as the range over which the vertical +parameter values vary. The default is 1.0. +.TP +-i \fIr\fP +Specifies the real value of the initial condition to use. Default is 0.05. +.TP +-m \fIn\fP +Selects between available non-linear maps of the unit interval. A value of +0 specifies the logistic map. A value of 1, the circle map. A value of 2, +the left-logistic. A value of 3, the right-logistic. A value of 4, the +double-logistic. The default is 0, the logistic map. +.TP +-o \fIfilename\fP +Specifies the output filename to be used. If the -o option is given, this +file will automatically be written out at the completion of the drawing. +If it is not specified, a default filename of lyap.out is used and only +written if the 'f' or 'F' keys are pressed during a run. The format of the +output file is PPM for color and PGM for monochrom. The parameters used to +calculate the picture are included as comments at the beginning of the output +file. +.TP +-p +Switches color indices for negative and positive exponents. Generally, +causes negative exponents to be displayed in more detail while darkening +and narrowing the color range for positive exponents. This can be toggled +during runtime by pressing the 'p' key. +.TP +-r \fIn\fP +Specifies the maximum rgb value to be used. Default is 35000. +.TP +-s \fIn\fP +Specifies the length of the color wheel spin. +.TP +-u +Produces a usage message. +.TP +-v +Prints out the various values to be used and exits. +.TP +-w \fIr\fP +Specifies the real value to be used as the range over which the horizontal +parameter values vary. The default is 1.0. +.TP +-x \fIn\fP +Specifies the x screen coordinate of the window (default is 256). +.TP +-y \fIn\fP +Specifies the y screen coordinate of the window (default is 256). +.sp 2 +.SH NOTES +.sp +During display, pressing any mouse button allows you to select the area to +be investigated with the mouse. The upper left hand corner of the desired +area is the location of the cursor when the button is pressed. The lower +right hand corner is specified by the cursor when the button is released. +.sp 2 +Use of the keys +\fIbBeEfFkKjJmnrRsSwWxXqQ\fP +indicates: +.sp +.ti 10 +(<) Halve dwell value. +.ti 10 +(>) Double dwell value. +.ti 10 +([) Halve settle value. +.ti 10 +(]) Double settle value. +.ti 10 +(B or b) Toggle button display on/off +.ti 10 +(E or e) Recalculate the indices into the color wheel using a different method +.ti 10 +(F or f) Save current screen to ouput file (not yet implemented) +.ti 10 +(H or h or ?) Display brief help message +.ti 10 +(i) Decrement the interval between stripes for the striped color map. +.ti 10 +(I) Increment the interval between stripes for the striped color map. +.ti 10 +(K) Decrease value exponents are compared against by 0.05. +.ti 10 +(J) Increase value exponents are compared against by 0.05. +.ti 10 +(M) Decrease value exponents are compared against by 0.005. +.ti 10 +(N) Increase value exponents are compared against by 0.005. +.ti 10 +(m) Increment the map index, changing the map to be iterated. +.ti 10 +(P or p) Toggle positive/negative exponent display. +.ti 10 +(r) Redraw the window using previously calculated exponents. +.ti 10 +(R) Redraw the window using the newly set dwell and/or settle values. +.ti 10 +(S) Spin the color wheel +.ti 10 +(s) Halve the length of the spin and spin the color wheel +.ti 10 +(u) Go up to the window just prior to the most recent zoom. +.ti 10 +(U) Go all the way up to the original window. +.ti 10 +(V or v) Display values of various parameters currently in use +.ti 10 +(W or w) Use next color map. +.ti 10 +(X or x) Clear window +.ti 10 +(Q or q) quit +.sp 2 +.SH AUTHOR +.nf + Ronald Joe Record + The Santa Cruz Operation + P.O. Box 1900 + Santa Cruz, CA 95061 + rr@sco.com +.fi +.sp 2 +.SH ACKNOWLEDGEMENTS +.PP +The algorithm was taken from the September 1991 Scientific American article +by A. K. Dewdney who gives credit to Mario Markus of the Max Planck Institute +for its creation. Additional information and ideas were gleaned from the +discussion on alt.fractals involving Stephen Hall, Ed Kubaitis, Dave Platt +and Baback Moghaddam. Assistance with colormaps and spinning color wheels +and X was gleaned from Hiram Clawson. Rubber banding code was adapted from +an existing Mandelbrot program written by Stacey Campbell. + +Viciously hacked for xscreensaver by Jamie Zawinski, 20-Nov-97. diff --git a/hacks/xroger-hack.c b/hacks/xroger-hack.c new file mode 100644 index 00000000..d8db872c --- /dev/null +++ b/hacks/xroger-hack.c @@ -0,0 +1,102 @@ +/* xscreensaver, Copyright (c) 1991-1994 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. + */ + +#include "screenhack.h" + +char *progclass = "XRoger"; + +char *defaults [] = { + "XRoger.background: black", + "XRoger.foreground: red", + "*delay: 5", + 0 +}; + +XrmOptionDescRec options [] = { + { "-delay", ".delay", XrmoptionSepArg, 0 }, + { 0, 0, 0, 0 } +}; + +extern void skull (Display *, Window, GC, GC, int, int, int, int); + +void +screenhack (dpy, window) + Display *dpy; + Window window; +{ + double delta = 0.005; + XGCValues gcv; + Colormap cmap; + GC draw_gc, erase_gc; + unsigned int fg; + XColor color, color2, color3; + int delay = get_integer_resource ("delay", "Integer"); + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + cmap = xgwa.colormap; + gcv.foreground = get_pixel_resource ("background", "Background", dpy, cmap); + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + fg = get_pixel_resource ("foreground", "Foreground", dpy, cmap); + if (fg == gcv.foreground) + fg = ((gcv.foreground == WhitePixel (dpy, DefaultScreen (dpy))) + ? BlackPixel (dpy, DefaultScreen (dpy)) + : WhitePixel (dpy, DefaultScreen (dpy))); + gcv.foreground = fg; + draw_gc = XCreateGC (dpy, window, GCForeground, &gcv); + color.pixel = gcv.foreground; + XQueryColor (dpy, cmap, &color); + while (1) + { + int w, h, ww, hh, x, y; + time_t start_time; + XGetWindowAttributes (dpy, window, &xgwa); + w = xgwa.width; + h = xgwa.height; + + ww = 100 + random () % (w - 100); + hh = 100 + random () % (h - 100); + if (ww < 10) ww = 50; + if (hh < 10) hh = 50; + if (ww < hh) hh = ww; + else ww = hh; + x = random () % (w - ww); + y = random () % (h - hh); + XClearWindow (dpy, window); + + + skull (dpy, window, draw_gc, erase_gc, x, y, ww, hh); + XSync (dpy, True); + start_time = time ((time_t *) 0); + if (mono_p) + sleep (delay); + else + while (start_time + delay > time ((time_t *) 0)) + { + int H; + double S, V; + color2 = color; + rgb_to_hsv (color2.red, color2.green, color2.blue, &H, &S, &V); + V += delta; + if (V >= 1.0) V = 1.0, delta = -delta; + if (V <= 0.6) V = 0.7, delta = -delta; + hsv_to_rgb (H, S, V, &color2.red, &color2.green, &color2.blue); + color3 = color2; + if (XAllocColor (dpy, cmap, &color3)) + { + XSetForeground (dpy, draw_gc, color3.pixel); + color2.pixel = color3.pixel; + XFreeColors (dpy, cmap, &color.pixel, 1, 0); + } + color = color2; + usleep (20000); + } + } +} diff --git a/hacks/xroger.man b/hacks/xroger.man new file mode 100644 index 00000000..799f5005 --- /dev/null +++ b/hacks/xroger.man @@ -0,0 +1,52 @@ +.TH XScreenSaver 1 "22-mar-93" "X Version 11" +.SH NAME +xroger - throbbing X logo, of a sort +.SH SYNOPSIS +.B xroger +[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] +.SH DESCRIPTION +The \fIxroger\fP program displays a replacement for the X logo with a more +accurate Look and Feel. +.SH OPTIONS +.I xroger +accepts the following options: +.TP 8 +.B \-window +Draw on a newly-created window. This is the default. +.TP 8 +.B \-root +Draw on the root window. +.TP 8 +.B \-mono +If on a color display, pretend we're on a monochrome display. +.TP 8 +.B \-install +Install a private colormap for the window. +.TP 8 +.B \-visual \fIvisual\fP +Specify which visual to use. Legal values are the name of a visual class, +or the id number (decimal or hex) of a specific visual. +.SH ENVIRONMENT +.PP +.TP 8 +.B DISPLAY +to get the default host and display number. +.TP 8 +.B XENVIRONMENT +to get the name of a resource file that overrides the global resources +stored in the RESOURCE_MANAGER property. +.SH BUGS +It should also drip blood while making a horrible screeching noise. +.SH SEE ALSO +.BR X (1), +.BR xscreensaver (1) +.SH COPYRIGHT +Copyright \(co 1992, 1993 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 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 fnord implied warranty. +.SH AUTHOR +Jamie Zawinski , 13-aug-92. diff --git a/hacks/xscreensaver-sgigl.c b/hacks/xscreensaver-sgigl.c new file mode 100644 index 00000000..fd03d1b6 --- /dev/null +++ b/hacks/xscreensaver-sgigl.c @@ -0,0 +1,256 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +/* This is a kludge that lets xscreensaver work with SGI demos that expect + to be run from `haven'. It runs the program given on the command line, + then waits for an X window to be created whose name is that of the + program. Then, it resizes that window to fill the screen. Run it + like this: + + xscreensaver-sgigl /usr/demos/bin/ep -S + xscreensaver-sgigl -n ant /usr/demos/General_Demos/ant/RUN + xscreensaver-sgigl -n atlantis /usr/demos/General_Demos/atlantis/RUN + xscreensaver-sgigl -n /usr/demos/General_Demos/powerflip/powerflip \ + /usr/demos/General_Demos/powerflip/RUN + + Except that doesn't really work. You have to do this instead: + + xscreensaver-sgigl -n ant ant.sh + + where ant.sh contains + + #!/bin/sh + cd /usr/demos/General_Demos/ant + exec ./ant -S + + There's no way to make this work with powerflip at all, since it doesn't + take a -S option to run in the foreground. + */ + +/* #### Another way to do this would be: + instead of exec'ing the hack, fork it; then wait for that fork to die. + If it dies, but the window ID is still valid, then that means the + sub-process has forked itself (as those fuckwits at SGI are wont to do.) + In that case, this process should go to sleep, and set up a signal handler + that will destroy the X window when it is killed. That way, the caller + is given a foreground pid which, when killed, will cause the hack to die + (by a roundabout mechanism.) + + This would all be so much simpler if those assholes would just: + + 1: get out of the habit of writing programs that magically background + themselves, and + + 2: give the fucking programs arguments which control the window size + instead of always making 100x100 windows! + + I won't even dream of having a "-root" option that understood virtual-roots; + that would just be too outlandish to even dream about. + */ + +static char *progname; + +#include +#include +#include +#include +#include +#include +#include + +#include "vroot.h" +#undef RootWindowOfScreen +#undef RootWindow +#undef DefaultRootWindow + + +static int +BadWindow_ehandler (Display *dpy, XErrorEvent *error) +{ + if (error->error_code == BadWindow || + error->error_code == BadMatch || + error->error_code == BadDrawable) + return 0; + else + { + fprintf (stderr, "\nX error in %s:\n", progname); + if (XmuPrintDefaultErrorMessage (dpy, error, stderr)) + exit(1); + else + fprintf (stderr, " (nonfatal.)\n"); + } + return 0; +} + + +void +main(int ac, char **av) +{ + char buf [512]; + pid_t parent, forked; + Display *dpy; + Screen *screen; + char *s; + char *n1 = 0; + char *n2 = 0; + Bool verbose = False; + Window root, vroot; + + progname = av[0]; + + s = strrchr(progname, '/'); + if (s) progname = s+1; + + if (ac < 1) + { + fprintf(stderr, + "usage: %s [ -v ] [ -n window-name ] program arguments...\n", + progname); + exit(1); + } + + if (ac > 2 && !strcmp(av[1], "-v")) + { + verbose = True; + av++; + ac--; + } + + if (ac > 2 && !strcmp(av[1], "-n")) + { + n2 = av[2]; + av += 2; + ac -= 2; + } + + n1 = strrchr(av[1], '/'); + if (n1) n1++; + else n1 = av[1]; + + + dpy = XOpenDisplay(0); + if (!dpy) + { + fprintf(stderr, "%s: couldn't open display\n", progname); + exit(1); + } + + screen = DefaultScreenOfDisplay(dpy); + root = XRootWindowOfScreen (screen); + vroot = VirtualRootWindowOfScreen (screen); + + XSelectInput (dpy, root, SubstructureNotifyMask); + if (root != vroot) + XSelectInput (dpy, vroot, SubstructureNotifyMask); + + XSetErrorHandler (BadWindow_ehandler); + + if (verbose) + fprintf(stderr, "%s: selected SubstructureNotifyMask on 0x%x / 0x%x\n", + progname, root, vroot); + + parent = getpid(); + + if (verbose) + fprintf(stderr, "%s: pid is %d\n", progname, parent); + + switch ((int) (forked = fork ())) + { + case -1: + { + sprintf (buf, "%s: couldn't fork", progname); + perror (buf); + exit (1); + break; + } + case 0: /* forked */ + { + time_t start = time((time_t) 0); + XEvent event; + + if (verbose) + fprintf(stderr, "%s: forked pid is %d\n", progname, getpid()); + + while (1) + { + XNextEvent(dpy, &event); + + if (event.xany.type == CreateNotify) + { + char *name = 0; + Window w = event.xcreatewindow.window; + XSync(dpy, False); + + XFetchName(dpy, w, &name); + if (!name) + { + /* Try again to see if the name has been set later... */ + XSync(dpy, False); + sleep(1); + XFetchName(dpy, w, &name); + } + + if (name && + ((n1 && !strcmp(name, n1)) || + (n2 && !strcmp(name, n2)))) + { + if (verbose) + fprintf(stderr, "%s: resizing 0x%x\n", progname, w); + + XMoveResizeWindow(dpy, w, 0, 0, + WidthOfScreen(screen), + HeightOfScreen(screen)); + +#if 0 + if (vroot && vroot != root && + event.xcreatewindow.parent == root) + { + if (verbose) + fprintf(stderr, + "%s: reparenting 0x%x from 0x%x to 0x%x\n", + progname, w, root, vroot); + XReparentWindow(dpy, w, vroot, 0, 0); + } +#endif + + XSync(dpy, False); + fflush(stdout); + fflush(stderr); + exit(0); /* Note that this only exits a child fork. */ + } + } + + if (start + 5 < time((time_t) 0)) + { + fprintf(stderr, + "%s: timed out: no window named \"%s\" has been created\n", + progname, (n2 ? n2 : n1)); + fflush(stdout); + fflush(stderr); + kill(parent, SIGTERM); + exit(1); + } + } + break; + } + default: /* foreground */ + { + close (ConnectionNumber (dpy)); /* close display fd */ + execvp (av[1], av+1); /* shouldn't return. */ + sprintf (buf, "%s: execvp(\"%s\") failed", progname, av[1]); + perror (buf); + fflush(stderr); + fflush(stdout); + exit (1); + break; + } + } +} diff --git a/install-sh b/install-sh new file mode 100755 index 00000000..ebc66913 --- /dev/null +++ b/install-sh @@ -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/makevms.com b/makevms.com new file mode 100644 index 00000000..213cc0ca --- /dev/null +++ b/makevms.com @@ -0,0 +1,57 @@ +$! Build Xscreensaver under OpenVMS V 6.x system with DEC C 5.x compiler +$! +$ copy /log CONFIG.H-VMS CONFIG.H +$! +$! Architecture type test (VAX < 1024 <= Alpha AXP) +$! +$ if f$getsyi("HW_MODEL").ge.1024 +$ then +$! +$! Alpha AXP +$! build Utils library +$! +$ set def [.UTILS] +$ @COMPILE_AXP +$ set def [-] +$! +$! build graphics hacks +$! +$ set def [.HACKS] +$ @COMPILE_AXP +$ @LINK_AXP +$ set def [-] +$! +$! Build Xscreensaver & Xscreensaver-command +$! +$ set def [.DRIVER] +$ @COMPILE_AXP +$ @LINK_AXP +$ set def [-] +$ else +$! +$! Good old VAX +$! build Utils library +$! +$ set def [.UTILS] +$ @COMPILE_DECC +$ set def [-] +$! +$! build graphics hacks +$! +$ set def [.HACKS] +$ @COMPILE_DECC +$ @LINK_DECC +$ set def [-] +$! +$! Build Xscreensaver & Xscreensaver-command +$! +$ set def [.DRIVER] +$ @COMPILE_DECC +$ @LINK_DECC +$ set def [-] +$ endif +$! +$! DCL symbols definition +$! +$ @SETUP +$ exit diff --git a/screenblank.txt b/screenblank.txt new file mode 100644 index 00000000..17621585 --- /dev/null +++ b/screenblank.txt @@ -0,0 +1,46 @@ +From mrapple@quack.kfu.com Mon Apr 26 18:31:07 1993 +Newsgroups: alt.hackers +From: mrapple@quack.kfu.com (Nick Sayer) +Subject: screenblank and xautolock living in harmony +Organization: The Duck Pond public unix: +1 408 249 9630, log in as 'guest'. +Date: 23 Apr 1993 19:26:57 UTC + + +I have a Sun and use xinit to start X. This presented a problem. +If I use xautolock or xscreensaver to save the screen, then after +a period of inactivity screenblank would turn the video off despite +'xset s off'. If I didn't run screenblank, then who would take care of +the display when X wasn't running? + +The hack that saved the day was to include this in .xinitrc: + +( + +while true ; do +sleep 360 +touch /dev/console +done + +) & +killblank=$! + +[start up all the clients, etc, etc. Wait for the window manager +to die, then ] + +kill $killblank + +The result is that screenblank is kept safely out of the way when X +is running and left to do its job otherwise. + +Yes, I know using XDM would solve this problem. + +No, I'm probably not the first to think of this. + +You're welcome. + +-- +Nick Sayer | "Dear Sexy Nickers. I don't half fancy +N6QQQ @ N0ARY.#NOCAL.CA.USA.NOAM | you. Meet me at the lift at 5:30 and ++1 408 249 9630, log in as 'guest' | we'll get it together." +PGP 2.2 public key via finger | -- Mr. Lucas + diff --git a/setup.com b/setup.com new file mode 100644 index 00000000..2f4c977e --- /dev/null +++ b/setup.com @@ -0,0 +1,72 @@ +$! Xscreensaver - definition of various DCL symbols +$ set NOON +$ set def [.HACKS] +$ mydisk = f$trnlmn("SYS$DISK") +$ mydir = mydisk+f$directory() +$ ant :== $'mydir'ant +$ attraction :== $'mydir'attraction +$ blitspin :== $'mydir'blitspin +$ bouboule :== $'mydir'bouboule +$ braid :== $'mydir'braid +$ bubbles :== $'mydir'bubbles +$ coral :== $'mydir'coral +$ cynosure :== $'mydir'cynosure +$ decayscreen :== $'mydir'decayscreen +$ deco :== $'mydir'deco +$ drift :== $'mydir'drift +$ fadeplot :== $'mydir'fadeplot +$ flag :== $'mydir'flag +$ flame :== $'mydir'flame +$ forest :== $'mydir'forest +$ galaxy :== $'mydir'galaxy +$ goop :== $'mydir'goop +$ grav :== $'mydir'grav +$ greynetic :== $'mydir'greynetic +$ halo :== $'mydir'halo +$ helix :== $'mydir'helix +$ hopalong :== $'mydir'hopalong +$ hypercube :== $'mydir'hypercube +$ ifs :== $'mydir'ifs +$ imsmap :== $'mydir'imsmap +$ julia :== $'mydir'julia +$ kaleidescope :== $'mydir'kaleidescope +$ laser :== $'mydir'laser +$ lightning :== $'mydir'lightning +$ lisa :== $'mydir'lisa +$ lissie :== $'mydir'lissie +$ lmorph :== $'mydir'lmorph +$ maze :== $'mydir'maze +$ moire :== $'mydir'moire +$ moire2 :== $'mydir'moire2 +$ mountain :== $'mydir'mountain +$ munch :== $'mydir'munch +$ noseguy :== $'mydir'noseguy +$ pedal :== $'mydir'pedal +$ penrose :== $'mydir'penrose +$ puzzle :== $'mydir'puzzle +$ pyro :== $'mydir'pyro +$ qix :== $'mydir'qix +$ rd-bomb :== $'mydir'rd-bomb +$ rocks :== $'mydir'rocks +$ rorschach :== $'mydir'rorschach +$ rotor :== $'mydir'rotor +$ sierpinski :== $'mydir'sierpinski +$ slidescreen :== $'mydir'slidescreen +$ slip :== $'mydir'slip +$ sphere :== $'mydir'sphere +$ spiral :== $'mydir'spiral +$ starfish :== $'mydir'starfish +$ strange :== $'mydir'strange +$ swirl :== $'mydir'swirl +$ triangle :== $'mydir'triangle +$ vines :== $'mydir'vines +$ worm :== $'mydir'worm +$ xjack :== $'mydir'xjack +$ xlyap :== $'mydir'xlyap +$ xroger :== $'mydir'xroger +$ set def [-.DRIVER] +$ mydir = mydisk+f$directory() +$ xscreensaver :== $'mydir'xscreensaver +$ xscreen*command :== $'mydir'xscreensaver-command +$ set def [-] +$ exit diff --git a/utils/Makefile.in b/utils/Makefile.in new file mode 100644 index 00000000..663ba2c9 --- /dev/null +++ b/utils/Makefile.in @@ -0,0 +1,190 @@ +# utils/Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski. +# the `../configure' script generates `utils/Makefile' from this file. + +@SET_MAKE@ +.SUFFIXES: +.SUFFIXES: .c .o + +srcdir = @srcdir@ +VPATH = @srcdir@ +prefix = @prefix@ + +CC = @CC@ +CFLAGS = @CFLAGS@ +DEFS = @DEFS@ + +DEPEND = @DEPEND@ +DEPEND_FLAGS = @DEPEND_FLAGS@ +DEPEND_DEFINES = @DEPEND_DEFINES@ + +SHELL = /bin/sh + +X_CFLAGS = @X_CFLAGS@ + +INCLUDES = -I$(srcdir) -I$(srcdir)/.. -I.. @INCLUDES@ + +SRCS = alpha.c colors.c fade.c grabscreen.c hsv.c overlay.c \ + resources.c spline.c usleep.c visual.c xmu.c xroger.c \ + yarandom.c erase.c sgivideo.c +OBJS = alpha.o colors.o fade.o grabscreen.o hsv.o overlay.o \ + resources.o spline.o usleep.o visual.o xmu.o xroger.o \ + yarandom.o erase.o sgivideo.o +HDRS = alpha.h colors.h fade.h grabscreen.h hsv.h resources.h \ + spline.h usleep.h utils.h version.h visual.h vroot.h xmu.h \ + yarandom.h erase.h sgivideo.h +EXTRAS = README Makefile.in ad2c +VMSFILES = compile_axp.com compile_decc.com vms-gtod.c vms-gtod.h \ + vms-strdup.c + +TARFILES = $(EXTRAS) $(VMSFILES) $(SRCS) $(HDRS) + + +all: $(OBJS) + +install: install-program install-man +uninstall: uninstall-program uninstall-man + +install-strip: + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install + +install-program: +install-man: +uninstall-program: +uninstall-man: + +clean: + -rm -f *.o a.out core + +distclean: clean + -rm -f config.h 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@ \([^$$]\)@ $$(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) + + +# How we build object files in this directory. +.c.o: + $(CC) -c $(INCLUDES) $(DEFS) $(CFLAGS) $(X_CFLAGS) $< + + +# Rules for generating the VMS makefiles on Unix, so that it doesn't have to +# be done by hand... +# +VMS_AXP_COMPILE=$$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) + +compile_axp.com: Makefile.in + @echo generating $@ from $<... ; \ + ( ( for c in $(SRCS) vms-*.c ; do \ + c=`echo $$c | tr a-z A-Z` ; \ + echo "$(VMS_AXP_COMPILE) $$c" ; \ + done ; \ + ) | sort ; \ + echo '$$ lib/cre utils.olb_axp' ; \ + echo '$$ lib utils.olb_axp *.obj' ; \ + echo '$$! delete/noconf *.obj;' ; \ + ) > $@ + +compile_decc.com: compile_axp.com + @echo generating $@ from $<... ; \ + sed 's/axp/decc/g' < $< > $@ + +distdepend:: compile_axp.com compile_decc.com + + +############################################################################## +# +# DO NOT DELETE: updated by make distdepend + +alpha.o: $(srcdir)/utils.h +alpha.o: ../config.h +alpha.o: $(srcdir)/alpha.h +alpha.o: $(srcdir)/hsv.h +alpha.o: $(srcdir)/yarandom.h +alpha.o: $(srcdir)/resources.h +colors.o: $(srcdir)/utils.h +colors.o: ../config.h +colors.o: $(srcdir)/hsv.h +colors.o: $(srcdir)/yarandom.h +colors.o: $(srcdir)/visual.h +colors.o: $(srcdir)/colors.h +fade.o: $(srcdir)/utils.h +fade.o: ../config.h +fade.o: $(srcdir)/visual.h +fade.o: $(srcdir)/usleep.h +fade.o: $(srcdir)/fade.h +grabscreen.o: $(srcdir)/utils.h +grabscreen.o: ../config.h +grabscreen.o: $(srcdir)/yarandom.h +grabscreen.o: $(srcdir)/usleep.h +grabscreen.o: $(srcdir)/colors.h +grabscreen.o: $(srcdir)/grabscreen.h +grabscreen.o: $(srcdir)/sgivideo.h +grabscreen.o: $(srcdir)/visual.h +grabscreen.o: $(srcdir)/resources.h +grabscreen.o: $(srcdir)/vroot.h +hsv.o: $(srcdir)/utils.h +hsv.o: ../config.h +hsv.o: $(srcdir)/hsv.h +overlay.o: $(srcdir)/utils.h +overlay.o: ../config.h +overlay.o: $(srcdir)/visual.h +resources.o: $(srcdir)/utils.h +resources.o: ../config.h +resources.o: $(srcdir)/resources.h +spline.o: $(srcdir)/utils.h +spline.o: ../config.h +spline.o: $(srcdir)/spline.h +usleep.o: ../config.h +visual.o: $(srcdir)/utils.h +visual.o: ../config.h +visual.o: $(srcdir)/resources.h +visual.o: $(srcdir)/visual.h +xmu.o: ../config.h +xroger.o: $(srcdir)/utils.h +xroger.o: ../config.h +xroger.o: $(srcdir)/spline.h +yarandom.o: ../config.h +yarandom.o: $(srcdir)/yarandom.h +erase.o: $(srcdir)/utils.h +erase.o: ../config.h +erase.o: $(srcdir)/yarandom.h +erase.o: $(srcdir)/usleep.h +erase.o: $(srcdir)/resources.h +sgivideo.o: $(srcdir)/utils.h +sgivideo.o: ../config.h +sgivideo.o: $(srcdir)/sgivideo.h +sgivideo.o: $(srcdir)/resources.h +sgivideo.o: $(srcdir)/visual.h +sgivideo.o: $(srcdir)/usleep.h + diff --git a/utils/README b/utils/README new file mode 100644 index 00000000..2f5bc119 --- /dev/null +++ b/utils/README @@ -0,0 +1,6 @@ + +This directory contains various utilities that are used both by the +screensaver driver and by the demo programs; for example, a portable +implementation of usleep(), and code for manipulating color maps. + +If you have compilation problems, check the parameters in ../config.h. diff --git a/utils/ad2c b/utils/ad2c new file mode 100755 index 00000000..1435e554 --- /dev/null +++ b/utils/ad2c @@ -0,0 +1,38 @@ +#!/bin/sh +# +# ad2c : Convert app-defaults file to C strings decls. +# +# George Ferguson, ferguson@cs.rcohester.edu, 12 Nov 1990. +# 19 Mar 1991 : gf +# Made it self-contained. +# 6 Jan 1992 : mycroft@gnu.ai.mit.edu (Charles Hannum) +# Removed use of "-n" and ":read" label since Gnu and +# IBM sed print pattern space on "n" command. Still works +# with Sun sed, of course. +# 7 Jan 1992: matthew@sunpix.East.Sun.COM (Matthew Stier) +# Escape quotes after escaping backslashes. +# + +sed ' +/^!/d +/^$/d +s/\\/\\\\/g +s/\\$//g +s/"/\\"/g +s/^/"/ +: test +/\\$/b slash +s/$/",/ +p +d +: slash +n +/^!/d +/^$/d +s/"/\\"/g +s/\\\\/\\/g +s/\\n/\\\\n/g +s/\\t/\\\\t/g +s/\\f/\\\\f/g +s/\\b/\\\\b/g +b test' "$@" diff --git a/utils/alpha.c b/utils/alpha.c new file mode 100644 index 00000000..0f55ca01 --- /dev/null +++ b/utils/alpha.c @@ -0,0 +1,177 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +/* Beauty is only skin deep, unless you've got an alpha channel. */ + + +#include "utils.h" +#include "alpha.h" +#include "hsv.h" +#include "yarandom.h" +#include "resources.h" + +#ifndef countof +# define countof(x) (sizeof(*(x))/sizeof((x))) +#endif + + +/* I don't believe this fucking language doesn't have builtin exponentiation. + I further can't believe that the fucking ^ character means fucking XOR!! */ +static int +i_exp (int i, int j) +{ + int k = 1; + while (j--) k *= i; + return k; +} + + +static void +merge_colors (int argc, XColor **argv, XColor *into_color, int mask, + Bool additive_p) +{ + int j; + *into_color = *argv [0]; + into_color->pixel |= mask; + + for (j = 1; j < argc; j++) + { +# define SHORT_INC(x,y) (x = ((((x)+(y)) > 0xFFFF) ? 0xFFFF : ((x)+(y)))) +# define SHORT_DEC(x,y) (x = ((((x)-(y)) < 0) ? 0 : ((x)-(y)))) + if (additive_p) + { + SHORT_INC (into_color->red, argv[j]->red); + SHORT_INC (into_color->green, argv[j]->green); + SHORT_INC (into_color->blue, argv[j]->blue); + } + else + { + SHORT_DEC (into_color->red, argv[j]->red); + SHORT_DEC (into_color->green, argv[j]->green); + SHORT_DEC (into_color->blue, argv[j]->blue); + } +# undef SHORT_INC +# undef SHORT_DEC + } +} + +static void +permute_colors (XColor *pcolors, XColor *colors, + int count, + unsigned long *plane_masks, + Bool additive_p) +{ + int out = 0; + int max = i_exp (2, count); + if (count > 31) abort (); + for (out = 1; out < max; out++) + { + XColor *argv [32]; + int this_mask = 0; + int argc = 0; + int bit; + for (bit = 0; bit < 32; bit++) + if (out & (1< 1 && + !XAllocColorCells (dpy, cmap, False, plane_masks, nplanes, + base_pixel_ret, 1)) + nplanes--; + + return nplanes; +} + + +void +initialize_transparency_colormap (Display *dpy, Colormap cmap, + int nplanes, + unsigned long base_pixel, + unsigned long *plane_masks, + XColor *colors, + Bool additive_p) +{ + int i; + int total_colors = i_exp (2, nplanes); + XColor *all_colors = (XColor *) calloc (total_colors, sizeof (XColor)); + + for (i = 0; i < nplanes; i++) + colors[i].pixel = base_pixel | plane_masks [i]; + permute_colors (colors, all_colors, nplanes, plane_masks, additive_p); + + /* clone the default background of the window into our "base" pixel */ + all_colors [total_colors - 1].pixel = + get_pixel_resource ("background", "Background", dpy, cmap); + XQueryColor (dpy, cmap, &all_colors [total_colors - 1]); + all_colors [total_colors - 1].pixel = base_pixel; + + for (i = 0; i < total_colors; i++) + all_colors[i].flags = DoRed|DoGreen|DoBlue; + XStoreColors (dpy, cmap, all_colors, total_colors); + XFree ((XPointer) all_colors); +} + + +Bool +allocate_alpha_colors (Display *dpy, Colormap cmap, + int *nplanesP, Bool additive_p, + unsigned long **plane_masks, + unsigned long *base_pixelP) +{ + XColor *colors; + int nplanes = *nplanesP; + int i; + + if (nplanes > 31) nplanes = 31; + *plane_masks = (unsigned long *) malloc(sizeof(unsigned long) * nplanes); + + nplanes = allocate_color_planes (dpy, cmap, nplanes, *plane_masks, + base_pixelP); + *nplanesP = nplanes; + + if (nplanes <= 1) + { + free(*plane_masks); + *plane_masks = 0; + return False; + } + + colors = (XColor *) calloc (nplanes, sizeof (XColor)); + for (i = 0; i < nplanes; i++) + { + /* pick the base colors. If we are in subtractive mode, pick higher + intensities. */ + hsv_to_rgb (random () % 360, + frand (1.0), + frand (0.5) + (additive_p ? 0.2 : 0.5), + &colors[i].red, + &colors[i].green, + &colors[i].blue); + } + initialize_transparency_colormap (dpy, cmap, nplanes, + *base_pixelP, *plane_masks, colors, + additive_p); + XFree ((XPointer) colors); + return True; +} diff --git a/utils/alpha.h b/utils/alpha.h new file mode 100644 index 00000000..e16b3edb --- /dev/null +++ b/utils/alpha.h @@ -0,0 +1,32 @@ +/* xscreensaver, Copyright (c) 1992, 1995, 1996, 1997 + * 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. + */ + +#ifndef __XSCREENSAVER_ALPHA_H__ +#define __XSCREENSAVER_ALPHA_H__ + +extern int allocate_color_planes (Display *dpy, Colormap cmap, + int nplanes, unsigned long *plane_masks, + unsigned long *base_pixel_ret); + +extern void initialize_transparency_colormap (Display *dpy, Colormap cmap, + int nplanes, + unsigned long base_pixel, + unsigned long *plane_masks, + XColor *colors, + Bool additive_p); + +extern Bool allocate_alpha_colors (Display *dpy, Colormap cmap, + int *nplanesP, Bool additive_p, + unsigned long **plane_masks, + unsigned long *base_pixelP); + +#endif /* __XSCREENSAVER_ALPHA_H__ */ diff --git a/utils/colors.c b/utils/colors.c new file mode 100644 index 00000000..09631162 --- /dev/null +++ b/utils/colors.c @@ -0,0 +1,685 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +/* This file contains some utility routines for randomly picking the colors + to hack the screen with. + */ + +#include "utils.h" +#include "hsv.h" +#include "yarandom.h" +#include "visual.h" +#include "colors.h" + +extern char *progname; + +void +free_colors(Display *dpy, Colormap cmap, XColor *colors, int ncolors) +{ + int i; + if (ncolors > 0) + { + unsigned long *pixels = (unsigned long *) + malloc(sizeof(*pixels) * ncolors); + for (i = 0; i < ncolors; i++) + pixels[i] = colors[i].pixel; + XFreeColors (dpy, cmap, pixels, ncolors, 0L); + free(pixels); + } +} + + +void +allocate_writable_colors (Display *dpy, Colormap cmap, + unsigned long *pixels, int *ncolorsP) +{ + int desired = *ncolorsP; + int got = 0; + int requested = desired; + unsigned long *new_pixels = pixels; + + *ncolorsP = 0; + while (got < desired + && requested > 0) + { + if (desired - got < requested) + requested = desired - got; + + if (XAllocColorCells (dpy, cmap, False, 0, 0, new_pixels, requested)) + { + /* Got all the pixels we asked for. */ + new_pixels += requested; + got += requested; + } + else + { + /* We didn't get all/any of the pixels we asked for. This time, ask + for half as many. (If we do get all that we ask for, we ask for + the same number again next time, so we only do O(log(n)) server + roundtrips.) + */ + requested = requested / 2; + } + } + *ncolorsP += got; +} + + + +void +make_color_ramp (Display *dpy, Colormap cmap, + int h1, double s1, double v1, /* 0-360, 0-1.0, 0-1.0 */ + int h2, double s2, double v2, /* 0-360, 0-1.0, 0-1.0 */ + XColor *colors, int *ncolorsP, + Bool closed_p, + Bool allocate_p, + Bool writable_p) +{ + int i; + int ncolors = *ncolorsP; + double dh, ds, dv; /* deltas */ + + AGAIN: + + memset (colors, 0, (*ncolorsP) * sizeof(*colors)); + + if (closed_p) + ncolors = (ncolors / 2) + 1; + + /* Note: unlike other routines in this module, this function assumes that + if h1 and h2 are more than 180 degrees apart, then the desired direction + is always from h1 to h2 (rather than the shorter path.) make_uniform + depends on this. + */ + dh = ((double)h2 - (double)h1) / ncolors; + ds = (s2 - s1) / ncolors; + dv = (v2 - v1) / ncolors; + + for (i = 0; i < ncolors; i++) + { + colors[i].flags = DoRed|DoGreen|DoBlue; + hsv_to_rgb ((int) (h1 + (i*dh)), (s1 + (i*ds)), (v1 + (i*dv)), + &colors[i].red, &colors[i].green, &colors[i].blue); + } + + if (closed_p) + for (i = ncolors; i < *ncolorsP; i++) + colors[i] = colors[(*ncolorsP)-i]; + + if (!allocate_p) + return; + + if (writable_p) + { + unsigned long *pixels = (unsigned long *) + malloc(sizeof(*pixels) * ((*ncolorsP) + 1)); + + /* allocate_writable_colors() won't do here, because we need exactly this + number of cells, or the color sequence we've chosen won't fit. */ + if (! XAllocColorCells(dpy, cmap, False, 0, 0, pixels, *ncolorsP)) + { + free(pixels); + goto FAIL; + } + + for (i = 0; i < *ncolorsP; i++) + colors[i].pixel = pixels[i]; + free (pixels); + + XStoreColors (dpy, cmap, colors, *ncolorsP); + } + else + { + for (i = 0; i < *ncolorsP; i++) + { + XColor color; + color = colors[i]; + if (XAllocColor (dpy, cmap, &color)) + { + colors[i].pixel = color.pixel; + } + else + { + free_colors (dpy, cmap, colors, i); + goto FAIL; + } + } + } + + return; + + FAIL: + /* we weren't able to allocate all the colors we wanted; + decrease the requested number and try again. + */ + ncolors = (ncolors > 170 ? ncolors - 20 : + ncolors > 100 ? ncolors - 10 : + ncolors > 75 ? ncolors - 5 : + ncolors > 25 ? ncolors - 3 : + ncolors > 10 ? ncolors - 2 : + ncolors > 2 ? ncolors - 1 : + 0); + *ncolorsP = ncolors; + if (ncolors > 0) + goto AGAIN; +} + + +#define MAXPOINTS 50 /* yeah, so I'm lazy */ + + +static void +make_color_path (Display *dpy, Colormap cmap, + int npoints, int *h, double *s, double *v, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool writable_p) +{ + int i, j, k; + int total_ncolors = *ncolorsP; + + int ncolors[MAXPOINTS]; /* number of pixels per edge */ + double dh[MAXPOINTS]; /* distance between pixels, per edge (0 - 360.0) */ + double ds[MAXPOINTS]; /* distance between pixels, per edge (0 - 1.0) */ + double dv[MAXPOINTS]; /* distance between pixels, per edge (0 - 1.0) */ + + if (npoints == 0) + { + *ncolorsP = 0; + return; + } + else if (npoints == 2) /* using make_color_ramp() will be faster */ + { + make_color_ramp (dpy, cmap, + h[0], s[0], v[0], h[1], s[1], v[1], + colors, ncolorsP, + True, /* closed_p */ + allocate_p, writable_p); + return; + } + else if (npoints >= MAXPOINTS) + { + npoints = MAXPOINTS-1; + } + + AGAIN: + + { + double DH[MAXPOINTS]; /* Distance between H values in the shortest + direction around the circle, that is, the + distance between 10 and 350 is 20. + (Range is 0 - 360.0.) + */ + double edge[MAXPOINTS]; /* lengths of edges in unit HSV space. */ + double ratio[MAXPOINTS]; /* proportions of the edges (total 1.0) */ + double circum = 0; + double one_point_oh = 0; /* (debug) */ + + for (i = 0; i < npoints; i++) + { + int j = (i+1) % npoints; + double d = ((double) (h[i] - h[j])) / 360; + if (d < 0) d = -d; + if (d > 0.5) d = 0.5 - (d - 0.5); + DH[i] = d; + } + + for (i = 0; i < npoints; i++) + { + int j = (i+1) % npoints; + edge[i] = sqrt((DH[i] * DH[j]) + + ((s[j] - s[i]) * (s[j] - s[i])) + + ((v[j] - v[i]) * (v[j] - v[i]))); + circum += edge[i]; + } + +#ifdef DEBUG + fprintf(stderr, "\ncolors:"); + for (i=0; i < npoints; i++) + fprintf(stderr, " (%d, %.3f, %.3f)", h[i], s[i], v[i]); + fprintf(stderr, "\nlengths:"); + for (i=0; i < npoints; i++) + fprintf(stderr, " %.3f", edge[i]); +#endif /* DEBUG */ + + if (circum < 0.0001) + goto FAIL; + + for (i = 0; i < npoints; i++) + { + ratio[i] = edge[i] / circum; + one_point_oh += ratio[i]; + } + +#ifdef DEBUG + fprintf(stderr, "\nratios:"); + for (i=0; i < npoints; i++) + fprintf(stderr, " %.3f", ratio[i]); +#endif /* DEBUG */ + + if (one_point_oh < 0.99999 || one_point_oh > 1.00001) + abort(); + + /* space the colors evenly along the circumference -- that means that the + number of pixels on a edge is proportional to the length of that edge + (relative to the lengths of the other edges.) + */ + for (i = 0; i < npoints; i++) + ncolors[i] = total_ncolors * ratio[i]; + + +#ifdef DEBUG + fprintf(stderr, "\npixels:"); + for (i=0; i < npoints; i++) + fprintf(stderr, " %d", ncolors[i]); + fprintf(stderr, " (%d)\n", total_ncolors); +#endif /* DEBUG */ + + for (i = 0; i < npoints; i++) + { + int j = (i+1) % npoints; + + if (ncolors[i] > 0) + { + dh[i] = 360 * (DH[i] / ncolors[i]); + ds[i] = (s[j] - s[i]) / ncolors[i]; + dv[i] = (v[j] - v[i]) / ncolors[i]; + } + } + } + + memset (colors, 0, (*ncolorsP) * sizeof(*colors)); + + k = 0; + for (i = 0; i < npoints; i++) + { + int distance, direction; + distance = h[(i+1) % npoints] - h[i]; + direction = (distance >= 0 ? -1 : 1); + + if (distance > 180) + distance = 180 - (distance - 180); + else if (distance < -180) + distance = -(180 - ((-distance) - 180)); + else + direction = -direction; + +#ifdef DEBUG + fprintf (stderr, "point %d: %3d %.2f %.2f\n", + i, h[i], s[i], v[i]); + fprintf(stderr, " h[i]=%d dh[i]=%.2f ncolors[i]=%d\n", + h[i], dh[i], ncolors[i]); +#endif /* DEBUG */ + for (j = 0; j < ncolors[i]; j++, k++) + { + double hh = (h[i] + (j * dh[i] * direction)); + if (hh < 0) hh += 360; + else if (hh > 360) hh -= 0; + colors[k].flags = DoRed|DoGreen|DoBlue; + hsv_to_rgb ((int) + hh, + (s[i] + (j * ds[i])), + (v[i] + (j * dv[i])), + &colors[k].red, &colors[k].green, &colors[k].blue); +#ifdef DEBUG + fprintf (stderr, "point %d+%d: %.2f %.2f %.2f %04X %04X %04X\n", + i, j, + hh, + (s[i] + (j * ds[i])), + (v[i] + (j * dv[i])), + colors[k].red, colors[k].green, colors[k].blue); +#endif /* DEBUG */ + } + } + + /* Floating-point round-off can make us decide to use fewer colors. */ + if (k < *ncolorsP) + { + *ncolorsP = k; + if (k <= 0) + return; + } + + if (!allocate_p) + return; + + if (writable_p) + { + unsigned long *pixels = (unsigned long *) + malloc(sizeof(*pixels) * ((*ncolorsP) + 1)); + + /* allocate_writable_colors() won't do here, because we need exactly this + number of cells, or the color sequence we've chosen won't fit. */ + if (! XAllocColorCells(dpy, cmap, False, 0, 0, pixels, *ncolorsP)) + { + free(pixels); + goto FAIL; + } + + for (i = 0; i < *ncolorsP; i++) + colors[i].pixel = pixels[i]; + free (pixels); + + XStoreColors (dpy, cmap, colors, *ncolorsP); + } + else + { + for (i = 0; i < *ncolorsP; i++) + { + XColor color; + color = colors[i]; + if (XAllocColor (dpy, cmap, &color)) + { + colors[i].pixel = color.pixel; + } + else + { + free_colors (dpy, cmap, colors, i); + goto FAIL; + } + } + } + + return; + + FAIL: + /* we weren't able to allocate all the colors we wanted; + decrease the requested number and try again. + */ + total_ncolors = (total_ncolors > 170 ? total_ncolors - 20 : + total_ncolors > 100 ? total_ncolors - 10 : + total_ncolors > 75 ? total_ncolors - 5 : + total_ncolors > 25 ? total_ncolors - 3 : + total_ncolors > 10 ? total_ncolors - 2 : + total_ncolors > 2 ? total_ncolors - 1 : + 0); + *ncolorsP = total_ncolors; + if (total_ncolors > 0) + goto AGAIN; +} + + +void +make_color_loop (Display *dpy, Colormap cmap, + int h0, double s0, double v0, /* 0-360, 0-1.0, 0-1.0 */ + int h1, double s1, double v1, /* 0-360, 0-1.0, 0-1.0 */ + int h2, double s2, double v2, /* 0-360, 0-1.0, 0-1.0 */ + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool writable_p) +{ + int h[3]; + double s[3], v[3]; + h[0] = h0; h[1] = h1; h[2] = h2; + s[0] = s0; s[1] = s1; s[2] = s2; + v[0] = v0; v[1] = v1; v[2] = v2; + make_color_path(dpy, cmap, + 3, h, s, v, + colors, ncolorsP, + allocate_p, writable_p); +} + + +static void +complain (int wanted_colors, int got_colors, + Bool wanted_writable, Bool got_writable) +{ + if (wanted_writable && !got_writable) + fprintf(stderr, + "%s: wanted %d writable colors; got %d read-only colors.\n", + progname, wanted_colors, got_colors); + + else if (wanted_colors > (got_colors + 10)) + /* don't bother complaining if we're within ten pixels. */ + fprintf(stderr, "%s: wanted %d%s colors; got %d.\n", + progname, wanted_colors, (got_writable ? " writable" : ""), + got_colors); +} + + +void +make_smooth_colormap (Display *dpy, Visual *visual, Colormap cmap, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p) +{ + int npoints; + int ncolors = *ncolorsP; + Bool wanted_writable = (allocate_p && writable_pP && *writable_pP); + int i; + int h[MAXPOINTS]; + double s[MAXPOINTS]; + double v[MAXPOINTS]; + double total_s = 0; + double total_v = 0; + Screen *screen = DefaultScreenOfDisplay(dpy); /* #### WRONG! */ + + if (*ncolorsP <= 0) return; + + { + int n = random() % 20; + if (n <= 5) npoints = 2; /* 30% of the time */ + else if (n <= 15) npoints = 3; /* 50% of the time */ + else if (n <= 18) npoints = 4; /* 15% of the time */ + else npoints = 5; /* 5% of the time */ + } + + REPICK_ALL_COLORS: + for (i = 0; i < npoints; i++) + { + REPICK_THIS_COLOR: + h[i] = random() % 360; + s[i] = frand(1.0); + v[i] = frand(0.8) + 0.2; + + /* Make sure that no two adjascent colors are *too* close together. + If they are, try again. + */ + if (i > 0) + { + int j = (i+1 == npoints) ? 0 : (i-1); + double hi = ((double) h[i]) / 360; + double hj = ((double) h[j]) / 360; + double dh = hj - hi; + double distance; + if (dh < 0) dh = -dh; + if (dh > 0.5) dh = 0.5 - (dh - 0.5); + distance = sqrt ((dh * dh) + + ((s[j] - s[i]) * (s[j] - s[i])) + + ((v[j] - v[i]) * (v[j] - v[i]))); + if (distance < 0.2) + goto REPICK_THIS_COLOR; + } + total_s += s[i]; + total_v += v[i]; + } + + /* If the average saturation or intensity are too low, repick the colors, + so that we don't end up with a black-and-white or too-dark map. + */ + if (total_s / npoints < 0.2) + goto REPICK_ALL_COLORS; + if (total_v / npoints < 0.3) + goto REPICK_ALL_COLORS; + + /* If this visual doesn't support writable cells, don't bother trying. + */ + if (wanted_writable && !has_writable_cells(screen, visual)) + *writable_pP = False; + + RETRY_NON_WRITABLE: + make_color_path (dpy, cmap, npoints, h, s, v, colors, &ncolors, + allocate_p, (writable_pP && *writable_pP)); + + /* If we tried for writable cells and got none, try for non-writable. */ + if (allocate_p && *ncolorsP == 0 && *writable_pP) + { + *writable_pP = False; + goto RETRY_NON_WRITABLE; + } + + if (verbose_p) + complain(*ncolorsP, ncolors, wanted_writable, + wanted_writable && *writable_pP); + + *ncolorsP = ncolors; +} + + +void +make_uniform_colormap (Display *dpy, Visual *visual, Colormap cmap, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p) +{ + int ncolors = *ncolorsP; + Bool wanted_writable = (allocate_p && writable_pP && *writable_pP); + Screen *screen = DefaultScreenOfDisplay(dpy); /* #### WRONG! */ + + double S = ((double) (random() % 34) + 66) / 100.0; /* range 66%-100% */ + double V = ((double) (random() % 34) + 66) / 100.0; /* range 66%-100% */ + + if (*ncolorsP <= 0) return; + + /* If this visual doesn't support writable cells, don't bother trying. */ + if (wanted_writable && !has_writable_cells(screen, visual)) + *writable_pP = False; + + RETRY_NON_WRITABLE: + make_color_ramp(dpy, cmap, + 0, S, V, + 359, S, V, + colors, &ncolors, + False, True, wanted_writable); + + /* If we tried for writable cells and got none, try for non-writable. */ + if (allocate_p && *ncolorsP == 0 && writable_pP && *writable_pP) + { + ncolors = *ncolorsP; + *writable_pP = False; + goto RETRY_NON_WRITABLE; + } + + if (verbose_p) + complain(*ncolorsP, ncolors, wanted_writable, + wanted_writable && *writable_pP); + + *ncolorsP = ncolors; +} + + +void +make_random_colormap (Display *dpy, Visual *visual, Colormap cmap, + XColor *colors, int *ncolorsP, + Bool bright_p, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p) +{ + Bool wanted_writable = (allocate_p && writable_pP && *writable_pP); + int ncolors = *ncolorsP; + int i; + Screen *screen = DefaultScreenOfDisplay(dpy); /* #### WRONG! */ + + if (*ncolorsP <= 0) return; + + /* If this visual doesn't support writable cells, don't bother trying. */ + if (wanted_writable && !has_writable_cells(screen, visual)) + *writable_pP = False; + + for (i = 0; i < ncolors; i++) + { + colors[i].flags = DoRed|DoGreen|DoBlue; + if (bright_p) + { + int H = random() % 360; /* range 0-360 */ + double S = ((double) (random()%70) + 30)/100.0; /* range 30%-100% */ + double V = ((double) (random()%34) + 66)/100.0; /* range 66%-100% */ + hsv_to_rgb (H, S, V, + &colors[i].red, &colors[i].green, &colors[i].blue); + } + else + { + colors[i].red = random() % 0xFFFF; + colors[i].green = random() % 0xFFFF; + colors[i].blue = random() % 0xFFFF; + } + } + + if (!allocate_p) + return; + + RETRY_NON_WRITABLE: + if (writable_pP && *writable_pP) + { + unsigned long *pixels = (unsigned long *) + malloc(sizeof(*pixels) * (ncolors + 1)); + + allocate_writable_colors (dpy, cmap, pixels, &ncolors); + if (ncolors > 0) + for (i = 0; i < ncolors; i++) + colors[i].pixel = pixels[i]; + free (pixels); + if (ncolors > 0) + XStoreColors (dpy, cmap, colors, ncolors); + } + else + { + for (i = 0; i < ncolors; i++) + { + XColor color; + color = colors[i]; + if (!XAllocColor (dpy, cmap, &color)) + break; + colors[i].pixel = color.pixel; + } + ncolors = i; + } + + /* If we tried for writable cells and got none, try for non-writable. */ + if (allocate_p && ncolors == 0 && writable_pP && *writable_pP) + { + ncolors = *ncolorsP; + *writable_pP = False; + goto RETRY_NON_WRITABLE; + } + + if (verbose_p) + complain(*ncolorsP, ncolors, wanted_writable, + wanted_writable && *writable_pP); + + *ncolorsP = ncolors; +} + + +void +rotate_colors (Display *dpy, Colormap cmap, + XColor *colors, int ncolors, int distance) +{ + int i; + XColor *colors2 = (XColor *) malloc(sizeof(*colors2) * ncolors); + if (ncolors < 2) return; + distance = distance % ncolors; + for (i = 0; i < ncolors; i++) + { + int j = i - distance; + if (j >= ncolors) j -= ncolors; + if (j < 0) j += ncolors; + colors2[i] = colors[j]; + colors2[i].pixel = colors[i].pixel; + } + XStoreColors (dpy, cmap, colors2, ncolors); + XFlush(dpy); + memcpy(colors, colors2, sizeof(*colors) * ncolors); + free(colors2); +} diff --git a/utils/colors.h b/utils/colors.h new file mode 100644 index 00000000..174c6bfd --- /dev/null +++ b/utils/colors.h @@ -0,0 +1,140 @@ +/* xscreensaver, Copyright (c) 1992, 1997 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. + */ + +#ifndef __COLORS_H__ +#define __COLORS_H__ + +/* Like XFreeColors, but works on `XColor *' instead of `unsigned long *' + */ +extern void free_colors (Display *, Colormap, XColor *, int ncolors); + + +/* Allocates writable, non-contiguous color cells. The number requested is + passed in *ncolorsP, and the number actually allocated is returned there. + (Unlike XAllocColorCells(), this will allocate as many as it can, instead + of failing if they can't all be allocated.) + */ +extern void allocate_writable_colors (Display *dpy, Colormap cmap, + unsigned long *pixels, int *ncolorsP); + + +/* Generates a sequence of colors evenly spaced between the given pair + of HSV coordinates. + + If closed_p is true, the colors will go from the first point to the + second then back to the first. + + If allocate_p is true, the colors will be allocated from the map; + if enough colors can't be allocated, we will try for less, and the + result will be returned to ncolorsP. + + If writable_p is true, writable color cells will be allocated; + otherwise, read-only cells will be allocated. + */ +extern void make_color_ramp (Display *dpy, Colormap cmap, + int h1, double s1, double v1, + int h2, double s2, double v2, + XColor *colors, int *ncolorsP, + Bool closed_p, + Bool allocate_p, + Bool writable_p); + +/* Generates a sequence of colors evenly spaced around the triangle + indicated by the thee HSV coordinates. + + If allocate_p is true, the colors will be allocated from the map; + if enough colors can't be allocated, we will try for less, and the + result will be returned to ncolorsP. + + If writable_p is true, writable color cells will be allocated; + otherwise, read-only cells will be allocated. + */ +extern void make_color_loop (Display *, Colormap, + int h1, double s1, double v1, + int h2, double s2, double v2, + int h3, double s3, double v3, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool writable_p); + + +/* Allocates a hopefully-interesting colormap, which will be a closed loop + without any sudden transitions. + + If allocate_p is true, the colors will be allocated from the map; + if enough colors can't be allocated, we will try for less, and the + result will be returned to ncolorsP. An error message will be + printed on stderr (if verbose_p). + + If *writable_pP is true, writable color cells will be allocated; + otherwise, read-only cells will be allocated. If no writable cells + cannot be allocated, we will try to allocate unwritable cells + instead, and print a message on stderr to that effect (if verbose_p). + */ +extern void make_smooth_colormap (Display *dpy, Visual *visual, + Colormap cmap, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p); + +/* Allocates a uniform colormap which touches each hue of the spectrum, + evenly spaced. The saturation and intensity are chosen randomly, but + will be high enough to be visible. + + If allocate_p is true, the colors will be allocated from the map; + if enough colors can't be allocated, we will try for less, and the + result will be returned to ncolorsP. An error message will be + printed on stderr (if verbose_p). + + If *writable_pP is true, writable color cells will be allocated; + otherwise, read-only cells will be allocated. If no writable cells + cannot be allocated, we will try to allocate unwritable cells + instead, and print a message on stderr to that effect (if verbose_p). + */ +extern void make_uniform_colormap (Display *dpy, Visual *visual, + Colormap cmap, + XColor *colors, int *ncolorsP, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p); + +/* Allocates a random colormap (the colors are unrelated to one another.) + If `bright_p' is false, the colors will be completely random; if it is + true, all of the colors will be bright enough to see on a black background. + + If allocate_p is true, the colors will be allocated from the map; + if enough colors can't be allocated, we will try for less, and the + result will be returned to ncolorsP. An error message will be + printed on stderr (if verbose_p). + + If *writable_pP is true, writable color cells will be allocated; + otherwise, read-only cells will be allocated. If no writable cells + cannot be allocated, we will try to allocate unwritable cells + instead, and print a message on stderr to that effect (if verbose_p). + */ +extern void make_random_colormap (Display *dpy, Visual *visual, + Colormap cmap, + XColor *colors, int *ncolorsP, + Bool bright_p, + Bool allocate_p, + Bool *writable_pP, + Bool verbose_p); + + +/* Assuming that the array of colors indicates the current state of a set + of writable color cells, this rotates the contents of the array by + `distance' steps, moving the colors of cell N to cell (N - distance). + */ +extern void rotate_colors (Display *, Colormap, + XColor *, int ncolors, int distance); + +#endif /* __COLORS_H__ */ diff --git a/utils/compile_axp.com b/utils/compile_axp.com new file mode 100644 index 00000000..d22243d8 --- /dev/null +++ b/utils/compile_axp.com @@ -0,0 +1,20 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) ALPHA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) COLORS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) ERASE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) FADE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) GRABSCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) HSV.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) OVERLAY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) RESOURCES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) SGIVIDEO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) SPLINE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) USLEEP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VISUAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VMS-GTOD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VMS-STRDUP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) XMU.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) XROGER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) YARANDOM.C +$ lib/cre utils.olb_axp +$ lib utils.olb_axp *.obj +$! delete/noconf *.obj; diff --git a/utils/compile_decc.com b/utils/compile_decc.com new file mode 100644 index 00000000..cd1792e6 --- /dev/null +++ b/utils/compile_decc.com @@ -0,0 +1,20 @@ +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) ALPHA.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) COLORS.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) ERASE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) FADE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) GRABSCREEN.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) HSV.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) OVERLAY.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) RESOURCES.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) SGIVIDEO.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) SPLINE.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) USLEEP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VISUAL.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VMS-GTOD.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) VMS-STRDUP.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) XMU.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) XROGER.C +$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H)/INCL=([],[-]) YARANDOM.C +$ lib/cre utils.olb_decc +$ lib utils.olb_decc *.obj +$! delete/noconf *.obj; diff --git a/utils/erase.c b/utils/erase.c new file mode 100644 index 00000000..874ed925 --- /dev/null +++ b/utils/erase.c @@ -0,0 +1,397 @@ +/* erase.c: Erase the screen in various more or less interesting ways. + * (c) 1997 by Johannes Keukelaar + * Permission to use in any way granted. Provided "as is" without expressed + * or implied warranty. NO WARRANTY, NO EXPRESSION OF SUITABILITY FOR ANY + * PURPOSE. (I.e.: Use in any way, but at your own risk!) + */ + +#include "utils.h" +#include "yarandom.h" +#include "usleep.h" +#include "resources.h" + +#undef countof +#define countof(x) (sizeof(x)/sizeof(*(x))) + +typedef void (*Eraser) (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity); + + +static void +random_lines (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + Bool horiz_p = (random() & 1); + int max = (horiz_p ? height : width); + int *lines = (int *) calloc(max, sizeof(*lines)); + int i; + + for (i = 0; i < max; i++) + lines[i] = i; + + for (i = 0; i < max; i++) + { + int t, r; + t = lines[i]; + r = random() % max; + lines[i] = lines[r]; + lines[r] = t; + } + + for (i = 0; i < max; i++) + { + if (horiz_p) + XDrawLine (dpy, window, gc, 0, lines[i], width, lines[i]); + else + XDrawLine (dpy, window, gc, lines[i], 0, lines[i], height); + + XSync (dpy, False); + if (delay > 0 && ((i % granularity) == 0)) + usleep (delay * granularity); + } + free(lines); +} + + +static void +venetian (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + Bool horiz_p = (random() & 1); + Bool flip_p = (random() & 1); + int max = (horiz_p ? height : width); + int *lines = (int *) calloc(max, sizeof(*lines)); + int i, j; + + granularity /= 6; + + j = 0; + for (i = 0; i < max*2; i++) + { + int line = ((i / 16) * 16) - ((i % 16) * 15); + if (line >= 0 && line < max) + lines[j++] = (flip_p ? max - line : line); + } + + for (i = 0; i < max; i++) + { + if (horiz_p) + XDrawLine (dpy, window, gc, 0, lines[i], width, lines[i]); + else + XDrawLine (dpy, window, gc, lines[i], 0, lines[i], height); + + XSync (dpy, False); + if (delay > 0 && ((i % granularity) == 0)) + usleep (delay * granularity); + } + free(lines); +} + + +static void +triple_wipe (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + Bool flip_x = random() & 1; + Bool flip_y = random() & 1; + int max = width + (height / 2); + int *lines = (int *)calloc(max, sizeof(int)); + int i; + + for(i = 0; i < width/2; i++) + lines[i] = i*2+height; + for(i = 0; i < height/2; i++) + lines[i+width/2] = i*2; + for(i = 0; i < width/2; i++) + lines[i+width/2+height/2] = width-i*2-(width%2?0:1)+height; + + granularity /= 6; + + for (i = 0; i < max; i++) + { + int x, y, x2, y2; + if (lines[i] < height) + x = 0, y = lines[i], x2 = width, y2 = y; + else + x = lines[i]-height, y = 0, x2 = x, y2 = height; + + if (flip_x) + x = width-x, x2 = width-x2; + if (flip_y) + y = height-y, y2 = height-y2; + + XDrawLine (dpy, window, gc, x, y, x2, y2); + XSync (dpy, False); + if (delay > 0 && ((i % granularity) == 0)) + usleep (delay*granularity); + } + free(lines); +} + + +static void +quad_wipe (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + Bool flip_x = random() & 1; + Bool flip_y = random() & 1; + int max = width + height; + int *lines = (int *)calloc(max, sizeof(int)); + int i; + + granularity /= 3; + + for (i = 0; i < max/4; i++) + { + lines[i*4] = i*2; + lines[i*4+1] = height-i*2-(height%2?0:1); + lines[i*4+2] = height+i*2; + lines[i*4+3] = height+width-i*2-(width%2?0:1); + } + + for (i = 0; i < max; i++) + { + int x, y, x2, y2; + if (lines[i] < height) + x = 0, y = lines[i], x2 = width, y2 = y; + else + x = lines[i]-height, y = 0, x2 = x, y2 = height; + + if (flip_x) + x = width-x, x2 = width-x2; + if (flip_y) + y = height-y, y2 = height-y2; + + XDrawLine (dpy, window, gc, x, y, x2, y2); + XSync (dpy, False); + if (delay > 0 && ((i % granularity) == 0)) + usleep (delay*granularity); + } + free(lines); +} + + + +static void +circle_wipe (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + int full = 360 * 64; + int inc = full / 64; + int start = random() % full; + int rad = (width > height ? width : height); + int i; + if (random() & 1) + inc = -inc; + for (i = (inc > 0 ? 0 : full); + (inc > 0 ? i < full : i > 0); + i += inc) + { + XFillArc(dpy, window, gc, + (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (i+start) % full, inc); + XFlush (dpy); + usleep (delay*granularity); + } +} + + +static void +three_circle_wipe (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + int i; + int full = 360 * 64; + int q = full / 6; + int q2 = q * 2; + int inc = full / 240; + int start = random() % q; + int rad = (width > height ? width : height); + + for (i = 0; i < q; i += inc) + { + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start+i) % full, inc); + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start-i) % full, -inc); + + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start+q2+i) % full, inc); + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start+q2-i) % full, -inc); + + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start+q2+q2+i) % full, inc); + XFillArc(dpy, window, gc, (width/2)-rad, (height/2)-rad, rad*2, rad*2, + (start+q2+q2-i) % full, -inc); + + XSync (dpy, False); + usleep (delay*granularity); + } +} + + +static void +squaretate (Display *dpy, Window window, GC gc, + int width, int height, int delay, int granularity) +{ + int steps = (((width > height ? width : width) * 2) / granularity); + int i; + Bool flip = random() & 1; + +#define DRAW() \ + if (flip) { \ + points[0].x = width-points[0].x; \ + points[1].x = width-points[1].x; \ + points[2].x = width-points[2].x; } \ + XFillPolygon (dpy, window, gc, points, 3, Convex, CoordModeOrigin) + + for (i = 0; i < steps; i++) + { + XPoint points [3]; + points[0].x = 0; + points[0].y = 0; + points[1].x = width; + points[1].y = 0; + points[2].x = 0; + points[2].y = points[0].y + ((i * height) / steps); + DRAW(); + + points[0].x = 0; + points[0].y = 0; + points[1].x = 0; + points[1].y = height; + points[2].x = ((i * width) / steps); + points[2].y = height; + DRAW(); + + points[0].x = width; + points[0].y = height; + points[1].x = 0; + points[1].y = height; + points[2].x = width; + points[2].y = height - ((i * height) / steps); + DRAW(); + + points[0].x = width; + points[0].y = height; + points[1].x = width; + points[1].y = 0; + points[2].x = width - ((i * width) / steps); + points[2].y = 0; + DRAW(); + + XSync (dpy, True); + if (delay > 0) + usleep (delay * granularity); + } +#undef DRAW +} + + + + +static Eraser erasers[] = { + random_lines, + venetian, + triple_wipe, + quad_wipe, + circle_wipe, + three_circle_wipe, + squaretate, +}; + + +void +erase_window(Display *dpy, Window window, GC gc, + int width, int height, int mode, int delay) +{ + int granularity = 25; + + if (mode < 0 || mode >= countof(erasers)) + mode = random() % countof(erasers); + (*(erasers[mode])) (dpy, window, gc, width, height, delay, granularity); + XClearWindow (dpy, window); + XSync(dpy, False); +} + + +void +erase_full_window(Display *dpy, Window window) +{ + XWindowAttributes xgwa; + XGCValues gcv; + GC erase_gc; + XColor black; + int erase_speed, erase_mode; + char *s; + + s = get_string_resource("eraseSpeed", "Integer"); + if (s && *s) + erase_speed = get_integer_resource("eraseSpeed", "Integer"); + else + erase_speed = 400; + if (s) free(s); + + s = get_string_resource("eraseMode", "Integer"); + if (s && *s) + erase_mode = get_integer_resource("eraseMode", "Integer"); + else + erase_mode = -1; + if (s) free(s); + + XGetWindowAttributes (dpy, window, &xgwa); + black.flags = DoRed|DoGreen|DoBlue; + black.red = black.green = black.blue = 0; + XAllocColor(dpy, xgwa.colormap, &black); + gcv.foreground = black.pixel; + erase_gc = XCreateGC (dpy, window, GCForeground, &gcv); + erase_window (dpy, window, erase_gc, xgwa.width, xgwa.height, + erase_mode, erase_speed); + XFreeColors(dpy, xgwa.colormap, &black.pixel, 1, 0); + XFreeGC(dpy, erase_gc); +} + + + +#if 0 +#include "screenhack.h" + +char *progclass = "Erase"; +char *defaults [] = { + 0 +}; + +XrmOptionDescRec options [] = {0}; +int options_size = 0; + +void +screenhack (dpy, window) + Display *dpy; + Window window; +{ + int delay = 500000; + XGCValues gcv; + GC gc; + XColor white; + XWindowAttributes xgwa; + XGetWindowAttributes (dpy, window, &xgwa); + white.flags = DoRed|DoGreen|DoBlue; + white.red = white.green = white.blue = 0xFFFF; + XAllocColor(dpy, xgwa.colormap, &white); + gcv.foreground = white.pixel; + gc = XCreateGC (dpy, window, GCForeground, &gcv); + + while (1) + { + XFillRectangle(dpy, window, gc, 0, 0, 1280, 1024); + XSync (dpy, False); + usleep (delay); + erase_full_window(dpy, window); + XSync (dpy, False); + usleep (delay); + + } +} + +#endif diff --git a/utils/erase.h b/utils/erase.h new file mode 100644 index 00000000..2f00d3e1 --- /dev/null +++ b/utils/erase.h @@ -0,0 +1,15 @@ +/* erase.c: Erase the screen in various more or less interesting ways. + * (c) 1997 by Johannes Keukelaar + * Permission to use in any way granted. Provided "as is" without expressed + * or implied warranty. NO WARRANTY, NO EXPRESSION OF SUITABILITY FOR ANY + * PURPOSE. (I.e.: Use in any way, but at your own risk!) + */ + +#ifndef __XSCREENSAVER_ERASE_H__ +#define __XSCREENSAVER_ERASE_H__ + +extern void erase_window(Display *dpy, Window window, GC gc, + int width, int height, int mode, int delay); +extern void erase_full_window(Display *dpy, Window window); + +#endif /* __XSCREENSAVER_ERASE_H__ */ diff --git a/utils/fade.c b/utils/fade.c new file mode 100644 index 00000000..9622c31e --- /dev/null +++ b/utils/fade.c @@ -0,0 +1,621 @@ +/* xscreensaver, Copyright (c) 1992-1998 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. + */ + +#include "utils.h" + +#include /* for gettimeofday() */ + +#ifdef VMS +# include "vms-gtod.h" +#endif /* VMS */ + +#include "visual.h" +#include "usleep.h" +#include "fade.h" + + +Colormap +copy_colormap (Screen *screen, Visual *visual, + Colormap cmap, Colormap into_cmap) +{ + int i; + Display *dpy = DisplayOfScreen (screen); + Window window = RootWindowOfScreen (screen); + int ncolors = CellsOfScreen (screen); + XColor *colors = 0; + + /* If this is a colormap on a mono visual, or one with insanely many + color cells, bug out. */ + if (ncolors <= 2 || ncolors > 4096) + return 0; + /* If this is a non-writable visual, bug out. */ + if (!has_writable_cells (screen, visual)) + return 0; + + if (! into_cmap) + into_cmap = XCreateColormap (dpy, window, visual, AllocAll); + if (! cmap) + cmap = DefaultColormapOfScreen (screen); + + colors = (XColor *) calloc(sizeof(XColor), ncolors); + for (i = 0; i < ncolors; i++) + colors [i].pixel = i; + XQueryColors (dpy, cmap, colors, ncolors); + XStoreColors (dpy, into_cmap, colors, ncolors); + free (colors); + return into_cmap; +} + + +void +blacken_colormap (Screen *screen, Colormap cmap) +{ + Display *dpy = DisplayOfScreen (screen); + int ncolors = CellsOfScreen (screen); + XColor *colors; + int i; + if (ncolors > 4096) + return; + colors = (XColor *) calloc(sizeof(XColor), ncolors); + for (i = 0; i < ncolors; i++) + colors[i].pixel = i; + XStoreColors (dpy, cmap, colors, ncolors); + free (colors); +} + + + +static void fade_screens_1 (Display *dpy, Colormap *cmaps, + Window *black_windows, int seconds, int ticks, + Bool out_p, Bool clear_windows); +#ifdef HAVE_SGI_VC_EXTENSION +static int sgi_gamma_fade (Display *dpy, + Window *black_windows, int seconds, int ticks, + Bool out_p, Bool clear_windows); +#endif /* HAVE_SGI_VC_EXTENSION */ + + + +void +fade_screens (Display *dpy, Colormap *cmaps, Window *black_windows, + int seconds, int ticks, + Bool out_p, Bool clear_windows) +{ + int oseconds = seconds; + Bool was_in_p = !out_p; + + /* When we're asked to fade in, first fade out, then fade in. + That way all the transitions are smooth -- from what's on the + screen, to black, to the desktop. + */ + if (was_in_p) + { + clear_windows = True; + out_p = True; + seconds /= 3; + if (seconds == 0) + seconds = 1; + } + + AGAIN: + +#ifdef HAVE_SGI_VC_EXTENSION + /* First try to do it by fading the gamma in an SGI-specific way... */ + if (0 != sgi_gamma_fade(dpy, black_windows, seconds, ticks, out_p, + clear_windows)) +#endif /* HAVE_SGI_VC_EXTENSION */ + /* Else, do it the old-fashioned way, which (somewhat) loses if + there are TrueColor windows visible. */ + fade_screens_1 (dpy, cmaps, black_windows, seconds, ticks, + out_p, clear_windows); + + /* If we were supposed to be fading in, do so now (we just faded out, + so now fade back in.) + */ + if (was_in_p) + { + was_in_p = False; + out_p = False; + seconds = oseconds * 2 / 3; + if (seconds == 0) + seconds = 1; + goto AGAIN; + } +} + + +/* The business with `cmaps_per_screen' is to fake out the SGI 8-bit video + hardware, which is capable of installing multiple (4) colormaps + simultaniously. We have to install multiple copies of the same set of + colors in order to fill up all the available slots in the hardware color + lookup table, so we install an extra N colormaps per screen to make sure + that all screens really go black. + + I'm told that this trick also works with XInside's AcceleratedX when using + the Matrox Millenium card (which also allows multiple PseudoColor and + TrueColor visuals to co-exist and display properly at the same time.) + + This trick works ok on the 24-bit Indy video hardware, but doesn't work at + all on the O2 24-bit hardware. I guess the higher-end hardware is too + "good" for this to work (dammit.) So... I figured out the "right" way to + do this on SGIs, which is to ramp the monitor's gamma down to 0. That's + what is implemented in sgi_gamma_fade(), so we use that if we can. + */ +static void +fade_screens_1 (Display *dpy, Colormap *cmaps, Window *black_windows, + int seconds, int ticks, + Bool out_p, Bool clear_windows) +{ + int i, j, k; + int steps = seconds * ticks; + long usecs_per_step = (long)(seconds * 1000000) / (long)steps; + XEvent dummy_event; + int cmaps_per_screen = 5; + int nscreens = ScreenCount(dpy); + int ncmaps = nscreens * cmaps_per_screen; + Colormap *fade_cmaps = 0; + Bool installed = False; + int total_ncolors; + XColor *orig_colors, *current_colors, *screen_colors, *orig_screen_colors; + struct timeval then, now; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; +#endif + + total_ncolors = 0; + for (i = 0; i < nscreens; i++) + total_ncolors += CellsOfScreen (ScreenOfDisplay(dpy, i)); + + orig_colors = (XColor *) calloc(sizeof(XColor), total_ncolors); + current_colors = (XColor *) calloc(sizeof(XColor), total_ncolors); + + /* Get the contents of the colormap we are fading from or to. */ + screen_colors = orig_colors; + for (i = 0; i < nscreens; i++) + { + int ncolors = CellsOfScreen (ScreenOfDisplay (dpy, i)); + Colormap cmap = (cmaps ? cmaps[i] : 0); + if (!cmap) cmap = DefaultColormap(dpy, i); + + for (j = 0; j < ncolors; j++) + screen_colors[j].pixel = j; + XQueryColors (dpy, cmap, screen_colors, ncolors); + + screen_colors += ncolors; + } + + memcpy (current_colors, orig_colors, total_ncolors * sizeof (XColor)); + + + /* Make the writable colormaps (we keep these around and reuse them.) */ + if (!fade_cmaps) + { + fade_cmaps = (Colormap *) calloc(sizeof(Colormap), ncmaps); + for (i = 0; i < nscreens; i++) + { + Visual *v = DefaultVisual(dpy, i); + Screen *s = ScreenOfDisplay(dpy, i); + if (has_writable_cells (s, v)) + for (j = 0; j < cmaps_per_screen; j++) + fade_cmaps[(i * cmaps_per_screen) + j] = + XCreateColormap (dpy, RootWindowOfScreen (s), v, AllocAll); + } + } + +#ifdef GETTIMEOFDAY_TWO_ARGS + gettimeofday(&then, &tzp); +#else + gettimeofday(&then); +#endif + + /* Iterate by steps of the animation... */ + for (i = (out_p ? steps : 0); + (out_p ? i > 0 : i < steps); + (out_p ? i-- : i++)) + { + + /* For each screen, compute the current value of each color... + */ + orig_screen_colors = orig_colors; + screen_colors = current_colors; + for (j = 0; j < nscreens; j++) + { + int ncolors = CellsOfScreen (ScreenOfDisplay (dpy, j)); + for (k = 0; k < ncolors; k++) + { + /* This doesn't take into account the relative luminance of the + RGB components (0.299, 0.587, and 0.114 at gamma 2.2) but + the difference is imperceptible for this application... */ + screen_colors[k].red = orig_screen_colors[k].red * i / steps; + screen_colors[k].green = orig_screen_colors[k].green * i / steps; + screen_colors[k].blue = orig_screen_colors[k].blue * i / steps; + } + screen_colors += ncolors; + orig_screen_colors += ncolors; + } + + /* Put the colors into the maps... + */ + screen_colors = current_colors; + for (j = 0; j < nscreens; j++) + { + int ncolors = CellsOfScreen (ScreenOfDisplay (dpy, j)); + for (k = 0; k < cmaps_per_screen; k++) + { + Colormap c = fade_cmaps[j * cmaps_per_screen + k]; + if (c) + XStoreColors (dpy, c, screen_colors, ncolors); + } + screen_colors += ncolors; + } + + /* Put the maps on the screens, and then take the windows off the screen. + (only need to do this the first time through the loop.) + */ + if (!installed) + { + for (j = 0; j < ncmaps; j++) + if (fade_cmaps[j]) + XInstallColormap (dpy, fade_cmaps[j]); + installed = True; + + if (black_windows && !out_p) + for (j = 0; j < nscreens; j++) + if (black_windows[j]) + { + XUnmapWindow (dpy, black_windows[j]); + XClearWindow (dpy, black_windows[j]); + } + } + + XSync (dpy, False); + + /* If there is user activity, bug out. (Bug out on keypresses or + mouse presses, but not motion, and not release events. Bugging + out on motion made the unfade hack be totally useless, I think.) + + We put the event back so that the calling code can notice it too. + It would be better to not remove it at all, but that's harder + because Xlib has such a non-design for this kind of crap, and + in this application it doesn't matter if the events end up out + of order, so in the grand unix tradition we say "fuck it" and + do something that mostly works for the time being. + */ + if (XCheckMaskEvent (dpy, (KeyPressMask|ButtonPressMask), &dummy_event)) + { + XPutBackEvent (dpy, &dummy_event); + goto DONE; + } + +#ifdef GETTIMEOFDAY_TWO_ARGS + gettimeofday(&now, &tzp); +#else + gettimeofday(&now); +#endif + + /* If we haven't already used up our alotted time, sleep to avoid + changing the colormap too fast. */ + { + long diff = (((now.tv_sec - then.tv_sec) * 1000000) + + now.tv_usec - then.tv_usec); + then.tv_sec = now.tv_sec; + then.tv_usec = now.tv_usec; + if (usecs_per_step > diff) + usleep (usecs_per_step - diff); + } + } + + DONE: + + if (orig_colors) free (orig_colors); + if (current_colors) free (current_colors); + + /* If we've been given windows to raise after blackout, raise them before + releasing the colormaps. + */ + if (out_p && black_windows) + { + for (i = 0; i < nscreens; i++) + { + if (clear_windows) + XClearWindow (dpy, black_windows[i]); + XMapRaised (dpy, black_windows[i]); + } + XSync(dpy, False); + } + + /* Now put the target maps back. + If we're fading out, use the given cmap (or the default cmap, if none.) + If we're fading in, always use the default cmap. + */ + for (i = 0; i < nscreens; i++) + { + Colormap cmap = (cmaps ? cmaps[i] : 0); + if (!cmap || !out_p) + cmap = DefaultColormap(dpy, i); + XInstallColormap (dpy, cmap); + } + + /* The fade (in or out) is complete, so we don't need the black maps on + stage any more. + */ + for (i = 0; i < ncmaps; i++) + if (fade_cmaps[i]) + { + XUninstallColormap(dpy, fade_cmaps[i]); + XFreeColormap(dpy, fade_cmaps[i]); + fade_cmaps[i] = 0; + } + free(fade_cmaps); + fade_cmaps = 0; +} + + +#ifdef HAVE_SGI_VC_EXTENSION + +# include + +struct screen_gamma_info { + int gamma_map; /* ??? always using 0 */ + int nred, ngreen, nblue; + unsigned short *red1, *green1, *blue1; + unsigned short *red2, *green2, *blue2; + int gamma_size; + int gamma_precision; + Bool alpha_p; +}; + + +static void whack_gamma(Display *dpy, int screen, + struct screen_gamma_info *info, float ratio); + +static int +sgi_gamma_fade (Display *dpy, + Window *black_windows, int seconds, int ticks, + Bool out_p, Bool clear_windows) +{ + int steps = seconds * ticks; + long usecs_per_step = (long)(seconds * 1000000) / (long)steps; + XEvent dummy_event; + int nscreens = ScreenCount(dpy); + struct timeval then, now; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; +#endif + int i, screen; + int status = -1; + struct screen_gamma_info *info = (struct screen_gamma_info *) + calloc(nscreens, sizeof(*info)); + + /* Get the current gamma maps for all screens. + Bug out and return -1 if we can't get them for some screen. + */ + for (screen = 0; screen < nscreens; screen++) + { + if (!XSGIvcQueryGammaMap(dpy, screen, info[screen].gamma_map, + &info[screen].gamma_size, + &info[screen].gamma_precision, + &info[screen].alpha_p)) + goto FAIL; + + if (!XSGIvcQueryGammaColors(dpy, screen, info[screen].gamma_map, + XSGIVC_COMPONENT_RED, + &info[screen].nred, &info[screen].red1)) + goto FAIL; + if (! XSGIvcQueryGammaColors(dpy, screen, info[screen].gamma_map, + XSGIVC_COMPONENT_GREEN, + &info[screen].ngreen, &info[screen].green1)) + goto FAIL; + if (!XSGIvcQueryGammaColors(dpy, screen, info[screen].gamma_map, + XSGIVC_COMPONENT_BLUE, + &info[screen].nblue, &info[screen].blue1)) + goto FAIL; + + if (info[screen].gamma_precision == 8) /* Scale it up to 16 bits. */ + { + int j; + for(j = 0; j < info[screen].nred; j++) + info[screen].red1[j] = + ((info[screen].red1[j] << 8) | info[screen].red1[j]); + for(j = 0; j < info[screen].ngreen; j++) + info[screen].green1[j] = + ((info[screen].green1[j] << 8) | info[screen].green1[j]); + for(j = 0; j < info[screen].nblue; j++) + info[screen].blue1[j] = + ((info[screen].blue1[j] << 8) | info[screen].blue1[j]); + } + + info[screen].red2 = (unsigned short *) + malloc(sizeof(*info[screen].red2) * (info[screen].nred+1)); + info[screen].green2 = (unsigned short *) + malloc(sizeof(*info[screen].green2) * (info[screen].ngreen+1)); + info[screen].blue2 = (unsigned short *) + malloc(sizeof(*info[screen].blue2) * (info[screen].nblue+1)); + } + +#ifdef GETTIMEOFDAY_TWO_ARGS + gettimeofday(&then, &tzp); +#else + gettimeofday(&then); +#endif + + /* If we're fading in (from black), then first crank the gamma all the + way down to 0, then take the windows off the screen. + */ + if (!out_p) + for (screen = 0; screen < nscreens; screen++) + { + whack_gamma(dpy, screen, &info[screen], 0.0); + if (black_windows && black_windows[screen]) + { + XUnmapWindow (dpy, black_windows[screen]); + XClearWindow (dpy, black_windows[screen]); + XSync(dpy, False); + } + } + + + /* Iterate by steps of the animation... */ + for (i = (out_p ? steps : 0); + (out_p ? i > 0 : i < steps); + (out_p ? i-- : i++)) + { + for (screen = 0; screen < nscreens; screen++) + { + whack_gamma(dpy, screen, &info[screen], + (((float)i) / ((float)steps))); + + /* If there is user activity, bug out. (Bug out on keypresses or + mouse presses, but not motion, and not release events. Bugging + out on motion made the unfade hack be totally useless, I think.) + + We put the event back so that the calling code can notice it too. + It would be better to not remove it at all, but that's harder + because Xlib has such a non-design for this kind of crap, and + in this application it doesn't matter if the events end up out + of order, so in the grand unix tradition we say "fuck it" and + do something that mostly works for the time being. + */ + if (XCheckMaskEvent (dpy, (KeyPressMask|ButtonPressMask), + &dummy_event)) + { + XPutBackEvent (dpy, &dummy_event); + goto DONE; + } + +#ifdef GETTIMEOFDAY_TWO_ARGS + gettimeofday(&now, &tzp); +#else + gettimeofday(&now); +#endif + + /* If we haven't already used up our alotted time, sleep to avoid + changing the colormap too fast. */ + { + long diff = (((now.tv_sec - then.tv_sec) * 1000000) + + now.tv_usec - then.tv_usec); + then.tv_sec = now.tv_sec; + then.tv_usec = now.tv_usec; + if (usecs_per_step > diff) + usleep (usecs_per_step - diff); + } + } + } + + + DONE: + + if (out_p && black_windows) + { + for (screen = 0; screen < nscreens; screen++) + { + if (clear_windows) + XClearWindow (dpy, black_windows[i]); + XMapRaised (dpy, black_windows[i]); + } + XSync(dpy, False); + } + + /* I can't explain this; without this delay, we get a flicker. + I suppose there's some lossage with stale bits being in the + hardware frame buffer or something, and this delay gives it + time to flush out. This sucks! */ + usleep(100000); /* 1/10th second */ + + for (screen = 0; screen < nscreens; screen++) + whack_gamma(dpy, screen, &info[screen], 1.0); + XSync(dpy, False); + + status = 0; + + FAIL: + for (screen = 0; screen < nscreens; screen++) + { + if (info[screen].red1) free (info[screen].red1); + if (info[screen].green1) free (info[screen].green1); + if (info[screen].blue1) free (info[screen].blue1); + if (info[screen].red2) free (info[screen].red2); + if (info[screen].green2) free (info[screen].green2); + if (info[screen].blue2) free (info[screen].blue2); + } + free(info); + + return status; +} + +static void +whack_gamma(Display *dpy, int screen, struct screen_gamma_info *info, + float ratio) +{ + int k; + + if (ratio < 0) ratio = 0; + if (ratio > 1) ratio = 1; + for (k = 0; k < info->gamma_size; k++) + { + info->red2[k] = info->red1[k] * ratio; + info->green2[k] = info->green1[k] * ratio; + info->blue2[k] = info->blue1[k] * ratio; + } + + XSGIvcStoreGammaColors16(dpy, screen, info->gamma_map, info->nred, + XSGIVC_MComponentRed, info->red2); + XSGIvcStoreGammaColors16(dpy, screen, info->gamma_map, info->ngreen, + XSGIVC_MComponentGreen, info->green2); + XSGIvcStoreGammaColors16(dpy, screen, info->gamma_map, info->nblue, + XSGIVC_MComponentBlue, info->blue2); + XSync(dpy, False); +} + +#endif /* HAVE_SGI_VC_EXTENSION */ + + + + +#if 0 +#include "screenhack.h" + +char *progclass = "foo"; +char *defaults [] = { + 0 +}; + +XrmOptionDescRec options [] = {0}; +int options_size = 0; + +void +screenhack (dpy, w) + Display *dpy; + Window w; +{ + int seconds = 3; + int ticks = 20; + int delay = 1; + + while (1) + { + XSync (dpy, False); + + fprintf(stderr,"out..."); fflush(stderr); + fade_screens (dpy, 0, seconds, ticks, True); + fprintf(stderr, "done.\n"); fflush(stderr); + + if (delay) sleep (delay); + + fprintf(stderr,"in..."); fflush(stderr); + fade_screens (dpy, 0, seconds, ticks, False); + fprintf(stderr, "done.\n"); fflush(stderr); + + if (delay) sleep (delay); + } +} + +#endif diff --git a/utils/fade.h b/utils/fade.h new file mode 100644 index 00000000..5fd8c187 --- /dev/null +++ b/utils/fade.h @@ -0,0 +1,21 @@ +/* xscreensaver, Copyright (c) 1992-1997 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. + */ + +#ifndef __FADE_H__ +#define __FADE_H__ + +extern Colormap copy_colormap (Screen *, Visual *, Colormap from, Colormap to); +extern void blacken_colormap (Screen *, Colormap cmap); +extern void fade_screens (Display *dpy, + Colormap *cmaps, Window *black_windows, + int seconds, int ticks, + Bool out_p, Bool clear_windows); +#endif /* __FADE_H__ */ diff --git a/utils/grabscreen.c b/utils/grabscreen.c new file mode 100644 index 00000000..78c21163 --- /dev/null +++ b/utils/grabscreen.c @@ -0,0 +1,722 @@ +/* xscreensaver, Copyright (c) 1992, 1993, 1994, 1997, 1998 + * 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. + */ + +/* This file contains code for grabbing an image of the screen to hack its + bits. This is a little tricky, since doing this involves the need to tell + the difference between drawing on the actual root window, and on the fake + root window used by the screensaver, since at this level the illusion + breaks down... + */ + +#include "utils.h" +#include "yarandom.h" + +#include +#include + +#ifdef HAVE_XMU +# ifndef VMS +# include +# else /* VMS */ +# include +# endif /* VMS */ +#endif + +#include "usleep.h" +#include "colors.h" +#include "grabscreen.h" +#include "sgivideo.h" +#include "visual.h" +#include "resources.h" + +#include "vroot.h" +#undef RootWindowOfScreen +#undef RootWindow +#undef DefaultRootWindow + + +#ifdef HAVE_READ_DISPLAY_EXTENSION +# include + static Bool read_display (Screen *, Window, Pixmap, Bool); +#endif /* HAVE_READ_DISPLAY_EXTENSION */ + + +static void copy_default_colormap_contents (Screen *, Colormap, Visual *); + +#if defined(HAVE_READ_DISPLAY_EXTENSION) || defined(HAVE_SGI_VIDEO) +static void make_cubic_colormap (Screen *, Window, Visual *); +#endif + + +static Bool +MapNotify_event_p (Display *dpy, XEvent *event, XPointer window) +{ + return (event->xany.type == MapNotify && + event->xvisibility.window == (Window) window); +} + +#ifdef DEBUG +extern char *progname; +#endif /* DEBUG */ + + +static void +raise_window(Display *dpy, Window window, Bool dont_wait) +{ +#ifdef DEBUG + fprintf(stderr, "%s: raising window 0x%08lX (%s)\n", + progname, (unsigned long) window, + (dont_wait ? "not waiting" : "waiting")); +#endif /* DEBUG */ + + if (! dont_wait) + { + XWindowAttributes xgwa; + XSizeHints hints; + long supplied = 0; + memset(&hints, 0, sizeof(hints)); + XGetWMNormalHints(dpy, window, &hints, &supplied); + XGetWindowAttributes (dpy, window, &xgwa); + hints.x = xgwa.x; + hints.y = xgwa.y; + hints.width = xgwa.width; + hints.height = xgwa.height; + hints.flags |= (PPosition|USPosition|PSize|USSize); + XSetWMNormalHints(dpy, window, &hints); + } + + XMapRaised(dpy, window); + + if (! dont_wait) + { + XEvent event; + XIfEvent (dpy, &event, MapNotify_event_p, (XPointer) window); + XSync (dpy, True); + } +} + + +static Bool +xscreensaver_window_p (Display *dpy, Window window) +{ + Atom type; + int format; + unsigned long nitems, bytesafter; + char *version; + if (XGetWindowProperty (dpy, window, + XInternAtom (dpy, "_SCREENSAVER_VERSION", False), + 0, 1, False, XA_STRING, + &type, &format, &nitems, &bytesafter, + (unsigned char **) &version) + == Success + && type != None) + return True; + return False; +} + + + +static XErrorHandler old_ehandler = 0; +static int +BadWindow_ehandler (Display *dpy, XErrorEvent *error) +{ + if (error->error_code == BadWindow || error->error_code == BadDrawable) + return 0; + else if (!old_ehandler) + abort(); + else + return (*old_ehandler) (dpy, error); +} + + +/* XCopyArea seems not to work right on SGI O2s if you draw in SubwindowMode + on a window whose depth is not the maximal depth of the screen? Or + something. Anyway, things don't work unless we: use SubwindowMode for + the real root window (or a legitimate virtual root window); but do not + use SubwindowMode for the xscreensaver window. I make no attempt to + explain. + */ +Bool +use_subwindow_mode_p(Screen *screen, Window window) +{ + if (window != VirtualRootWindowOfScreen(screen)) + return False; + else if (xscreensaver_window_p(DisplayOfScreen(screen), window)) + return False; + else + return True; +} + + +/* Install the colormaps of all visible windows, deepest first. + This should leave the colormaps of the topmost windows installed + (if only N colormaps can be installed at a time, then only the + topmost N windows will be shown in the right colors.) + */ +static void +install_screen_colormaps (Screen *screen) +{ + int i; + Display *dpy = DisplayOfScreen (screen); + Window vroot, real_root; + Window parent, *kids = 0; + unsigned int nkids = 0; + + XSync (dpy, False); + old_ehandler = XSetErrorHandler (BadWindow_ehandler); + + vroot = VirtualRootWindowOfScreen (screen); + if (XQueryTree (dpy, vroot, &real_root, &parent, &kids, &nkids)) + for (i = 0; i < nkids; i++) + { + XWindowAttributes xgwa; + Window client; +#ifdef HAVE_XMU + /* #### need to put XmuClientWindow() in xmu.c, sigh... */ + if (! (client = XmuClientWindow (dpy, kids[i]))) +#endif + client = kids[i]; + xgwa.colormap = 0; + XGetWindowAttributes (dpy, client, &xgwa); + if (xgwa.colormap && xgwa.map_state == IsViewable) + XInstallColormap (dpy, xgwa.colormap); + } + XInstallColormap (dpy, DefaultColormapOfScreen (screen)); + XSync (dpy, False); + XSetErrorHandler (old_ehandler); + XSync (dpy, False); + + if (kids) + XFree ((char *) kids); +} + + +static void +grab_screen_image_1 (Screen *screen, Window window) +{ + Display *dpy = DisplayOfScreen (screen); + XWindowAttributes xgwa; + Window real_root = XRootWindowOfScreen (screen); /* not vroot */ + Bool root_p = (window == real_root); + Bool saver_p = xscreensaver_window_p (dpy, window); + Bool grab_mouse_p = False; + int unmap_time = 0; + + if (saver_p) + /* I think this is redundant, but just to be safe... */ + root_p = False; + + if (saver_p) + /* The only time grabbing the mouse is important is if this program + is being run while the saver is locking the screen. */ + grab_mouse_p = True; + + if (!root_p) + { + double unmap = 0; + if (saver_p) + { + unmap = get_float_resource("grabRootDelay", "Seconds"); + if (unmap <= 0.00001 || unmap > 20) unmap = 2.5; + } + else + { + unmap = get_float_resource("grabWindowDelay", "Seconds"); + if (unmap <= 0.00001 || unmap > 20) unmap = 0.66; + } + unmap_time = unmap * 100000; + } + +#ifdef DEBUG + fprintf(stderr, + "\n%s: window 0x%08lX root: %d saver: %d grab: %d wait: %.1f\n", + progname, (unsigned long) window, + root_p, saver_p, grab_mouse_p, ((double)unmap_time)/1000000.0); + { + XWindowAttributes xgwa2; + XGetWindowAttributes (dpy, window, &xgwa2); + fprintf(stderr, "%s: ", progname); + describe_visual(stderr, screen, xgwa2.visual); + } +#endif /* DEBUG */ + + if (!root_p) + XSetWindowBackgroundPixmap (dpy, window, None); + + if (grab_mouse_p) + { + /* prevent random viewer of the screen saver (locker) from messing + with windows. We don't check whether it succeeded, because what + are our options, really... */ + XGrabPointer (dpy, real_root, True, ButtonPressMask|ButtonReleaseMask, + GrabModeAsync, GrabModeAsync, None, None, CurrentTime); + XGrabKeyboard (dpy, real_root, True, GrabModeSync, GrabModeAsync, + CurrentTime); + } + + if (unmap_time > 0) + { + XUnmapWindow (dpy, window); + install_screen_colormaps (screen); + XSync (dpy, True); + usleep(unmap_time); /* wait for everyone to swap in and handle exposes */ + } + + XGetWindowAttributes (dpy, window, &xgwa); + + if (!root_p) + { +#ifdef HAVE_READ_DISPLAY_EXTENSION + if (! read_display(screen, window, 0, saver_p)) +#endif /* HAVE_READ_DISPLAY_EXTENSION */ + { +#if defined(HAVE_READ_DISPLAY_EXTENSION) && defined(DEBUG) + fprintf(stderr, "%s: read_display() failed\n", progname); +#endif /* DEBUG */ + copy_default_colormap_contents (screen, xgwa.colormap, xgwa.visual); + raise_window(dpy, window, saver_p); + } + } + else /* root_p */ + { + Pixmap pixmap; + XWindowAttributes xgwa; + XGetWindowAttributes(dpy, window, &xgwa); + pixmap = XCreatePixmap(dpy, window, xgwa.width, xgwa.height, xgwa.depth); + +#ifdef HAVE_READ_DISPLAY_EXTENSION + if (! read_display(screen, window, pixmap, True)) +#endif + { + Window real_root = XRootWindowOfScreen (xgwa.screen); /* not vroot */ + XGCValues gcv; + GC gc; + +#if defined(HAVE_READ_DISPLAY_EXTENSION) && defined(DEBUG) + fprintf(stderr, "%s: read_display() failed\n", progname); +#endif /* DEBUG */ + + copy_default_colormap_contents (screen, xgwa.colormap, xgwa.visual); + + gcv.function = GXcopy; + gcv.subwindow_mode = IncludeInferiors; + gc = XCreateGC (dpy, window, GCFunction | GCSubwindowMode, &gcv); + XCopyArea (dpy, real_root, pixmap, gc, + xgwa.x, xgwa.y, xgwa.width, xgwa.height, 0, 0); + XFreeGC (dpy, gc); + } + XSetWindowBackgroundPixmap (dpy, window, pixmap); + XFreePixmap (dpy, pixmap); + } + + if (grab_mouse_p) + { + XUngrabPointer (dpy, CurrentTime); + XUngrabKeyboard (dpy, CurrentTime); + } + + XSync (dpy, True); +} + +void +grab_screen_image (Screen *screen, Window window) +{ +#ifdef HAVE_SGI_VIDEO + char c, *s = get_string_resource("grabVideoProbability", "Float"); + double prob = -1; + if (!s || + (1 != sscanf (s, " %lf %c", &prob, &c)) || + prob < 0 || + prob > 1) + prob = 0.5; + + if ((random() % 100) < ((int) (100 * prob))) + { + XWindowAttributes xgwa; + Display *dpy = DisplayOfScreen (screen); + XGetWindowAttributes (dpy, window, &xgwa); +# ifdef DEBUG + fprintf(stderr, "%s: trying to grab from video...\n", progname); +# endif /* DEBUG */ + if (grab_video_frame (screen, xgwa.visual, window)) + { + if (xgwa.depth < 24) + { + int class = visual_class (screen, xgwa.visual); + if (class == PseudoColor || class == DirectColor) + make_cubic_colormap (screen, window, xgwa.visual); + } + return; + } + } +#endif /* HAVE_SGI_VIDEO */ + + grab_screen_image_1 (screen, window); +} + + +/* When we are grabbing and manipulating a screen image, it's important that + we use the same colormap it originally had. So, if the screensaver was + started with -install, we need to copy the contents of the default colormap + into the screensaver's colormap. + */ +static void +copy_default_colormap_contents (Screen *screen, + Colormap to_cmap, + Visual *to_visual) +{ + Display *dpy = DisplayOfScreen (screen); + Visual *from_visual = DefaultVisualOfScreen (screen); + Colormap from_cmap = XDefaultColormapOfScreen (screen); + + XColor *old_colors, *new_colors; + unsigned long *pixels; + XVisualInfo vi_in, *vi_out; + int out_count; + int from_cells, to_cells, max_cells, got_cells; + int i; + + if (from_cmap == to_cmap) + return; + + vi_in.screen = XScreenNumberOfScreen (screen); + vi_in.visualid = XVisualIDFromVisual (from_visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + from_cells = vi_out [0].colormap_size; + XFree ((char *) vi_out); + + vi_in.screen = XScreenNumberOfScreen (screen); + vi_in.visualid = XVisualIDFromVisual (to_visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + to_cells = vi_out [0].colormap_size; + XFree ((char *) vi_out); + + max_cells = (from_cells > to_cells ? to_cells : from_cells); + + old_colors = (XColor *) calloc (sizeof (XColor), max_cells); + new_colors = (XColor *) calloc (sizeof (XColor), max_cells); + pixels = (unsigned long *) calloc (sizeof (unsigned long), max_cells); + for (i = 0; i < max_cells; i++) + old_colors[i].pixel = i; + XQueryColors (dpy, from_cmap, old_colors, max_cells); + + got_cells = max_cells; + allocate_writable_colors (dpy, to_cmap, pixels, &got_cells); + +#ifdef DEBUG + if (got_cells != max_cells) + fprintf(stderr, "%s: got only %d of %d cells\n", progname, + got_cells, max_cells); +#endif /* DEBUG */ + + if (got_cells <= 0) /* we're screwed */ + ; + else if (got_cells == max_cells && /* we're golden */ + from_cells == to_cells) + XStoreColors (dpy, to_cmap, old_colors, got_cells); + else /* try to cope... */ + { + for (i = 0; i < got_cells; i++) + { + XColor *c = old_colors + i; + int j; + for (j = 0; j < got_cells; j++) + if (pixels[j] == c->pixel) + { + /* only store this color value if this is one of the pixels + we were able to allocate. */ + XStoreColors (dpy, to_cmap, c, 1); + break; + } + } + } + + +#ifdef DEBUG + fprintf(stderr, "%s: installing copy of default colormap\n", progname); +#endif /* DEBUG */ + + free (old_colors); + free (new_colors); + free (pixels); +} + + + +/* The SGI ReadDisplay extension. + This extension lets you get back a 24-bit image of the screen, taking into + account the colors with which all windows are *currently* displayed, even + if those windows have different visuals. Without this extension, presence + of windows with different visuals or colormaps will result in technicolor + when one tries to grab the screen image. + */ + +#ifdef HAVE_READ_DISPLAY_EXTENSION + +static Bool +read_display (Screen *screen, Window window, Pixmap into_pixmap, + Bool dont_wait) +{ + Display *dpy = DisplayOfScreen (screen); + XWindowAttributes xgwa; + int rd_event_base = 0; + int rd_error_base = 0; + unsigned long hints = 0; + XImage *image = 0; + XGCValues gcv; + int class; + GC gc; + Bool install_p = False; + + /* Check to see if the server supports the extension, and bug out if not. + */ + if (! XReadDisplayQueryExtension (dpy, &rd_event_base, &rd_error_base)) + return False; + + /* If this isn't a visual we know how to handle, bug out. We handle: + = TrueColor in depths 8, 12, 16, and 32; + = PseudoColor and DirectColor in depths 8 and 12. + */ + XGetWindowAttributes(dpy, window, &xgwa); + class = visual_class (screen, xgwa.visual); + if (class == TrueColor) + { + if (xgwa.depth != 8 && xgwa.depth != 12 && xgwa.depth != 16 && + xgwa.depth != 24 && xgwa.depth != 32) + return False; + } + else if (class == PseudoColor || class == DirectColor) + { + if (xgwa.depth != 8 && xgwa.depth != 12) + return False; + else + /* Install a colormap that makes this visual behave like + a TrueColor visual of the same depth. */ + install_p = True; + } + + + /* Try and read the screen. + */ + hints = (XRD_TRANSPARENT | XRD_READ_POINTER); + image = XReadDisplay (dpy, window, xgwa.x, xgwa.y, xgwa.width, xgwa.height, + hints, &hints); + if (!image) + return False; + if (!image->data) + { + XDestroyImage(image); + return False; + } + + /* XReadDisplay tends to LIE about the depth of the image it read. + It is returning an XImage which has `depth' and `bits_per_pixel' + confused! + + That is, on a 24-bit display, where all visuals claim depth 24, and + where XGetImage would return an XImage with depth 24, and where + XPutImage will get a BadMatch with images that are not depth 24, + XReadDisplay is returning images with depth 32! Fuckwits! + + So if the visual is of depth 24, but the image came back as depth 32, + hack it to be 24 lest we get a BadMatch from XPutImage. + + I wonder what happens on an 8-bit SGI... Probably it still returns + an image claiming depth 32? Certainly it can't be 8. So, let's just + smash it to 32... + */ + if (image->depth == 32 /* && xgwa.depth == 24 */ ) + image->depth = 24; + + /* If the visual of the window/pixmap into which we're going to draw is + less deep than the screen itself, then we need to convert the grabbed bits + to match the depth by clipping off the less significant bit-planes of each + color component. + */ + if (image->depth > xgwa.depth) + { + int x, y; + /* We use the same image->data in both images -- that's ok, because + since we're reading from B and writing to A, and B uses more bytes + per pixel than A, the write pointer won't overrun the read pointer. + */ + XImage *image2 = XCreateImage (dpy, xgwa.visual, xgwa.depth, + ZPixmap, 0, image->data, + xgwa.width, xgwa.height, + 8, 0); + if (!image2) + return False; + +#ifdef DEBUG + fprintf(stderr, "%s: converting from depth %d to depth %d\n", + progname, image->depth, xgwa.depth); +#endif /* DEBUG */ + + for (y = 0; y < image->height; y++) + for (x = 0; x < image->width; x++) + { + /* #### really these shift values should be determined from the + mask values -- but that's a pain in the ass, and anyway, + this is an SGI-specific extension so hardcoding assumptions + about the SGI server's behavior isn't *too* heinous... */ + unsigned long pixel = XGetPixel(image, x, y); + unsigned int r = (pixel & image->red_mask); + unsigned int g = (pixel & image->green_mask) >> 8; + unsigned int b = (pixel & image->blue_mask) >> 16; + + if (xgwa.depth == 8) + pixel = ((r >> 5) | ((g >> 5) << 3) | ((b >> 6) << 6)); + else if (xgwa.depth == 12) + pixel = ((r >> 4) | ((g >> 4) << 4) | ((b >> 4) << 8)); + else if (xgwa.depth == 16) + pixel = ((r >> 3) | ((g >> 3) << 5) | ((b >> 3) << 10)); + else + abort(); + + XPutPixel(image2, x, y, pixel); + } + image->data = 0; + XDestroyImage(image); + image = image2; + } + + + /* Now actually put the bits into the window or pixmap -- note the design + bogosity of this extension, where we've been forced to take 24 bit data + from the server to the client, and then push it back from the client to + the server, *without alteration*. We should have just been able to tell + the server, "put a screen image in this drawable", instead of having to + go through the intermediate step of converting it to an Image. Geez. + (Assuming that the window is of screen depth; we happen to handle less + deep windows, but that's beside the point.) + */ + gcv.function = GXcopy; + gc = XCreateGC (dpy, window, GCFunction, &gcv); + + if (into_pixmap) + { + gcv.function = GXcopy; + gc = XCreateGC (dpy, into_pixmap, GCFunction, &gcv); + XPutImage (dpy, into_pixmap, gc, image, 0, 0, 0, 0, + xgwa.width, xgwa.height); + } + else + { + gcv.function = GXcopy; + gc = XCreateGC (dpy, window, GCFunction, &gcv); + + /* Ok, now we'll be needing that window on the screen... */ + raise_window(dpy, window, dont_wait); + + /* Plop down the bits... */ + XPutImage (dpy, window, gc, image, 0, 0, 0, 0, xgwa.width, xgwa.height); + } + XFreeGC (dpy, gc); + + if (image->data) + { + free(image->data); + image->data = 0; + } + XDestroyImage(image); + + if (install_p) + make_cubic_colormap (screen, window, xgwa.visual); + + return True; +} +#endif /* HAVE_READ_DISPLAY_EXTENSION */ + + +#if defined(HAVE_READ_DISPLAY_EXTENSION) || defined(HAVE_SGI_VIDEO) + +/* Makes and installs a colormap that makes a PseudoColor or DirectColor + visual behave like a TrueColor visual of the same depth. + */ +static void +make_cubic_colormap (Screen *screen, Window window, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + Colormap cmap = XCreateColormap(dpy, window, visual, AllocAll); + int nr, ng, nb, cells; + int r, g, b; + int depth; + XColor colors[4097]; + int i; + + depth = visual_depth(screen, visual); + switch (depth) + { + case 8: nr = 3; ng = 3; nb = 2; cells = 256; break; + case 12: nr = 4; ng = 4; nb = 4; cells = 4096; break; + default: abort(); break; + } + + memset(colors, 0, sizeof(colors)); + for (i = 0; i < cells; i++) + { + colors[i].flags = DoRed|DoGreen|DoBlue; + colors[i].red = colors[i].green = colors[i].blue = 0; + } + + for (r = 0; r < (1 << nr); r++) + for (g = 0; g < (1 << ng); g++) + for (b = 0; b < (1 << nb); b++) + { + i = (r | (g << nr) | (b << (nr + ng))); + colors[i].pixel = i; + if (depth == 8) + { + colors[i].red = ((r << 13) | (r << 10) | (r << 7) | + (r << 4) | (r << 1)); + colors[i].green = ((g << 13) | (g << 10) | (g << 7) | + (g << 4) | (g << 1)); + colors[i].blue = ((b << 14) | (b << 12) | (b << 10) | + (b << 8) | (b << 6) | (b << 4) | + (b << 2) | b); + } + else + { + colors[i].red = (r << 12) | (r << 8) | (r << 4) | r; + colors[i].green = (g << 12) | (g << 8) | (g << 4) | g; + colors[i].blue = (b << 12) | (b << 8) | (b << 4) | b; + } + } + +#ifdef DEBUG + fprintf(stderr, "%s: installing cubic colormap\n", progname); +#endif /* DEBUG */ + + XStoreColors (dpy, cmap, colors, cells); + XSetWindowColormap (dpy, window, cmap); + + /* Gag, install the colormap. + This is definitely right in the `if xscreensaver_window_p' case, since + it will never get installed otherwise. But, if we don't do it + unconditionally, then the new colormap won't get installed until the + window (re-)gains focus. It's generally very antisocial to install + the colormap of a non-OverrideRedirect window (that task belongs to + the WM) and if we were being kosher, we would only install this cmap + if the old cmap was already installed (or perhaps, if the window had + focus.) But, since this extension only exists on SGIs, and since SGIs + can handle four colormaps at once, let's go ahead and install it all + the time, so that even if the window pops up and has never had focus, + it will still display in the proper colors. + */ + XInstallColormap (dpy, cmap); +} + +#endif /* HAVE_READ_DISPLAY_EXTENSION || HAVE_SGI_VIDEO */ diff --git a/utils/grabscreen.h b/utils/grabscreen.h new file mode 100644 index 00000000..9c70eab8 --- /dev/null +++ b/utils/grabscreen.h @@ -0,0 +1,27 @@ +/* xscreensaver, Copyright (c) 1992, 1993, 1994, 1997 + * 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. + */ + +#ifndef __GRABSCREEN_H__ +#define __GRABSCREEN_H__ + +/* This will write a snapshot of the screen image into the given window. + Beware that the colormap of the window may also be changed (to match + the bits that were drawn.) + */ +extern void grab_screen_image (Screen *, Window); + +/* Whether one should use GCSubwindowMode when drawing on this window + (assuming a screen image has been grabbed onto it.) Yes, this is a + total kludge. */ +extern Bool use_subwindow_mode_p(Screen *screen, Window window); + +#endif /* __GRABSCREEN_H__ */ diff --git a/utils/hsv.c b/utils/hsv.c new file mode 100644 index 00000000..027657c8 --- /dev/null +++ b/utils/hsv.c @@ -0,0 +1,81 @@ +/* xscreensaver, Copyright (c) 1992, 1997 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. + */ + +/* This file contains some utility routines for randomly picking the colors + to hack the screen with. + */ + +#include "utils.h" +#include "hsv.h" + +void +hsv_to_rgb (int h, double s, double v, + unsigned short *r, unsigned short *g, unsigned short *b) +{ + double H, S, V, R, G, B; + double p1, p2, p3; + double f; + int i; + + if (s < 0) s = 0; + if (v < 0) v = 0; + if (s > 1) s = 1; + if (v > 1) v = 1; + + S = s; V = v; + H = (h % 360) / 60.0; + i = H; + f = H - i; + p1 = V * (1 - S); + p2 = V * (1 - (S * f)); + p3 = V * (1 - (S * (1 - f))); + if (i == 0) { R = V; G = p3; B = p1; } + else if (i == 1) { R = p2; G = V; B = p1; } + else if (i == 2) { R = p1; G = V; B = p3; } + else if (i == 3) { R = p1; G = p2; B = V; } + else if (i == 4) { R = p3; G = p1; B = V; } + else { R = V; G = p1; B = p2; } + *r = R * 65535; + *g = G * 65535; + *b = B * 65535; +} + +void +rgb_to_hsv (unsigned short r, unsigned short g, unsigned short b, + int *h, double *s, double *v) +{ + double R, G, B, H, S, V; + double cmax, cmin; + double cmm; + int imax; + R = ((double) r) / 65535.0; + G = ((double) g) / 65535.0; + B = ((double) b) / 65535.0; + cmax = R; cmin = G; imax = 1; + if ( cmax < G ) { cmax = G; cmin = R; imax = 2; } + if ( cmax < B ) { cmax = B; imax = 3; } + if ( cmin > B ) { cmin = B; } + cmm = cmax - cmin; + V = cmax; + if (cmm == 0) + S = H = 0; + else + { + S = cmm / cmax; + if (imax == 1) H = (G - B) / cmm; + else if (imax == 2) H = 2.0 + (B - R) / cmm; + else /*if (imax == 3)*/ H = 4.0 + (R - G) / cmm; + if (H < 0) H += 6.0; + } + *h = (H * 60.0); + *s = S; + *v = V; +} diff --git a/utils/hsv.h b/utils/hsv.h new file mode 100644 index 00000000..6d9578a1 --- /dev/null +++ b/utils/hsv.h @@ -0,0 +1,27 @@ +/* xscreensaver, Copyright (c) 1992, 1997 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. + */ + +#ifndef __HSV_H__ +#define __HSV_H__ + +/* Converts between RGB and HSV color spaces. + R, G, and B are in the range 0 - 65535; + H is in the range 0 - 360; + S and V are in the range 0.0 - 1.0. + */ +extern void hsv_to_rgb (int h, double s, double v, + unsigned short *r, + unsigned short *g, + unsigned short *b); +extern void rgb_to_hsv (unsigned short r, unsigned short g, unsigned short b, + int *h, double *s, double *v); + +#endif /* __HSV_H__ */ diff --git a/utils/overlay.c b/utils/overlay.c new file mode 100644 index 00000000..0d82419b --- /dev/null +++ b/utils/overlay.c @@ -0,0 +1,126 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +/* If the server's root window contains a SERVER_OVERLAY_VISUALS property, + then that identifies the visuals which correspond to the video hardware's + overlay planes. Windows created in these kinds of visuals have the + property that one particular pixel value is transparent. + + On my Indy, there are two transparent visuals, one of which is at layer 1, + and one of which is at layer 2. This is apparently the ordering in which + they are overlayed (1 being topmost.) The other difference between them + is that the topmost one only has 2 planes, while the next one has 8. + + Rumor has it that SGI, HP, DEC, and IBM all use the same mechanism. + + This code selects the topmost one, regardless of depth. Maybe that's not + the right thing. Well, in XScreenSaver, we only need to allocate two + colors from it (it's only used to display the stderr output, so that the + text can overlay the graphics without being obliterated by it.) + */ + + +#include "utils.h" + +#include +#include + +#include "visual.h" + + +struct overlay_data +{ + CARD32 visual_id; + CARD32 transparency; /* 0: none; 1: pixel; 2: mask (?) */ + CARD32 value; /* the transparent pixel */ + CARD32 layer; /* -1: underlay; 0: normal; 1: popup; 2: overlay */ +}; + +static int +get_overlay_prop (Screen *screen, struct overlay_data **data_ret) +{ + int result; + Atom actual_type; + int actual_format; + unsigned long nitems, bytes_after; + struct overlay_data *data = 0; + Display *dpy = DisplayOfScreen(screen); + Window window = RootWindowOfScreen(screen); + Atom XA_SERVER_OVERLAY_VISUALS = + XInternAtom (dpy, "SERVER_OVERLAY_VISUALS", False); + + *data_ret = 0; + result = XGetWindowProperty (dpy, window, XA_SERVER_OVERLAY_VISUALS, + 0, (65536 / sizeof (long)), False, + XA_SERVER_OVERLAY_VISUALS, + &actual_type, &actual_format, + &nitems, &bytes_after, + (unsigned char **) &data); + if (result != Success || + actual_type != XA_SERVER_OVERLAY_VISUALS || + actual_format != 32 || + nitems < 1) + { + if (data) XFree(data); + return 0; + } + else + { + *data_ret = data; + return nitems / (sizeof(*data) / sizeof(CARD32)); + } +} + + +Visual * +get_overlay_visual (Screen *screen, unsigned long *transparent_pixel_ret) +{ + struct overlay_data *data = 0; + int n_visuals = get_overlay_prop (screen, &data); + Visual *visual = 0; + int depth = 0; + unsigned long pixel = 0; + unsigned int layer = 0; + int i; + + if (data) + for (i = 0; i < n_visuals; i++) + + /* Only accept ones that have a transparent pixel. */ + if (data[i].transparency == 1) + { + XVisualInfo vi_in, *vi_out; + int out_count; + vi_in.visualid = data[i].visual_id; + vi_out = XGetVisualInfo (DisplayOfScreen(screen), VisualIDMask, + &vi_in, &out_count); + if (vi_out) + { + /* Prefer the one at the topmost layer; after that, prefer + the one with the greatest depth (most colors.) */ + if (layer < data[i].layer || + (layer == data[i].layer && + depth < vi_out[0].depth)) + { + visual = vi_out[0].visual; + depth = vi_out[0].depth; + layer = data[i].layer; + pixel = data[i].value; + } + XFree(vi_out); + } + } + + if (data) XFree(data); + if (visual && transparent_pixel_ret) + *transparent_pixel_ret = pixel; + return visual; +} diff --git a/utils/resources.c b/utils/resources.c new file mode 100644 index 00000000..d13fb820 --- /dev/null +++ b/utils/resources.c @@ -0,0 +1,214 @@ +/* xscreensaver, Copyright (c) 1992, 1997, 1998 + * 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. + */ + +#include "utils.h" +#include "resources.h" +#include + + +/* Resource functions. Assumes: */ + +extern char *progname; +extern char *progclass; +extern XrmDatabase db; + +static unsigned int get_time_resource (char *res_name, char *res_class, + Bool sec_p); + +#ifndef isupper +# define isupper(c) ((c) >= 'A' && (c) <= 'Z') +#endif +#ifndef _tolower +# define _tolower(c) ((c) - 'A' + 'a') +#endif + +char * +get_string_resource (char *res_name, char *res_class) +{ + XrmValue value; + char *type; + char full_name [1024], full_class [1024]; + strcpy (full_name, progname); + strcat (full_name, "."); + strcat (full_name, res_name); + strcpy (full_class, progclass); + strcat (full_class, "."); + strcat (full_class, res_class); + if (XrmGetResource (db, full_name, full_class, &type, &value)) + { + char *str = (char *) malloc (value.size + 1); + strncpy (str, (char *) value.addr, value.size); + str [value.size] = 0; + return str; + } + return 0; +} + +Bool +get_boolean_resource (char *res_name, char *res_class) +{ + char *tmp, buf [100]; + char *s = get_string_resource (res_name, res_class); + char *os = s; + if (! s) return 0; + for (tmp = buf; *s; s++) + *tmp++ = isupper (*s) ? _tolower (*s) : *s; + *tmp = 0; + free (os); + + while (*buf && + (buf[strlen(buf)-1] == ' ' || + buf[strlen(buf)-1] == '\t')) + buf[strlen(buf)-1] = 0; + + if (!strcmp (buf, "on") || !strcmp (buf, "true") || !strcmp (buf, "yes")) + return 1; + if (!strcmp (buf,"off") || !strcmp (buf, "false") || !strcmp (buf,"no")) + return 0; + fprintf (stderr, "%s: %s must be boolean, not %s.\n", + progname, res_class, buf); + return 0; +} + +int +get_integer_resource (char *res_name, char *res_class) +{ + int val; + char c, *s = get_string_resource (res_name, res_class); + if (!s) return 0; + if (1 == sscanf (s, " %d %c", &val, &c)) + { + free (s); + return val; + } + fprintf (stderr, "%s: %s must be an integer, not %s.\n", + progname, res_name, s); + free (s); + return 0; +} + +double +get_float_resource (char *res_name, char *res_class) +{ + double val; + char c, *s = get_string_resource (res_name, res_class); + if (! s) return 0.0; + if (1 == sscanf (s, " %lf %c", &val, &c)) + { + free (s); + return val; + } + fprintf (stderr, "%s: %s must be a float, not %s.\n", + progname, res_name, s); + free (s); + return 0.0; +} + + +unsigned int +get_pixel_resource (char *res_name, char *res_class, + Display *dpy, Colormap cmap) +{ + XColor color; + char *s = get_string_resource (res_name, res_class); + char *s2; + if (!s) goto DEFAULT; + + for (s2 = s + strlen(s) - 1; s2 > s; s2--) + if (*s2 == ' ' || *s2 == '\t') + *s2 = 0; + else + break; + + if (! XParseColor (dpy, cmap, s, &color)) + { + fprintf (stderr, "%s: can't parse color %s\n", progname, s); + goto DEFAULT; + } + if (! XAllocColor (dpy, cmap, &color)) + { + fprintf (stderr, "%s: couldn't allocate color %s\n", progname, s); + goto DEFAULT; + } + free (s); + return color.pixel; + DEFAULT: + if (s) free (s); + return (strcmp (res_class, "Background") + ? WhitePixel (dpy, DefaultScreen (dpy)) + : BlackPixel (dpy, DefaultScreen (dpy))); +} + + +int +parse_time (char *string, Bool seconds_default_p, Bool silent_p) +{ + unsigned int h, m, s; + char c; + if (3 == sscanf (string, " %u : %2u : %2u %c", &h, &m, &s, &c)) + ; + else if (2 == sscanf (string, " : %2u : %2u %c", &m, &s, &c) || + 2 == sscanf (string, " %u : %2u %c", &m, &s, &c)) + h = 0; + else if (1 == sscanf (string, " : %2u %c", &s, &c)) + h = m = 0; + else if (1 == sscanf (string, " %u %c", + (seconds_default_p ? &s : &m), &c)) + { + h = 0; + if (seconds_default_p) m = 0; + else s = 0; + } + else + { + if (! silent_p) + fprintf (stderr, "%s: invalid time interval specification \"%s\".\n", + progname, string); + return -1; + } + if (s >= 60 && (h != 0 || m != 0)) + { + if (! silent_p) + fprintf (stderr, "%s: seconds > 59 in \"%s\".\n", progname, string); + return -1; + } + if (m >= 60 && h > 0) + { + if (! silent_p) + fprintf (stderr, "%s: minutes > 59 in \"%s\".\n", progname, string); + return -1; + } + return ((h * 60 * 60) + (m * 60) + s); +} + +static unsigned int +get_time_resource (char *res_name, char *res_class, Bool sec_p) +{ + int val; + char *s = get_string_resource (res_name, res_class); + if (!s) return 0; + val = parse_time (s, sec_p, False); + free (s); + return (val < 0 ? 0 : val); +} + +unsigned int +get_seconds_resource (char *res_name, char *res_class) +{ + return get_time_resource (res_name, res_class, True); +} + +unsigned int +get_minutes_resource (char *res_name, char *res_class) +{ + return get_time_resource (res_name, res_class, False); +} diff --git a/utils/resources.h b/utils/resources.h new file mode 100644 index 00000000..6179565e --- /dev/null +++ b/utils/resources.h @@ -0,0 +1,24 @@ +/* xscreensaver, Copyright (c) 1992, 1997 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. + */ + +#ifndef __XSCREENSAVER_RESOURCES_H__ +#define __XSCREENSAVER_RESOURCES_H__ + +extern char *get_string_resource (char*,char*); +extern Bool get_boolean_resource (char*,char*); +extern int get_integer_resource (char*,char*); +extern double get_float_resource (char*,char*); +extern unsigned int get_pixel_resource (char*,char*,Display*,Colormap); +extern unsigned int get_minutes_resource (char*,char*); +extern unsigned int get_seconds_resource (char*,char*); +extern int parse_time (char *string, Bool seconds_default_p, Bool silent_p); + +#endif /* __XSCREENSAVER_RESOURCES_H__ */ diff --git a/utils/sgivideo.c b/utils/sgivideo.c new file mode 100644 index 00000000..13fb7a3c --- /dev/null +++ b/utils/sgivideo.c @@ -0,0 +1,502 @@ +/* xscreensaver, Copyright (c) 1997, 1998 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. + */ + +/* This file contains code for grabbing a frame from one of the video inputs + on an SGI. It returns it on a Drawable where it can be hacked at will. + This code checks all available video devices for the first one with a + non-blank signal. + + It checks the deviced whose number comes from the `videoDevice' resource + first, then the default video device, then all the devices in order. + + The intensity of the video signal is increased by the value of the + `videoGain' resource (a float) defaulting to 2.2, since NTSC video tends + to appear kind of dim on computer screens. + + The video image is expanded to fit the window (while preserving the aspect + ratio.) This is done by simply replicating pixels, not dithering. That + turns out to look good enough most of the time. + + If the target window is not TrueColor, the grabbed image will be quantized + to fit. This also is done without dithering, but in this case, dithering + would help a lot, because it looks like crap. So use TrueColor if you care. + */ + +#include "utils.h" +#include "sgivideo.h" +#include "resources.h" +#include "visual.h" + +#ifdef HAVE_SGI_VIDEO /* whole file */ + +#include "usleep.h" + +#include + +#ifdef DEBUG +extern char *progname; +#endif /* DEBUG */ + + +# include + +static Bool dark_image_p(unsigned long *image, int width, int height); +static Bool install_video_frame(unsigned long *image, int width, int height, + Screen *screen, Visual *visual, Drawable dest); + +#ifdef DEBUG +static void +describe_input(const char *prefix, VLServer server, int camera) +{ + VLDevList dl; + int i, j; + + if (camera == VL_ANY) + { + printf("%s: %s VL_ANY\n", progname, prefix); + return; + } + + vlGetDeviceList(server, &dl); + for (i = 0; i < dl.numDevices; i++) + { + VLDevice *d = &dl.devices[i]; + for (j = 0; j < d->numNodes; j++) + if (d->nodes[j].number == camera) + { + printf("%s: %s %d, \"%s\"\n", progname, prefix, + d->nodes[j].number, + d->nodes[j].name); + return; + } + } + + /* else... */ + printf("%s: %s %d (???)\n", progname, prefix, camera); +} +#endif /* DEBUG */ + + +static Bool +grab_frame_1(Screen *screen, Visual *visual, Drawable dest, int camera) +{ + Bool status = False; + int width = 0; + int height = 0; + VLServer server = 0; + VLNode input = -1; + VLNode output = -1; + VLPath path = 0; + VLBuffer buffer = 0; + VLControlValue ctl; + VLInfoPtr info; + VLTransferDescriptor trans; + unsigned long *image = 0; + + server = vlOpenVideo (NULL); + if (!server) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to open video server\n", progname); +#endif /* DEBUG */ + goto DONE; + } + +#ifdef DEBUG + describe_input("trying device", server, camera); +#endif /* DEBUG */ + + input = vlGetNode (server, VL_SRC, VL_VIDEO, camera); + output = vlGetNode (server, VL_DRN, VL_MEM, VL_ANY); + + if (input == -1 || output == -1) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to get video I/O nodes: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + path = vlCreatePath (server, VL_ANY, input, output); + if (path == -1) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to get video path: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + if (vlSetupPaths (server, (VLPathList) &path, 1, VL_SHARE, VL_SHARE) == -1) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to set up video path: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + ctl.intVal = VL_CAPTURE_INTERLEAVED; + if (vlSetControl (server, path, output, VL_CAP_TYPE, &ctl) == -1) + { +#ifdef DEBUG + fprintf (stderr, + "%s: unable to set video capture type to interleaved: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + ctl.intVal = VL_PACKING_RGBA_8; + if (vlSetControl (server, path, output, VL_PACKING, &ctl) == -1) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to set video packing to RGB8: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + buffer = vlCreateBuffer (server, path, output, 3); + if (!buffer) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to create video buffer: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + vlRegisterBuffer (server, path, output, buffer); + + memset(&trans, 0, sizeof(trans)); + trans.trigger = VLTriggerImmediate; + trans.mode = VL_TRANSFER_MODE_DISCRETE; + trans.delay = 0; + trans.count = 1; + if (vlBeginTransfer (server, path, 1, &trans) == -1) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to begin video transfer: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + + /* try to get a frame; don't try more than a zillion times. + I strongly suspect this isn't the best way to do this... + */ + { + int i; + for (i = 0; i < 1000; i++) + { + info = vlGetLatestValid (server, buffer); + if (info) break; + usleep(10000); /* 1/100th second (a bit more than half a field) */ + } + } + + if (!info) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to get video info: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + image = vlGetActiveRegion (server, buffer, info); + if (!image) + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to grab video frame: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + + if (vlGetControl (server, path, input, VL_SIZE, &ctl) != -1) + { + width = ctl.xyVal.x; + height = ctl.xyVal.y; + } + else + { +#ifdef DEBUG + fprintf (stderr, "%s: unable to get video image size: %d\n", + progname, vlErrno); +#endif /* DEBUG */ + goto DONE; + } + +#ifdef DEBUG + describe_input("read device", server, camera); +#endif /* DEBUG */ + + if (dark_image_p(image, width, height)) + goto DONE; + + status = install_video_frame(image, width, height, screen, visual, dest); + + DONE: + + /* I think `image' is freed as a result of destroying buffer. */ + + if (buffer) + vlDestroyBuffer(server, buffer); + if (path) + vlDestroyPath(server, path); + if (server) + vlCloseVideo (server); + + return status; +} + + +static Bool +dark_image_p(unsigned long *image, int width, int height) +{ + double max = 0.02; + double total = 0.0; + int i; + int pixels = (width * height); +#ifdef DEBUG + int mr = 0, mg = 0, mb = 0; +#endif /* DEBUG */ + for (i = pixels-1; i >= 0; i--) + { + unsigned long pixel = image[i]; + unsigned int r = (pixel & 0x0000FF); + unsigned int g = (pixel & 0x00FF00) >> 8; + unsigned int b = (pixel & 0xFF0000) >> 16; +#ifdef DEBUG + if (r > mr) mr = r; + if (g > mg) mg = g; + if (b > mb) mb = b; +#endif /* DEBUG */ + total += ((r * (0.3086 / 0xFF)) + /* gamma 1.0 intensity values */ + (g * (0.6094 / 0xFF)) + + (b * (0.0820 / 0xFF))); + } + total /= pixels; +#ifdef DEBUG + fprintf(stderr, "%s: %sdark %f (max rgb: %d %d %d)\n", progname, + (total < max ? "" : "not "), + total, mr, mg, mb); +#endif /* DEBUG */ + return (total < max); +} + + +Bool +grab_video_frame(Screen *screen, Visual *visual, Drawable dest) +{ + char *def_camera = get_string_resource("videoDevice", "Integer"); + if (def_camera && *def_camera) + { + int cam; + char c; + int ok = (1 == sscanf(def_camera, " %d %c", &cam, &c)); + free (def_camera); + if (ok && grab_frame_1(screen, visual, dest, cam)) + return True; + } + + if (grab_frame_1(screen, visual, dest, VL_ANY)) + return True; + else + { + int i; + VLServer server = vlOpenVideo (NULL); + for (i = 0; i < 5; i++) /* if we get all black images, retry up to + five times. */ + { + VLDevList dl; + int j; + vlGetDeviceList(server, &dl); + vlCloseVideo(server); + for (j = 0; j < dl.numDevices; j++) + { + VLDevice *d = &dl.devices[j]; + int k; + for (k = 0; k < d->numNodes; k++) + if (d->nodes[k].type == VL_SRC && + d->nodes[k].kind == VL_VIDEO) + if (grab_frame_1(screen, visual, dest, d->nodes[k].number)) + return True; + /* nothing yet? go around and try again... */ + } + } + } +#ifdef DEBUG + fprintf (stderr, "%s: images on all video feeds are too dark.\n", + progname); +#endif /* DEBUG */ + return False; +} + + +static Bool +install_video_frame(unsigned long *image, int width, int height, + Screen *screen, Visual *visual, Drawable dest) +{ + Display *dpy = DisplayOfScreen(screen); + int x, y; + unsigned int w, h, b, d; + Window root; + XGCValues gcv; + GC gc; + XImage *ximage = 0; + int image_depth; + Bool free_data = False; + int vblank_kludge = 3; /* lose the closed-captioning blips... */ + + double gain; + char c, *G = get_string_resource("videoGain", "Float"); + if (!G || (1 != sscanf (G, " %lf %c", &gain, &c))) + /* default to the usual NTSC gamma value. Is this the right thing to do? + (Yeah, "gain" isn't quite "gamma", but it's close enough...) */ + gain = 2.2; + if (G) free (G); + + XGetGeometry(dpy, dest, &root, &x, &y, &w, &h, &b, &d); + + gcv.function = GXcopy; + gcv.foreground = BlackPixelOfScreen(screen); + gc = XCreateGC (dpy, dest, GCFunction|GCForeground, &gcv); + + image_depth = visual_depth(screen, visual); + if (image_depth < 24) + image_depth = 24; /* We'll dither */ + + ximage = XCreateImage (dpy, visual, image_depth, ZPixmap, 0, (char *) image, + width, height, 8, 0); + XInitImage(ximage); + if (!ximage) + return False; + + if (gain > 0.0) /* Pump up the volume */ + { + unsigned char *end = (unsigned char *) (image + (width * height)); + unsigned char *s = (unsigned char *) image; + while (s < end) + { + unsigned int r = s[1] * gain; + unsigned int g = s[2] * gain; + unsigned int b = s[3] * gain; + s[1] = (r > 255 ? 255 : r); + s[2] = (g > 255 ? 255 : g); + s[3] = (b > 255 ? 255 : b); + s += 4; + } + } + + /* If the drawable is not of truecolor depth, we need to convert the + grabbed bits to match the depth by clipping off the less significant + bit-planes of each color component. + */ + if (d != 24 && d != 32) + { + int x, y; + /* We use the same ximage->data in both images -- that's ok, because + since we're reading from B and writing to A, and B uses more bytes + per pixel than A, the write pointer won't overrun the read pointer. + */ + XImage *ximage2 = XCreateImage (dpy, visual, d, ZPixmap, 0, + (char *) image, + width, height, 8, 0); + XInitImage(ximage2); + if (!ximage2) + { + XDestroyImage(ximage); + return False; + } + +#ifdef DEBUG + fprintf(stderr, "%s: converting from depth %d to depth %d\n", + progname, ximage->depth, ximage2->depth); +#endif /* DEBUG */ + + for (y = 0; y < ximage->height; y++) + for (x = 0; x < ximage->width; x++) + { + unsigned long pixel = XGetPixel(ximage, x, y); + unsigned int r = (pixel & 0x0000FF); + unsigned int g = (pixel & 0x00FF00) >> 8; + unsigned int b = (pixel & 0xFF0000) >> 16; + + if (d == 8) + pixel = ((r >> 5) | ((g >> 5) << 3) | ((b >> 6) << 6)); + else if (d == 12) + pixel = ((r >> 4) | ((g >> 4) << 4) | ((b >> 4) << 8)); + else if (d == 16) + pixel = ((r >> 3) | ((g >> 3) << 5) | ((b >> 3) << 10)); + else + abort(); + + XPutPixel(ximage2, x, y, pixel); + } + ximage->data = 0; + XDestroyImage(ximage); + ximage = ximage2; + } + + if (width < w && height < h) /* Stretch the image to fit the window. */ + { + double dw = (((double) w) / ((double) width)); + double dh = (((double) h) / ((double) height)); + double d = (dw > dh ? dh : dw); + int width2 = d * width; + int height2 = d * height; + int x, y; + XImage *ximage2 = XCreateImage (dpy, visual, ximage->depth, ZPixmap, + 0, NULL, + width2, height2, 8, 0); + if (!ximage2->data) + ximage2->data = (char *) malloc(width2 * height2 * 4); + free_data = True; + XInitImage(ximage2); +#ifdef DEBUG + fprintf(stderr, "%s: stretching video image by %f (%d %d -> %d %d)\n", + progname, d, width, height, width2, height2); +#endif /* DEBUG */ + for (y = 0; y < height2; y++) + { + int y2 = (int) (y / d); + for (x = 0; x < width2; x++) + XPutPixel(ximage2, x, y, XGetPixel(ximage, (int) (x / d), y2)); + } + ximage->data = 0; + XDestroyImage(ximage); + ximage = ximage2; + width = width2; + height = height2; + vblank_kludge *= d; + } + + XFillRectangle(dpy, dest, gc, 0, 0, w, h); + XPutImage(dpy, dest, gc, ximage, 0, vblank_kludge, + (w - width) / 2, + (h - height) / 2, + width, height - vblank_kludge); + XSync(dpy, False); + + if (free_data) + free(ximage->data); + ximage->data = 0; + XDestroyImage(ximage); + XFreeGC (dpy, gc); + return True; +} + +#endif /* HAVE_SGI_VIDEO */ diff --git a/utils/sgivideo.h b/utils/sgivideo.h new file mode 100644 index 00000000..065350f6 --- /dev/null +++ b/utils/sgivideo.h @@ -0,0 +1,18 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +#ifndef __SGIVIDEO_H__ +# ifdef HAVE_SGI_VIDEO + +Bool grab_video_frame(Screen *screen, Visual *visual, Drawable dest); + +# endif /* HAVE_SGI_VIDEO */ +#endif /* __SGIVIDEO_H__ */ diff --git a/utils/spline.c b/utils/spline.c new file mode 100644 index 00000000..84de1cb4 --- /dev/null +++ b/utils/spline.c @@ -0,0 +1,321 @@ +/* + * Copyright (c) 1987, 1988, 1989 Stanford University + * + * 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 Stanford not be used in advertising or + * publicity pertaining to distribution of the software without specific, + * written prior permission. Stanford makes no representations about + * the suitability of this software for any purpose. It is provided "as is" + * without express or implied warranty. + * + * STANFORD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, + * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. + * IN NO EVENT SHALL STANFORD 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. + */ + +/* This code came with the InterViews distribution, and was translated + from C++ to C by Matthieu Devin some time in 1992. + */ + +#include "utils.h" +#include "spline.h" + +#define SMOOTHNESS 1.0 + +static void no_more_memory (void); +static void grow_spline_points (spline* s); +static void mid_point (double x0, double y0, double x1, double y1, + double *mx, double *my); +static int can_approx_with_line (double x0, double y0, double x2, + double y2, double x3, double y3); +static void add_line (spline* s, double x0, double y0, double x1, double y1); +static void add_bezier_arc (spline* s, + double x0, double y0, double x1, double y1, + double x2, double y2, double x3, double y3); +static void third_point (double x0, double y0, double x1, double y1, + double *tx, double *ty); +static void calc_section (spline* s, double cminus1x, double cminus1y, + double cx, double cy, double cplus1x, double cplus1y, + double cplus2x, double cplus2y); + +static void +no_more_memory (void) +{ + fprintf (stderr, "No more memory\n"); + exit (1); +} + +spline* +make_spline (u_int size) +{ + spline* s = (spline*)calloc (1, sizeof (spline)); + if (!s) + no_more_memory (); + s->n_controls = size; + s->control_x = (double*)calloc (s->n_controls, sizeof (double)); + s->control_y = (double*)calloc (s->n_controls, sizeof (double)); + + s->n_points = 0; + s->allocated_points = s->n_controls; + s->points = (XPoint*)calloc (s->allocated_points, sizeof (XPoint)); + + if (!s->control_x || !s->control_y || !s->points) + no_more_memory (); + + return s; +} + +static void +grow_spline_points (spline *s) +{ + s->allocated_points *= 2; + s->points = + (XPoint*)realloc (s->points, s->allocated_points * sizeof (XPoint)); + + if (!s->points) + no_more_memory (); +} + +static void +mid_point (double x0, double y0, + double x1, double y1, + double *mx, double *my) +{ + *mx = (x0 + x1) / 2.0; + *my = (y0 + y1) / 2.0; +} + +static void +third_point (double x0, double y0, + double x1, double y1, + double *tx, double *ty) +{ + *tx = (2 * x0 + x1) / 3.0; + *ty = (2 * y0 + y1) / 3.0; +} + +static int +can_approx_with_line (double x0, double y0, + double x2, double y2, + double x3, double y3) +{ + double triangle_area, side_squared, dx, dy; + + triangle_area = x0 * y2 - x2 * y0 + x2 * y3 - x3 * y2 + x3 * y0 - x0 * y3; + /* actually 4 times the area. */ + triangle_area *= triangle_area; + dx = x3 - x0; + dy = y3 - y0; + side_squared = dx * dx + dy * dy; + return triangle_area <= SMOOTHNESS * side_squared; +} + +static void +add_line (spline *s, + double x0, double y0, + double x1, double y1) +{ + if (s->n_points >= s->allocated_points) + grow_spline_points (s); + + if (s->n_points == 0) + { + s->points [s->n_points].x = x0; + s->points [s->n_points].y = y0; + s->n_points += 1; + } + s->points [s->n_points].x = x1; + s->points [s->n_points].y = y1; + s->n_points += 1; +} + +static void +add_bezier_arc (spline *s, + double x0, double y0, + double x1, double y1, + double x2, double y2, + double x3, double y3) +{ + double midx01, midx12, midx23, midlsegx, midrsegx, cx, + midy01, midy12, midy23, midlsegy, midrsegy, cy; + + mid_point (x0, y0, x1, y1, &midx01, &midy01); + mid_point (x1, y1, x2, y2, &midx12, &midy12); + mid_point (x2, y2, x3, y3, &midx23, &midy23); + mid_point (midx01, midy01, midx12, midy12, &midlsegx, &midlsegy); + mid_point (midx12, midy12, midx23, midy23, &midrsegx, &midrsegy); + mid_point (midlsegx, midlsegy, midrsegx, midrsegy, &cx, &cy); + + if (can_approx_with_line (x0, y0, midlsegx, midlsegy, cx, cy)) + add_line (s, x0, y0, cx, cy); + else if ((midx01 != x1) || (midy01 != y1) || (midlsegx != x2) + || (midlsegy != y2) || (cx != x3) || (cy != y3)) + add_bezier_arc (s, x0, y0, midx01, midy01, midlsegx, midlsegy, cx, cy); + + if (can_approx_with_line (cx, cy, midx23, midy23, x3, y3)) + add_line (s, cx, cy, x3, y3); + else if ((cx != x0) || (cy != y0) || (midrsegx != x1) || (midrsegy != y1) + || (midx23 != x2) || (midy23 != y2)) + add_bezier_arc (s, cx, cy, midrsegx, midrsegy, midx23, midy23, x3, y3); +} + +static void +calc_section (spline *s, + double cminus1x, double cminus1y, + double cx, double cy, + double cplus1x, double cplus1y, + double cplus2x, double cplus2y) +{ + double p0x, p1x, p2x, p3x, tempx, + p0y, p1y, p2y, p3y, tempy; + + third_point (cx, cy, cplus1x, cplus1y, &p1x, &p1y); + third_point (cplus1x, cplus1y, cx, cy, &p2x, &p2y); + third_point (cx, cy, cminus1x, cminus1y, &tempx, &tempy); + mid_point (tempx, tempy, p1x, p1y, &p0x, &p0y); + third_point (cplus1x, cplus1y, cplus2x, cplus2y, &tempx, &tempy); + mid_point (tempx, tempy, p2x, p2y, &p3x, &p3y); + add_bezier_arc (s, p0x, p0y, p1x, p1y, p2x, p2y, p3x, p3y); +} + +void +compute_spline (spline *s) +{ + int i; + s->n_points = 0; + + if (s->n_controls < 3) + return; + + calc_section (s, s->control_x [0], s->control_y [0], s->control_x [0], + s->control_y [0], s->control_x [0], s->control_y [0], + s->control_x [1], s->control_y [1]); + calc_section (s, s->control_x [0], s->control_y [0], s->control_x [0], + s->control_y [0], s->control_x [1], s->control_y [1], + s->control_x [2], s->control_y [2]); + + for (i = 1; i < s->n_controls - 2; i++) + calc_section (s, s->control_x [i - 1], s->control_y [i - 1], + s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [i + 2], s->control_y [i + 2]); + + calc_section (s, s->control_x [i - 1], s->control_y [i - 1], + s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [i + 1], s->control_y [i + 1]); + calc_section (s, s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [i + 1], s->control_y [i + 1]); +} + +void +compute_closed_spline (spline *s) +{ + int i; + s->n_points = 0; + + if (s->n_controls < 3) + return; + + calc_section (s, + s->control_x [s->n_controls - 1], + s->control_y [s->n_controls - 1], + s->control_x [0], s->control_y [0], + s->control_x [1], s->control_y [1], + s->control_x [2], s->control_y [2]); + + for (i = 1; i < s->n_controls - 2; i++) + calc_section (s, s->control_x [i - 1], s->control_y [i - 1], + s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [i + 2], s->control_y [i + 2]); + + calc_section (s, s->control_x [i - 1], s->control_y [i - 1], + s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [0], s->control_y [0]); + calc_section (s, s->control_x [i], s->control_y [i], + s->control_x [i + 1], s->control_y [i + 1], + s->control_x [0], s->control_y [0], + s->control_x [1], s->control_y [1]); +} + +void +just_fill_spline (spline *s) +{ + int i; + + while (s->allocated_points < s->n_controls + 1) + grow_spline_points (s); + + for (i = 0; i < s->n_controls; i++) + { + s->points [i].x = s->control_x [i]; + s->points [i].y = s->control_y [i]; + } + s->points [s->n_controls].x = s->control_x [0]; + s->points [s->n_controls].y = s->control_y [0]; + s->n_points = s->n_controls + 1; +} + +void +append_spline_points (spline *s1, spline *s2) +{ + int i; + while (s1->allocated_points < s1->n_points + s2->n_points) + grow_spline_points (s1); + for (i = s1->n_points; i < s1->n_points + s2->n_points; i++) + { + s1->points [i].x = s2->points [i - s1->n_points].x; + s1->points [i].y = s2->points [i - s1->n_points].y; + } + s1->n_points = s1->n_points + s2->n_points; +} + +void +spline_bounding_box (spline *s, XRectangle *rectangle_out) +{ + int min_x; + int max_x; + int min_y; + int max_y; + int i; + + if (s->n_points == 0) + { + rectangle_out->x = 0; + rectangle_out->y = 0; + rectangle_out->width = 0; + rectangle_out->height = 0; + } + + min_x = s->points [0].x; + max_x = min_x; + min_y = s->points [0].y; + max_y = min_y; + + for (i = 1; i < s->n_points; i++) + { + if (s->points [i].x < min_x) + min_x = s->points [i].x; + if (s->points [i].x > max_x) + max_x = s->points [i].x; + if (s->points [i].y < min_y) + min_y = s->points [i].y; + if (s->points [i].y > max_y) + max_y = s->points [i].y; + } + rectangle_out->x = min_x; + rectangle_out->y = min_y; + rectangle_out->width = max_x - min_x; + rectangle_out->height = max_y - min_y; +} diff --git a/utils/spline.h b/utils/spline.h new file mode 100644 index 00000000..998c049d --- /dev/null +++ b/utils/spline.h @@ -0,0 +1,60 @@ +/* + * Copyright (c) 1987, 1988, 1989 Stanford University + * + * 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 Stanford not be used in advertising or + * publicity pertaining to distribution of the software without specific, + * written prior permission. Stanford makes no representations about + * the suitability of this software for any purpose. It is provided "as is" + * without express or implied warranty. + * + * STANFORD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, + * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. + * IN NO EVENT SHALL STANFORD 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. + */ + +/* This code came with the InterViews distribution, and was translated + from C++ to C by Matthieu Devin some time in 1992. + */ + +#ifndef _SPLINE_H_ +#define _SPLINE_H_ + +#ifdef VMS +# ifndef __DECC + typedef unsigned int u_int; +# else +# if __DECC_VER < 50200000 + typedef unsigned int u_int; +# endif +# endif +#endif + +typedef struct _spline +{ + /* input */ + u_int n_controls; + double* control_x; + double* control_y; + + /* output */ + u_int n_points; + XPoint* points; + u_int allocated_points; +} spline; + +spline* make_spline (u_int size); +void compute_spline (spline* s); +void compute_closed_spline (spline* s); +void just_fill_spline (spline* s); +void append_spline_points (spline* s1, spline* s2); +void spline_bounding_box (spline* s, XRectangle* rectangle_out); + +#endif /* _SPLINE_H_ */ diff --git a/utils/usleep.c b/utils/usleep.c new file mode 100644 index 00000000..04a17aa7 --- /dev/null +++ b/utils/usleep.c @@ -0,0 +1,58 @@ +/* xscreensaver, Copyright (c) 1992, 1996, 1997 + * 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 HAVE_CONFIG_H +# include "config.h" +#else /* !HAVE_CONFIG_H */ +# ifndef NO_SELECT +# define HAVE_SELECT +# endif +#endif /* !HAVE_CONFIG_H */ + +#ifdef __STDC__ +# include +#endif + +#if defined(VMS) +# include +# include +# include +#elif defined(HAVE_SELECT) +# include /* for struct timeval */ +#endif + + +#ifdef __SCREENHACK_USLEEP_H__ +ERROR, do not include that here +#endif + +void +screenhack_usleep (unsigned long usecs) +{ +# if defined(VMS) + float seconds = ((float) usecs)/1000000.0; + unsigned long int statvms = lib$wait(&seconds); + +#elif defined(HAVE_SELECT) + /* usleep() doesn't exist everywhere, and select() is faster anyway. */ + struct timeval tv; + tv.tv_sec = usecs / 1000000L; + tv.tv_usec = usecs % 1000000L; + (void) select (0, 0, 0, 0, &tv); + +#else /* !VMS && !HAVE_SELECT */ + /* If you don't have select() or usleep(), I guess you lose... + Maybe you have napms() instead? Let me know. */ + usleep (usecs); + +#endif /* !VMS && !HAVE_SELECT */ +} diff --git a/utils/usleep.h b/utils/usleep.h new file mode 100644 index 00000000..6d58293d --- /dev/null +++ b/utils/usleep.h @@ -0,0 +1,20 @@ +/* xscreensaver, Copyright (c) 1992, 1996 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. + */ + +#ifndef __SCREENHACK_USLEEP_H__ +#define __SCREENHACK_USLEEP_H__ + +extern void screenhack_usleep (unsigned long usecs); + +#undef usleep +#define usleep(usecs) screenhack_usleep(usecs) + +#endif /* __SCREENHACK_USLEEP_H__ */ diff --git a/utils/utils.h b/utils/utils.h new file mode 100644 index 00000000..2dbe47d9 --- /dev/null +++ b/utils/utils.h @@ -0,0 +1,22 @@ +/* xscreensaver, Copyright (c) 1997 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 HAVE_CONFIG_H +# include "config.h" +#endif + +#include +#include +#include +#include + +#include +#include diff --git a/utils/version.h b/utils/version.h new file mode 100644 index 00000000..5539daab --- /dev/null +++ b/utils/version.h @@ -0,0 +1,2 @@ +static const char screensaver_id[] = + "@(#)xscreensaver 2.16, by Jamie Zawinski (jwz@netscape.com)"; diff --git a/utils/visual.c b/utils/visual.c new file mode 100644 index 00000000..c8364360 --- /dev/null +++ b/utils/visual.c @@ -0,0 +1,465 @@ +/* xscreensaver, Copyright (c) 1993, 1994, 1995, 1996, 1997, 1998 + * 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. + */ + +/* This file contains some code for intelligently picking the best visual + (where "best" is biased in the direction of either: high color counts; + or: having writable color cells...) + */ + +#include "utils.h" +#include "resources.h" /* for get_string_resource() */ +#include "visual.h" + +#include + +extern char *progname; + + +#ifndef isupper +# define isupper(c) ((c) >= 'A' && (c) <= 'Z') +#endif +#ifndef _tolower +# define _tolower(c) ((c) - 'A' + 'a') +#endif + + +static Visual *pick_best_visual (Screen *, Bool, Bool); +static Visual *pick_mono_visual (Screen *); +static Visual *pick_best_visual_of_class (Screen *, int); +static Visual *id_to_visual (Screen *, int); +static Visual *id_to_visual (Screen *screen, int id); + + +#define DEFAULT_VISUAL -1 +#define BEST_VISUAL -2 +#define MONO_VISUAL -3 +#define GRAY_VISUAL -4 +#define COLOR_VISUAL -5 +#define SPECIFIC_VISUAL -6 + +Visual * +get_visual (Screen *screen, const char *string, Bool prefer_writable_cells, + Bool verbose_p) +{ + char *v = (string ? strdup(string) : 0); + char c, *tmp; + int vclass; + unsigned long id; + Visual *result = 0; + + if (v) + for (tmp = v; *tmp; tmp++) + if (isupper (*tmp)) *tmp = _tolower (*tmp); + + if (!v) vclass = BEST_VISUAL; + else if (!strcmp (v, "default")) vclass = DEFAULT_VISUAL; + else if (!strcmp (v, "best")) vclass = BEST_VISUAL; + else if (!strcmp (v, "mono")) vclass = MONO_VISUAL; + else if (!strcmp (v, "monochrome")) vclass = MONO_VISUAL; + else if (!strcmp (v, "gray")) vclass = GRAY_VISUAL; + else if (!strcmp (v, "grey")) vclass = GRAY_VISUAL; + else if (!strcmp (v, "color")) vclass = COLOR_VISUAL; + else if (!strcmp (v, "staticgray")) vclass = StaticGray; + else if (!strcmp (v, "staticcolor")) vclass = StaticColor; + else if (!strcmp (v, "truecolor")) vclass = TrueColor; + else if (!strcmp (v, "grayscale")) vclass = GrayScale; + else if (!strcmp (v, "greyscale")) vclass = GrayScale; + else if (!strcmp (v, "pseudocolor")) vclass = PseudoColor; + else if (!strcmp (v, "directcolor")) vclass = DirectColor; + else if (1 == sscanf (v, " %ld %c", &id, &c)) vclass = SPECIFIC_VISUAL; + else if (1 == sscanf (v, " 0x%lx %c", &id, &c)) vclass = SPECIFIC_VISUAL; + else + { + fprintf (stderr, "%s: unrecognized visual \"%s\".\n", progname, v); + vclass = DEFAULT_VISUAL; + } + + if (vclass == DEFAULT_VISUAL) + result = DefaultVisualOfScreen (screen); + else if (vclass == BEST_VISUAL) + result = pick_best_visual (screen, prefer_writable_cells, False); + else if (vclass == MONO_VISUAL) + { + result = pick_mono_visual (screen); + if (!result && verbose_p) + fprintf (stderr, "%s: no monochrome visuals.\n", progname); + } + else if (vclass == GRAY_VISUAL) + { + if (prefer_writable_cells) + result = pick_best_visual_of_class (screen, GrayScale); + if (!result) + result = pick_best_visual_of_class (screen, StaticGray); + if (!result) + result = pick_best_visual_of_class (screen, GrayScale); + if (!result && verbose_p) + fprintf (stderr, "%s: no GrayScale or StaticGray visuals.\n", + progname); + } + else if (vclass == COLOR_VISUAL) + { + int class; + /* First see if the default visual will do. */ + result = DefaultVisualOfScreen (screen); + class = visual_class(screen, result); + if (class != TrueColor && + class != PseudoColor && + class != DirectColor && + class != StaticColor) + result = 0; + if (result && visual_depth(screen, result) <= 1) + result = 0; + + /* Else, find the best non-default color visual */ + if (!result) + result = pick_best_visual (screen, prefer_writable_cells, True); + + if (!result && verbose_p) + fprintf (stderr, "%s: no color visuals.\n", progname); + } + else if (vclass == SPECIFIC_VISUAL) + { + result = id_to_visual (screen, id); + if (!result && verbose_p) + fprintf (stderr, "%s: no visual with id 0x%x.\n", progname, + (unsigned int) id); + } + else + { + Visual *visual = pick_best_visual_of_class (screen, vclass); + if (visual) + result = visual; + else if (verbose_p) + fprintf (stderr, "%s: no visual of class %s.\n", progname, v); + } + + if (v) free (v); + return result; +} + +Visual * +get_visual_resource (Screen *screen, char *name, char *class, + Bool prefer_writable_cells) +{ + char *string = get_string_resource (name, class); + Visual *v = get_visual (screen, string, prefer_writable_cells, True); + if (string) + free(string); + if (v) + return v; + else + return DefaultVisualOfScreen (screen); +} + + +static Visual * +pick_best_visual (Screen *screen, Bool prefer_writable_cells, Bool color_only) +{ + Visual *visual; + + if (!prefer_writable_cells) + { + /* If we don't prefer writable cells, then the "best" visual is the one + on which we can allocate the largest range and number of colors. + + Therefore, a TrueColor visual which is at least 16 bits deep is best. + (The assumption here being that a TrueColor of less than 16 bits is + really just a PseudoColor visual with a pre-allocated color cube.) + + The next best thing is a PseudoColor visual of any type. After that + come the non-colormappable visuals, and non-color visuals. + */ + if ((visual = pick_best_visual_of_class (screen, TrueColor)) && + visual_depth (screen, visual) >= 16) + return visual; + } + +#define TRY_CLASS(CLASS) \ + if ((visual = pick_best_visual_of_class (screen, CLASS)) && \ + (!color_only || visual_depth(screen, visual) > 1)) \ + return visual + TRY_CLASS(PseudoColor); + TRY_CLASS(TrueColor); + TRY_CLASS(DirectColor); + TRY_CLASS(StaticColor); + if (!color_only) + { + TRY_CLASS(GrayScale); + TRY_CLASS(StaticGray); + } +#undef TRY_CLASS + + visual = DefaultVisualOfScreen (screen); + if (!color_only || visual_depth(screen, visual) > 1) + return visual; + else + return 0; +} + +static Visual * +pick_mono_visual (Screen *screen) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count; + + vi_in.depth = 1; + vi_in.screen = screen_number (screen); + vi_out = XGetVisualInfo (dpy, (VisualDepthMask | VisualScreenMask), + &vi_in, &out_count); + if (vi_out) + { + Visual *v = (out_count > 0 ? vi_out [0].visual : 0); + if (v && vi_out[0].depth != 1) + v = 0; + XFree ((char *) vi_out); + return v; + } + else + return 0; +} + + +static Visual * +pick_best_visual_of_class (Screen *screen, int visual_class) +{ + /* The best visual of a class is the one which on which we can allocate + the largest range and number of colors, which means the one with the + greatest depth and number of cells. + + (But actually, for XDaliClock, all visuals of the same class are + probably equivalent - either we have writable cells or we don't.) + */ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count; + + vi_in.class = visual_class; + vi_in.screen = screen_number (screen); + vi_out = XGetVisualInfo (dpy, (VisualClassMask | VisualScreenMask), + &vi_in, &out_count); + if (vi_out) + { + /* choose the 'best' one, if multiple */ + int i, best; + Visual *visual; + for (i = 0, best = 0; i < out_count; i++) + /* It's better if it's deeper, or if it's the same depth with + more cells (does that ever happen? Well, it could...) */ + if ((vi_out [i].depth > vi_out [best].depth) || + ((vi_out [i].depth == vi_out [best].depth) && + (vi_out [i].colormap_size > vi_out [best].colormap_size))) + best = i; + visual = (best < out_count ? vi_out [best].visual : 0); + XFree ((char *) vi_out); + return visual; + } + else + return 0; +} + +static Visual * +id_to_visual (Screen *screen, int id) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count; + vi_in.screen = screen_number (screen); + vi_in.visualid = id; + vi_out = XGetVisualInfo (dpy, (VisualScreenMask | VisualIDMask), + &vi_in, &out_count); + if (vi_out) + { + Visual *v = vi_out[0].visual; + XFree ((char *) vi_out); + return v; + } + return 0; +} + +int +visual_depth (Screen *screen, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count, d; + vi_in.screen = screen_number (screen); + vi_in.visualid = XVisualIDFromVisual (visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + d = vi_out [0].depth; + XFree ((char *) vi_out); + return d; +} + + +#if 0 +/* You very probably don't want to be using this. + Pixmap depth doesn't refer to the depths of pixmaps, but rather, to + the depth of protocol-level on-the-wire pixmap data, that is, XImages. + To get this info, you should be looking at XImage->bits_per_pixel + instead. (And allocating the data for your XImage structures by + multiplying ximage->bytes_per_line by ximage->height.) + */ +int +visual_pixmap_depth (Screen *screen, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + int vdepth = visual_depth (screen, visual); + int pdepth = vdepth; + int i, pfvc = 0; + XPixmapFormatValues *pfv = XListPixmapFormats (dpy, &pfvc); + + /* Return the first matching depth in the pixmap formats. If there are no + matching pixmap formats (which shouldn't be able to happen at all) then + return the visual depth instead. */ + for (i = 0; i < pfvc; i++) + if (pfv[i].depth == vdepth) + { + pdepth = pfv[i].bits_per_pixel; + break; + } + if (pfv) + XFree (pfv); + return pdepth; +} +#endif /* 0 */ + + +int +visual_class (Screen *screen, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count, c; + vi_in.screen = screen_number (screen); + vi_in.visualid = XVisualIDFromVisual (visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + c = vi_out [0].class; + XFree ((char *) vi_out); + return c; +} + +Bool +has_writable_cells (Screen *screen, Visual *visual) +{ + switch (visual_class (screen, visual)) + { + case GrayScale: /* Mappable grays. */ + case PseudoColor: /* Mappable colors. */ + return True; + case StaticGray: /* Fixed grays. */ + case TrueColor: /* Fixed colors. */ + case StaticColor: /* (What's the difference again?) */ + case DirectColor: /* DirectColor visuals are like TrueColor, but have + three colormaps - one for each component of RGB. + Screw it. */ + return False; + default: + abort(); + } +} + +void +describe_visual (FILE *f, Screen *screen, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count; + vi_in.screen = screen_number (screen); + vi_in.visualid = XVisualIDFromVisual (visual); + vi_out = XGetVisualInfo (dpy, (VisualScreenMask | VisualIDMask), + &vi_in, &out_count); + if (! vi_out) abort (); + fprintf (f, "0x%02x (%s depth: %2d, cmap: %3d)\n", + (unsigned int) vi_out->visualid, + (vi_out->class == StaticGray ? "StaticGray, " : + vi_out->class == StaticColor ? "StaticColor," : + vi_out->class == TrueColor ? "TrueColor, " : + vi_out->class == GrayScale ? "GrayScale, " : + vi_out->class == PseudoColor ? "PseudoColor," : + vi_out->class == DirectColor ? "DirectColor," : + "UNKNOWN: "), + vi_out->depth, vi_out->colormap_size /*, vi_out->bits_per_rgb*/); + XFree ((char *) vi_out); +} + +int +screen_number (Screen *screen) +{ + Display *dpy = DisplayOfScreen (screen); + int i; + for (i = 0; i < ScreenCount (dpy); i++) + if (ScreenOfDisplay (dpy, i) == screen) + return i; + abort (); +} + +int +visual_cells (Screen *screen, Visual *visual) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + int out_count, c; + vi_in.screen = screen_number (screen); + vi_in.visualid = XVisualIDFromVisual (visual); + vi_out = XGetVisualInfo (dpy, VisualScreenMask|VisualIDMask, + &vi_in, &out_count); + if (! vi_out) abort (); + c = vi_out [0].colormap_size; + XFree ((char *) vi_out); + return c; +} + +Visual * +find_similar_visual(Screen *screen, Visual *old_visual) +{ + Display *dpy = DisplayOfScreen (screen); + XVisualInfo vi_in, *vi_out; + Visual *result = 0; + int out_count; + + vi_in.screen = screen_number (screen); + vi_in.class = visual_class (screen, old_visual); + vi_in.depth = visual_depth (screen, old_visual); + + /* Look for a visual of the same class and depth. + */ + vi_out = XGetVisualInfo (dpy, (VisualScreenMask | VisualClassMask | + VisualDepthMask), + &vi_in, &out_count); + if (vi_out && out_count > 0) + result = vi_out[0].visual; + if (vi_out) XFree (vi_out); + vi_out = 0; + + /* Failing that, look for a visual of the same class. + */ + if (!result) + { + vi_out = XGetVisualInfo (dpy, (VisualScreenMask | VisualClassMask), + &vi_in, &out_count); + if (vi_out && out_count > 0) + result = vi_out[0].visual; + if (vi_out) XFree (vi_out); + vi_out = 0; + } + + /* Failing that, return the default visual. */ + if (!result) + result = DefaultVisualOfScreen (screen); + + return result; +} diff --git a/utils/visual.h b/utils/visual.h new file mode 100644 index 00000000..14820a9c --- /dev/null +++ b/utils/visual.h @@ -0,0 +1,27 @@ +/* xscreensaver, Copyright (c) 1993-1998 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. + */ + +#ifndef __VISUAL_H__ +#define __VISUAL_H__ + +extern Visual *get_visual (Screen *, const char *name, Bool, Bool); +extern Visual *get_visual_resource (Screen *, char *, char *, Bool); +extern int visual_depth (Screen *, Visual *); +/* extern int visual_pixmap_depth (Screen *, Visual *); */ +extern int visual_class (Screen *, Visual *); +extern int visual_cells (Screen *, Visual *); +extern int screen_number (Screen *); +extern Visual *find_similar_visual (Screen *, Visual *old); +extern void describe_visual (FILE *f, Screen *, Visual *); +extern Visual *get_overlay_visual (Screen *, unsigned long *pixel_return); +extern Bool has_writable_cells (Screen *screen, Visual *visual); + +#endif /* __VISUAL_H__ */ diff --git a/utils/vms-gtod.c b/utils/vms-gtod.c new file mode 100644 index 00000000..7b1df5ab --- /dev/null +++ b/utils/vms-gtod.c @@ -0,0 +1,31 @@ +/* + * UNIX-style Time Functions, by pmoreau@cena.dgac.fr + * (picked up from XVMSUTILS unix emulation routines for VMS by + * Trevor Taylor, Patrick Mahans and Martin P.J. Zinser) + * + * 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. + */ +#include +#include +#include +#include "vms-gtod.h" + +/* + * gettimeofday(2) - Returns the current time + */ + +int gettimeofday(tv) +struct timeval *tv; +{ + timeb_t tmp_time; + ftime(&tmp_time); + tv->tv_sec = tmp_time.time; + tv->tv_usec = tmp_time.millitm * 1000; + return (0); +} diff --git a/utils/vms-gtod.h b/utils/vms-gtod.h new file mode 100644 index 00000000..ffd65868 --- /dev/null +++ b/utils/vms-gtod.h @@ -0,0 +1,85 @@ +/* @(#)time.h 2.9 87/01/17 SMI; from UCB 7.1 6/4/86 */ + +/* + Definitions of various structures used on UNIX for + time-related syscalls. +*/ + +/* + * Copyright (c) 1982, 1986 Regents of the University of California. + * All rights reserved. The Berkeley software License Agreement + * specifies the terms and conditions for redistribution. + */ + +#ifndef _VMS_GTOD_ +#define _VMS_GTOD_ + +#ifdef __cplusplus +extern "C" { +#endif + +/* + * Structure returned by gettimeofday(2) system call, + * and used in other calls. + */ +#ifndef __DECC +struct timeval +{ + long tv_sec; /* seconds */ + long tv_usec; /* and microseconds */ +}; +#else +#if __DECC_VER < 50200000 +struct timeval +{ + long tv_sec; /* seconds */ + long tv_usec; /* and microseconds */ +}; +#endif /* __DECC_VER */ +#endif /* __DECC */ + +/* + * Operations on timevals. + * + * NB: timercmp does not work for >= or <=. + */ +#define timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_usec) +#define timercmp(tvp, uvp, cmp) \ + ((tvp)->tv_sec cmp (uvp)->tv_sec || \ + (tvp)->tv_sec == (uvp)->tv_sec && (tvp)->tv_usec cmp (uvp)->tv_usec) +#define timerclear(tvp) (tvp)->tv_sec = (tvp)->tv_usec = 0 + +/* + * Names of the interval timers, and structure + * defining a timer setting. + */ +#define ITIMER_REAL 0 +#define ITIMER_VIRTUAL 1 +#define ITIMER_PROF 2 + +#ifndef __DECC +struct itimerval +{ + struct timeval it_interval; /* timer interval */ + struct timeval it_value; /* current value */ +}; +#else +#if __DECC_VER < 50200000 +struct itimerval +{ + struct timeval it_interval; /* timer interval */ + struct timeval it_value; /* current value */ +}; +#endif /* __DECC_VER */ +#endif /* __DECC */ + +#ifndef KERNEL +#include +#endif + +#ifdef __cplusplus +} +#endif + +#endif /*!_VMS_GTOD_*/ + diff --git a/utils/vms-strdup.c b/utils/vms-strdup.c new file mode 100644 index 00000000..1afc257d --- /dev/null +++ b/utils/vms-strdup.c @@ -0,0 +1,25 @@ +/* + * strdup.c + * + * Simple version of strdup for machines without it (ie DEC Ultrix 4.2) + * Apparently VMS only got strdup in 1995 (v5.2...) + * + * By David Chatterton + * 29 July 1993 + * + * You can do anything you like to this... :) + * I've stolen it from xpilot and added it to the xvmstuils MPJZ ;-) + */ + +#if (__VMS_VER < 70000000) +#include +#include + +char* strdup (const char* s1) +{ + char* s2; + if (s2 = (char*)malloc(strlen(s1)+1)) + strcpy(s2,s1); + return s2; +} +#endif diff --git a/utils/vroot.h b/utils/vroot.h new file mode 100644 index 00000000..ba3e5d29 --- /dev/null +++ b/utils/vroot.h @@ -0,0 +1,126 @@ +/*****************************************************************************/ +/** Copyright 1991 by Andreas Stolcke **/ +/** Copyright 1990 by Solbourne Computer Inc. **/ +/** Longmont, Colorado **/ +/** **/ +/** 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 permis- **/ +/** sion notice appear in supporting documentation, and that the **/ +/** name of Solbourne not be used in advertising **/ +/** in publicity pertaining to distribution of the software without **/ +/** specific, written prior permission. **/ +/** **/ +/** ANDREAS STOLCKE AND SOLBOURNE COMPUTER INC. DISCLAIMS ALL WARRANTIES **/ +/** WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF **/ +/** MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL ANDREAS STOLCKE **/ +/** OR SOLBOURNE 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. **/ +/*****************************************************************************/ +/* + * vroot.h -- Virtual Root Window handling header file + * + * This header file redefines the X11 macros RootWindow and DefaultRootWindow, + * making them look for a virtual root window as provided by certain `virtual' + * window managers like swm and tvtwm. If none is found, the ordinary root + * window is returned, thus retaining backward compatibility with standard + * window managers. + * The function implementing the virtual root lookup remembers the result of + * its last invocation to avoid overhead in the case of repeated calls + * on the same display and screen arguments. + * The lookup code itself is taken from Tom LaStrange's ssetroot program. + * + * Most simple root window changing X programs can be converted to using + * virtual roots by just including + * + * #include + * + * after all the X11 header files. It has been tested on such popular + * X clients as xphoon, xfroot, xloadimage, and xaqua. + * It also works with the core clients xprop, xwininfo, xwd, and editres + * (and is necessary to get those clients working under tvtwm). + * It does NOT work with xsetroot; get the xsetroot replacement included in + * the tvtwm distribution instead. + * + * Andreas Stolcke , 9/7/90 + * - replaced all NULL's with properly cast 0's, 5/6/91 + * - free children list (suggested by Mark Martin ), 5/16/91 + * - include X11/Xlib.h and support RootWindowOfScreen, too 9/17/91 + */ + +#ifndef _VROOT_H_ +#define _VROOT_H_ + +#if !defined(lint) && !defined(SABER) +static const char vroot_rcsid[] = "#Id: vroot.h,v 1.4 1991/09/30 19:23:16 stolcke Exp stolcke #"; +#endif + +#include +#include +#include + +static Window +#ifdef __STDC__ /* ANSIfication added by jwz, to avoid superfluous warnings. */ +VirtualRootWindowOfScreen(Screen *screen) +#else /* !__STDC__ */ +VirtualRootWindowOfScreen(screen) Screen *screen; +#endif /* !__STDC__ */ +{ + static Screen *save_screen = (Screen *)0; + static Window root = (Window)0; + + if (screen != save_screen) { + Display *dpy = DisplayOfScreen(screen); + Atom __SWM_VROOT = None; + int i; + Window rootReturn, parentReturn, *children; + unsigned int numChildren; + + root = RootWindowOfScreen(screen); + + /* go look for a virtual root */ + __SWM_VROOT = XInternAtom(dpy, "__SWM_VROOT", False); + if (XQueryTree(dpy, root, &rootReturn, &parentReturn, + &children, &numChildren)) { + for (i = 0; i < numChildren; i++) { + Atom actual_type; + int actual_format; + unsigned long nitems, bytesafter; + Window *newRoot = (Window *)0; + + if (XGetWindowProperty(dpy, children[i], + __SWM_VROOT, 0, 1, False, XA_WINDOW, + &actual_type, &actual_format, + &nitems, &bytesafter, + (unsigned char **) &newRoot) == Success + && newRoot) { + root = *newRoot; + break; + } + } + if (children) + XFree((char *)children); + } + + save_screen = screen; + } + + return root; +} + +#undef RootWindowOfScreen +#define RootWindowOfScreen(s) VirtualRootWindowOfScreen(s) + +#undef RootWindow +#define RootWindow(dpy,screen) VirtualRootWindowOfScreen(ScreenOfDisplay(dpy,screen)) + +#undef DefaultRootWindow +#define DefaultRootWindow(dpy) VirtualRootWindowOfScreen(DefaultScreenOfDisplay(dpy)) + +#endif /* _VROOT_H_ */ diff --git a/utils/xmu.c b/utils/xmu.c new file mode 100644 index 00000000..9773cd23 --- /dev/null +++ b/utils/xmu.c @@ -0,0 +1,168 @@ +/* This file contains compatibility routines for systems without Xmu. + * You would be better served by installing Xmu on your machine or + * yelling at your vendor to ship it. + */ + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#ifndef HAVE_XMU +/* + * Copyright 1989 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, 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. + * + * M.I.T. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL M.I.T. + * 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. + */ + +#include "xmu.h" + +#ifndef NEED_EVENTS +# define NEED_EVENTS /* to make Xproto.h define xEvent */ +#endif +#ifndef VMS +# include /* for xEvent (used by Xlibint.h) */ +# include /* for _XExtension */ +#else /* VMS */ +# include +#endif /* VMS */ +#include /* for XtSpecificationRelease */ + +/* + * XmuPrintDefaultErrorMessage - print a nice error that looks like the usual + * message. Returns 1 if the caller should consider exitting else 0. + */ +int XmuPrintDefaultErrorMessage (Display *dpy, XErrorEvent *event, FILE *fp) +{ + char buffer[BUFSIZ]; + char mesg[BUFSIZ]; + char number[32]; + char *mtype = "XlibMessage"; + _XExtension *ext = (_XExtension *)NULL; + XGetErrorText(dpy, event->error_code, buffer, BUFSIZ); + XGetErrorDatabaseText(dpy, mtype, "XError", "X Error", mesg, BUFSIZ); + (void) fprintf(fp, "%s: %s\n ", mesg, buffer); + XGetErrorDatabaseText(dpy, mtype, "MajorCode", "Request Major code %d", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->request_code); + if (event->request_code < 128) { + sprintf(number, "%d", event->request_code); + XGetErrorDatabaseText(dpy, "XRequest", number, "", buffer, BUFSIZ); + } else { + /* XXX this is non-portable */ + for (ext = dpy->ext_procs; + ext && (ext->codes.major_opcode != event->request_code); + ext = ext->next) + ; + if (ext) + strcpy(buffer, ext->name); + else + buffer[0] = '\0'; + } + (void) fprintf(fp, " (%s)", buffer); + fputs("\n ", fp); +#if (XtSpecificationRelease >= 5) + if (event->request_code >= 128) { + XGetErrorDatabaseText(dpy, mtype, "MinorCode", "Request Minor code %d", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->minor_code); + if (ext) { + sprintf(mesg, "%s.%d", ext->name, event->minor_code); + XGetErrorDatabaseText(dpy, "XRequest", mesg, "", buffer, BUFSIZ); + (void) fprintf(fp, " (%s)", buffer); + } + fputs("\n ", fp); + } + if (event->error_code >= 128) { + /* let extensions try to print the values */ + /* XXX this is non-portable code */ + for (ext = dpy->ext_procs; ext; ext = ext->next) { + if (ext->error_values) + (*ext->error_values)(dpy, event, fp); + } + /* the rest is a fallback, providing a simple default */ + /* kludge, try to find the extension that caused it */ + buffer[0] = '\0'; + for (ext = dpy->ext_procs; ext; ext = ext->next) { + if (ext->error_string) + (*ext->error_string)(dpy, event->error_code, &ext->codes, + buffer, BUFSIZ); + if (buffer[0]) + break; + } + if (buffer[0]) + sprintf(buffer, "%s.%d", ext->name, + event->error_code - ext->codes.first_error); + else + strcpy(buffer, "Value"); + XGetErrorDatabaseText(dpy, mtype, buffer, "", mesg, BUFSIZ); + if (*mesg) { + (void) fprintf(fp, mesg, event->resourceid); + fputs("\n ", fp); + } + } else if ((event->error_code == BadWindow) || + (event->error_code == BadPixmap) || + (event->error_code == BadCursor) || + (event->error_code == BadFont) || + (event->error_code == BadDrawable) || + (event->error_code == BadColor) || + (event->error_code == BadGC) || + (event->error_code == BadIDChoice) || + (event->error_code == BadValue) || + (event->error_code == BadAtom)) { + if (event->error_code == BadValue) + XGetErrorDatabaseText(dpy, mtype, "Value", "Value 0x%x", + mesg, BUFSIZ); + else if (event->error_code == BadAtom) + XGetErrorDatabaseText(dpy, mtype, "AtomID", "AtomID 0x%x", + mesg, BUFSIZ); + else + XGetErrorDatabaseText(dpy, mtype, "ResourceID", "ResourceID 0x%x", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->resourceid); + fputs("\n ", fp); + } +#elif (XtSpecificationRelease == 4) + XGetErrorDatabaseText(dpy, mtype, "MinorCode", "Request Minor code %d", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->minor_code); + fputs("\n ", fp); + if (ext) { + sprintf(mesg, "%s.%d", ext->name, event->minor_code); + XGetErrorDatabaseText(dpy, "XRequest", mesg, "", buffer, BUFSIZ); + (void) fprintf(fp, " (%s)", buffer); + } + XGetErrorDatabaseText(dpy, mtype, "ResourceID", "ResourceID 0x%x", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->resourceid); + fputs("\n ", fp); +#else +ERROR! Unsupported release of X11 +#endif + XGetErrorDatabaseText(dpy, mtype, "ErrorSerial", "Error Serial #%d", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, event->serial); + fputs("\n ", fp); + XGetErrorDatabaseText(dpy, mtype, "CurrentSerial", "Current Serial #%d", + mesg, BUFSIZ); + (void) fprintf(fp, mesg, NextRequest(dpy)-1); + fputs("\n", fp); + if (event->error_code == BadImplementation) return 0; + return 1; +} + +#endif /* !HAVE_XMU */ diff --git a/utils/xmu.h b/utils/xmu.h new file mode 100644 index 00000000..48084f74 --- /dev/null +++ b/utils/xmu.h @@ -0,0 +1,14 @@ +/* This file contains compatibility routines for systems without Xmu. + * You would be better served by installing Xmu on your machine or + * yelling at your vendor to ship it. + */ + +#ifndef __XMU_H__ +#define __XMU_H__ + +#include +#include + +int XmuPrintDefaultErrorMessage (Display *dpy, XErrorEvent *event, FILE *fp); + +#endif /* __XMU_H__ */ diff --git a/utils/xroger.c b/utils/xroger.c new file mode 100644 index 00000000..e64d2899 --- /dev/null +++ b/utils/xroger.c @@ -0,0 +1,134 @@ +/* xscreensaver, Copyright (c) 1991-1998 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. + */ + +#include "utils.h" + +static void +crossbones (Display *dpy, Window window, GC draw_gc, + int x, int y, int w, int h) +{ + double xscale = w / 440.0; + double yscale = h / 216.0; + XPoint points [6]; + points[0].x = x + xscale * 20; points[0].y = y + yscale * 10; + points[1].x = x + xscale * 120; points[1].y = y + yscale * 10; + points[2].x = x + xscale * 243; points[2].y = y + yscale * 93; + points[3].x = x + xscale * 57; points[3].y = y + yscale * 210; + points[4].x = x + xscale * 20; points[4].y = y + yscale * 210; + points[5].x = x + xscale * 175; points[5].y = y + yscale * 113; + XFillPolygon (dpy, window, draw_gc, points, 6, Complex, CoordModeOrigin); + points[0].x = x + xscale * 202; points[0].y = y + yscale * 132; + points[1].x = x + xscale * 384; points[1].y = y + yscale * 10; + points[2].x = x + xscale * 420; points[2].y = y + yscale * 10; + points[3].x = x + xscale * 270; points[3].y = y + yscale * 113; + points[4].x = x + xscale * 420; points[4].y = y + yscale * 210; + points[5].x = x + xscale * 320; points[5].y = y + yscale * 210; + XFillPolygon (dpy, window, draw_gc, points, 6, Complex, CoordModeOrigin); +} + + +#include "spline.h" + +void +skull (Display *dpy, Window window, GC draw_gc, GC erase_gc, + int x, int y, int w, int h) +{ + spline s; + float w100, h100; + XPoint points [20]; + double sx[20], sy[20]; + int i; + + memset(&s, 0, sizeof(s)); + s.control_x = sx; + s.control_y = sy; + + y -= (w * 0.025); + + crossbones (dpy, window, draw_gc, x, y+(h/2), w, (h / 3)); + + x += (w * 0.27); + y += (h * 0.25); + w *= 0.6; + h *= 0.6; + + w100 = w / 100.0; + h100 = h / 100.0; + + points[ 0].x = x + (0 * w100); points[ 0].y = y + (10 * h100); + points[ 1].x = x + (10 * w100); points[ 1].y = y + (0 * h100); + points[ 2].x = x + (90 * w100); points[ 2].y = y + (0 * h100); + points[ 3].x = x + (100 * w100); points[ 3].y = y + (10 * h100); + points[ 4].x = x + (100 * w100); points[ 4].y = y + (30 * h100); + points[ 5].x = x + (90 * w100); points[ 5].y = y + (40 * h100); + points[ 6].x = x + (70 * w100); points[ 6].y = y + (40 * h100); + points[ 7].x = x + (70 * w100); points[ 7].y = y + (50 * h100); + points[ 8].x = x + (30 * w100); points[ 8].y = y + (50 * h100); + points[ 9].x = x + (30 * w100); points[ 9].y = y + (40 * h100); + points[10].x = x + (10 * w100); points[10].y = y + (40 * h100); + points[11].x = x + (0 * w100); points[11].y = y + (30 * h100); + + for (i = 0; i < 12; i++) + sx[i] = points[i].x, sy[i] = points[i].y; + s.n_controls = i; + s.allocated_points = i; + s.points = (XPoint *) calloc (i, sizeof (*s.points)); + compute_closed_spline(&s); + + XFillPolygon (dpy, window, draw_gc, points+6, 4, Complex, CoordModeOrigin); + XFillPolygon (dpy, window, draw_gc, s.points, s.n_points, + Complex, CoordModeOrigin); + + points[0].x = x + (20 * w100); points[0].y = y + (18 * h100); + points[1].x = x + (25 * w100); points[1].y = y + (15 * h100); + points[2].x = x + (43 * w100); points[2].y = y + (15 * h100); + points[3].x = x + (45 * w100); points[3].y = y + (17 * h100); + points[4].x = x + (45 * w100); points[4].y = y + (25 * h100); + points[5].x = x + (40 * w100); points[5].y = y + (30 * h100); + points[6].x = x + (30 * w100); points[6].y = y + (30 * h100); + points[7].x = x + (20 * w100); points[7].y = y + (23 * h100); + for (i = 0; i < 8; i++) + sx[i] = points[i].x, sy[i] = points[i].y; + s.n_controls = i; + compute_closed_spline(&s); + XFillPolygon (dpy, window, erase_gc, s.points, s.n_points, + Complex, CoordModeOrigin); + + points[0].x = x + (80 * w100); points[0].y = y + (18 * h100); + points[1].x = x + (75 * w100); points[1].y = y + (15 * h100); + points[2].x = x + (57 * w100); points[2].y = y + (15 * h100); + points[3].x = x + (55 * w100); points[3].y = y + (17 * h100); + points[4].x = x + (55 * w100); points[4].y = y + (25 * h100); + points[5].x = x + (60 * w100); points[5].y = y + (30 * h100); + points[6].x = x + (70 * w100); points[6].y = y + (30 * h100); + points[7].x = x + (80 * w100); points[7].y = y + (23 * h100); + for (i = 0; i < 8; i++) + sx[i] = points[i].x, sy[i] = points[i].y; + s.n_controls = i; + compute_closed_spline(&s); + XFillPolygon (dpy, window, erase_gc, s.points, s.n_points, + Complex, CoordModeOrigin); + + points[ 0].x = x + (48 * w100); points[ 0].y = y + (30 * h100); + points[ 1].x = x + (52 * w100); points[ 1].y = y + (30 * h100); + points[ 2].x = x + (56 * w100); points[ 2].y = y + (42 * h100); + points[ 3].x = x + (52 * w100); points[ 3].y = y + (45 * h100); + points[ 4].x = x + (48 * w100); points[ 4].y = y + (45 * h100); + points[ 5].x = x + (44 * w100); points[ 5].y = y + (42 * h100); + for (i = 0; i < 6; i++) + sx[i] = points[i].x, sy[i] = points[i].y; + s.n_controls = i; + compute_closed_spline(&s); + XFillPolygon (dpy, window, erase_gc, s.points, s.n_points, + Complex, CoordModeOrigin); + + free(s.points); +} diff --git a/utils/yarandom.c b/utils/yarandom.c new file mode 100644 index 00000000..63958e24 --- /dev/null +++ b/utils/yarandom.c @@ -0,0 +1,114 @@ +/* yarandom.c -- Yet Another Random Number Generator. + + The unportable mess that is rand(), random(), drand48() and friends led me + to ask Phil Karlton what the Right Thing to Do was. + He responded with this. It is non-cryptographically secure, reasonably + random (more so than anything that is in any C library), and very fast. + + I don't understand how it works at all, but he says "look at Knuth, + Vol. 2 (original edition), page 26, Algorithm A. In this case n=55, + k=20 and m=2^32." + + So there you have it. + + --------------------------- + Note: xlockmore 4.03a10 uses this very simple RNG: + + if ((seed = seed % 44488 * 48271 - seed / 44488 * 3399) < 0) + seed += 2147483647; + return seed-1; + + of which it says + + ``Dr. Park's algorithm published in the Oct. '88 ACM "Random Number + Generators: Good Ones Are Hard To Find" His version available at + ftp://cs.wm.edu/pub/rngs.tar Present form by many authors.'' + + Karlton says: ``the usual problem with that kind of RNG turns out to + be unexepected short cycles for some word lengths.'' + + Karlton's RNG is faster, since it does three adds and two stores, while the + xlockmore RNG does two multiplies, two divides, three adds, and one store. + + Compiler optimizations make a big difference here: + gcc -O: difference is 1.2x. + gcc -O2: difference is 1.4x. + gcc -O3: difference is 1.5x. + SGI cc -O: difference is 2.4x. + SGI cc -O2: difference is 2.4x. + SGI cc -O3: difference is 5.1x. + Irix 6.2; Indy r5k; SGI cc version 6; gcc version 2.7.2.1. + */ + + +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#ifdef HAVE_UNISTD_H +# include /* for getpid() */ +#endif +#include /* for gettimeofday() */ + +#include "yarandom.h" + + +/* The following 'random' numbers are taken from CRC, 18th Edition, page 622. + Each array element was taken from the corresponding line in the table, + except that a[0] was from line 100. 8s and 9s in the table were simply + skipped. The high order digit was taken mod 4. + */ +#define VectorSize 55 +static unsigned int a[VectorSize] = { + 035340171546, 010401501101, 022364657325, 024130436022, 002167303062, /* 5 */ + 037570375137, 037210607110, 016272055420, 023011770546, 017143426366, /* 10 */ + 014753657433, 021657231332, 023553406142, 004236526362, 010365611275, /* 14 */ + 007117336710, 011051276551, 002362132524, 001011540233, 012162531646, /* 20 */ + 007056762337, 006631245521, 014164542224, 032633236305, 023342700176, /* 25 */ + 002433062234, 015257225043, 026762051606, 000742573230, 005366042132, /* 30 */ + 012126416411, 000520471171, 000725646277, 020116577576, 025765742604, /* 35 */ + 007633473735, 015674255275, 017555634041, 006503154145, 021576344247, /* 40 */ + 014577627653, 002707523333, 034146376720, 030060227734, 013765414060, /* 45 */ + 036072251540, 007255221037, 024364674123, 006200353166, 010126373326, /* 50 */ + 015664104320, 016401041535, 016215305520, 033115351014, 017411670323 /* 55 */ +}; + +static int i1, i2; + +unsigned int +ya_random (void) +{ + register int ret = a[i1] + a[i2]; + a[i1] = ret; + if (++i1 >= VectorSize) i1 = 0; + if (++i2 >= VectorSize) i2 = 0; + return ret; +} + +void +ya_rand_init(unsigned int seed) +{ + int i; + if (seed == 0) + { + struct timeval tp; +#ifdef GETTIMEOFDAY_TWO_ARGS + struct timezone tzp; + gettimeofday(&tp, &tzp); +#else + gettimeofday(&tp); +#endif + /* ignore overflow */ + seed = (999*tp.tv_sec) + (1001*tp.tv_usec) + (1003 * getpid()); + } + + a[0] += seed; + for (i = 1; i < VectorSize; i++) + { + seed = a[i-1]*1001 + seed*999; + a[i] += seed; + } + + i1 = a[0] % VectorSize; + i2 = (i1 + 024) % VectorSize; +} diff --git a/utils/yarandom.h b/utils/yarandom.h new file mode 100644 index 00000000..6563be7e --- /dev/null +++ b/utils/yarandom.h @@ -0,0 +1,52 @@ +/* xscreensaver, Copyright (c) 1997 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. + */ + +#ifndef __YARANDOM_H__ +#define __YARANDOM_H__ + +#undef random +#undef rand +#undef drand48 +#undef srandom +#undef srand +#undef srand48 +#undef frand + +#ifdef VMS +# include "vms-gtod.h" +#endif + +#define random() ya_random() +#define srandom(i) ya_rand_init(0) + +extern unsigned int ya_random (void); +extern void ya_rand_init (unsigned int); + + +#if defined (__GNUC__) && (__GNUC__ >= 2) + /* Implement frand using GCC's statement-expression extension. */ + +# define frand(f) \ + ({ double tmp = (((double) random()) / \ + (((double) ((unsigned int)~0)) / ((double) (f)))); \ + tmp < 0 ? (-tmp) : tmp; }) + +#else /* not GCC2 - implement frand using a global variable.*/ + +static double _frand_tmp_; +# define frand(f) \ + (_frand_tmp_ = (((double) random()) / \ + (((double) ((unsigned int)~0)) / ((double) (f)))), \ + _frand_tmp_ < 0 ? (-_frand_tmp_) : _frand_tmp_) + +#endif /* not GCC2 */ + +#endif /* __YARANDOM_H__ */ diff --git a/xscreensaver.lsm b/xscreensaver.lsm new file mode 100644 index 00000000..810e2311 --- /dev/null +++ b/xscreensaver.lsm @@ -0,0 +1,28 @@ +Begin3 +Title: xscreensaver +Version: 2.16 +Entered-date: 21FEB98 +Description: A modular screen saver and locker for the X Window System. + Highly customizable: allows the use of any program that + can draw on the root window as a display mode. + Comes with more than 60 display modes. + Home page: http://people.netscape.com/jwz/xscreensaver/ +Keywords: screen saver, screen lock, lock, xlock, X11 +Author: jwz@netscape.com (Jamie Zawinski) +Maintained-by: jwz@netscape.com (Jamie Zawinski) +Primary-site: ftp.x.org /contrib/applications/ + 742K xscreensaver-2.16.tar.gz + 17K xscreensaver.README + 1K xscreensaver.lsm +Alternate-site: sunsite.unc.edu /pub/Linux/X11/screensavers/ + 742K xscreensaver-2.16.tar.gz + 17K xscreensaver.README + 1K xscreensaver.lsm +Platforms: Linux, Irix, SunOS, Solaris, HPUX, AIX, FreeBSD, NetBSD, + BSDI, SCO, OSF1, Ultrix, VMS. + Requires X11 and ANSI C. + Works with Motif or Athena. + Shadow passwords, Kerberos, and OpenGL optionally supported. + Multi-headed machines supported. +Copying-policy: BSD +End diff --git a/xscreensaver.lsm.sh b/xscreensaver.lsm.sh new file mode 100755 index 00000000..2ae10138 --- /dev/null +++ b/xscreensaver.lsm.sh @@ -0,0 +1,53 @@ +#!/bin/sh +# +# generate an lsm file (http://sunsite.unc.edu/pub/Linux/Incoming/LSM-TEMPLATE) +# that is more-or-less correct for the current version of xscreensaver. +# jwz, 18-Jan-98 + +size() { + ls -l $* | + tail -1 | + sed 's/.* \([0-9][0-9][0-9][0-9][0-9]*\) .*/\1/' | + sed 's/[0-9][0-9][0-9]$/K/' +} + +TAR_SIZE=`size xscreensaver-*.gz` +README_SIZE=`size README` +#LSM_SIZE=`size xscreensaver.lsm` +LSM_SIZE="1K" + +VERSION=`sed -n 's/.*\([0-9][0-9]*\.[0-9]*\).*/\1/p' < utils/version.h` +DATE=`date '+%d%b%y' | tr a-z A-Z` + +#URL=`sed -n 's/\(http:[^ ]*\)/\1/p' < README | sed 's/[^a-zA-Z/]$//'` + +echo "Begin3 +Title: xscreensaver +Version: $VERSION +Entered-date: $DATE +Description: A modular screen saver and locker for the X Window System. + Highly customizable: allows the use of any program that + can draw on the root window as a display mode. + Comes with more than 60 display modes. + Home page: http://people.netscape.com/jwz/xscreensaver/ +Keywords: screen saver, screen lock, lock, xlock, X11 +Author: jwz@netscape.com (Jamie Zawinski) +Maintained-by: jwz@netscape.com (Jamie Zawinski) +Primary-site: ftp.x.org /contrib/applications/ + $TAR_SIZE xscreensaver-$VERSION.tar.gz + $README_SIZE xscreensaver.README + $LSM_SIZE xscreensaver.lsm +Alternate-site: sunsite.unc.edu /pub/Linux/X11/screensavers/ + $TAR_SIZE xscreensaver-$VERSION.tar.gz + $README_SIZE xscreensaver.README + $LSM_SIZE xscreensaver.lsm +Platforms: Linux, Irix, SunOS, Solaris, HPUX, AIX, FreeBSD, NetBSD, + BSDI, SCO, OSF1, Ultrix, VMS. + Requires X11 and ANSI C. + Works with Motif or Athena. + Shadow passwords, Kerberos, and OpenGL optionally supported. + Multi-headed machines supported. +Copying-policy: BSD +End" + +exit 0 -- 2.39.5