Imported wmMatrix-0.2.tar.gz

This commit is contained in:
Alexey I. Froloff 2012-08-14 17:04:14 +04:00 committed by Carlos R. Mafra
parent 91a59cb9a4
commit 902e9790e6
18 changed files with 8144 additions and 0 deletions

38
wmMatrix/Makefile Normal file
View file

@ -0,0 +1,38 @@
CC = gcc
CFLAGS = -O2 -Wall
INCDIR = -I/usr/X11R6/include/X11 -I/usr/X11R6/include
DESTDIR= /usr/X11R6
LIBDIR = -L/usr/X11R6/lib
# for Linux
LIBS = -lXpm -lX11 -lXext
# for Solaris
#LIBS = -lXpm -lX11 -lXext -lsocket -lnsl
OBJS = wmMatrix.o matrix.o xutils.o yarandom.o
.c.o:
$(CC) $(CFLAGS) -D$(shell echo `uname -s`) -c $< -o $*.o $(INCDIR)
all: wmMatrix.o wmMatrix
wmMatrix.o: wmMatrix_master.xpm wmMatrix_mask.xbm
wmMatrix: $(OBJS)
$(CC) $(COPTS) $(SYSTEM) -o wmMatrix $^ $(INCDIR) $(LIBDIR) $(LIBS)
clean:
for i in $(OBJS) ; do \
rm -f $$i; \
done
rm -f wmMatrix
install:: wmMatrix
install -c -s -m 0755 wmMatrix $(DESTDIR)/bin

358
wmMatrix/config.h Normal file
View file

@ -0,0 +1,358 @@
/* config.h. Generated automatically by configure. */
/* config.h.in --- xscreensaver, Copyright (c) 1998 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 <X11/extensions/readdisplay.h>.) 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.)
*/
#define HAVE_MIT_SAVER_EXTENSION 1
/* 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 */
/* Define this if you have the XDPMS extension. This is standard on
* sufficiently-recent XFree86 systems, and possibly elsewhere. (It's
* available if the file /usr/include/X11/extensions/dpms.h exists.)
*/
/* #undef HAVE_DPMS_EXTENSION */
/* Define this if you have the functions XF86VidModeGetModeLine() and
* XF86VidModeGetViewPort(), in support of virtual desktops where the
* X server's root window is bigger than the actual screen. This is
* an XFree86 thing, and probably doesn't exist elsewhere. (It's
* available if the file /usr/include/X11/extensions/xf86vmode.h exists.)
*/
/* #undef HAVE_XF86VMODE */
/* Define this if you have a Linux-like /proc/interrupts file which can be
* examined to determine when keyboard activity has occurred.
*/
/* #undef HAVE_PROC_INTERRUPTS */
/* *************************************************************************
CONFIGURING GRAPHICS TOOLKITS
************************************************************************* */
/* Define this if you have Motif.
*/
#define HAVE_MOTIF 1
/* Define this if you have Gtk.
*/
#define HAVE_GTK 1
/* Define this if you have Athena (-Xaw).
*/
#define HAVE_ATHENA 1
/* 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.)
*/
#define HAVE_XawViewportSetCoordinates 1
/* Define this if you have the XPM library installed. Some of the demos can
* make use of this if it is available.
*/
#define HAVE_XPM 1
/* 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 1
/* 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.)
*/
#define HAVE_GL 1
/* Define this if you have OpenGL, but it's the MesaGL variant. (The
libraries have different names.) (HAVE_GL should be defined too.)
*/
/* #undef HAVE_MESA_GL */
/* Define this if your version of OpenGL has the glBindTexture() routine.
This is the case for OpenGL 1.1, but not for OpenGL 1.0.
*/
#define HAVE_GLBINDTEXTURE 1
/* Define this if the `xscreensaver' process itself (the driver process)
should be linked against GL. Most systems won't want this (in particular,
if you're using Linux and/or Mesa, you don't want this) but SGI systems
do want this. It may also be useful on other systems that have serious
GL support -- you only need this if you have a lot of different visuals,
not all of which work with GL programs.
*/
/* #undef DAEMON_USE_GL */
/* Define this if you have the X Shared Memory Extension.
*/
#define HAVE_XSHM_EXTENSION 1
/* Define this if you have the X Double Buffer Extension.
*/
#define HAVE_DOUBLE_BUFFER_EXTENSION 1
/* 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 "/packages/libexec/emacs/20.2/sparc-sun-solaris2.6/yow"
/* *************************************************************************
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 you want to use PAM (Pluggable Authentication Modules)
* to lock/unlock the screen, instead of standard /etc/passwd authentication.
*/
/* #undef HAVE_PAM */
/* If PAM is being used, this is the name of the PAM service that xscreensaver
* will authenticate as. The default is "xscreensaver", which means that the
* PAM library will look for an "xscreensaver" line in /etc/pam.conf, or (on
* recent Linux systems) will look for a file called /etc/pam.d/xscreensaver.
* Some systems might already have a PAM installation that is configured for
* xlock, so setting this to "xlock" would also work in that case.
*/
#define PAM_SERVICE_NAME "xscreensaver"
/* Define if you have PAM and pam_strerror() requires two arguments. */
/* #undef PAM_STRERROR_TWO_ARGS */
/* 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-pwent.c
* if you're having trouble related to reading passwords.)
*/
#define HAVE_SHADOW_PASSWD 1
/* Define this if your system is Digital or SCO Unix with so-called ``Enhanced
Security'', that is, the passwords live in /tcb/files/auth/<x>/<xyz>
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 */
/* Define this if you are on a system that supports the VT_LOCKSWITCH and
VT_UNLOCKSWITCH ioctls. If this is defined, then when the screen is
locked, switching to another virtual terminal will also be prevented.
That is, the whole console will be locked, rather than just the VT on
which X is running. (Well, that's the theory anyway -- in practice,
I haven't yet figured out how to make that work.)
*/
/* #undef HAVE_VT_LOCKSWITCH */
/* Define this if you the openlog(), syslog(), and closelog() functions.
This is used for logging failed login attempts.
*/
#define HAVE_SYSLOG 1
/* *************************************************************************
OTHER C ENVIRONMENT JUNK
************************************************************************* */
/* Define this to void* if you're using X11R4 or earlier. */
/* #undef XPointer */
/* Define if you have the nice function. */
#define HAVE_NICE 1
/* Define if you have the setpriority function. */
#define HAVE_SETPRIORITY 1
/* Define to empty if the keyword does not work. */
/* #undef const */
/* Define if you have <sys/wait.h> that is POSIX.1 compatible. */
#define HAVE_SYS_WAIT_H 1
/* Define as __inline if that's what the C compiler calls it. */
/* #undef inline */
/* Define to `int' if <sys/types.h> doesn't define. */
/* #undef mode_t */
/* Define to `int' if <sys/types.h> doesn't define. */
/* #undef pid_t */
/* Define as the return type of signal handlers (int or void). */
#define RETSIGTYPE void
/* Define to `unsigned' if <sys/types.h> doesn't define. */
/* #undef size_t */
/* Define if you have the ANSI C header files. */
#define STDC_HEADERS 1
/* Define if you can safely include both <sys/time.h> and <time.h>. */
#define TIME_WITH_SYS_TIME 1
/* Define if you have the gettimeofday function. */
#define HAVE_GETTIMEOFDAY 1
/* Define if gettimeofday requires two arguments. */
#define GETTIMEOFDAY_TWO_ARGS 1
/* Define if you have the putenv function. */
#define HAVE_PUTENV 1
/* Define if you have the select function. */
#define HAVE_SELECT 1
/* Define if you have the getcwd function. */
#define HAVE_GETCWD 1
/* Define if you have the getcwd function. */
#define HAVE_GETWD 1
/* Define if you have the realpath function. */
#define HAVE_REALPATH 1
/* Define if you have the uname function. */
#define HAVE_UNAME 1
/* Define if you have the fcntl function. */
#define HAVE_FCNTL 1
/* Define if you have the sigaction function. */
#define HAVE_SIGACTION 1
/* Define if you have the <unistd.h> header file. */
#define HAVE_UNISTD_H 1
/* Define if you have the <crypt.h> header file. */
#define HAVE_CRYPT_H 1
/* Define if you have <sys/select.h> that defines fd_set and FD_SET. */
#define HAVE_SYS_SELECT_H 1
/* 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 */
/* Define this if you do pings with a `struct icmp' and a `icmp_id' slot.
*/
#define HAVE_ICMP 1
/* Define this if you do pings with a `struct icmphdr' and a `un.echo.id' slot.
*/
/* #undef HAVE_ICMPHDR */

904
wmMatrix/images/big.xpm Normal file
View file

@ -0,0 +1,904 @@
/* XPM */
static char * matrix[] = {
"56 837 64 1",
". c #000000",
"+ c #020E04",
"@ c #021804",
"# c #062604",
"$ c #0B3008",
"% c #021E04",
"& c #114410",
"* c #0C360E",
"= c #0D3E0E",
"- c #0E4E0C",
"; c #1F561E",
"> c #145417",
", c #136314",
"' c #1D5E1D",
") c #1C4E1C",
"! c #127410",
"~ c #269624",
"{ c #1AA614",
"] c #169614",
"^ c #26B529",
"/ c #178618",
"( c #246624",
"_ c #2F832F",
": c #2B7729",
"< c #368B34",
"[ c #3B9439",
"} c #298B27",
"| c #3AC237",
"1 c #42D73C",
"2 c #62DA61",
"3 c #32D634",
"4 c #88E688",
"5 c #1E751C",
"6 c #4CB34A",
"7 c #44AB42",
"8 c #42A244",
"9 c #26C227",
"0 c #FFFFFF",
"a c #40CC44",
"b c #52BB54",
"c c #3E9C3C",
"d c #5AC254",
"e c #286E26",
"f c #32CB34",
"g c #5ACA5C",
"h c #5ED05C",
"i c #2AA62C",
"j c #166E14",
"k c #62DE64",
"l c #3EDE3C",
"m c #36B634",
"n c #D9F9D8",
"o c #26CB24",
"p c #2E9A34",
"q c #66E561",
"r c #9DD89F",
"s c #7AF67C",
"t c #E8FEEA",
"u c #92F294",
"v c #D8F3D8",
"w c #76EE74",
"x c #73E774",
"y c #66E264",
"z c #D7F2D8",
"........................................................",
"...........++++++......................++++++...........",
"........++++@++++++.................+@+@#@@@@++.........",
".......+@@@###$#%@@++..............+@@#$$$&$#%@@+.......",
"......+@####*#**$%%@+.............@@$$$=-=--&$#@@.......",
".....+@$&;>>>,,'-)&$#++..........@%-!~{]]{{^]/!-$@+.....",
"....+@#)(__:::<[_('&*@+.........+#$}|123|4442|{5-@+.....",
"...+%%$([678[8668<:(=#@+.......+#%=90000000004a^,$%+....",
"...+##-:[b8[<<c8c[<:;#@+.......@$&!a000044000041~&%@....",
"..+@$-;_6d8_(e:_<86['*#@+.....+%-/~200019f|14000^-$%+...",
".++%=;e[7gc:>>>>_8h6:=#++....++#,i|0000f]]]]1000a,$@+...",
"..+@&(:cbg[j----:7k6:&##+.....@#5^|00009////|000a!=$@...",
".+%#;:<c7b<e-&-&e8g6_>*$@....+%=~a400049////f0002]-=@...",
".+@$;_[887_j---&:[g7_'&#@+...+%=i10000l9///!|0002i5&#+..",
".+%$(<8777_'=&-&e[d6_()*@+...@%&^400001^!!/!|0002^/-%+..",
".+@$(<888c_,--==:[b6<(;*%+...+#&m400003^//!!f0004^~-#+..",
".+@*e[688c_>=&&=e8d6[('=@+...+%-|000003{!!!!|0000|i,#+..",
".@@$([78cc:,--&&:[d6[e;=@+...@#&m000n0o{//!!|0000|~,#+..",
".@@*;<c787<,--&&:[d6_;)*@+...@%-i400004^//!!f0004i/-#+..",
".+@$':<86b<(----ecb7_;=#@+...+%=ia4000l9////|0002~,=@+..",
".++$;e<86bp(--&-e[d8:)*#+....+%=~|400049////9000a/>$@...",
".++#&;e[6g85->>>:8d6:&$#@....+@$!i|000qo/]]]f0003!-$%...",
"..+@*-;cdk7:>>'(_7g8:=#++.....+#-/iq0003]]^^2000a,$@+...",
"..+@$*)_dh75>,,e<7h6:$#@+.....+@=,/2000o]^^94000|-$@+...",
"...+#*&e8bc_j::_<[8:'$@+.......@$-!a00n199o12002i=#@....",
"...+@%$':<<_}_<[<:e'&@@+.......+@$=ia44214q041ri!%@+....",
"....+%#='e_<cc8c<(&*$@+.........+#$,i|1400002^!>=#+.....",
"....++@*&;;(ee::()=#@++.........+@@>!~im|||am/,=#++.....",
".....++@$*&&))))=*#@+............++#=-!!}}/}!-$@%.......",
".......+@@@##%%#%@+@...............+@#%$$$$$#%@%........",
"........+++@@%+@@++.................++%@%#@@%++.........",
"........................................................",
"............+.+.........................+.+.............",
"..........++@@+@++....................+@#%@@@+..........",
".........+@%#$#%@++..................+%%$&=#%@+.........",
"........+@#*=$*$#%++................+#$-,--=$#@+........",
".......+@@)e<ee(;)&$+..............+@#/|4f|^~/5-@.......",
".......+@#([d6[_:e()$..............@#$m000021|m}&.......",
".......@@#_dskd8<<:(=..............@%=20t00002|m,.......",
"......+@#*:gsh8_:(;=$.............+%$&a0t00aami5=.......",
"......+@#*_bsd[;;))$@.............+#$-20t00ip}5=#.......",
"......+@$$<dsb:&=##@+.............+#=-20t0a!,=$#+.......",
"......+@#*<bu6:=$$@++.............+%=-20t0a,-=%@+.......",
"......+%#*<bs6_=*#%@..............+#$>20t01,-$#%........",
"......+@$$<dsb:=$#+@..............+#=-40t0a,-$@@........",
"......+@$$<dsb:=##%+..............+%=-20t0f,=$#+........",
"......@@#$<bs6:$$@++..............%%$-40t0a-=%%+........",
"......+@$*<ds6:=##@...............+#=)20t0a,=$@.........",
".....+@##$<bu6:=$@@..............+@$=-40t0|,=#@.........",
"......+@$=<gsb:*##++..............%#=,20t01-=$@+........",
".....+@#$$<bsb:=$#@+.............+@$=-40t01,=$@+........",
".....+@#$=<gsb:=$#++.............+#$-,20t0o,-$@+........",
".....++#$=_dsb:*$$@+.............+@$-,40t0a--=#+........",
".....+%%$=<gs6:*$#@+.............+#$=,v0t0a,=*%+........",
".....+%$$&_dwb_**#@+.............+#=-!40t01,-$#@........",
".....@+$&;<6h8_,&=#@.............@@-!p20001{!,$@........",
".....+@=)(_7d8_(>=#%+............+%,}m40002|],=%+.......",
".....++=;e<[7[_e;&$@+............+@,i|20002|i5&#+.......",
"......+$=);(:(;)=$@@..............+=,}ima|p_,=#@........",
".......+%$*=&==$$@+................@$=),5,,=&#+.........",
"........++@+@++@+...................+@@@@@@@+...........",
".........++++++......................+++@++.............",
"...........+++++.......................+++++............",
"........+++@%++@++..................++@%#%%@@+..........",
".......+@%#$*$#$#@++...............+##$=-=&=$%@+........",
".....++@#$$=====$$%++............+@#$--,,,,,-=#@+.......",
".....+@#&&))&)--&=*#@+...........+@=,!//////!,-=%+......",
"....+%#;:<_ee(((((:'=+..........+#$~a429|9^^9|ai>@......",
"...++#$e[d8[____<[[_)#+........+@$-|000011212002}$+.....",
"...+%$=_bhdc<_<<[8b[;#+........+#=,2000044240000i$+.....",
"...+#=)_bh6[:e(e_[7<;#+........+=,/40004ff9|2004p$@.....",
"...+$)([bhc_,,>;(<c_;#+........@-/m00001^{{]|402~$+.....",
"..+@=;([bg[e>--&;:[_)@+.......+%,~|0000f]//!ia02}#+.....",
"..++$)([bh85--&&);(;$@+.......+@>/m00009//j!/imp>%+.....",
"..+@$&;[6h8:--&*&&&&#+........+@-5i0000f//!,!55,$+......",
"...+*&;[bh85--&=*$#@++.........@-5i0000o]/!,-=$#%+......",
"...@$*)_8dc}j>-=$$#%+..........@=-/200039{/,-*$%%.......",
"...+@$*:[78<_j'*=$#@++.........+%-,|000439{,,=$#++......",
"..+@%$$(<[88c_,&=##@@+........+%#=-^400003{!,=$#@+......",
"...+@#$>e_<p8_5>)=##++.........+#$-]91q4n3o{/,=$@+......",
"...@@#$-'e_[7[}:,-*$@+.........@#$-/i910n0lo^/-=#@......",
"...+%#*&->5~ccp[:'=##@+........+%=-!/]fl0n4qo{,=$@+.....",
"..+@$$=->'e~[ccc_(>&$@+.......+%=-!/]{flqnnn19]!-%@.....",
"...+$&;',!___~p8c}_(&#@........@&!]{^o331lqnn43^!$%.....",
"...@=)'ee_555}c77c[:;#%+.......%,}^|93fool00n001~=%+....",
"...@*;'5__}__~c7878};$++.......%>~if14l13l000004~=%+....",
"...+$&;:<cp[[876778<>$++.......@=5~|40qq0n000004~=@+....",
"...+$*):<878776768c_;#@........+&,}a000000000002~=%.....",
"...+#*=(<8888c88c[[e)#+........+$-!m40000000000a/$@.....",
"....+#$);(eee:ee((()*@+.........@$=/pm||mf|||mm}>%+.....",
".....+@#$*=*&=&==**$@+...........@#$-),,!,!,,--*%+......",
"......++@@######@@+++.............+@@%$$$$$$%%@%+.......",
"........++.@++@+@++.................+++@@@@%%++.........",
"..........++@+++......................++@+++............",
"........+@@@###@++..................@%##$$$%%+..........",
"......+@%#$*=$$*$%++..............+@#$&-,---*#@+........",
".....++@$$=&&&&&$$@++............+%#=-,!!!!!-=%@+.......",
"....++%=;';;;'';)=*#+...........+%%,]ii~iiii/,-$@.......",
"....+%#;_c<:e::<:(;&#+..........+#=p2n4afa14am~5=+......",
"...+@#*:7g6c_<[8[_:;=+.........+@$-a0000140002fp)@......",
"...+@$&<bh6[_[[8[<:(=@.........+#&!400003400041m,@......",
"...+$*)<6h7<e:_<_::;=@.........+=,_200029a222a|p,#......",
"...+$);[6h8:''eeeee;*+.........@-/i0000f{^9|a||p>@......",
"..+@=)([6g[e>';;(((;*+........+%,}^0000f]iiimmm~-+......",
"..++*&)<7g7<(j';))&*#+........+@-!~4000499{~/}5>$+......",
"..+@#$)_7g7[}:;&=$$%+.........+@$-/200001fi!j-=$+.......",
"..+@#$&_8gbc<_;&$$@++.........+#=-!100004fi!-=%@+.......",
"..+%$=)<8g67[_(&=$@@+.........+%=,/1000n01^!,=%%+.......",
"..+@$&><8d67p_(;=#++..........%#-!~40000q19~,=@+........",
"..+%=-;<7g68[_e;&*%++.........+#,/i4000002|~!-#%+.......",
".+@@)(:[86c<:('-=$%@+........+@%/^o000n2f9i/,=#@+.......",
"..+#;:<[cc<:,>)=$##+++........%$p|400043^]/,-*$@@+......",
"..@#;<cc8p_,>-==*#$%@+........%$i40nnq3^]/!,-==#@+......",
"..+#;:<ccc_j---->';)$+........+$~a000039////]ii/-@......",
"..+@)e_<88_(>'>'e_<:)@+.......@#/|200019]{{{910a/#+.....",
"..+%=;e[c6<!>>,e_8b['#+.......+#,i|40019]{^|2000i$+.....",
"...+=&;:<8<:,ee__<c_;@+........@-5~a4n4o^9912002p%+.....",
"...+#$&':___:___<__(=@+........+$-5ia413a122222m,#+.....",
"....@@$&'ee_<<<[<e;)*++.........@#&!i||244404|i/-%+.....",
"....+@+=);((:::ee;)=#@..........+@@,/im9|aa||i},$@......",
".....+@#*=&)));;)=*$++...........+@$-,5//~~~_,-&@+......",
".......++@###$###@+++..............+@#$$===$$%@++.......",
"........+++@+@@@@@+.................++@@%%##%%+.........",
"...........++++++.+....................++++++.+.........",
"..........+.+.........................+.+...............",
"........+@+@@++.....................@@%%@@+.............",
"......+@@$##$@@++.................+@#=$&=#%++...........",
"......+@$#**$$#@+.................+#==---=$#@...........",
".....+@#&-;5e;=#@@...............+@=!/{9f~,$%@..........",
".....@@=);_<8_'*$@++.............@#,/ia003i-=#@+........",
"....+@#)(e8dh8e**$@+............+@$/^fn000f,-=%+........",
"....+@%-(_c6h7<,-$%%+...........+#$/m100001^/-##@.......",
"....@%#>j_86g7c_j-#%@+..........@#=]910000019/=#@+......",
"....@#$;(_[6b68c_'*$@+..........%$=~^10000003{-=#@......",
"....+##;e}[7bb78<(-=$@+.........@$=~f1q0000049/,=%+.....",
"...+%%*,:}p77777c_5;*#@+.......+#$-{fl4n000n01f],$#+....",
"...+%#*>:}pc77787p_:-$@+.......+#=-{olqnnn00n44f/=%@....",
"...+%$=':~[i77i6ccc_'*#@+......+%=,iflq0n0n00n02i,$%+...",
"...+#$-j_[88m7c8c87[e>*%+......+$-/91qnn0nn0nn0q|],$+...",
"...+#=-([8i66i8}876c_'&$@......%=,/9qnn00nnl00003i!=%...",
"..+@$&,5p766678}p6d8<()*@+....+%&!{f4n000nnl40004^/-#+..",
"..++=>'<8b|ggmi87878_(>$%.....+@,~^4n00000nnn00029~-%...",
"...@='e8bhghhb6i66mc_e;*@......@,i|n0000000n00002|p>%...",
"..+@=;:cbghghg6m88c[_e;=%.....+#,ian00000000n0002|~,#...",
"...+=-'_8mbmbi[}__ee;)=#+......%-/{1n0000nq1l3|9i/,=+...",
"...@#$&e_ccc8}_,'>>-=$#@+......@$-!|10nn0lf^{]]/,-=@+...",
"...+@##>(__<[5'&**$##%@+.......+#$=]91144f^!,>==$#%+....",
"....@%$-(5___(-$*##%@+..........@$=/^fa149/--==%%+......",
"....+@%=;(j::'&$#%%+++..........+@%'pm9a|i!=$##@++......",
".....+@=);((e;=@@@+..............@#,/imm|~,#%@+.........",
".....++$*&&))=$@++...............+@&>55//,=%++..........",
".......+#$#$##++...................@$===&$++............",
".........@+++........................@+++...............",
"........................................................",
"........................................................",
"........++@+@+@+++..................++@@@@@@++..........",
"......+@##$$*$*$#@+...............+#$&=-----=%@.........",
".....++$=&)))>))=*%@+............+@=,5//}~//,-#%+.......",
".....@#*);''';'()&$@+............@$>}~i^iiim}5&#@.......",
"....+%$);ee__<<<_()&#+..........@$&/iaaa14401m/,$+......",
"....@#=':<<<<87b[_;)$+..........@=,i|444000002i/-+......",
"....%$=(_[c8cbghb[:;*@..........#=,m20n0000000ap>%......",
"....+$*)(:_<_[6b7<:;&@+.........@=-~m|14100004ai,#+.....",
"....@%$&;'j55}[7[<:'=@+.........%$&!]^9ool4001|i,@+.....",
"...+@#$*&->',5_[<_e;&++........+@$=,!/]{{o1qq1ai!@+.....",
"...++##&>'j5:[p7c_:'=%+........+%$=!]^9o3lq001ai,#+.....",
"...+@#*>j__[~87b7<:;=++........+%$-]9334q00004ai,@+.....",
"...+##*;:<876bgg6[:;=%+........@#=-ia400000000ap,#+.....",
"..+@$*-:[8887876[_()$+........+@=,/o400nn00001^/-@......",
"..++$)'}8d7c_<<<:')=#+........+%-/i400004144a^/,$+......",
"..@%&'e8bg7~55(';)$$@+........@#!{f0000lf99^~_-&%+......",
"..+#&e_86g8_j,'>&=#@++........+$5|2000039^{]!,=#@+......",
"..@#>:<867<e'>>-=*$%++........@$~|4000qf{]]/,-=#@+......",
"..+%;_cc[8_,-&&=$##%@.........%$p2n0003^/!!,-=$%%.......",
"..+#;:<c[[_,-=&&==$#+.........+$~a00041{/!!!,,-$@.......",
"..++&;:_[c_j>,,((;(;*+........+@5i|30039]{{^^im~>+......",
"..@@*&;_[c_(>'e:___e&+........%@>!ia0029]{|a222|5@......",
"...+$=-e<8_(>(:<<_[:&@.........%=,/|40l9]9o4440a5@......",
"...+@$*;e_:5je_<:_e;*+.........+#=,{|2af9a2422|i>+......",
"....@@#&>(e::__<:(;&$+..........@#$!~^|aa222ami5=+......",
"....++%$&>(:__:_:;&*@+..........+@%-!]^a2a22|p5)#+......",
".....+@#$=&);;(;)&$#@............+%$=,5]~iii}5=$@.......",
"......++@#$$==**$$@...............+@#$=-,,)>==#+........",
"........++@@+@@@+++.................+@@@%%##@++.........",
"..........+++++++.....................+++++++...........",
"........................................................",
".......++###$%+@++.................+@$=$=$@@++..........",
".......$=&);;)=#@++................=,5}pi/,&#@+.........",
"......+=;e::_()=$#@++.............+,p|fa2m/,=$%++.......",
"......+&;e:_<:(-&$@@+.............@,i|a24|^/!-##+.......",
".....++*);(::__:(>*#@+...........++>_~ma2123^]-=%+......",
".....++%*&;(:_c8<,&*#@+..........+@$-!i^f1004^!-$#+.....",
".....+%#$*;;(<86c:>&*@+..........+%$=-]i92000f]!-%@.....",
".....@@#$=->,:}8[<<(-$%+.........%#$-,/]^fl00449/=#@....",
"....+@@$$=->,(_~[c7_(*%@........+@#=-,/]{93lqn04^-#@....",
"....++##$*->>jj_p7b8(=#@+.......+%$=-,/]]991q000|,=#+...",
"....@%$)(e555}}c7dh6:=$@+.......@#=/^9oooll00000f,=%+...",
"...+@#=(<8c[[c77bgxb_-##+......+#=,m4000q0n000003/=$@...",
"..++#$&_8g67876bgywg<-$#@.....++$-!30000n00000t04/=$@...",
"..+@*)'<767p/[pcmgyb_-$#++....+%-/^2000qlqqn00003/-$@+..",
"..+@&(e[76[_j55_[7h6_=*#@+....+#5^a00001^of340001!-$@+..",
"..@#;:[[78<j'>>,:8d85&*#++....%$~a000019{{{{30009!-&%+..",
"..+#;:c[88_,>>>,/cd8_=$#++....+$ia00001^]]]{3000a!=$@+..",
"..+#;_[c[c_j->>>:cg75&$%@.....@$p2000n39/]]]f000o!-%@...",
"..+#;_c[[[e,>---_pg8:=$@+.....@$i20000f^]/]/3000|,=#@...",
"..+#)e<[[[_,->>,_8d85=#%+.....+$}a4400o^/]{{3000o,=#+...",
"..++=;e<c8<j>,,(_8d8e*#%+.....+@,~|4n049]{^91000|-$#+...",
"..+@$*):8b[e>,::[8b['$%+......+@=,/a004o{^fa4000^-%@....",
"...+#*&e[8<:>e5__[8<'#@+.......@$-5|004f{9f12004i&@+....",
"...+@$$)e_e5ee___:e;=%@+.......+%=-}|1a9|f122a|p,%%+....",
"....+@#*)'(:::__e;&*#++.........+@$,/imaaaa2|i!-$@+.....",
"....+++$=&'(::e:;)#@@++.........+@@*,!ima|aai!=##++.....",
".....++@#*=&))))=$%@+............++#=-,!}//_,=#@+.......",
".......+@@#$##$##@++...............+@#$=====$@@+........",
".........+++@+@+++...................++@@@@@%+..........",
"...........+++.+.......................+++.+............",
"........................................................",
"......+@#$#$$$*$#$##@+............+%$*&-----&==$%+......",
".....+@$=);;;));)))=#@+..........+#-,/}~~}/~///,=%+.....",
"....+@$&;'(eee(e'(;;=$@+........+#&5i^^|9|9|mmi~,&#+....",
"....@#*;:<:__::_e_e()=#+........@$-pa422aaaaaaam},$@....",
"....+#=:8d7[<<<<<[[<()=#........@$,a000044444004m/,$....",
"....#$&<bxg7[[<<[86[:;&$........$&540t000q440000|i5=....",
"....@$&[dxg6[[[<[[c[:;&#........%=500000q0q40000ap5=....",
"....+#*:8g6c}_:e:::(;)*#........@$)2000nl1a9|aa|i5>$....",
"....@@*([6c[_jj>);;&&*$+........%%-m00n0399]]~~5(>=@....",
"....@@$'<8<__e'&==**$$#+........%#=i404419{!,,,--=$@....",
"....+@@)(:<pc_,=&$$$#@@.........+@#/ma4403^!j-==$#@.....",
".....@@=)(_[6_(==$#@@+...........@#,}^2002^,,-$%@+......",
".....+@#=&:[b[,=$$#@+............+@*,/a00l9,-=$#%.......",
"......+#$&e<8<e-=$#@@.............+$=!|2029/,-$@@.......",
"......++%$;_[<(')$#@+.............+@$*i2049{/-$#+.......",
".......@@#;:[_e')=#@+..............@#$~a02|i/,$#+.......",
".......+%#=;(::_(&#%+..............+#$,i||119!$#@.......",
"........+@$=)e<[:;#%@+..............+#=,/|20a~$#@+......",
"........+@%$$'<6<;##++..............+@$=-^404{=$@+......",
".........+@#$;<8<:=*#+...............+%$=i404|!-$+......",
".........+@##;:8<:()$+...............+%$$~a0q|m}&@......",
"..........+@#)e[<::;=@................+%$/|042|i,@......",
"..........++@=;:::_e=+................++#(paaa2|,@......",
"...........++$=)(:_e)+.................+@=,}ma2|5@......",
"............++#$)e[:&@..................+@$=}|015@......",
".............++@=;e;*+...................+@#(p|i;+......",
"...............+$*&*#......................+=)5)$.......",
".................++..........................++.........",
"........................................................",
"........................................................",
"........................................................",
"...........+++++++.....................+++@+++..........",
".........+++@@%@+@++.................+@@%#%#@@@+........",
".......++%$*===&$$%@+..............+@#&-,,,!-=$%@.......",
"......+@#$&)'';';&*$%++...........+@$=!}iiii~!-=#@+.....",
".....++@$=;(::::e'==$@+..........+@#&,~^aa1f|i!,=%@.....",
".....+@=;(ee::::55:'&#@+.........+%,i||aaffaooai!$%@....",
"....++#;_[<_e:5e_<c_'*%@........+@$~20419fff14n2i-#@....",
"....+%#e[dc_ej55<7g85=#@+.......+#$|000199994000f,=#+...",
"....+@$:7g8_5555}7g8e&$@+.......+%=a0001ooool000|,=%@...",
"....+#$:6h7}(jjj[7g6_=##@.......@$&a00019999l0003!=$%...",
"....@#$_6k7~jjj,}7h7_-$%@+......@$-2000l999930003/=$@+..",
"...++#*e7g8p:___cbd6_-$#@+.....+%$-|000l3o33n0003/-$#+..",
"...++#*e[6787i7m6|g85>$#++.....+@$-|000nnn000000f/-$@+..",
"...+@$*;:[7mbghhhgg7:-&#%+.....+#=-ia0n000000000o/,=#+..",
"...+@#$;_<6dhghhhgb7/&*$@+.....+#$-if0000000000n3/-=#+..",
"...+%#*e_776gbb66bg8_>*#%+.....+%=-94n00000000003],=%@..",
"...+%$$:cb|bdm7i7mg8_>&$@@.....+#=-fn00000nnn00n3],=%@..",
"...+%#=5cb6|b7p}c6b7_'&$@+.....+#=,f00000nqln0001{!-%+..",
"...+%$*:8g7cp}_5}p7c_,-*@+.....+#=,f0000ql3o14001^/-#+..",
"...+@%=:7g7}55j!:}8p_(;*#+.....+%$,a00nloo993l0019],$@..",
"...+%#=_6g8_>>,>5}[<_(,=%@.....+#$,20003{{{{o3441|i,#@..",
"...+%#$:8hc5j>,>5<68_(;*@+.....+%=-|000o^{{]fq002^]>%+..",
"....@%$:8g8_,',>5cd6_;)*++......@#-a0003^{{]o0002i/>@+..",
"....@@$:8d8:,>>-:cg6<'&$@.......%#=|00no^{]/f0004i5=%...",
"....++%;:[_:jj,,:<8<(&$@+.......+@#~a02a99^^f204m5-#+...",
"....++@=;(ee:ee(:::e)$#@........++#,pm9|o|9|faa|}-$@....",
"......+#$*;(e:::e(;)*@@+..........+$-,~m|a|a|mi/-#@+....",
"......++%#=)';;;;&)*#@+...........+%%=,/i~pi~55>$@+.....",
".......+@@#$=****$##.+.............+%#$&,>>--==$++......",
"...........@+@+@++++..................+@@#@#@@++........",
"............++++++......................++++++..........",
"..........++@@@@+++...................++@@@%+++.........",
"........++++@@@@@+++................++%@#####%@+........",
".......++@$=)&))&*$#++.............+@#=,55//!-=$@+......",
"......+@%#&;(((('&=*%@+...........@@#$!~9mmmi5,-$@+.....",
".....+@@$$)e::::e'-=*@++.........+@#=-/9aaaa|{/,-#@+....",
"....+@%=;(ee:::eee:()*%@........+%#,~9||afa9faa^/-$@....",
"....+@#)_[__:e((:<[<'=$@+.......+%=~1441ff99|404^,=#+...",
"...+@%*([68<55,,_868e)*#+......+%%-m0004f9^^1n00a/-=@...",
"...+@#*ec6[_e(,'e<7[_>&$@+.....+@=-f00039^{{f400a~!=@+..",
"...+%$*:cb[5,,>>j<c<:(>$@+.....+#=-an00f^{]]9404a^~-#+..",
"...+@$*e8b[5>>>>(:<[:(;=%+.....%#=,f004o]]]]^f041|i,%@..",
"..+@#*&_8gc5>,>-j_[[_e'=%@....+@$-!a000o{{]]91041|i,#@..",
"...@%#=_7gc/>,>>j_8[_e'=#+.....@$=j100q3]{{]91n019i,$+..",
"..+@$$=}6g8:>,',5_8c_e;=@+....+@==!100n3{{{{o1002|i,#@..",
"...@%$&_6h6~5!5j_c6c_()$%+.....%$-j2000looo910001^/-#+..",
"...@##=}bhdmc[~[c7b8:;&$@+.....@$=!10000nqlq0000ai!=@+..",
"...+%$=_bkhb7667bbg8_)*%+......+#=,10000000000001/-$+...",
"...+@#=:7ggdb66c877[(=$@+......+%=,a000000000000m,&#+...",
"...+@##(<87bb7[___:()$@@.......+%$=^40000n03a2a|/-%@....",
"....@#$>5<c76c/>>;)&$#++........@$=]f4n0003{]]/!&$%+....",
"....++#&'5[8bp_'>=*$#@@+........+@$5if40041{]!,==#@+....",
".....@@*&>_~8[_5(-*$#+++.........@#-!~1q00lf^/,*$@++....",
".....+@#$*(<78c<5>*#%%+..........+@$-,m40004f]-=##+.....",
"......+@##;:c[[[_'=$@++...........+@$={a0000a{,=#%+.....",
".......@@#=;e:_<:';&$@.............%#$(~|a24a^]5=@......",
"........+%$$=;(::ee;$+..............+%=-,~^aa||p-@......",
".........++@%=;e(:e;&@...............+%%$,p||a|i,@......",
"..........+@@$=))))=#+................+@#='}_}_,$+......",
"...........+++@##$#@+..................++@#$*=$#+.......",
"..............+++.+.......................@++++.........",
"........................................................",
"........................................................",
"........................................................",
"........................................................",
".............++++........................++@+...........",
"...........++@$$#+.....................+@%&=$@..........",
"..........@#*&;e>&++..................@=-5i|~,@+........",
"..........#*)(_[:)@+..................$>/m20a}%@........",
".........+$=):[6<'#@+................+&,}a004i$%@.......",
".........+#*)ecd[;$%@................+$)5|000i=#@.......",
".........+@#*e[d[e$#%+...............+%=>r000|-$#@......",
"........+@@#$(cg[e=#%@..............%%#$&|000|,*#@......",
"........++%#*([6[e>=#@+.............+@#=-m000f],=@@.....",
"......++%%#$$;_8<:()*%@...........++#%$=-{202a^/,#@.....",
"......+@@##**'e[__e'=%++..........+%%$=--ia042|i,%@+....",
".....+@$$&&));e::_:e)#@+.........@@&-!!//{|aa12|/$@+....",
"....@@@=;';''';(:_[:>#@++.......@%%,~i{{i{i^f20a~&#@+...",
"...+@%#)(:e(e,>-e_8_'*#@+......+##=/^1f9|^]/9102i-$@+...",
"..+@#=&;:_5(;>>&(_8<(=#@++....+@=,!iaa|^{]]/^204^,$#@+..",
".++%=;(e:_:,>>--j:8<'=$#@+...+%%,~^|a1f^]]//9104^,=$%@..",
".+%#)e:___('---)(_8<(=*#%@+..+%$/||1129{////^104^!-=#%+.",
".+@$;_[[<}:,'>>,_[6c}(;-=$#..+#-i20041f^{{{^300019~/,-$.",
".+$=:cb8[__:(5__[6db8c<e()*+.%=,a000q41o99310000004a^/-@",
"+@$&<bhb8____<c76dhgggb[:(&%+#=54000n123140000000000am5#",
".@$&:6gc__:55_<[886666c[:;=%.#=!20004aff|12000000000ai,%",
".+#=(<8_(;'>>;('e:::::e(')*+.@$,m2029~i]~i^m||aaaa|mi}>@",
".@#$)e:;>*$$$*$*==&=&&&&&=$+.%$=~||i/,--->--(,5,55555,&+",
".+@#=;'&*$$##$#%##$#$#$**$@..+#$'pi5-==$$=$$$=&$=*=>>=#.",
"..+@$*=$#@@%@+@%@%@@@%@@@@@...+#&>,-$###%@#%#%%#%##%##@.",
"....+@%+@@++++++++@+++@+........+#%%@@++++++++@+%+@+....",
".......................+...........................+....",
"........................................................",
"........................................................",
"..........+@@++.......................@@#@+.............",
"........+@#$=$@+....................+@$-,=#+............",
".......++%*&;=#++..................+@#>5~,=@+...........",
".......@*=);()=@++.................#-,/im}>@@+..........",
"......+$)'e:_(&#@++...............+-}i|12^!$%@+.........",
"......+)e_<[[:>##%++..............+5|v200a]=$#@+........",
"......+*(:<[[:()=$@++.............+,m2400am/,=%@+.......",
"......+*&;e:<<_:,&$%++............+>5p|a4411^!=#@+......",
".......+#*;e:<c8_'##@+.............@$)~|24002i=$@@......",
".......++@&;:_87<(&*#%+............+@#5ia2004m!-=#@.....",
".......+@@*&;(:<:_:(&$#+...........+@#-5~m|411a^5=$+....",
"........+@#*=);(:<8_(=#@............@@$-(/i^a204^,=%....",
"........++@#$*&):[68:&*#+...........+@%$=-!}a000a5-$+...",
"........++@%$$=&e[bc:)$@+...........++%$=-,/|000|/-#+...",
".........+@#$$=-e[68:)=#+............@@$=-,/9000a},$+...",
".........+@@#$&&([6c:)$#+............+#%=-j!|000|/-$+...",
"........++#$*);e::<:;=#+............++$=-/{||24ap,=@....",
"........+@#$-(:<_e;;=#%+............+#*-/^a42|i~,=#+....",
"........@@*&)e<c_(=$#@@.............@%-!/|402m,>$@%.....",
".......+@$)(__:_()*#%++............@#=}m2222|/-$#@+.....",
".......%$*(<c<:;)$$@@+.............#&,m402ai_-=%%+......",
"......+#*):8dc(*$#+++.............+$,52000m-=$@++.......",
"......+*)(:[c:;*%%@+..............+>}ma00ap-$#%+........",
"......+=(_:ee;=@@++...............+,m2ar|~,#%++.........",
".....++):[:;**$@+................++}a01p,>=%%...........",
".......=;:;&*#+++..................,i|p5>$@++...........",
".......#*)$$@%+....................$>}-=%#+.............",
"........++++++......................+@++++..............",
"..........+...........................+.................",
"........................................................",
"........................................................",
"........................................................",
".........+++@+@+@+...................++@@@@@@+..........",
".......++@+%@%#%@+@++..............+@@@###$##@@@+.......",
".....++%#**=&&&&&*$#@+...........++#&--,!!!!!,&$%+......",
".....+@$=;;;'((e(;&*$+++........++@-,~~ii^9r^~!,&@++....",
"...+@@#=;(ee:_<<_e')=%++.......+@#$,~|||a2442|i/,$@+....",
"..++#$&;(eeee_<c<_e')=*#+.....++$-!~^9|||14041|i/,-$@...",
"..+@=;e(e:(,':c6c<_ee')*@+....@#,p||rf9^{a00043||i/-%+..",
".+@#;e<_:e(>-:[b7[__:e(&#@+..+%$~a221|^]/f000041aam5$#+.",
"++@$'_[_:e'>-:cd6c____e)*#+.++#&i202f9i]/f00001111a}-$@.",
".@$*(<[_'>>&=e[bc_jee::'&*$+.%=,m401^]]j!f00019f|a9i!,=+",
"+#$&e[[_;==&&j[bc_',:_:('&$%+$=!|00ai!!!!94001{^f219~5-#",
"+#$&:[8e>===&(<8[:,je::e(;=@%$-5a00|],,,,9400f{9ffa|mi,%",
"@$=)ec7_>=*==>:[<_:_:ee::e)#@=,_f00a],,,,{a441aaf9|aa|}$",
".$&;_[8e,*=**-(e__[_5ee_[<;#+&!p200f{>,,-/^a14q1f992q4p&",
"@$&):c7:'=*=$->':_c[5,(_[<'*@=5~a001{,-,-/]^f4nqf^9z04i-",
".%$):[7_>&=$=*->e<c[_ee:<_)$+$=5a002{!!-,,/]f2002f|122}=",
".+#*ec6<(-&***=&j<78<e::_:)#.@$>r004^/!---,!92002f9a2a}$",
".@+$([8_e>&=*$*=;<88<_e::e&#.%@=m002|]!!---,i4004aaaa|5$",
".++#)(_ee('>>&==>e__<<_e()*+.+@$}ma||^{~]!,,]|22442|^~>@",
"..++$&);(e('(>&$&;':_c<e&&#@..+%=5}pm|mim]!-!]^f40qr5,$@",
"...++#$=;::ee'-$*&&;_8[(*#++...+@$=5i|a||i/-,!5i200m,$%+",
"...+++#*&))))=*$$**);((&#++....++@$-5}}}/,)==--5i|m5$@+.",
".....+@@$$$$$$$$###$*==$@+.......+@#*&-=--&=$=$=),,=@+..",
".......++++@+@%#@@@@++++...........++@@@@@$$%@#@@%++....",
"..........+++++@++++++................++++@%++++++......",
"...............+...........................+............",
"........................................................",
"........................................................",
"........................................................",
".........++.+........................++.+...............",
"..+++@+@@+@+@+@+++............++@@@%@@%@@@@+++..........",
".++###$%@%%%#%@@@@++.........+@$$==#####$###%@@+........",
".%#$$$=*$$##$#$##%@+++.......#$-&-,-=======$$#%@++......",
"+#&);;>>->'(((>-&&&*#@+.....+=!}~~]]]]{^9^]/!!!-=%+.....",
"@=;((:ee(5_[[_ee''')=#@+....@,~m|aa|9f1404a|^ii/,=%+....",
"@&(:__<<__c7d7c:_:e(&$#+....#5m|22242100000aaaam5&$@....",
"+*);(e(eje[7d8_(('')=$%@....@>}{^99f^f400019^ii},=#@....",
"@$$&->,,',_8bc_'>>-&$#@+....%=-5/]{{^^100n1{]]/!-=#+....",
"+##$$*&--,_7bc5-&=**$#@++...@$$=-,!//{3n00o]!,,-=$#@+...",
"#$)>>>->',}8g8:>>-&=$$$@+...$-/]]]/]{^10003]]/!,-==@+...",
"*)ee(>>,'j}6di},>,--=**@+...-}|a^{{{^9300nl^{{]/!,-#+...",
"*(<c_e,j!5c7h7}j,>'>-&$$@...>|2039^999n00039^{{]/!-=%...",
"$;:_ee''(!c6h7<j(''>)&*#+...=pa2|9{^99q00049^{{]/!,$@...",
"$&;e'''(je[6g7}(,'-;-&*#+...&5i|ii{^99n0003^^i]~/5>$+...",
"@*&))->',e<6g8_,,;>)&&*#+...#)5}/]~{^940001^^]]/5!-$+...",
"+#$=&)->;,<8g8_'>>&&=*$++...+$-'!//]i{40003{]]5!,-&%+...",
".@@#$**=->_8d[:&&=$$##@+.....@#$&>,,/]3000|!!,-=$$%+....",
"..++@@#$$*:[b['=*##@++........+@#%$--,a000^,-=$#@+......",
"....@@%#$$ecb['$*##@+...........@%%$=-|004^--$$@@.......",
".....+@##*e[6<,*##+@+............+%$=-|004^-=$@%+.......",
".....+.###e[6<'*##@+.............++%$=9004i-=$@+........",
"......+@#$([b<'*$%++..............+#$=m001^-=#%+........",
"......++@#([d[e=$#@+..............+@%$m0009,-$%+........",
".......+%#([d[:)=#+................+#$m000f},$+.........",
".......++@'[d[:)=#+................+@#i000|},=+.........",
"........+@);_()*$@+.................+@5i2m},=@+.........",
".........+$*=*$#@+...................+=)(,=$#+..........",
"...........@+@++......................+@@@@+............",
"............++.+........................++.+............",
"........................................................",
"...........++..........................+%...............",
"........+@$*=$+.....................@%=>,&@.............",
".......@#$&);&#....................%$>5_i,$.............",
".......+$*)(e;$....................@&)}m|p).............",
".......@#$;:[(*+...................@$=pa0i,+............",
".......+@$;_8:&+...................+%&p2015+............",
".......++$;[6:)++..................+@&i00a}@+...........",
".......+%@;<6_)@+..................+##p402}@+...........",
".......+%$;[6:)++..................+%&i00a}@@...........",
".......@+#;<6_;%++.................@%$p002~#++..........",
".......@@#;[6:;@@+.................@#$i002p#@+..........",
".......@@$(_b_)#++.................@#=i402}$@+..........",
".......@@$;[6_;#@+.................@#=i002~$#+..........",
".......+@$;[6<;#%+.................@#&i004~$%@..........",
".......@@$;[6_;##@+................@#=i004i$$@+.........",
".......@@#(<b_'##@+................@#$m002{=$#+.........",
".......+@#;[6_;$#@+................+#$i002i=$#@.........",
".......+@#(:6<'$#%@+...............+#$i204i-=%@+........",
".......++@;<c_(=*#++...............+@#i402^,-*@+........",
"........@%)e[_e()$%+................@#_|02|^/-#@........",
"........@+&;(::_e&$@+...............@%,p|a22|5=@+.......",
".........+$=):[6_'#@+................@&,/|002i=#@.......",
".........+@$*;:[:'&$@................+#=(ia0ai,=%.......",
"..........+@$&;(';)=#.................@%&,pmip},$.......",
"...........++#$*&;;)#..................+@$=>5~i}=.......",
"............++@#*&;&$...................+%#$>5p5&.......",
"..............++@$*$+.....................+@%&>=@.......",
".................++..........................+@.........",
"........................................................",
"........................................................",
"........................................................",
"............+.+++.+.....................+.+++.+.........",
"........+++@+@++@@+@+++.............++@@@%@@@%@@@++.....",
".......+++%@%####%#@%@++...........++@###$$$$#$##%@+....",
"......+#$===&=&*&=&&==$%@+........+$-,,,!,!,!!!!,,-$@+..",
".....++=;((('(,(,,(,'>)*@+.......+@,~^m^^^^^^^^^{~/-#+..",
"....+@@)(___________::'&#@+.....+%#/|232131a32a11f^!=%+.",
"....+@#;_<<:_:_:_:__}__>$%+.....@#$~2022aa13a11114f]=#@.",
"....@@#([8c_j55j555_[[<'*#@+....@%=m4041999o9oo34n4i,$@+",
"...+%#*e[b~_jjjjj555p7c(&$@+...+#$-|00q399999oo3q009!=#+",
"...+%#=:86c_j5,555/<cmcj=$@+...@#=,|000lo99o9ooln0n9!=#@",
"..+@#*&:c68p<}}}}}}p7675&$%@..+@$-j3n0n43l3llllqn009!-#%",
"..+@#*-_[78c8[pc878i66c/-##+..+@=,/f00nnnqqqnnnn00no/=$@",
"..+@*)>_86m7i78i7i767m8:-*#@..+%-/]1n00nnnnnnnn00003/-$%",
"..+#)(_<c8c888787m6668ce,=#@..@$/|20nnnnnnnnn000000f{!*%",
"..+%;<c888iccip77m6m87p5'-*@..+$i20n0nn0nnnnn000nnq9{/-%",
"..@#([78c8p88c8i76bm8p_e')*+..%$m000nnqnnqnnn000nq1fi/-%",
"..@%)(_<pcp[ppcp8mgm7}_,-*$@..@#/m144nqq4qqqn000nl3^/,&@",
"..++$&>e~cp[[}[p7bhb85,>=#@+..+@-5]fln4qqlqq0000nf^],=@+",
"...@%$=,_c[}~}~}76hbp:>&$#++...%%=,^1nqllllln000qo]!=$@+",
"...+%#*e[7p}<_:/~877<:'&$%+....%#=-940qll333l0004f^!=#+.",
"...++#*j[bc}5/55_}p<_:(&#@+....+@$-9n0nloooo3lq41|^!=#+.",
"...+%##e[b[:!5jj55_:::e)#+.....+%$=|0043oo99o93a1a|/$+..",
"....@@$([8p_5jjj,(,''')*@+......%#*^40q3o9999^^^ii/-#+..",
"....+@#'_8<__:5e'>)&&=$#+.......+#$i20413o99^]/!!,-$+...",
".....@@)e_<___ej(-$*#@@+.........%%}|44111f9^/--&#@+....",
".....+@&(e__[<_e'&$#%@+..........+#!ia24041a{!=$%#@.....",
".....+@$=>:[7<_e'&#@@+...........+@&,]|000a|i!$%%+......",
"......+@$$ecd7<e>*#++.............+#=>|0004|~,$@+.......",
"......++@$;:<_(>&$@@..............++#=pa02m~!=%@........",
".......++%*);;=*$@+................+@#)_i~5-=#+.........",
".........+@%##%@++...................@%#$$%%@+..........",
"........................................................",
"........................................................",
"...............+.+.........................+.+..........",
".............++#%$##+....................+@$$==$@.......",
"...........++##*==)=#+.................+@$=-,,/,$+......",
".........++@%$*=);;)$+...............+@@#=-,}pi}-@......",
"......+++%@##=>(((e;*@+...........++@##$=,]^^m|~>@+.....",
"....++@+%###*>e:_::'&@+.........++@@#$$=-]|a1a|i!#@.....",
"...++@%##$*=='_c<_e'&#@@.......++##$==-,,{1042ai!$%@....",
"..+@$&>;>'>>'e_c[<<:;$%+......@#-5~]]{]{{f20044a~=#@....",
".@%*;:<__<_::_}cc87<'*%@+....@%>pa44441aa1lqn004^-#@+...",
".@$&:8d6668cp[<<c6bce*#@+....#&5a000000nq44l00009,$#+...",
".@#=([7866878c[}c8bce&*@+....%$,m000000nnn4l0000|!-#@...",
".@@#)(:<[87ccp}_[<c[e'&$@....%%=}ma40000nq43l0n0ai5=@...",
"..+@$=)e<[887p_!_}<_:e'=@+....+%=,}|40nn0q1o1141a|i,%+..",
"..+@%$=;:<c86[_j5e::::;&@+....+%$=,ia4000ql9ff1aa|i5#+..",
"...++#$);(<i6c:',''(e:e)#@+....+@$=/i94n00f{{{i^|a|/&%+.",
"...+++#$=-:cb[5---&)(:e;*#+....++@$-,/|n00o///!]ma|~>$+.",
"....++%##=e[6<e-&**&;:e)*#+.....+@#$=,|0009/!,-5i||_>$@.",
".....+@%##;_<<e'>&**&)=*#+.......+@%$=~a04|^]!--:},>$@..",
"......+@%#)(::_:(-#$$##@+.........+%#$/^aaa1m/===&$#+...",
".......++@$&((:_e)$#@%++...........+@%>/^|a1|/=$#%@+....",
"........+@$$&;e:e)&*#@+.............+@=-5i|a|~!>$%+.....",
".........+@#$;;:e;;&$++..............+@$*_ia|i~5&@+.....",
"..........+++=;:e(;&$@+...............+%@,ia|mi5=@+.....",
"...........++#&));;)*+.................++$,}}pp_>%......",
"............++#$=&;&*#+.................+@$=,5p5)$@.....",
"...............+$*)&*@@...................++=>}5>#@.....",
"................+$*$#@......................@=-=$%......",
".................@+++........................%@@+.......",
"........................................................",
"........................................................",
"...........++++++......................++++++...........",
"........+++++++@++..................+@+@@@@#@+..........",
".......@$=$$#*);&$@+...............%&,==$-/p5-%+........",
"......+$&;&=$)(_(=#@+.............@&5~5,=/m2^,$#+.......",
".....+@=;(;=='_[:;$@@+...........+@,~|]!,{20a~=%#+......",
"....+@@)e_e>=e<6_'$$#++.........@@#}|2|]!9404{-=$@+.....",
"...+@@#;<c_(-e<b[j&##@++.......+%#*i402^/f0009!=$%@+....",
"...+@#$([6<5'_8b[5==$#@+.......+%$&m004f{10009!,=$%+....",
".+@%#$$:[6<5'_8gc/-=*#%@+....+##$=-f0049{100no/!-=$@+...",
".+#$#$=:86c:j~8gc_>-=$$++....@$==-,|00039ln0q3]/,==@+...",
"+@$**$=:c6p:j}7g8/>-*$$%++..+#----,fn0q39l00n3{/,-=$@+..",
"@*)''';<7g7~:8mg6}5,,-=*%+..%-}ii{i400n33n0003o^{/,-#+..",
"@&e_:eecbg78~7dkdc:5j',*#@+.@5|2aff0000nln000n3o9^{,=%+.",
"#;<[[<[8bhb7cmghg6p~__()$%+.$i4004400000000000lllf|/&#+.",
"@)(::::86g67}8dgm8__5('=#@+.@}maaa|n000nln000n13f^i,=#+.",
"+$&);;;<mbc}/p6g6p5(,>&$%@..+=5}~~i4000l3q000q99^]!-%@..",
".++##*=:cbp_j}cmc}j'&=$#++...+@$=-,a00q39ln0n19{!,=$%+..",
".+++##*ecb<!'5p7p_j>-*#@@+...++@$&,|0049{oqnq39{/-=#@+..",
"..+@%$#e[6<5,j_[<_:(-*$@+.....+@%=*|00qo{o1044|9/-=#@...",
"...+@@$([6_(-(5__}<5>$#%@......+%%=m0029/^f31149]-$%%...",
"....+@#(_6_(->,e:_<e>$#@+.......+#$m402^/]^9324a]-$#+...",
"....+@@;<6_;&&>>(_[_'=$%+.......+%%i402i!!]~9202{,=%@...",
".....+%;<8:;====;_[<(*$#@+.......+#i40ai,,,,i304^,=$@+..",
".....+@;_8:;$$$*)e[_(&$#++.......+%p20a~----_|02m!-$@+..",
"......+)e[(&####=;;;';&*@+........+}|0m!$$$$,~iii]5-#@..",
".......&(_;=#@#@#*=&;(;=#@........+5m2p,$%$#$-,5~mp,$@..",
".......*;e)*@+@+@@%$&(;=$++........)p|})%@@@%%#&5mi,&@+.",
".......#*&*@@++++++#$==$@+.........$>5-#@+++++@$&,,&@+..",
"........+@@+....+.++@#@+............@@@+....+.++#$#@....",
"........................................................",
"........................................................",
"...........+++.........................+++..............",
"........++@###@++...................++#$=$%++...........",
".......++@$)(&*+++.................+@@-}m5-@@+..........",
".....++@@#;:<e)#@+@+.............+@%#$~a4|/$%@@+........",
"....+@%##$;_8:;$$%@++...........+@#$$=i401~=&##@+.......",
"...+@@##$=e[6_,=$$#@++.........@#%$=-,|004^,-=$%@+......",
"..@@#$$===:cb[(*=$$$%++.......@@$=-,,jf0009,,-==#@+.....",
".+@#$&&&->_cdc:>-==*$%@+.....@%$-!!!/]1000f]/!!-=$@+....",
"+%#=':__5([6h8_jj:5';=$@....+#$,{a33o94000399oo^~,-%....",
"+#*):76c[_cbkbc__[c_e;&#+...+$,/10004l0000032404|~5=+...",
"@$*'[bkbc~6dhb7}cc68_()=+...#=,i4000nl0000nl00002m}-@...",
"+$*-<6d8}_pdhmc:}[8[_(;*+...@=,/4000l3n0000f10002m~>@...",
"@$*&<6d8_5p7g7}j:<[<:(;$@...@=-/200n194000l93404am~-@...",
"+#*&_8dp5,[7g7_>j_[<:(;*+...@$-!100qo^l00n1{9304am~>@...",
"@#$=_7gc_jpbh7}5_<8<:(;*@...@$-j100qlo40003f34041m~>@...",
"@#$=_7dm<_8bhbc_<c7[_()*+...%$=!a0004ln000n340002m}>@...",
"+##*_6g6c~7gkb7_c768_()*@...@$=,10000400000400004m/)@...",
"+%#$(<8[_:c6h7[:__8<:;)$+...+#$-90001fn0000f2404ai/&+...",
"+@#$;:<e(,<7g7_'e:::;)*#+...+@$*~f2f^{20001{9|2ai},$+...",
".+@#*)'--&e8b<(-)'(())*%.....@%$,}i//!|0009/}imi~5)$....",
".++@$=)&**e[6[(==))&=*#%.....+@%=,/!,,|000^,!/~5,>$%....",
"..++##$***ecb_(=$=**$@+.......++$=--->|002^,-,)>=#%.....",
"....+@@%#$(<b_;$$#@++...........+@%#$*m002i=*$#@@.......",
".....++@@#;_8_)%@%@+.............+@##$p202}$%#@+........",
".......@@@):[e&#@++................%@%}|0r!$%@+.........",
"........++&;_;&+@+..................++5i2i,@@+..........",
"..........*)()$+.+...................+>}m}&+.+..........",
"..........@$=$+.......................%&,=%.............",
"...........+++.........................+@+..............",
"........................................................",
"........................................................",
"...............++++++......................++++++.......",
".............+@###@@@++..................+%==$%#%@+.....",
"............+#*&=$*$#@@+................+$>5,--&$%#+....",
"............+$&;;&=**$$+................@&5i~!,,-&=@....",
"...........@+&':e'-&&*$@+..............%@,i1|i/!!,=%+...",
"..........+@#):c<:'>-&=#+.............+#$/a02f^]/!,$+...",
"..........@@#;<7[<(('>=#+.............@%$i200199i~,&@...",
".........+@##(<68[_:'>=$@............+@$=^40001fi],=@...",
".........++#$;_c[[<_(&$#+............+%$-i300041^!-$@...",
".........+%$*>e<p87<(&$@@............%%=-]f440049!=#@...",
"........+@#*&,e}pc7[,&$%@+..........+%=-!^flqn04^!=$@+..",
"........++$&;:<8877<(-$#++..........+@=!~f4nnn049/-$@+..",
"........+@$>(_cm7c8}e-=$++..........+@-]^10000n4|/,=@+..",
"........@@=>e_8d77c_5>=$%+..........@#,]m4000n0l9],-#+..",
".......+@@$-'_cb78p_e>-$@+.........+@%-/{3000n4lf]/-#@..",
".......+@#$=-_8bmc}}5'-=#@.........+#$=!/1n00nl1f{/,$@..",
"......+@@%**-jp668<_5'>=%@+.......+%#$-,/9q00n43f^],$@+.",
".....@+@#$*=&:[b7i8<_e'&$++......@%%$=-,!fq00nn43|{!=@+.",
"...++@%##$*=-!}76878}_(&$@+....++@#$==,!/9l000nn419!&%+.",
"...++@#%*$==-5~877m8p_5)#@+....+%#$$--,!/oln0000q1f/=%+.",
".+@#*=&->>,je<[8788c<:'&%@+..+#$-,!/]]^994q0nn0n4|i!$#+.",
".+#$);e(e:__c[p[c88[e(-=%@+..@$-/i9|99140nq0nn04f^/,%@+.",
".%*=':___<[8678pc[[<(-*$@+...%-,ia222400000400049/,=#@..",
".@#*)(::::_<<_:e5:_5('&$@@...%$>}maaaa2222afffaf^i!-@%..",
".+@$)'eeeee((;,;>'>'(;;*%+...@#=/i||||9^mi{~]i]i^i~,%+..",
".+@@=;;';;)*$*$*$$$*'e'&+....+@#,~iiii/,----=--,i|i,%...",
"..++$&)))-=*$###$%#$&))$+.....+@>,/}}/,-=$*$=$$-5}}=+...",
"...+@#$$**##@%@+@%@%$$#@.......+#$-=--=$##%%##@#=-$#....",
".....+++@@@@+@+@++++.+...........++@@@@@%%+@++++.+......",
"........................................................",
"........................................................",
"...........++++........................++++.............",
".........+@#$##@++...................+%=-=$%@+..........",
".......+@+$&))=*#@+................+@@&5}/,-$%+.........",
"......++%#&;e;)=*#++..............+@#$5p|i/,-$@+........",
"....++@%##;:<:'=$#%@+...........+@##$=]a4aij-$#%+.......",
"...+@###=$([6<'&$$$@+@.........+@$$=--^004^!--=#@@......",
"..++@$$$=&:cg[:==*$$%++.......+@#=--,!|000f!,--=#@+.....",
".+@#&'e(''<bh6<j,>-&=$#@.....+%$5i|^{^000029{{/!,-=%....",
".+$=(<8<__7dybc__:e(';=$+....@=,m400110000031f|m{},&+...",
".#$)<6gb8[bhxgbi[[__e(;$+....$-/40000000000n0442|m~-@...",
"+@$=<bg6c[7dhg6cc<<:e;)$+...+#&540000400000n044a|i}&+...",
".@$=:7d8_5<8b88c[_ee')=#+....%=,20001o4n00nnqlf|i/,=+...",
".@#*:8d<:>!}[p<~__(;)*#@.....%$>|004a{o1q44l1a^i/-=@....",
"+@@*:86<5'j:_~[p_5'>=*#@....+##>a0049{9f1lq41f^],-$%....",
".@@$e86<(,,j5_p8_(>&$#@@.....@%-|0049{^9o1qn29]!-$#%....",
".@@$([8<5>,>,:[6[j&=##@+.....@#=m004o{^{{30049!,=$@+....",
".@@$([8<j',>,:<6<j&*$%@+.....@#=m0019{^{{o4049!-=##+....",
".+@#;:[:_:jj,_<8<e-=##++.....+@=pa02ao99^14n4|/,=$@+....",
".+@@)(:____:e_<<_'>&*@%+.....+@#}ma2113of3403^]!-%#+....",
"..+@=(e:<<__5__<:(>)*#++......+%,i|a4021f112||]/-$@@....",
"..+@$=):[7<<:5('(:e(;=$%+.....+%>5_a0002|f9m^||m~,&#+...",
"...+@$=ecb8<:(;-;e<e(;&#+......+#=,a0004a^~/i|4a^~5=+...",
"....@@#e[dc<:;&$)(<_e;&$+.......@#$|0004ai!-/|42|p5=+...",
"....++%)(_e;;&*#=)(;;)=#+.......+@#5|2ri~!>$,}mi~/,=@...",
".....++%&&&**$#@%$*===*#+........+@$,55)>=$%$=-(,,>$+...",
".......++@+@++@%@++@$$$%+..........@+#@@@@%%@%@@&)&#+...",
".........++++@++++++@#@+.............++++@++++++#$%+....",
"....................+++.........................+++.....",
"........................................................",
"........................................................",
"........................................................",
"........................................................",
"......++@+@+@+@+@+++..............+@@@@@@@@@@@++........",
"....++@@%@##%#%@%@@@++..........+@@@##$$#$###%#%@+......",
"...+@%###$#####$#$##%@+........+@#=$==$=$===$=$$#%+.....",
"..++*)'>&*&$*$$#=&>)&$#@......+@-/i]!,,--=-=,!]/!-=%....",
"..+#)e_:,>-==$==-':(;&=#+.....+$}|2f^]/,,-,,/ia|~5,$+...",
".++#(<c_(,>-=&**>:<_e'&#@....+%$^4029{]/,!,,{f42|i!=@...",
".+@#([8<5>>-*&&&,e<<e;)*+....+@=m0049{]/,!!!{f44|i}-@...",
".+%#([8<e>--&&==,e<<:(;*@+...+%&m0049{//!j,!{944|^~>%+..",
".+@$([8_(,--&&=&>:_<:(;=%+...+#=m0039{//!!!!{a423m~,#+..",
".+@$([8<j--=&&&&':<_:('=@+...+%&m0029]/!!j!!{f4419i,#+..",
".+@*([7<(,-&==&&>5[<_e;=%+...+#-|0049{/j,,!!{f42a9i,%@..",
".@@$([8}j--==&=&>:<_:e;=%+...@%=m0019]/!,j,!{344a|ij#+..",
".@%$([8<(,--===&,5[<_e'=@+...%#-m0019{//,!,!{fq4f|i,%+..",
".+@$([7_j--====='5<_:('=#+...+#=|001^]/!>,!j{f44a9i,$@..",
".+@$([8_(--&=*==,:[<_e'=@@...+#=m0019]/!,,,j{3q41|i,#@..",
".+@$([7<5,,--->-j_[<_(;&@+...+#=|0049^{]//]/93041|{,#+..",
".+@$([8[_e!j,,,(:<7[_e'=%+...+@=m0003o99{^^^a40029i,#@..",
".+@#([7[[__:_::_<868<e;=%+...+#$m0004413afa140002|~,#+..",
"..+#;<8c<_::eeee<[8c_e;=@+....@$i40041afff|f40001|~,%+..",
"..+#;<[_e('';>',e_c<:';*++....@$i402f^i{~~{{9204a^~>@+..",
"..+%;:[:'-&*=$=*>(<::;;*@.....+#pa0|i/!,,-,,]|42ai~)%...",
"...@)e_()***$#$$&;ee';&$+......@}|2m/,--===-!i||ii5=+...",
"...+$&)&$$##%##$*&))&)$#+......+=5}5-=$$$$$=-!_/55-$+...",
"....+###@@@%%@@%%#$$###.........@$=$%%#%%#%%#=*&=$$+....",
"......+++++++++@+@@@@+@...........+++++++++%@@#@#%@.....",
"........+.+......+++................+.+......+++........",
"........................................................",
"........................................................",
"........................................................",
".......++++++++++..................++++@+++++...........",
".....+++@@@%@@+++@+++............++@#####%@@@@@++.......",
"....+@#####$$#$##%@++@+.........@#$$$$$=&$=$$#%@@@+.....",
"...+%$*$$*$$**$*##$#%@%+.......+#=------,---==&$##%@....",
"...@#&-------&-&&===*$#@@+.....@=!///////!/!!!,,--$%@+..",
"...@&e____:5jj!5555(,(;=#@+....#!|2133o999oo99f9^^~,&%+.",
"..+#(<7877[<_<<p[[[[<_e;=#@...+$m40000nl314qq00042ap,&@.",
"..+#([b6bb78<p878888[[_'=$+...+$m000000n4qn0n000002i,=@.",
"..+@)(_<88c8pc86c<_::e()$#@...+%}m20000nq0n0041fa|m5&$@.",
"...+$=)e_ppcc877p_';;))=@+.....+&'}|24qnn0n043^{i~/,#+..",
"...++#$)e_[}[i66[5>&&&=#++.....+@$*]f144qn00q9]!!!,$@+..",
"....@@#&>(5__p8bc5-&=$$@+.......%#$,~^ff1q000o/!,-&%+...",
"....++@$*->>,<cb[5-*$##++.......+%#=,/]{^3n00f/,-=$%+...",
".....+@@#$*--_pdce**$%%+.........+@#$=,//10009,-=%#+....",
"......+@@$$=&(c6<j=$$@@+..........+@#=-,!90049,-=#@+....",
".......+@@#$='<6<(*$#%+............+@#$-,^401^,==%%.....",
"........+@##*'_c_,$$#@+.............+%$$-i202{-=$@+.....",
".........+@%#-:[_'&$$%+..............+#%=]|02{!-=#@.....",
"..........+%#)e_e(-=#@@...............+#$/|2|^/,=%@.....",
"..........+@@=;:e;;&*@+...............+@#(i||ii!-@@.....",
"...........++$);'((;=$@+...............+@&/ii^m~,&%+....",
"............@#*&)(e()=$@................@$-5}^am},&#....",
".............++%&(_e;&*@.................+@#5m2|i5)%....",
".............+@+*;e(;=*%.................+@@)~|m~,>#....",
"..............+@#*&)**$@..................+@$>55,)&%....",
"................++@####@....................+@#$$$$%....",
"..................++@@++......................++#%@+....",
"....................+@+.........................+%+.....",
"........................................................",
"........................................................",
"........................................................",
".........++@+@@+%+@@+++..............@+@@%@@%@%@@++.....",
".......+@@#&)**#*=&&*#@+...........+@%&,/,-$-,5!,=%+....",
"......++#$);:'&#&(e(')*#+.........+@$&/iai!=5^ami5,$+...",
"......+@$=(<8:'=;_c<e'&#+.........+#=,m40ai,{a00ai5=@...",
".....@@$$=e[7_'&;_8[_(>*%+.......@#=-,|004{!i200am]-#+..",
"....+%#*=&e<b<(&(_[<_(;=@+......@#&-,5|0049!^1041m~,%@..",
"....%$*==):[d<5>'_[<_e;&#@+.....#=),!}a000f]{1043|i!$%+.",
"....@*&));_7d8:>:_c[<_()$@+.....#-5!/~2000f{f1n4419/-%+.",
"....$=);(([6g7[5_c88[__;&$@.....=,_i^|0000qf1000q4ai!&#.",
"....$&;e:<cdg68}[7b67c[e)=#+....&5i||40000n1q00000q|_,$+",
"....$&;ee_cbhbc_p86688<e>=#....+=5p|az000001q000004|],$.",
"....@$=&;(<6g7[e}p87c<:;=$@.....#=,5~m4000qf1q0004ai,=#.",
"....++#$*&:8dc:,:<8[<:e)$@@.....+@==,5a0003{31n4qa|/>#@.",
".....@+#$$e[dc5,j_p[_e(&#@+......@@$=-|000f{91q41f^!$#+.",
".....+@@$*ec6[e-j_c<_:(&#@+......+%#=-|000f]910q1fm!$@+.",
"......+@$#e[d[:-(_p[_5;&#++.......+%==|000f/^1401fi5$@+.",
"......+@%$e[b<5-j:[<_e'=#@.......++%$*|0009]93q419i,$%..",
"......++##([d[5-,_[__:;&@+........+%$=m000o/^3041fi!%@..",
"......+@@$([b[e>,_p<:e'=%@........+@#=m0009]^344a|i,#@..",
".......@@#(<b[e-,_<[_(;=@+.........@%$m0009/{10439i,#+..",
".......+@#([d[_,e<c<_e'=%+.........+#$m0003^f4n02|i,#+..",
".......++#(8d8<e_c7[_e;$@+.........+@$^0002f10002|~-#+..",
".......+@@(cg6[_<868_(;*@..........+%#m0000240002m~>@...",
"........++):[_e(::[_e;&$+...........+@}a02|^a242|i!=@...",
"........++*;(;)=;(e(;)=#+...........++)pmi_!~m|^p/,$+...",
".........++#$$$%*=))=*#@.............+@$=&*$-,_/(>=@....",
"..........++@@@@$$=$$##+..............+@#%##=-,-=$$+....",
"...........+@++++@##@++................+%++@@#$$%%+.....",
".................+.+.........................+.+........",
"........................................................",
"........................................................",
"...+@###$##@+%+@+@+++..........+%$===$$%@%@@@@+++.......",
"..@#=;';&&=*##$$$#@++++.......%$,]i]/!,-$=&-==#@@++.....",
".@#$;:_:e'-=*==&=*$$%@+@+....%$-ia2||{/,-,,!,-=&$%@@+...",
".@$=e[8<_e'-*&);>)**$#%+++...%&(|0002f^/,!/]]/,-=$#@@+..",
".+#*;:[__:(5,((5e::((;)&*#@..@$>ia021f99^99f|fa|^]}!>=@.",
".+@$)e::::___}___[7c<_:';&#+.+#=_|a|af132121400042|i~5&+",
".+@#&;(e:5_888[c7bgg78[_e'*@.+#$!]m9ff1n000000000002|i>@",
"..%@=)>(5_[[8[__[8668<<:;)$+..%#,/{9f14400110000002ai_=+",
".+@@$&>,:_~<8<:,_[88<_e;)=%+.+%%&!]^fll001f^140042ri/($+",
"..+%#$-'/<<[p:j-'_<<_e;)$#@+..@#=-!^34q4q19/^1442|i5-$#+",
"..@%$=-(_[p<[:'-'(::::()##+...@%=,/924q44f{/{91aff^/=$%.",
"..@@*)':<8[[_5'=-;(':ee)$%@+..%#,/io4nqq1f{!/~^^a||/=#@+",
"..@%=>(_[8c<_e,=&&-;e_e;$@+...@#,]^100n44f{j!j/i92a~-#@.",
"..@@&(:_p[p[_j>=**=;e_:;$%@...%%59a1q0q419],,,,]|4|~=%%.",
"..+#'_c<_:___(>==**;:[_;*@+...+$i2043f1119],,,,]a04i-@@.",
"..@#ec7[5,(e_(>==**;:8['$@@...%=|000f{9|2^],,--~200i-%@.",
"..+#(c6_'>,:_j-***=;_8[($@+...+$m002^]^a2^/,-,,]200m-#+.",
"..++&(:;)&(<[:>=*==;:7c'*%+...+@5mai}!^101],-,,~20ni>#+.",
"...+$=)&==(<7_'*=$=;_7[($++....@=,5!,,m402{,,-,p200m*%+.",
"....+%$##$([8<,&&&&(:8[($@+.....@$==*-^004{!!j!^z00m&@+.",
"....++%%##;:[<:(::__[[:)#+......+@%#$=pa04a9|a2200a}=@..",
"......+@%#)e<[[c[88c[:e&#@........+%#$}|4000000002|5$%..",
".......++@=;:<[866d8[e;=@+.........+@@,ia40000000|p,%+..",
"........++$=);::_:__;)=#+...........+@&(}iaaa222i_,$+...",
"..........%$*=);;;;;&*$@+.............%&-,}ppii}5>&#+...",
"...........+%%$****$#++................@#$&>>))=$@+.....",
"............+@@####%@+..................+@#$$$$$@++.....",
".............++@+++++....................+@@@@%++.......",
"................+...........................+...........",
"........................................................",
"........................................................",
".........++++........................++++...............",
".......@$==$$#+++++@@@++...........%-,,-=$@+++@@%%@+....",
"......+$);))&=$@@@@#$=$+..........+&}i~}5,&%#%#$&>&@....",
"......+='e(;;&*%%##$$=*#+.........+,i|mii!-##$=--,>*+...",
"......+*(eeee;&$*=&;(e'&#+........@(i|r||~!=-,5~m|i5$+..",
"......@=;e:__(>$&)'(:[_;$+........@,p|av2|]-!/ima02p=@..",
".....++=;e__[:'=-;(:[8[($%+......+@(i|140f{,/]^1000m-#+.",
".....++*&;:[8_'&;e__<<e;*@+......+%-5pa001^!~|2z44a~>%+.",
"......@$*):[6<(-':<<::'&*@+.......@=,/|0049/^o04aai5>#+.",
".....++%$*:[dc5>(_8[e;)=$#+......+%%&,f0009]9200|i},=$@.",
".....+@%$=e[6c}5__<_()=$#+.......+@$=,900nlo1102m/,-$@..",
".....+@##$e<77[[[__e;&*#@+.......+%$=-9400044l3|~!-$%+..",
".....+@#$=,_c876[<e(=$#+++.......+@=-,^1n00002f^!=$%++..",
".....+%#$=e<876d8<e;&##@+........@%$-,92n000019~!=$%+...",
"....+@@$*=,_[mbg6_'>&$@%+.......+%#=-,^1000001^]!=%#+...",
"...++%##=&j_c6gh6~'-$$#++......++#$=,!93n00004{/-=*%+...",
"...+@$=->':_p86d8<e;-##@+......+#-,/]^f1q00004f{/=$@+...",
"..+%=);:<[c[cp[pccc_'$#@+.....+#,/if2000040qn002i-$#@...",
"..+#&;:[6d88<<:e<868e&#%@+....%$5i|0000n44a94000|!=%@+..",
"..@$)e_[868[_:';:<6[:&*#@+....@=}|2000044f^i|q00f5-*%+..",
"..+#)e__<<ee;>-&;(ee(;)=##+...@$}|2244||i]/!pm||mi},&$+.",
"..+#)e_:e(;&*=$$==);;(;)=$@...+$_|2||m~!-,--,,}~pmi/,=%.",
"...@&(:;;&=$#####%$=);;)=$@....%5m2i~5,-$$$$$$=,}ic/,&#.",
"...+$&;&**$@@%@+@@@#*&=$%%+....+=5}5>-&#%##@@%#$>,,&$#+.",
"....+@%#@@++++++++@+@@@@@+......@#$$%@@+++++++@+%###@+..",
"........++++.........+..............++++.........+......",
"........................................................",
"........................................................",
"........................................................",
"........................................................",
"........................................................",
"...+@@#@+++....................+%%$%@++.................",
"..++#*$$#@+...................+@*--=$@@.................",
".+#$=&)=$$%@+................@$=,5/!-=$@+...............",
"@$&>(eee'>=#++..............@&5~^|a|i],=@+..............",
"+&(:_<[_:e;*@++.............@5ma24011m~-#@+.............",
"@)':<[8<<:'=#@++............@5m|400042{,$@++............",
"+$&;e<[<<<(-##@+++++@##+@...+&5p|40444m/=$%@++++%$$@@...",
"+@$=(:[[[<e-*#%%+++@#$##%+..+%&,ma0000|/-$##@@@#$==$#@..",
".+@$;::[[c:>$##%%%%#$&=$#@+..@#&~a240na]-=$###%=>!,-$@+.",
".@@%&(:[76<(=*$#$*=;;:;&#+...@@$5^|0004^,-===-,/i|i5$@..",
".+@@&)e[7g[,=$$#*);(:<:)$+...+@#!~90000^,-==-/~ma4|}=+..",
"..+%$&;[bh8(&=$**;(e<[_;#+....@%-!i000q9!,--,~ma404~$+..",
"..+@$=):cdc5>-=*-;:::e(*@+....+@&,/1000f]/,-/iaaa|m,#@..",
"....##=:[8<:,>&$;(_:(;&$@+.....+$=,|000f^]!-]m2amp5&@+..",
"...+@@#'_8[_e,-*;e<:;=$#+......+@%={20q1o^/,]|4|i,=$+...",
"....+%$)(_<[c5>=&;(;&$#++.......%#=}m22009],5~mp5>$%+...",
"....++%=>(_c6<,=&&)&$#@+........+@%,]^100q^,!!}!=$@%....",
".....@@#$&_8hce=**#$@@@+.........%#=-510009,,-==##@+....",
"......+%$=(<8<e'-=$##+@+..........+#-,m404f{/,=$$%@+....",
"......++@$)(::__e&*##@++..........+@#=/m|a239/-$$@@+....",
".......+@@#=)e_c:;#$@%++...........+##=,/|20a]==##@+....",
"........@%#$=;e_:(;&$#@+............@%$-,i|2a^]!-$%+....",
".........+@##&;(eee(&#@@.............+#$=5~||||^!=#%....",
"..........+@@$=&(:[:'=#%..............+@%=,j^20ai,$#....",
"...........++#$*)(:e;=*@+..............+@$&,_m1r],-%+...",
"............++@$*&;);)&$+...............+@%*>5~}~}5&+...",
"..............++%#$=&;)#+.................+@%$&,5~/&@...",
"...............++++#*)&$+..................++@@&-}5=+...",
"................+.++#$#+....................+.+@$=$@....",
".....................++..........................++.....",
"........................................................"};

1684
wmMatrix/images/large.xpm Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,40 @@
#define matrix_width 14
#define matrix_height 216
static char matrix_bits[] = {
0xff, 0x3f, 0xff, 0x3d, 0xeb, 0x30, 0xfd, 0x34, 0xeb, 0x2c, 0xef, 0x35,
0xeb, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3b, 0xfb, 0x3b, 0xf7, 0x39,
0xfb, 0x3b, 0xf7, 0x39, 0xfb, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x35,
0xeb, 0x38, 0xfb, 0x3d, 0xfb, 0x3b, 0xff, 0x31, 0xeb, 0x32, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x31, 0xfb, 0x38, 0xfb, 0x3d, 0xfb, 0x38, 0xff, 0x34,
0xeb, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3d, 0xfb, 0x3b, 0xf7, 0x31,
0xeb, 0x20, 0xff, 0x39, 0xff, 0x3b, 0xff, 0x3f, 0xff, 0x3b, 0xf7, 0x31,
0xeb, 0x3b, 0xf7, 0x31, 0xfb, 0x3c, 0xff, 0x35, 0xfb, 0x3b, 0xff, 0x3f,
0xff, 0x3b, 0xff, 0x33, 0xeb, 0x33, 0xe7, 0x31, 0xeb, 0x2e, 0xff, 0x35,
0xff, 0x3b, 0xff, 0x3f, 0xef, 0x3b, 0xfb, 0x31, 0xfb, 0x3b, 0xf7, 0x3b,
0xef, 0x3b, 0xff, 0x37, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x35,
0xeb, 0x20, 0xe7, 0x31, 0xeb, 0x28, 0xff, 0x35, 0xeb, 0x3b, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x35, 0xeb, 0x28, 0xfb, 0x35, 0xeb, 0x28, 0xff, 0x39,
0xef, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f, 0xef, 0x3b, 0xff, 0x37,
0xeb, 0x2e, 0xcd, 0x24, 0xef, 0x2a, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3d,
0xfb, 0x3b, 0xff, 0x37, 0xef, 0x2b, 0xff, 0x39, 0xfb, 0x3b, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x3d, 0xeb, 0x22, 0xfd, 0x36, 0xee, 0x2e, 0xdf, 0x2d,
0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x38, 0xfb, 0x3a, 0x77, 0x31,
0xfb, 0x3b, 0xff, 0x39, 0xfb, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3d,
0xfb, 0x3b, 0xff, 0x39, 0xff, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x35, 0xeb, 0x28, 0xd7, 0x21, 0xeb, 0x20, 0xff, 0x35,
0xfb, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f, 0xeb, 0x32, 0xf7, 0x31,
0xeb, 0x2b, 0xff, 0x3f, 0xff, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3d,
0xeb, 0x3a, 0xf3, 0x30, 0xea, 0x28, 0xff, 0x35, 0xeb, 0x2f, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x3d, 0xeb, 0x3a, 0xf5, 0x30, 0xeb, 0x28, 0xff, 0x39,
0xff, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x37, 0xef, 0x33, 0xf7, 0x33,
0xef, 0x2b, 0xef, 0x31, 0xfb, 0x2a, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3d,
0xeb, 0x28, 0xf5, 0x30, 0xef, 0x3a, 0xff, 0x35, 0xfb, 0x3f, 0xff, 0x3f,
0xff, 0x3f, 0xff, 0x3f, 0xeb, 0x2a, 0xff, 0x36, 0xef, 0x2a, 0xfd, 0x34,
0xff, 0x3f, 0xff, 0x3f, 0xff, 0x3f, 0xfd, 0x34, 0xeb, 0x2a, 0xf7, 0x33,
0xef, 0x3b, 0xff, 0x37, 0xff, 0x3f, 0xff, 0x3f, 0xef, 0x2b, 0xff, 0x31,
0xeb, 0x22, 0xf7, 0x31, 0xef, 0x2b, 0xff, 0x31, 0xff, 0x3b, 0xff, 0x3f,
0xfe, 0x3e, 0xff, 0x20, 0xeb, 0x2a, 0xff, 0x3d, 0xff, 0x2a, 0xff, 0x23,
0xef, 0x3b, 0xff, 0x3f, 0xff, 0x3f, 0xff, 0x2d, 0xeb, 0x2b, 0xf7, 0x33,
0xeb, 0x28, 0xff, 0x3d, 0xff, 0x3f, 0xff, 0x3f, 0xfe, 0x3e, 0xfd, 0x3c,
0xfb, 0x2c, 0xff, 0x35, 0xfb, 0x3b, 0xff, 0x37, 0xff, 0x2f, 0xff, 0x3f,
};

1684
wmMatrix/images/matrix.xpm Normal file

File diff suppressed because it is too large Load diff

1217
wmMatrix/images/medium.xpm Normal file

File diff suppressed because it is too large Load diff

698
wmMatrix/images/small.xpm Normal file
View file

@ -0,0 +1,698 @@
/* XPM */
static char *small[] = {
/* columns rows colors chars-per-pixel */
"8 108 584 2",
" c Gray0",
". c #000501a6000b",
"X c #00200253002f",
"o c #002c038e003f",
"O c #00de03f00108",
"+ c #0031044b003b",
"@ c #00e904bc0114",
"# c #001b0597001c",
"$ c #00e705560116",
"% c #01320498013a",
"& c #013c051f0155",
"* c #0036064e0044",
"= c #0084073100b4",
"- c #014c06680173",
"; c #0184076101b1",
": c #028007f202ad",
"> c #004c088a006e",
", c #000009a50000",
"< c #00f0096e0116",
"1 c #01640885019f",
"2 c #01bb098201c2",
"3 c #01eb08720219",
"4 c #01f309d30210",
"5 c #006c0a4e0077",
"6 c #00000b800000",
"7 c #017e0a5001cf",
"8 c #01500b5d015e",
"9 c #01db0adf0229",
"0 c #024d089e0264",
"q c #025109790282",
"w c #027a0a6a029c",
"e c #027e0b8702bc",
"r c #03710a51039c",
"t c #03000b820310",
"y c #03f70a2f0432",
"u c #00000c900000",
"i c #014c0d61019c",
"p c #01670c2b0202",
"a c #00000ea90000",
"s c #00470f690063",
"d c #01d40e7c022a",
"f c #02c60c9802e1",
"g c #02010d790251",
"h c #02d20d7b0303",
"j c #03050cf40344",
"k c #03810db80396",
"l c #02820e9f0291",
"z c #038c0e5403ac",
"x c #035f0fa6037b",
"c c #03fa0db0041d",
"v c #04d20a3704ef",
"b c #04760d930483",
"n c #05c90cc405f1",
"m c #041a0e7d0458",
"M c #04650fd2048b",
"N c #05ec0fd30621",
"B c #06750de30682",
"V c #06950f5b06bf",
"C c #000010a70000",
"Z c #000011190000",
"A c #0000128c0000",
"S c #0115135f014d",
"D c #01e013c5023b",
"F c #02e410a20311",
"G c #02d711400334",
"H c #0387106c03fb",
"J c #031d11130356",
"K c #034312320354",
"L c #0000149f0000",
"P c #01b914b801fc",
"I c #00001721004f",
"U c #028514e402c4",
"Y c #03fe16170421",
"T c #046c114e046e",
"R c #0571105a05ad",
"E c #05f711d40637",
"W c #04a9123704b0",
"Q c #050312430547",
"! c #05d413a305d9",
"~ c #063d10f90667",
"^ c #06b511c006e1",
"/ c #054d14340561",
"( c #0548156a057b",
") c #05e815e20610",
"_ c #0451160d0477",
"` c #050117020575",
"' c #06f515c40723",
"] c #0610165b064e",
"[ c #06dc1760071d",
"{ c #01da194e01c9",
"} c #01d61a3d0222",
"| c #02491e6402cd",
" . c #03121f420371",
".. c #0528186b0552",
"X. c #05a219a605bf",
"o. c #05ff1a18063c",
"O. c #068e19b506c7",
"+. c #078f199707aa",
"@. c #06c31a200730",
"#. c #06b11ba406bc",
"$. c #07b31a6807cb",
"%. c #07991b1d07d3",
"&. c #04fe1d0c04cb",
"*. c #05101c190526",
"=. c #041c1fad0416",
"-. c #05e11e2c05fc",
";. c #075f1c94078a",
":. c #062b1fb806b9",
">. c #09b115020a23",
",. c #080c16bc083a",
"<. c #08a717c308c6",
"1. c #09011708092d",
"2. c #084b199a0846",
"3. c #0a1f193c0a6b",
"4. c #0a5d1a3d0a84",
"5. c #08621cb6088b",
"6. c #09991c2209d7",
"7. c #09241d95090a",
"8. c #08261fee083f",
"9. c #09171e29094a",
"0. c #09731f0e099a",
"q. c #0ac31c740adf",
"w. c #0a731ed10a87",
"e. c #000022700000",
"r. c #03d1225a03eb",
"t. c #05d120cb05ea",
"y. c #0798211b07ae",
"u. c #06b723c406c0",
"i. c #05892525058a",
"p. c #06cd29520757",
"a. c #06fb2d8d0734",
"s. c #08a2202908ca",
"d. c #095a205a0982",
"f. c #098d218d09d4",
"g. c #08a2226b0950",
"h. c #08de23a5092f",
"j. c #0ab822d20af2",
"k. c #0aad24840acd",
"l. c #0a6d257d0a9d",
"z. c #0b7524130bbd",
"x. c #0a9c263a0a9a",
"c. c #0a6f27c50aa8",
"v. c #0bb8265c0bc2",
"b. c #0c9222330cca",
"n. c #0f04213b0f72",
"m. c #0e46231b0e7e",
"M. c #0e0025ca0e4e",
"N. c #0ab828fc0aee",
"B. c #0ad3296b0afa",
"V. c #0bd129480bda",
"C. c #0b1a2ae90ae6",
"Z. c #0b4b2c7a0b93",
"A. c #0d1028450d39",
"S. c #0dcd28510e28",
"D. c #0c7a2ace0ca7",
"F. c #0cfd2a730d57",
"G. c #0c612b580c9e",
"H. c #0d662aa50d8c",
"J. c #0db92a1d0e17",
"K. c #0d5e2d6c0d41",
"L. c #0deb2d420e12",
"P. c #0c842e010cbf",
"I. c #0cd82f120cae",
"U. c #0da72ee10da4",
"Y. c #0d542f3a0d26",
"T. c #0f862da20fa4",
"R. c #0e892e890eb7",
"E. c #0fca2efb0fb0",
"W. c #0f382f680f44",
"Q. c #06c5339a068b",
"!. c #07fb31490837",
"~. c #0ba630ac0be2",
"^. c #0a09341809e2",
"/. c #0b5c34fd0b6e",
"(. c #0cf433400d0e",
"). c #0da233d10dcd",
"_. c #0edd30250ee6",
"`. c #0e6d31d10e99",
"'. c #0f9e30d20fae",
"]. c #0f2031000ef6",
"[. c #0fb631190f91",
"{. c #0e8332c50ec9",
"}. c #0fbb33660fa6",
"|. c #0e9637370e52",
" X c #09b23f840a65",
".X c #0f7e38ed0f8d",
"XX c #0e5e3e370e84",
"oX c #0fab3f840f46",
"OX c #0fda321e100e",
"+X c #16f227b11739",
"@X c #136d282b1333",
"#X c #146b2b921490",
"$X c #14bf2fa214eb",
"%X c #1ae92c021b7d",
"&X c #1043363a0fe8",
"*X c #107c313d1058",
"=X c #113a31111178",
"-X c #10a2329d10bb",
";X c #104f34331084",
":X c #116134b7115c",
">X c #111835d610f4",
",X c #113a35f61168",
"<X c #103836781028",
"1X c #11743652118c",
"2X c #11af379511ab",
"3X c #12f134241302",
"4X c #125d35541264",
"5X c #151c33ca156b",
"6X c #166337b81691",
"7X c #11113ac010e9",
"8X c #11453ad81174",
"9X c #11b43bd411c7",
"0X c #1287381d12a5",
"qX c #1240390b125b",
"wX c #12543a8311f3",
"eX c #12053a4c1235",
"rX c #131e3bb912d4",
"tX c #136d3b671324",
"yX c #11f93c8a11fd",
"uX c #11df3d3611a5",
"iX c #12363d6c11f5",
"pX c #12b73c3c127f",
"aX c #13a53d941374",
"sX c #12d33e1d12c2",
"dX c #16483b9c1657",
"fX c #14db3d8314cc",
"gX c #14983e6a14a8",
"hX c #141a3fdc141a",
"jX c #15193eb214ee",
"kX c #18563552187b",
"lX c #18483672187b",
"zX c #1b5a37281b58",
"xX c #1bdb34f41c72",
"cX c #189439ea18c0",
"vX c #1b0f3bd41ba4",
"bX c #1c6839401c70",
"nX c #1c2b3fce1c74",
"mX c #1ee53f881f0a",
"MX c #1ff739fc204d",
"NX c #20333b022029",
"BX c #07a0484b07ed",
"VX c #0c6843eb0cfe",
"CX c #0eab45870e8f",
"ZX c #08924f4c08f4",
"AX c #0ce348bd0c53",
"SX c #13fe41a51416",
"DX c #14df4099148a",
"FX c #14eb41f814a0",
"GX c #156541811533",
"HX c #14ed42fb151f",
"JX c #14db439e14c6",
"KX c #159e437c152c",
"LX c #163c41511658",
"PX c #1506448014fa",
"IX c #15f345ea158f",
"UX c #14d4479d14c1",
"YX c #15ba46ae15e0",
"TX c #1524475e14db",
"RX c #1695448816a8",
"EX c #1625466815e6",
"WX c #176447db1701",
"QX c #10b5485c108e",
"!X c #139649891398",
"~X c #14a8481814e4",
"^X c #15d649cb1614",
"/X c #15714bf01587",
"(X c #1684497d164a",
")X c #176048151784",
"_X c #17114a0416a2",
"`X c #16a74fda1728",
"'X c #17d44ab81858",
"]X c #190640f61931",
"[X c #1a5243e31a57",
"{X c #19e245351a04",
"}X c #1a8a45e01aab",
"|X c #1bc945cd1bf0",
" o c #1c8242401cd0",
".o c #187148251847",
"Xo c #1857498f1826",
"oo c #194e48d61963",
"Oo c #1964493c1978",
"+o c #18bc4bd118c9",
"@o c #182a4d261842",
"#o c #19244cdd18ec",
"$o c #18b24ecb18b7",
"%o c #1a074e1819fb",
"&o c #1ab54f281a51",
"*o c #1b884e3f1b4a",
"=o c #17dc52531789",
"-o c #12695ea3125d",
";o c #16825d1d16dc",
":o c #183b529017bc",
">o c #188a530517d8",
",o c #181b568417ce",
"<o c #186b50921887",
"1o c #1a7d50351a0e",
"2o c #1999562918ec",
"3o c #1bcb54491baa",
"4o c #1d4f51121d3b",
"5o c #1d1c53571d2a",
"6o c #1c3257b51c0b",
"7o c #1e04574d1d99",
"8o c #1f4457c11ed5",
"9o c #19c15b2e1a13",
"0o c #1ae35c4b1aeb",
"qo c #1c5859581bdb",
"wo c #1e42598d1dec",
"eo c #1f595aa61eb1",
"ro c #1cc45d361bdd",
"to c #1d155d691c7a",
"yo c #17cd64741841",
"uo c #1a1663341a64",
"io c #1d1361591cce",
"po c #1fec65911ee9",
"ao c #1c0a6a611b6d",
"so c #1e7f6d491eb4",
"do c #11b07cf3116f",
"fo c #1dd07e351e09",
"go c #1fd4739c2013",
"ho c #21dc4a2921c3",
"jo c #20c44d6720b1",
"ko c #22724fb4224d",
"lo c #252a4a7e25b7",
"zo c #25bd4b9825ff",
"xo c #2a2b4a0a2a68",
"co c #24e253a42583",
"vo c #27ce50612810",
"bo c #20d05ca620ae",
"no c #21125ff120be",
"mo c #22715f4521cb",
"Mo c #238a5fa2238f",
"No c #267b583e264f",
"Bo c #253a5e232529",
"Vo c #294d527428f1",
"Co c #2b72535b2b91",
"Zo c #2ab455c72b3f",
"Ao c #2ab7571c2ab7",
"So c #2abb59ea2afd",
"Do c #2d6d58b52d8e",
"Fo c #2fe55d6c3035",
"Go c #30cb4ca130ea",
"Ho c #31e5520f3253",
"Jo c #34cc579b3513",
"Ko c #31765a4531bc",
"Lo c #201267f61f90",
"Po c #213164b020aa",
"Io c #21fc662221fd",
"Uo c #2284648221c0",
"Yo c #224c64ba222a",
"To c #220d67b9214f",
"Ro c #2313670e2233",
"Eo c #243b64102422",
"Wo c #20096bd52065",
"Qo c #227d6b462206",
"!o c #244c6a212372",
"~o c #256768a024c2",
"^o c #26726b3e2547",
"/o c #27006dcf26ad",
"(o c #29cb617a2aa0",
")o c #2b70651e2b71",
"_o c #2ae566652b55",
"`o c #2b78680d2b6c",
"'o c #2ba46a9f2b62",
"]o c #2a3d6f6c2a16",
"[o c #2d816e122dbe",
"{o c #2fd16d262fd0",
"}o c #21d972ca21a1",
"|o c #23dc70f022ab",
" O c #21e7766b21d5",
".O c #2170777821c1",
"XO c #23f1777823bd",
"oO c #23d475f52404",
"OO c #257273cb24d8",
"+O c #24c8775923d6",
"@O c #268477f925a5",
"#O c #26177675262c",
"$O c #27fc774d2742",
"%O c #21d57846226e",
"&O c #278178592729",
"*O c #24567ef5242a",
"=O c #28c3745927f8",
"-O c #2bd971d92bcc",
";O c #2d5c72d52cf2",
":O c #2d8772ed2d69",
">O c #299b7b232931",
",O c #2a96784029d4",
"<O c #2bf27c982bda",
"1O c #2be27d062af3",
"2O c #2e5179262eab",
"3O c #2cd47ef12be0",
"4O c #2c797fd02be6",
"5O c #2ded7e572cea",
"6O c #30ea65463131",
"7O c #35236c2734d4",
"8O c #3cce6be83d20",
"9O c #352173573536",
"0O c #355e767c3559",
"qO c #39c975c7399e",
"wO c #3b9e7de83b61",
"eO c #3d9e7acd3dca",
"rO c #3c307c313c5b",
"tO c #3d1f7fe63cff",
"yO c #44ca690c4520",
"uO c #4b5b70974b48",
"iO c #4ba778214b93",
"pO c #51577c94512c",
"aO c #1bbc95311afe",
"sO c #254d87182545",
"dO c #211b8b642117",
"fO c #22e88bd222a1",
"gO c #2c7a85732bdd",
"hO c #2f5184372ea6",
"jO c #2edd87172dd6",
"kO c #2e7987652e8e",
"lO c #2f6688392ec5",
"zO c #2fd28ca12f25",
"xO c #2f818fe72eeb",
"cO c #2d359c8d2c15",
"vO c #302483bc2f87",
"bO c #304f884c2fea",
"nO c #31dd80a130be",
"mO c #315a85aa30b7",
"MO c #312e876e3092",
"NO c #30de8ab73046",
"BO c #33868f713277",
"VO c #35ac8d23341a",
"CO c #3b448f8d3aa5",
"ZO c #3e3988943dc1",
"AO c #302c9d942fc1",
"SO c #31a59224314f",
"DO c #33f093eb330f",
"FO c #32e6950331d0",
"GO c #32e7943b3244",
"HO c #342893b6340d",
"JO c #358592b034f6",
"KO c #36199265345f",
"LO c #35a5977a34e4",
"PO c #36a294173582",
"IO c #373197cd35f9",
"UO c #33e1990c32f2",
"YO c #352e9972347d",
"TO c #3576995b3503",
"RO c #379099f536d3",
"EO c #37e59b263773",
"WO c #36039c5f358a",
"QO c #37949c8f36cd",
"!O c #3c4794b83b89",
"~O c #3da7963f3dad",
"^O c #38369a0d376b",
"/O c #386b9b1f3762",
"(O c #383f9e3c370c",
")O c #38a499693825",
"_O c #39a69c233844",
"`O c #39819dbf3859",
"'O c #3f3b9eda3e92",
"]O c #37c7a2563781",
"[O c #3643ab3a35d2",
"{O c #3a5ea1973996",
"}O c #3a3da2c039d1",
"|O c #3b96a3fb3ac2",
" + c #39e9a7a43964",
".+ c #3bbea7e03ada",
"X+ c #3c67a0ee3afc",
"o+ c #3d8da29f3cdf",
"O+ c #3eafa4453e13",
"++ c #3ee8a6003dc9",
"@+ c #3df2aa013cf3",
"#+ c #3d62abe33d03",
"$+ c #3e99a9c83e0c",
"%+ c #3fa6ae913f86",
"&+ c #3a2eb7c338f6",
"*+ c #3c93c1163bc3",
"=+ c #3ea5ce5d3d80",
"-+ c #404090f33f97",
";+ c #4167826c418c",
":+ c #4432822943a2",
">+ c #449d838644cf",
",+ c #46db8182474f",
"<+ c #45ab88af456d",
"1+ c #49f580fd49f0",
"2+ c #48528ba34793",
"3+ c #4a498cdb4a5f",
"4+ c #428394bd425a",
"5+ c #49c396b849aa",
"6+ c #58ba9298588e",
"7+ c #418daf774103",
"8+ c #4666abdf459b",
"9+ c #4af8a8944ae6",
"0+ c #423eb0d54163",
"q+ c #4327b0e941c7",
"w+ c #4271b32b41b5",
"e+ c #45f7b64044e4",
"r+ c #47f9b48146be",
"t+ c #4744b7da469d",
"y+ c #4301beaa422c",
"u+ c #4512ba79446d",
"i+ c #476fb81b4681",
"p+ c #489ebe3f4798",
"a+ c #48d1bf19486e",
"s+ c #4ad9bfb649d9",
"d+ c #51e9afbc51be",
"f+ c #5988a34559e6",
"g+ c #5cc3a19a5c23",
"h+ c #5914ab04582a",
"j+ c #5ab6b6025ad8",
"k+ c #5f69b6f45f0c",
"l+ c #69a1974d69be",
"z+ c #74679d0d745b",
"x+ c #68cba79868ed",
"c+ c #6c18bffa6b8c",
"v+ c #4394c37b4283",
"b+ c #415dc4024081",
"n+ c #4c88cbc04c23",
"m+ c #5594c63a5543",
"M+ c #53cfce8a5367",
"N+ c #570ccfec5632",
"B+ c #4c08e47e4acc",
"V+ c #64aac209649a",
"C+ c #6aebce606aaf",
"Z+ c #6fccdeba6eca",
"A+ c #7f89c7787f76",
"S+ c #7da0c9797da0",
"D+ c #76b4d606769e",
"F+ c #7e49d2e67e42",
"G+ c #7cddd6537bf9",
"H+ c #7cd3d5737c27",
"J+ c #7b20d8927b10",
"K+ c #7dc2d9f27d9c",
"L+ c #67fbe39e6759",
"P+ c #67aeead26676",
"I+ c #718bfdbc707a",
"U+ c #7463fe9a729a",
"Y+ c #7d48fb647bf1",
"T+ c #80c6c8a58088",
"R+ c #8bf8c2838c2e",
"E+ c #8e5ecb248e33",
"W+ c #825cd9e281d1",
"Q+ c #9761da9c9704",
"!+ c #8434e35b833a",
"~+ c #8533eab9848f",
"^+ c #8c0bed8f8b47",
"/+ c #8e40ed998d91",
"(+ c #842bffff8294",
")+ c #86dafc808639",
"_+ c #88ecffff8724",
"`+ c #8a8fffff89d8",
"'+ c #8a80ffff8a06",
"]+ c #8e51fa258de3",
"[+ c #8f9dffff8efe",
"{+ c #9015e9278f63",
"}+ c #9035ea068fff",
"|+ c #9310eb599270",
" @ c #9121f35490b4",
".@ c #96b9f30c9632",
"X@ c #9710f6d196bd",
"o@ c #910dffff9012",
"O@ c #937dffff92b3",
"+@ c #9833fc1896db",
"@@ c #9cfbffff9c10",
"#@ c #9d43ffff9c7d",
"$@ c #a7dce408a785",
"%@ c #a42af40da2ef",
"&@ c #a214ffffa159",
"*@ c #a3c9ffffa25b",
"=@ c #a60dfc95a58e",
"-@ c #a8f0f007a887",
";@ c #ae84ffffaddd",
":@ c #b013ffffae12",
">@ c #b43cf389b381",
",@ c #b0f4ffffb086",
"<@ c #b32dfc07b292",
"1@ c #b47cffffb3cb",
"2@ c #bee3ffffbd9d",
"3@ c #c1aeffffc140",
"4@ c #c327ffffc1b7",
"5@ c #c432ffffc36f",
"6@ c #c7f6ffffc699",
"7@ c #c9d7ffffc875",
"8@ c #ca81ffffc9ed",
"9@ c #cc62ffffcbfc",
"0@ c #cc71ffffcc74",
"q@ c #d0aaffffcfce",
"w@ c #d2a5ffffd1c2",
"e@ c #d418ffffd379",
/* pixels */
"0 ;XR.@ b Voho; ",
"0X/OPOs Jo=@|+kX",
"LXLOKOI yO @}+mX",
"Q wo%o # -+tON ",
" J.H. NX[XX ",
"o CO8o R+>+. ",
"* !OgX E+Ao ",
"$ 5oc. ,+fX ",
"c XoaX 9O_ov ",
"A.++2o MX,@SOV ",
"8.UOQo e.Y+h+h ",
"/ YoEo a g+z+R ",
"m &o<X rO9o- ",
"H.r+$o cX9@sO; ",
":X|O/X Do&@*Oy ",
"M EXRX + O-Or ",
"; GXd 6OS ",
"o.w+JO L 4@$@;.",
"l.a+EOJ !.w@-@=X",
"3 C. BX X ",
"f wo4o 4+1+= ",
"s.{OmO r.@@F+d ",
"'.QO=o Co[+fOq ",
"w 9X_. yo`X% ",
"- (XHX fo{oq ",
"d.zOt+s n.!+5@$X",
"*XGOHO> Ho)+~+#X",
"q I.V. ZXVX: ",
"! nO^o> B A+j+w.",
"z MO>o . K+lOk ",
" K.Ro oo8+2 ",
" 9. OX0 ",
"0 IXTX oO.O~ ",
"$.q+p+P J 3@0@6X",
"5.$+#+:.] 1@*@{X",
"0 8XPX uogo<.",
"q hXYX Wo%O' ",
"f.}OYOh.m.+@(+}X",
"( o+bO. , >@W+0.",
". O.&X G.;o= ",
" 0 2. n +X ",
"o 7X=O noV+l ",
"1XgO^O).FoB+]+So",
"v.`.:Xy.bX*oGonX",
"O 2X7 Bos ",
"X JX1Oh ]oC+q.",
"X EX!o1 :Od+,.",
"& -X co ",
"w D.W. QXjol ",
"KX&O_OoXeOM+`+XO",
"tX0o$Oro8OcOm+~O",
"$ o * o # 1.",
"Y.#oU. AXwO$o< ",
":o.+}od aO#@v+=.",
"#.5OUX L T+;O5 ",
" E.] xob. ",
". rXr (oE ",
". ~oz. x+zX ",
" &o_X ;+2O. ",
" ( g.@ ",
"w SX!X` sodo4X",
"F.%+y+,olX2@7@<+",
"k.]O +~.M._+O@Mo",
"3 eo|. 5+-o8 ",
"O o x. o XX3 ",
"L.)O`OD lo%@o@-X",
"j Uo|o.. f+*+(.",
" x. X4 ",
"3 }.D. 6o|X+ ",
"DXe+WOa `o8@^+a.",
"R.ROxOA vX.@P+/.",
"0 D.B.K ~XCXc.",
"e ].G ko} + ",
"1os+IOZ :+e@X@3X",
"pXO+vO6 No<@J+T.",
"o v.> ]Xu ",
" o iX= + Io_ ",
" P.@+*. )X;@.X",
"( iou+Z.C 'Oq@<o",
"d.EXsXf !.#O)oN.",
"t [... zoi.$ ",
".oi+NO. iO6@Z+u.",
",XFOOO ZoI+b+-.",
"; 6.@.X %Xp.( ",
"[ t.y. 3.Q.^./ ",
"RXao@O| pO&+=+^X",
"jX+OjO .uOn+L+Oo",
"k * g # A T ",
"5.qo(Xi @X2+qOS.",
"[ kODOs 4.G+/+Z.",
" F to# { AOY ",
" p . A x ",
"w 7o/o9. 3+k+dX",
"T VO0+GX# Q+:@'o",
". mo(OG. l+'++o",
"% e l. H 9X) ",
"U.Tobo%.@o7+6+ o",
"{.TO>OwX'XU+N+[o",
"+.Po4O>X>.9+D+Ko",
" X j. . xX^ ",
"; WXuX7. <OLo5X",
"9 3OX+X. S+@@eX",
"v.hO,OU FXH+c+).",
"t z ",
"aXDX 0O7O w ",
"[.BO:o&.vo{+dOqX",
"- 3opo+ ZO[OX.",
" - k.W 4 yX#."
};

353
wmMatrix/matrix.c Normal file
View file

@ -0,0 +1,353 @@
/* xscreensaver, Copyright (c) 1999 Jamie Zawinski <jwz@jwz.org>
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation. No representations are made about the suitability of this
* software for any purpose. It is provided "as is" without express or
* implied warranty.
*
* Matrix -- simulate the text scrolls from the movie "The Matrix".
*
* The movie people distribute their own Windows/Mac screensaver that does
* a similar thing, so I wrote one for Unix. However, that version (the
* Windows/Mac version at http://www.whatisthematrix.com/) doesn't match my
* memory of what the screens in the movie looked like, so my `xmatrix'
* does things differently.
*/
#include <stdio.h>
#include "images/small.xpm"
#include "images/medium.xpm"
#include "images/large.xpm"
#include "images/matrix.xbm"
/*
#define CHAR_HEIGHT 4
*/
#include "matrix.h"
/*
#include "resources.h"
*/
extern GC NormalGC;
extern GC EraseGC;
extern Pixel back_pix, fore_pix;
extern int PixmapSize;
int CHAR_HEIGHT;
static void load_images (m_state *state) {
if (state->xgwa.depth > 1) {
XpmAttributes xpmattrs;
int result;
xpmattrs.valuemask = 0;
xpmattrs.valuemask |= XpmCloseness;
xpmattrs.closeness = 40000;
xpmattrs.valuemask |= XpmVisual;
xpmattrs.visual = state->xgwa.visual;
xpmattrs.valuemask |= XpmDepth;
xpmattrs.depth = state->xgwa.depth;
xpmattrs.valuemask |= XpmColormap;
xpmattrs.colormap = state->xgwa.colormap;
if (PixmapSize == 1){
CHAR_HEIGHT = 4;
result = XpmCreatePixmapFromData (state->dpy, state->window, small,
&state->images, 0 /* mask */,
&xpmattrs);
} else if (PixmapSize == 2){
CHAR_HEIGHT = 6;
result = XpmCreatePixmapFromData (state->dpy, state->window, medium,
&state->images, 0 /* mask */,
&xpmattrs);
} else {
CHAR_HEIGHT = 8;
result = XpmCreatePixmapFromData (state->dpy, state->window, large,
&state->images, 0 /* mask */,
&xpmattrs);
}
if (!state->images || (result != XpmSuccess && result != XpmColorError))
state->images = 0;
state->image_width = xpmattrs.width;
state->image_height = xpmattrs.height;
state->nglyphs = state->image_height / CHAR_HEIGHT;
} else {
state->image_width = matrix_width;
state->image_height = matrix_height;
state->nglyphs = state->image_height / CHAR_HEIGHT;
state->images = XCreatePixmapFromBitmapData (state->dpy, state->window,
(char *) matrix_bits,
state->image_width, state->image_height,
back_pix, fore_pix, state->xgwa.depth);
}
}
m_state *init_matrix( Display *dpy, Window window ) {
m_state *state = (m_state *) calloc (sizeof(*state), 1);
state->dpy = dpy;
state->window = window;
XGetWindowAttributes (dpy, window, &state->xgwa);
load_images (state);
state->draw_gc = NormalGC;
state->erase_gc = EraseGC;
state->char_width = state->image_width / 2;
state->char_height = CHAR_HEIGHT;
state->grid_width = state->xgwa.width / state->char_width;
state->grid_height = state->xgwa.height / state->char_height;
state->grid_width++;
state->grid_height++;
state->cells = (m_cell *)calloc (sizeof(m_cell), state->grid_width * state->grid_height);
state->feeders = (m_feeder *)calloc (sizeof(m_feeder), state->grid_width);
state->density = 40;
state->insert_top_p = False;
state->insert_bottom_p = True;
return state;
}
static void insert_glyph (m_state *state, int glyph, int x, int y) {
Bool bottom_feeder_p = (y >= 0);
m_cell *from, *to;
if (y >= state->grid_height) return;
if (bottom_feeder_p) {
to = &state->cells[state->grid_width * y + x];
} else {
for (y = state->grid_height-1; y > 0; y--) {
from = &state->cells[state->grid_width * (y-1) + x];
to = &state->cells[state->grid_width * y + x];
*to = *from;
to->changed = True;
}
to = &state->cells[x];
}
to->glyph = glyph;
to->changed = True;
if (!to->glyph) ;
else if (bottom_feeder_p) to->glow = 1 + (random() % 2);
else to->glow = 0;
}
static void feed_matrix (m_state *state) {
int x;
/*
* Update according to current feeders.
*/
for (x = 0; x < state->grid_width; x++) {
m_feeder *f = &state->feeders[x];
if (f->throttle) { /* this is a delay tick, synced to frame. */
f->throttle--;
} else if (f->remaining > 0) { /* how many items are in the pipe */
int g = (random() % state->nglyphs) + 1;
insert_glyph (state, g, x, f->y);
f->remaining--;
if (f->y >= 0) f->y++; /* bottom_feeder_p */
} else { /* if pipe is empty, insert spaces */
insert_glyph (state, 0, x, f->y);
if (f->y >= 0) f->y++; /* bottom_feeder_p */
}
if ((random() % 10) == 0) { /* randomly change throttle speed */
f->throttle = ((random() % 5) + (random() % 5));
}
}
}
static int densitizer (m_state *state) {
/* Horrid kludge that converts percentages (density of screen coverage)
to the parameter that actually controls this. I got this mapping
empirically, on a 1024x768 screen. Sue me. */
if (state->density < 10) return 85;
else if (state->density < 15) return 60;
else if (state->density < 20) return 45;
else if (state->density < 25) return 25;
else if (state->density < 30) return 20;
else if (state->density < 35) return 15;
else if (state->density < 45) return 10;
else if (state->density < 50) return 8;
else if (state->density < 55) return 7;
else if (state->density < 65) return 5;
else if (state->density < 80) return 3;
else if (state->density < 90) return 2;
else return 1;
}
static void hack_matrix (m_state *state) {
int x;
/* Glow some characters. */
if (!state->insert_bottom_p) {
int i = random() % (state->grid_width / 2);
while (--i > 0) {
int x = random() % state->grid_width;
int y = random() % state->grid_height;
m_cell *cell = &state->cells[state->grid_width * y + x];
if (cell->glyph && cell->glow == 0) {
cell->glow = random() % 10;
cell->changed = True;
}
}
}
/* Change some of the feeders. */
for (x = 0; x < state->grid_width; x++) {
m_feeder *f = &state->feeders[x];
Bool bottom_feeder_p;
if (f->remaining > 0) /* never change if pipe isn't empty */
continue;
if ((random() % densitizer(state)) != 0) /* then change N% of the time */
continue;
f->remaining = 3 + (random() % state->grid_height);
f->throttle = ((random() % 5) + (random() % 5));
if ((random() % 4) != 0)
f->remaining = 0;
if (state->insert_top_p && state->insert_bottom_p)
bottom_feeder_p = (random() & 1);
else
bottom_feeder_p = state->insert_bottom_p;
if (bottom_feeder_p)
f->y = random() % (state->grid_height / 2);
else
f->y = -1;
}
}
void draw_matrix (m_state *state, int d) {
int x, y;
int count = 0;
state->density = d;
feed_matrix( state );
hack_matrix( state );
for (y = 0; y < state->grid_height; y++) {
for (x = 0; x < state->grid_width; x++) {
m_cell *cell = &state->cells[state->grid_width * y + x];
if ( cell->glyph ) count++;
if ( !cell->changed ) continue;
if ( cell->glyph == 0 ) {
XFillRectangle( state->dpy, state->window, state->erase_gc,
x * state->char_width, y * state->char_height,
state->char_width, state->char_height );
} else {
XCopyArea( state->dpy, state->images, state->window, state->draw_gc,
(cell->glow ? state->char_width : 0), (cell->glyph - 1) * state->char_height,
state->char_width, state->char_height, x * state->char_width, y * state->char_height );
}
cell->changed = False;
if (cell->glow > 0) {
cell->glow--;
cell->changed = True;
}
}
}
#if 0
{
static int i = 0;
static int ndens = 0;
static int tdens = 0;
i++;
if (i > 50)
{
int dens = (100.0 *
(((double)count) /
((double) (state->grid_width * state->grid_height))));
tdens += dens;
ndens++;
printf ("density: %d%% (%d%%)\n", dens, (tdens / ndens));
i = 0;
}
}
#endif
}

39
wmMatrix/matrix.h Normal file
View file

@ -0,0 +1,39 @@
#include <stdlib.h>
#include <stdio.h>
#include <X11/Xlib.h>
#include <X11/Xresource.h>
#include <X11/Xos.h>
#include <X11/Xutil.h>
#include <X11/xpm.h>
typedef struct {
int glyph;
int changed;
int glow;
} m_cell;
typedef struct {
int remaining;
int throttle;
int y;
} m_feeder;
typedef struct {
Display *dpy;
Window window;
XWindowAttributes xgwa;
GC draw_gc, erase_gc;
int grid_width, grid_height;
int char_width, char_height;
m_cell *cells;
m_feeder *feeders;
int insert_top_p, insert_bottom_p;
int density;
Pixmap images;
int image_width, image_height;
int nglyphs;
} m_state;

2
wmMatrix/version.h Normal file
View file

@ -0,0 +1,2 @@
static const char screensaver_id[] =
"@(#)xscreensaver 3.17 (15-Jul-99), by Jamie Zawinski (jwz@jwz.org)";

407
wmMatrix/wmMatrix.c Normal file
View file

@ -0,0 +1,407 @@
/*
*
* wmMatrix-0.2 (C) 1999 Mike Henderson (mghenderson@lanl.gov)
*
* - A DockApp version of Jamie Zawinski's xmatrix screensaver hack.
*
*
*
*
*
* This program 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, 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 (see the file COPYING); if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA
*
*
* Changes:
*
* Version 0.2 - released Aug 16, 1999.
*
*
* ToDo:
* Tie speed to cpu load or some such thing. (Idea from Ken Steen.) Still need to work
* on how best to accomplish this....
*
*
*
*
*/
/*
* Includes
*/
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <X11/X.h>
#include <X11/xpm.h>
#include "xutils.h"
#include "wmMatrix_master.xpm"
#include "wmMatrix_mask.xbm"
#include "matrix.h"
/*
* Delay between refreshes (in microseconds)
*/
#define DELAY 10000UL
#define WMMATRIX_VERSION "0.2"
void ParseCMDLine(int argc, char *argv[]);
void ButtonPressEvent(XButtonEvent *);
void print_usage();
m_state *init_matrix( Display *, Window );
void draw_matrix( m_state *, int );
int GotFirstClick1, GotDoubleClick1;
int GotFirstClick2, GotDoubleClick2;
int GotFirstClick3, GotDoubleClick3;
int DblClkDelay;
int HasExecute;
char ExecuteCommand[1024];
char *progname = "wmMatrix";
char *progclass = "WMMatrix";
int PixmapSize;
char TimeColor[30] = "#ffff00";
char BackgroundColor[30] = "#181818";
/*
* main
*/
int main(int argc, char *argv[]) {
XEvent event;
int n, k, m;
float avg1, user;
/*char Command[512];*/
m_state *state;
FILE *fp;
/*
* Parse any command line arguments.
*/
ParseCMDLine(argc, argv);
strcpy(ExecuteCommand, "xmatrixsmall");
HasExecute = 1;
initXwindow(argc, argv);
openXwindow(argc, argv, wmMatrix_master, wmMatrix_mask_bits, wmMatrix_mask_width, wmMatrix_mask_height);
state = init_matrix( display, iconwin );
/*
if (HasExecute){
sprintf(Command, "%s -window-id 0x%x &", ExecuteCommand, (int)iconwin);
system(Command);
}
*/
/*
* Loop until we die
*/
n = k = m = 32000;
while(1) {
#if 0
if ( n>10 ){
n = 0;
if ( (fp = fopen("/proc/loadavg", "r")) != NULL ){
fscanf(fp, "%f", &avg1); avg1 *= 10.0; fclose(fp);
m = (int)(40.0 - 1.00*avg1 + 0.5);
if (m < 0) m = 0;
} else {
printf("problem opening /proc/loadavg file for read\n");
exit(-1);
}
} else {
/*
* Update the counter.
*/
++n;
}
#endif
m=0;
if (k > m){
k = 0;
draw_matrix( state, 40 );
} else {
++k;
}
/*
* Double Click Delays
* Keep track of click events. If Delay too long, set GotFirstClick's to False.
*/
if (DblClkDelay > 150) {
DblClkDelay = 0;
GotFirstClick1 = 0; GotDoubleClick1 = 0;
GotFirstClick2 = 0; GotDoubleClick2 = 0;
GotFirstClick3 = 0; GotDoubleClick3 = 0;
} else {
++DblClkDelay;
}
/*
* Process any pending X events.
*/
while(XPending(display)){
XNextEvent(display, &event);
switch(event.type){
case Expose:
RedrawWindow();
break;
case ButtonPress:
ButtonPressEvent(&event.xbutton);
break;
case ButtonRelease:
break;
}
}
/*
* sleep till next update. I cant seem to get usleep or select to work properly
* with args smaller than 10000. A kernel tick problem? If I comment out the next line,
* the app screams (chews up cpu too). Or if I use DELAY of 0 it also screams.
* But a delay of 1 or higher is slow.....
*
*/
short_uusleep(DELAY);
}
}
/*
* ParseCMDLine()
*/
void ParseCMDLine(int argc, char *argv[]) {
int i;
PixmapSize = 2;
for (i = 1; i < argc; i++) {
if (!strcmp(argv[i], "-display")){
++i;
} else if (!strcmp(argv[i], "-tc")){
if ((i+1 >= argc)||(argv[i+1][0] == '-')) {
fprintf(stderr, "wmMatrix: No color found\n");
print_usage();
exit(-1);
}
strcpy(TimeColor, argv[++i]);
} else if (!strcmp(argv[i], "-bc")){
if ((i+1 >= argc)||(argv[i+1][0] == '-')) {
fprintf(stderr, "wmMatrix: No color found\n");
print_usage();
exit(-1);
}
strcpy(BackgroundColor, argv[++i]);
} else if (!strcmp(argv[i], "-e")){
if ((i+1 >= argc)||(argv[i+1][0] == '-')) {
fprintf(stderr, "wmMatrix: No command given\n");
print_usage();
exit(-1);
}
strcpy(ExecuteCommand, argv[++i]);
HasExecute = 1;
} else if (!strcmp(argv[i], "-sml")){
PixmapSize = 1;
} else if (!strcmp(argv[i], "-med")){
PixmapSize = 2;
} else if (!strcmp(argv[i], "-lrg")){
PixmapSize = 3;
} else {
print_usage();
exit(1);
}
}
}
void print_usage(){
printf("\nwmMatrix version: %s\n", WMMATRIX_VERSION);
printf("\t-h\t\tDisplay help screen.\n");
printf("\t-sml\t\tUse small size pixmap.\n");
printf("\t-med\t\tUse medium size pixmap.\n");
printf("\t-lrg\t\tUse large size pixmap.\n");
}
/*
* This routine handles button presses.
*
* Double click on
* Mouse Button 1: Execute the command defined in the -e command-line option.
* Mouse Button 2: No action assigned.
* Mouse Button 3: No action assigned.
*
*
*/
void ButtonPressEvent(XButtonEvent *xev){
DblClkDelay = 0;
if ((xev->button == Button1) && (xev->type == ButtonPress)){
if (GotFirstClick1) GotDoubleClick1 = 1;
else GotFirstClick1 = 1;
} else if ((xev->button == Button2) && (xev->type == ButtonPress)){
if (GotFirstClick2) GotDoubleClick2 = 1;
else GotFirstClick2 = 1;
} else if ((xev->button == Button3) && (xev->type == ButtonPress)){
if (GotFirstClick3) GotDoubleClick3 = 1;
else GotFirstClick3 = 1;
}
/*
* We got a double click on Mouse Button1 (i.e. the left one)
*/
if (GotDoubleClick1) {
GotFirstClick1 = 0;
GotDoubleClick1 = 0;
system("xscreensaver-demo");
}
/*
* We got a double click on Mouse Button2 (i.e. the left one)
*/
if (GotDoubleClick2) {
GotFirstClick2 = 0;
GotDoubleClick2 = 0;
}
/*
* We got a double click on Mouse Button3 (i.e. the left one)
*/
if (GotDoubleClick3) {
GotFirstClick3 = 0;
GotDoubleClick3 = 0;
}
return;
}

View file

@ -0,0 +1,38 @@
#define wmMatrix_mask_width 64
#define wmMatrix_mask_height 64
static char wmMatrix_mask_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,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,
0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,
0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,
0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,
0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,
0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,
0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,
0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,
0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,
0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,
0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,
0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,
0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,
0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,
0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,
0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,
0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,
0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,
0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,
0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,
0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,
0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,
0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,
0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,
0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,
0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,
0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,
0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,
0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,
0xff,0xff,0xff,0xff,0xff,0xff,0x0f,0xf0,0xff,0xff,0xff,0xff,0xff,0xff,0x0f,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00};

View file

@ -0,0 +1,73 @@
/* XPM */
static char *wmMatrix_master[] = {
/* width height num_colors chars_per_pixel */
" 64 64 2 1",
/* colors */
". c #ffffff",
"# c #000000",
/* pixels */
"................................................................",
"................................................................",
"................................................................",
"................................................................",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"....########################################################....",
"................................................................",
"................................................................",
"................................................................",
"................................................................"
};

393
wmMatrix/xutils.c Normal file
View file

@ -0,0 +1,393 @@
/*
* xutils.c - A collection of X-windows utilties for creating WindowMAker
* DockApps.
*
* This file contains alot of the lower-level X windows routines. Origins with wmppp
* (by Martijn Pieterse (pieterse@xs4all.nl)), but its been hacked up quite a bit
* and passed on from one new DockApp to the next.
*
*
*
*
* This program 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, 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 (see the file COPYING); if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA
*
*
*
*
*/
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <ctype.h>
#include <stdarg.h>
#include <X11/Xlib.h>
#include <X11/xpm.h>
#include <X11/extensions/shape.h>
#include <sys/time.h>
#include <sys/select.h>
#include "xutils.h"
/*
* X11 Variables
*/
int x_fd;
XSizeHints mysizehints;
XWMHints mywmhints;
Pixel back_pix, fore_pix;
char *Geometry = "";
GC NormalGC;
GC EraseGC;
XpmIcon wmgen;
Pixmap pixmask;
/*
* Colors for wmCalClock
*/
extern char TimeColor[30];
extern char BackgroundColor[30];
/*
* flush_expose
*/
static int flush_expose(Window w) {
XEvent dummy;
int i=0;
while (XCheckTypedWindowEvent(display, w, Expose, &dummy))
i++;
return i;
}
/*
* RedrawWindow
* RedrawWindowXY
*/
void RedrawWindow(void) {
flush_expose(iconwin);
XCopyArea(display, wmgen.pixmap, iconwin, NormalGC, 0,0, wmgen.attributes.width, wmgen.attributes.height, 0, 0);
flush_expose(win);
XCopyArea(display, wmgen.pixmap, win, NormalGC, 0,0, wmgen.attributes.width, wmgen.attributes.height, 0, 0);
}
void RedrawWindowXY(int x, int y) {
flush_expose(iconwin);
XCopyArea(display, wmgen.pixmap, iconwin, NormalGC, x,y, wmgen.attributes.width, wmgen.attributes.height, 0, 0);
flush_expose(win);
XCopyArea(display, wmgen.pixmap, win, NormalGC, x,y, wmgen.attributes.width, wmgen.attributes.height, 0, 0);
}
/*
* copyXPMArea
* copyXBMArea
*/
void copyXPMArea(int x, int y, int sx, int sy, int dx, int dy) {
XCopyArea(display, wmgen.pixmap, wmgen.pixmap, NormalGC, x, y, sx, sy, dx, dy);
}
void copyXBMArea(int x, int y, int sx, int sy, int dx, int dy) {
XCopyArea(display, wmgen.mask, wmgen.pixmap, NormalGC, x, y, sx, sy, dx, dy);
}
/*
* initXwindow
*/
void initXwindow(int argc, char *argv[]){
int i;
char *display_name = NULL;
for (i=1; argv[i]; ++i) {
if (!strcmp(argv[i], "-display")) display_name = argv[i+1];
}
if (!(display = XOpenDisplay(display_name))) {
fprintf(stderr, "%s: can't open display %s\n",
argv[0], XDisplayName(display_name));
exit(1);
}
screen = DefaultScreen(display);
Root = RootWindow(display, screen);
DisplayDepth = DefaultDepth(display, screen);
x_fd = XConnectionNumber(display);
}
/*
* openXwindow
*/
void openXwindow(int argc, char *argv[], char *pixmap_bytes[], char *pixmask_bits,
int pixmask_width, int pixmask_height) {
unsigned int borderwidth = 1;
XClassHint classHint;
char *wname = argv[0];
XTextProperty name;
XGCValues gcv;
unsigned long gcm;
int dummy=0, red, grn, blu;
XpmColorSymbol cols[10]={ {"Back", NULL, 0},
{"Color1", NULL, 0},
{"Color2", NULL, 0},
{"Color3", NULL, 0},
{"Color4", NULL, 0},
{"Color5", NULL, 0},
{"Color6", NULL, 0},
{"Color7", NULL, 0},
{"Color8", NULL, 0},
{"Color9", NULL, 0}};
/*
* Create Pixmap
*/
cols[0].pixel = getColor(BackgroundColor, 1.0000, &red, &grn, &blu);
cols[1].pixel = getBlendedColor(TimeColor, 0.1522, red, grn, blu);
cols[2].pixel = getBlendedColor(TimeColor, 0.2602, red, grn, blu);
cols[3].pixel = getBlendedColor(TimeColor, 0.3761, red, grn, blu);
cols[4].pixel = getBlendedColor(TimeColor, 0.4841, red, grn, blu);
cols[5].pixel = getBlendedColor(TimeColor, 0.5922, red, grn, blu);
cols[6].pixel = getBlendedColor(TimeColor, 0.6980, red, grn, blu);
cols[7].pixel = getBlendedColor(TimeColor, 0.7961, red, grn, blu);
cols[8].pixel = getBlendedColor(TimeColor, 0.8941, red, grn, blu);
cols[9].pixel = getBlendedColor(TimeColor, 1.0000, red, grn, blu);
wmgen.attributes.numsymbols = 10;
wmgen.attributes.colorsymbols = cols;
wmgen.attributes.exactColors = False;
wmgen.attributes.closeness = 40000;
wmgen.attributes.valuemask = XpmReturnPixels | XpmReturnExtensions | XpmColorSymbols
| XpmExactColors | XpmCloseness | XpmSize;
if (XpmCreatePixmapFromData(display, Root, pixmap_bytes,
&(wmgen.pixmap), &(wmgen.mask), &(wmgen.attributes)) != XpmSuccess){
fprintf(stderr, "Not enough free colorcells.\n");
exit(1);
}
/*
* Create a window
*/
mysizehints.flags = USSize | USPosition;
mysizehints.x = 0;
mysizehints.y = 0;
back_pix = getColor("black", 1.0, &red, &grn, &blu);
fore_pix = getColor("white", 1.0, &red, &grn, &blu);
XWMGeometry(display, screen, Geometry, NULL, borderwidth, &mysizehints,
&mysizehints.x, &mysizehints.y,&mysizehints.width,&mysizehints.height, &dummy);
mysizehints.width = 64;
mysizehints.height = 64;
win = XCreateSimpleWindow(display, Root, mysizehints.x, mysizehints.y,
mysizehints.width, mysizehints.height, borderwidth, fore_pix, back_pix);
iconwin = XCreateSimpleWindow(display, win, mysizehints.x, mysizehints.y,
mysizehints.width, mysizehints.height, borderwidth, fore_pix, back_pix);
/*
* Activate hints
*/
XSetWMNormalHints(display, win, &mysizehints);
classHint.res_name = wname;
classHint.res_class = wname;
XSetClassHint(display, win, &classHint);
/*
* Set up the xevents that you want the relevent windows to inherit
* Currently, its seems that setting KeyPress events here has no
* effect. I.e. for some you will need to Grab the focus and then return
* it after you are done...
*/
XSelectInput(display, win, ButtonPressMask | ExposureMask | ButtonReleaseMask
| PointerMotionMask | StructureNotifyMask | EnterWindowMask | LeaveWindowMask
| KeyPressMask | KeyReleaseMask);
XSelectInput(display, iconwin, ButtonPressMask | ExposureMask | ButtonReleaseMask
| PointerMotionMask | StructureNotifyMask | EnterWindowMask | LeaveWindowMask
| KeyPressMask | KeyReleaseMask);
if (XStringListToTextProperty(&wname, 1, &name) == 0) {
fprintf(stderr, "%s: can't allocate window name\n", wname);
exit(1);
}
XSetWMName(display, win, &name);
/*
* Create Graphics Context (GC) for drawing
*/
gcm = GCForeground | GCBackground | GCGraphicsExposures;
gcv.foreground = fore_pix;
gcv.background = back_pix;
gcv.graphics_exposures = 0;
NormalGC = XCreateGC(display, Root, gcm, &gcv);
/*
* Create Graphics Context (GC) for erasing
*/
gcm = GCForeground | GCBackground | GCGraphicsExposures;
gcv.foreground = back_pix;
gcv.background = back_pix;
gcv.graphics_exposures = 0;
EraseGC = XCreateGC(display, Root, gcm, &gcv);
pixmask = XCreateBitmapFromData(display, win, pixmask_bits, pixmask_width, pixmask_height);
XShapeCombineMask(display, win, ShapeBounding, 0, 0, pixmask, ShapeSet);
XShapeCombineMask(display, iconwin, ShapeBounding, 0, 0, pixmask, ShapeSet);
mywmhints.initial_state = WithdrawnState;
mywmhints.icon_window = iconwin;
mywmhints.icon_x = mysizehints.x;
mywmhints.icon_y = mysizehints.y;
mywmhints.window_group = win;
mywmhints.flags = StateHint | IconWindowHint | IconPositionHint | WindowGroupHint;
XSetWMHints(display, win, &mywmhints);
XSetCommand(display, win, argv, argc);
XMapWindow(display, win);
}
unsigned long getColor(char *ColorName, float fac, int *red, int *grn, int *blu) {
XColor Color;
XWindowAttributes Attributes;
XGetWindowAttributes(display, Root, &Attributes);
Color.pixel = 0;
XParseColor(display, Attributes.colormap, ColorName, &Color);
Color.red = (unsigned short)(fac*(Color.red-24) + 24);
Color.blue = (unsigned short)(fac*(Color.blue-24) + 24);
Color.green = (unsigned short)(fac*(Color.green-24) + 24);
Color.flags = DoRed | DoGreen | DoBlue;
XAllocColor(display, Attributes.colormap, &Color);
*red = Color.red;
*grn = Color.green;
*blu = Color.blue;
return Color.pixel;
}
unsigned long getBlendedColor(char *ColorName, float fac, int red, int grn, int blu) {
XColor Color;
XWindowAttributes Attributes;
XGetWindowAttributes(display, Root, &Attributes);
Color.pixel = 0;
XParseColor(display, Attributes.colormap, ColorName, &Color);
Color.red = (unsigned short)(fac*(Color.red-red) + red);
Color.blue = (unsigned short)(fac*(Color.blue-grn) + grn);
Color.green = (unsigned short)(fac*(Color.green-blu) + blu);
Color.flags = DoRed | DoGreen | DoBlue;
XAllocColor(display, Attributes.colormap, &Color);
return Color.pixel;
}
/*
* Here is a faster version of usleep using select()
*/
void uusleep(unsigned long usecs) {
struct timeval tv;
tv.tv_sec = usecs / 1000000UL;
tv.tv_usec = usecs % 1000000UL;
select(1, NULL, NULL, NULL, &tv);
}
/*
* This version assumes the tv_sec value will be zero. I.e. the delay
* will be less than 1 second. This allows us to save on a div operation.
*
*/
void short_uusleep(unsigned long usecs) {
struct timeval tv;
tv.tv_sec = 0;
tv.tv_usec = usecs;
select(1, NULL, NULL, NULL, &tv);
}

50
wmMatrix/xutils.h Normal file
View file

@ -0,0 +1,50 @@
#ifndef WMGENERAL_H_INCLUDED
#define WMGENERAL_H_INCLUDED
/*
* Typedefs
*/
typedef struct {
Pixmap pixmap;
Pixmap mask;
XpmAttributes attributes;
} XpmIcon;
/*
* Global variable
*/
Display *display;
Window Root;
Window iconwin, win;
int screen;
int DisplayDepth;
/*
* Function Prototypes
*/
void AddMouseRegion(int, int, int, int, int);
int CheckMouseRegion(int, int);
void openXwindow(int, char **, char **, char *, int, int);
void initXwindow(int, char **);
void RedrawWindow(void);
void RedrawWindowXY(int, int);
void copyXPMArea(int, int, int, int, int, int);
void copyXBMArea(int, int, int, int, int, int);
void setMaskXY(int, int);
unsigned long getColor(char *, float, int *, int *, int *);
unsigned long getBlendedColor(char *, float, int, int, int);
void RedrawWindow(void);
void wusleep( unsigned int );
#endif

112
wmMatrix/yarandom.c Normal file
View file

@ -0,0 +1,112 @@
#define HAVE_UNISTD_H 1
#define GETTIMEOFDAY_TWO_ARGS 1
/* yarandom.c -- Yet Another Random Number Generator.
The unportable mess that is rand(), random(), drand48() and friends led me
to ask Phil Karlton <karlton@netscape.com> 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_UNISTD_H
# include <unistd.h> /* for getpid() */
#endif
#include <sys/time.h> /* 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;
}

54
wmMatrix/yarandom.h Normal file
View file

@ -0,0 +1,54 @@
/* xscreensaver, Copyright (c) 1997, 1998 by Jamie Zawinski <jwz@jwz.org>
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation. No representations are made about the suitability of this
* software for any purpose. It is provided "as is" without express or
* implied warranty.
*/
#ifndef __YARANDOM_H__
#define __YARANDOM_H__
#undef random
#undef rand
#undef drand48
#undef srandom
#undef srand
#undef srand48
#undef frand
#undef RAND_MAX
#ifdef VMS
# include "vms-gtod.h"
#endif
#define random() ya_random()
#define srandom(i) ya_rand_init(0)
#define RAND_MAX 0x7FFFFFFF
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__ */