VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][0-9]*\).*/\1/p' utils/version.h` ; \
HEAD="xscreensaver-$$VERS" ; \
ADIR=archive/ ; \
- NAME="$$ADIR$$HEAD.tar.gz" ; \
+ BNAME="$$HEAD.tar.gz" ; \
+ NAME="$$ADIR$$BNAME" ; \
+ DNAME="$$DEST/$$HEAD.tar.gz" ; \
\
if [ ! -f $$NAME ]; then \
echo "$$NAME does not exist! Did you forget to \`make tar'?" ; \
exit 1 ; \
fi ; \
chmod a-w $$NAME ; \
- if [ -f $$DEST/$$NAME ]; then \
- echo -n "WARNING: $$DEST/$$NAME already exists! Overwrite? "; \
+ if [ -f $$DNAME ]; then \
+ echo -n "WARNING: $$DNAME already exists! Overwrite? "; \
read line; \
if [ "x$$line" != "xyes" -a "x$$line" != "xy" ]; then \
exit 1 ; \
fi ; \
fi ; \
- cp -p $$NAME $$DEST/$$NAME ; \
- chmod u+w $$DEST/$$NAME ; \
+ cp -p $$NAME $$DNAME ; \
+ chmod u+w $$DNAME ; \
cd $$DEST ; \
\
TMP=/tmp/xd.$$$$ ; \
else \
set -x ; \
fi ; \
- cvs add -kb $$NAME ; \
+ cvs add -kb $$BNAME ; \
cat $$TMP > download.html ; \
rm -f $$TMP ; \
\
============
+Changes since 3.33: * Turned `memoryLimit' off by default, sigh. Apparently
+ some versions of the GL libraries (appear to) allocate
+ hundreds of megs for every GL program, so `memoryLimit'
+ was causing GL programs to malfunction or crash on
+ those systems.
+ * Improved fading on TrueColor XFree86 4.1.x systems.
+ * New GL hack, `circuit'.
+ * Added `fuzz' mode to `decayscreen'.
+ * New version of `whirlygig'.
+ * Added links to `glplanet' and `sphereEversion'.
+ * Fixed rare race condition that could make `sonar' hang.
+ * Fixed potential crash in `speedmine'.
+ * Made `xscreensaver-demo' not crash when imageDirectory
+ was set to a non-existent directory.
+ * Made `xscreensaver-getimage-video' invoke XawTV's
+ `streamer' program better.
+ * Made `phosphor' and `starwars' deal with CR, LF,
+ or CRLF line endings.
+ * Changes for Cygwin compilation environments.
+ * Made `sonar' compile on systems that can't ping.
+ * Configure changes for HPUX 10.20.
+ * Made PAM code work on Red Had 4.2 systems.
+ * Made `xscreensaver-command -deactivate' work when the
+ saver is not active: what that does is reset the idle
+ timer, as if keyboard input had been detected. This
+ was added for the benefit of people writing DVD-playing
+ software: they can now prevent the screensaver from
+ kicking in by sending a -deactivate message once a
+ minute while the movie is playing and not paused.
+ * Various minor portability tweaks.
Changes since 3.32: * New hacks, `speedmine' and `whirlygig'.
* Sped up `pyro', made the explosions look a bit better.
* Added better stars to `glplanet' and `starwars'.
/* Define this if you have the functions XF86VidModeGetGamma() and
* XF86VidModeSetGamma(), which allow clients to change the gamma
- * response of the monitor. This is an XFree86 4.x thing, and probably
- * doesn't exist elsewhere. (It's available if the file
+ * response of the monitor. This is an XFree86 4.0.x thing, and
+ * probably doesn't exist elsewhere. (It's available if the file
* /usr/include/X11/extensions/xf86vmode.h exists and has stuff about
* gamma in it.)
*/
#undef HAVE_XF86VMODE_GAMMA
+/* Define this if you have the functions XF86VidModeGetGammaRamp() and
+ * XF86VidModeSetGammaRamp(), which provide finer-grained control than
+ * XF86VidMode[GS]etGamma(). These appeared in XFree86 4.1.0.
+ */
+#undef HAVE_XF86VMODE_GAMMA_RAMP
+
/* Define this if you have a Linux-like /proc/interrupts file which can be
* examined to determine when keyboard activity has occurred.
*/
struct ip ip;
i.type = ICMP_ECHO;
i.code = 0;
- i.cksum = 0;
+ i.checksum = 0;
i.un.echo.id = 0;
i.un.echo.sequence = 0;
si.sin_family = AF_INET;
#
for version in X11R6 X11R5 X11R4 ; do
# if either pair of directories exists...
- if test -d /usr/lib/$version || test -d /usr/contrib/$version/lib
+ if test -d /usr/include/$version || test -d /usr/contrib/$version/include
then
# if contrib exists, use it...
- if test -d /usr/contrib/$version/lib ; then
+ if test -d /usr/contrib/$version/include ; then
X_CFLAGS="$X_CFLAGS -I/usr/contrib/$version/include"
X_LIBS="$X_LIBS -L/usr/contrib/$version/lib"
fi
# if the "standard" one exists, use it.
- if test -d /usr/lib/$version ; then
+ if test -d /usr/include/$version ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/$version"
X_LIBS="$X_LIBS -L/usr/lib/$version"
fi
# Now find Motif. Thanks for not making xmkmf find this by
# default, you losers.
#
- if test -d /usr/lib/Motif1.2 ; then
+ if test -d /usr/include/Motif2.1 ; then
+ X_CFLAGS="$X_CFLAGS -I/usr/include/Motif2.1"
+ X_LIBS="$X_LIBS -L/usr/lib/Motif2.1"
+ elif test -d /usr/include/Motif1.2 ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.2"
X_LIBS="$X_LIBS -L/usr/lib/Motif1.2"
- elif test -d /usr/lib/Motif1.1 ; then
+ elif test -d /usr/include/Motif1.1 ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.1"
X_LIBS="$X_LIBS -L/usr/lib/Motif1.1"
fi
# Now let's check for the pseudo-standard locations for OpenGL and XPM.
#
- if test -d /opt/Mesa/lib ; then
+ if test -d /opt/graphics/OpenGL/include ; then
+ # HP-UX 10.20 puts it here
+ X_CFLAGS="-I/opt/graphics/OpenGL/include $X_CFLAGS"
+ X_LIBS="-L/opt/graphics/OpenGL/lib $X_LIBS"
+ elif test -d /opt/Mesa/lib ; then
X_CFLAGS="-I/opt/Mesa/include $X_CFLAGS"
X_LIBS="-L/opt/Mesa/lib $X_LIBS"
fi
+
if test -d /opt/xpm/lib/X11 ; then
X_CFLAGS="-I/opt/xpm/include $X_CFLAGS"
X_LIBS="-L/opt/xpm/lib/X11 $X_LIBS"
# Some versions of Slowlaris Motif require -lgen. But not all. Why?
echo $ac_n "checking for regcmp in -lgen""... $ac_c" 1>&6
-echo "configure:3479: checking for regcmp in -lgen" >&5
+echo "configure:3487: checking for regcmp in -lgen" >&5
ac_lib_var=`echo gen'_'regcmp | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lgen $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3487 "configure"
+#line 3495 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
regcmp()
; return 0; }
EOF
-if { (eval echo configure:3498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
;;
esac
echo $ac_n "checking for XPointer""... $ac_c" 1>&6
-echo "configure:3522: checking for XPointer" >&5
+echo "configure:3530: checking for XPointer" >&5
if eval "test \"`echo '$''{'ac_cv_xpointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 3533 "configure"
+#line 3541 "configure"
#include "confdefs.h"
#include <X11/Xlib.h>
int main() {
XPointer foo = (XPointer) 0;
; return 0; }
EOF
-if { (eval echo configure:3540: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3548: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_xpointer=yes
else
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/Xmu/Error.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/Xmu/Error.h""... $ac_c" 1>&6
-echo "configure:3578: checking for X11/Xmu/Error.h" >&5
+echo "configure:3586: checking for X11/Xmu/Error.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3583 "configure"
+#line 3591 "configure"
#include "confdefs.h"
#include <X11/Xmu/Error.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3588: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3596: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
case "$host" in
*-sunos4*)
echo $ac_n "checking for the SunOS 4.1.x _get_wmShellWidgetClass bug""... $ac_c" 1>&6
-echo "configure:3637: checking for the SunOS 4.1.x _get_wmShellWidgetClass bug" >&5
+echo "configure:3645: checking for the SunOS 4.1.x _get_wmShellWidgetClass bug" >&5
if eval "test \"`echo '$''{'ac_cv_sunos_xmu_bug'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# with X libraries because we know it's SunOS.
LDFLAGS="$LDFLAGS -lXmu -lXt -lX11 -lXext -lm"
cat > conftest.$ac_ext <<EOF
-#line 3650 "configure"
+#line 3658 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:3657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_sunos_xmu_bug=no
else
echo "$ac_t""$ac_cv_sunos_xmu_bug" 1>&6
if test "$ac_cv_sunos_xmu_bug" = yes ; then
echo $ac_n "checking whether the compiler understands -static""... $ac_c" 1>&6
-echo "configure:3673: checking whether the compiler understands -static" >&5
+echo "configure:3681: checking whether the compiler understands -static" >&5
if eval "test \"`echo '$''{'ac_cv_ld_static'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS -static"
cat > conftest.$ac_ext <<EOF
-#line 3680 "configure"
+#line 3688 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:3687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_ld_static=yes
else
/*)
echo $ac_n "checking for SGI SCREEN_SAVER headers""... $ac_c" 1>&6
-echo "configure:3770: checking for SGI SCREEN_SAVER headers" >&5
+echo "configure:3778: checking for SGI SCREEN_SAVER headers" >&5
d=$with_sgi/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for SGI SCREEN_SAVER libs""... $ac_c" 1>&6
-echo "configure:3780: checking for SGI SCREEN_SAVER libs" >&5
+echo "configure:3788: checking for SGI SCREEN_SAVER libs" >&5
d=$with_sgi/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/XScreenSaver.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/XScreenSaver.h""... $ac_c" 1>&6
-echo "configure:3813: checking for X11/extensions/XScreenSaver.h" >&5
+echo "configure:3821: checking for X11/extensions/XScreenSaver.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3818 "configure"
+#line 3826 "configure"
#include "confdefs.h"
#include <X11/extensions/XScreenSaver.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3823: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3831: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
/*)
echo $ac_n "checking for MIT-SCREEN-SAVER headers""... $ac_c" 1>&6
-echo "configure:3880: checking for MIT-SCREEN-SAVER headers" >&5
+echo "configure:3888: checking for MIT-SCREEN-SAVER headers" >&5
d=$with_mit/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for MIT-SCREEN-SAVER libs""... $ac_c" 1>&6
-echo "configure:3890: checking for MIT-SCREEN-SAVER libs" >&5
+echo "configure:3898: checking for MIT-SCREEN-SAVER libs" >&5
d=$with_mit/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/scrnsaver.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/scrnsaver.h""... $ac_c" 1>&6
-echo "configure:3923: checking for X11/extensions/scrnsaver.h" >&5
+echo "configure:3931: checking for X11/extensions/scrnsaver.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3928 "configure"
+#line 3936 "configure"
#include "confdefs.h"
#include <X11/extensions/scrnsaver.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3941: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XScreenSaverRegister in -lXext""... $ac_c" 1>&6
-echo "configure:3978: checking for XScreenSaverRegister in -lXext" >&5
+echo "configure:3986: checking for XScreenSaverRegister in -lXext" >&5
ac_lib_var=`echo Xext'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3986 "configure"
+#line 3994 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XScreenSaverRegister()
; return 0; }
EOF
-if { (eval echo configure:3997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XScreenSaverRegister in -lXExExt""... $ac_c" 1>&6
-echo "configure:4044: checking for XScreenSaverRegister in -lXExExt" >&5
+echo "configure:4052: checking for XScreenSaverRegister in -lXExExt" >&5
ac_lib_var=`echo XExExt'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXExExt -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4052 "configure"
+#line 4060 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XScreenSaverRegister()
; return 0; }
EOF
-if { (eval echo configure:4063: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4071: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XScreenSaverRegister in -lXss""... $ac_c" 1>&6
-echo "configure:4113: checking for XScreenSaverRegister in -lXss" >&5
+echo "configure:4121: checking for XScreenSaverRegister in -lXss" >&5
ac_lib_var=`echo Xss'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXss -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4121 "configure"
+#line 4129 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XScreenSaverRegister()
; return 0; }
EOF
-if { (eval echo configure:4132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for XIDLE headers""... $ac_c" 1>&6
-echo "configure:4198: checking for XIDLE headers" >&5
+echo "configure:4206: checking for XIDLE headers" >&5
d=$with_xidle/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for XIDLE libs""... $ac_c" 1>&6
-echo "configure:4208: checking for XIDLE libs" >&5
+echo "configure:4216: checking for XIDLE libs" >&5
d=$with_xidle/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/xidle.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/xidle.h""... $ac_c" 1>&6
-echo "configure:4241: checking for X11/extensions/xidle.h" >&5
+echo "configure:4249: checking for X11/extensions/xidle.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4246 "configure"
+#line 4254 "configure"
#include "confdefs.h"
#include <X11/extensions/xidle.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4251: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4259: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
/*)
echo $ac_n "checking for SGI-VIDEO-CONTROL headers""... $ac_c" 1>&6
-echo "configure:4307: checking for SGI-VIDEO-CONTROL headers" >&5
+echo "configure:4315: checking for SGI-VIDEO-CONTROL headers" >&5
d=$with_sgivc/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for SGI-VIDEO-CONTROL libs""... $ac_c" 1>&6
-echo "configure:4317: checking for SGI-VIDEO-CONTROL libs" >&5
+echo "configure:4325: checking for SGI-VIDEO-CONTROL libs" >&5
d=$with_sgivc/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/XSGIvc.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/XSGIvc.h""... $ac_c" 1>&6
-echo "configure:4352: checking for X11/extensions/XSGIvc.h" >&5
+echo "configure:4360: checking for X11/extensions/XSGIvc.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4357 "configure"
+#line 4365 "configure"
#include "confdefs.h"
#include <X11/extensions/XSGIvc.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4362: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4370: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XSGIvcQueryGammaMap in -lXsgivc""... $ac_c" 1>&6
-echo "configure:4406: checking for XSGIvcQueryGammaMap in -lXsgivc" >&5
+echo "configure:4414: checking for XSGIvcQueryGammaMap in -lXsgivc" >&5
ac_lib_var=`echo Xsgivc'_'XSGIvcQueryGammaMap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXsgivc -lXext -lX11 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4414 "configure"
+#line 4422 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XSGIvcQueryGammaMap()
; return 0; }
EOF
-if { (eval echo configure:4425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for DPMS headers""... $ac_c" 1>&6
-echo "configure:4490: checking for DPMS headers" >&5
+echo "configure:4498: checking for DPMS headers" >&5
d=$with_dpms/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for DPMS libs""... $ac_c" 1>&6
-echo "configure:4500: checking for DPMS libs" >&5
+echo "configure:4508: checking for DPMS libs" >&5
d=$with_dpms/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/dpms.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/dpms.h""... $ac_c" 1>&6
-echo "configure:4535: checking for X11/extensions/dpms.h" >&5
+echo "configure:4543: checking for X11/extensions/dpms.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4540 "configure"
+#line 4548 "configure"
#include "confdefs.h"
#include <X11/extensions/dpms.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4545: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4553: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for DPMSInfo in -lXext""... $ac_c" 1>&6
-echo "configure:4591: checking for DPMSInfo in -lXext" >&5
+echo "configure:4599: checking for DPMSInfo in -lXext" >&5
ac_lib_var=`echo Xext'_'DPMSInfo | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXext -lXext -lX11 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4599 "configure"
+#line 4607 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
DPMSInfo()
; return 0; }
EOF
-if { (eval echo configure:4610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for DPMSInfo in -lXdpms""... $ac_c" 1>&6
-echo "configure:4656: checking for DPMSInfo in -lXdpms" >&5
+echo "configure:4664: checking for DPMSInfo in -lXdpms" >&5
ac_lib_var=`echo Xdpms'_'DPMSInfo | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXdpms -lXext -lX11 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4664 "configure"
+#line 4672 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
DPMSInfo()
; return 0; }
EOF
-if { (eval echo configure:4675: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for xf86vmode headers""... $ac_c" 1>&6
-echo "configure:4742: checking for xf86vmode headers" >&5
+echo "configure:4750: checking for xf86vmode headers" >&5
d=$with_xf86vmode/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for xf86vmode libs""... $ac_c" 1>&6
-echo "configure:4752: checking for xf86vmode libs" >&5
+echo "configure:4760: checking for xf86vmode libs" >&5
d=$with_xf86vmode/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/xf86vmode.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/xf86vmode.h""... $ac_c" 1>&6
-echo "configure:4787: checking for X11/extensions/xf86vmode.h" >&5
+echo "configure:4795: checking for X11/extensions/xf86vmode.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4792 "configure"
+#line 4800 "configure"
#include "confdefs.h"
#include <X11/extensions/xf86vmode.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4797: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4805: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XF86VidModeGetViewPort in -lXxf86vm""... $ac_c" 1>&6
-echo "configure:4841: checking for XF86VidModeGetViewPort in -lXxf86vm" >&5
+echo "configure:4849: checking for XF86VidModeGetViewPort in -lXxf86vm" >&5
ac_lib_var=`echo Xxf86vm'_'XF86VidModeGetViewPort | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXxf86vm -lXext -lX11 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4849 "configure"
+#line 4857 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XF86VidModeGetViewPort()
; return 0; }
EOF
-if { (eval echo configure:4860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4868: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
###############################################################################
have_xf86gamma=no
+have_xf86gamma_ramp=no
with_xf86gamma_req=unspecified
# Check whether --with-xf86gamma-ext or --without-xf86gamma-ext was given.
if test "${with_xf86gamma_ext+set}" = set; then
/*)
echo $ac_n "checking for xf86gamma headers""... $ac_c" 1>&6
-echo "configure:4925: checking for xf86gamma headers" >&5
+echo "configure:4934: checking for xf86gamma headers" >&5
d=$with_xf86gamma/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for xf86gamma libs""... $ac_c" 1>&6
-echo "configure:4935: checking for xf86gamma libs" >&5
+echo "configure:4944: checking for xf86gamma libs" >&5
d=$with_xf86gamma/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/xf86vmode.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/xf86vmode.h""... $ac_c" 1>&6
-echo "configure:4973: checking for X11/extensions/xf86vmode.h" >&5
+echo "configure:4982: checking for X11/extensions/xf86vmode.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4978 "configure"
+#line 4987 "configure"
#include "confdefs.h"
#include <X11/extensions/xf86vmode.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4983: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XF86VidModeSetGamma in -lXxf86vm""... $ac_c" 1>&6
-echo "configure:5028: checking for XF86VidModeSetGamma in -lXxf86vm" >&5
+echo "configure:5037: checking for XF86VidModeSetGamma in -lXxf86vm" >&5
ac_lib_var=`echo Xxf86vm'_'XF86VidModeSetGamma | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXxf86vm -lXext -lX11 $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5036 "configure"
+#line 5045 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XF86VidModeSetGamma()
; return 0; }
EOF
-if { (eval echo configure:5047: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
- # pull in the lib, if we haven't already
- if test "$have_xf86gamma" = yes -a "$have_xf86vmode" = no; then
- SAVER_LIBS="$SAVER_LIBS -lXxf86vm"
+ # check for the Ramp versions of the functions too.
+ if test "$have_xf86gamma" = yes; then
+ have_xf86gamma_ramp=no
+
+ ac_save_CPPFLAGS="$CPPFLAGS"
+ ac_save_LDFLAGS="$LDFLAGS"
+# ac_save_LIBS="$LIBS"
+
+ if test \! -z "$includedir" ; then
+ CPPFLAGS="$CPPFLAGS -I$includedir"
fi
+ # note: $X_CFLAGS includes $x_includes
+ CPPFLAGS="$CPPFLAGS $X_CFLAGS"
- # if that succeeded, then we've really got it.
+ if test \! -z "$libdir" ; then
+ LDFLAGS="$LDFLAGS -L$libdir"
+ fi
+ # note: $X_LIBS includes $x_libraries
+ LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
+
+ echo $ac_n "checking for XF86VidModeSetGammaRamp in -lXxf86vm""... $ac_c" 1>&6
+echo "configure:5104: checking for XF86VidModeSetGammaRamp in -lXxf86vm" >&5
+ac_lib_var=`echo Xxf86vm'_'XF86VidModeSetGammaRamp | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ ac_save_LIBS="$LIBS"
+LIBS="-lXxf86vm -lXext -lX11 $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 5112 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char XF86VidModeSetGammaRamp();
+
+int main() {
+XF86VidModeSetGammaRamp()
+; return 0; }
+EOF
+if { (eval echo configure:5123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ have_xf86gamma_ramp=yes
+else
+ echo "$ac_t""no" 1>&6
+true
+fi
+
+ CPPFLAGS="$ac_save_CPPFLAGS"
+ LDFLAGS="$ac_save_LDFLAGS"
+# LIBS="$ac_save_LIBS"
+
+ fi
+
+ # if those tests succeeded, then we've really got the functions.
if test "$have_xf86gamma" = yes; then
cat >> confdefs.h <<\EOF
#define HAVE_XF86VMODE_GAMMA 1
fi
+ if test "$have_xf86gamma_ramp" = yes; then
+ cat >> confdefs.h <<\EOF
+#define HAVE_XF86VMODE_GAMMA_RAMP 1
+EOF
+
+ fi
+
+ # pull in the lib, if we haven't already
+ if test "$have_xf86gamma" = yes -a "$have_xf86vmode" = no; then
+ SAVER_LIBS="$SAVER_LIBS -lXxf86vm"
+ fi
+
elif test "$with_xf86gamma" != no; then
echo "error: must be yes or no: --with-xf86gamma-ext=$with_xf86vmode"
exit 1
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5106 "configure"
+#line 5189 "configure"
#include "confdefs.h"
#include <X11/XHPlib.h>
EOF
if test "$with_proc_interrupts" = yes; then
echo $ac_n "checking whether /proc/interrupts contains keyboard data""... $ac_c" 1>&6
-echo "configure:5144: checking whether /proc/interrupts contains keyboard data" >&5
+echo "configure:5227: checking whether /proc/interrupts contains keyboard data" >&5
if eval "test \"`echo '$''{'ac_cv_have_proc_interrupts'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
/*)
echo $ac_n "checking for PAM headers""... $ac_c" 1>&6
-echo "configure:5277: checking for PAM headers" >&5
+echo "configure:5360: checking for PAM headers" >&5
d=$with_pam/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for PAM libs""... $ac_c" 1>&6
-echo "configure:5287: checking for PAM libs" >&5
+echo "configure:5370: checking for PAM libs" >&5
d=$with_pam/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
if test "$enable_locking" = yes -a "$with_pam" = yes; then
echo $ac_n "checking for PAM""... $ac_c" 1>&6
-echo "configure:5313: checking for PAM" >&5
+echo "configure:5396: checking for PAM" >&5
if eval "test \"`echo '$''{'ac_cv_pam'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5324 "configure"
+#line 5407 "configure"
#include "confdefs.h"
#include <security/pam_appl.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:5331: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5414: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_pam=yes
else
# libpam typically requires dlopen and dlsym. On FreeBSD,
# those are in libc. On Linux and Solaris, they're in libdl.
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:5356: checking for dlopen in -ldl" >&5
+echo "configure:5439: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5364 "configure"
+#line 5447 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
dlopen()
; return 0; }
EOF
-if { (eval echo configure:5375: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking how to call pam_strerror""... $ac_c" 1>&6
-echo "configure:5397: checking how to call pam_strerror" >&5
+echo "configure:5480: checking how to call pam_strerror" >&5
if eval "test \"`echo '$''{'ac_cv_pam_strerror_args'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5402 "configure"
+#line 5485 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <stdlib.h>
char *s = pam_strerror(pamh, PAM_SUCCESS);
; return 0; }
EOF
-if { (eval echo configure:5412: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5495: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_pam_strerror_args=2
else
cat conftest.$ac_ext >&5
rm -rf conftest*
cat > conftest.$ac_ext <<EOF
-#line 5420 "configure"
+#line 5503 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <stdlib.h>
pam_strerror(PAM_SUCCESS);
; return 0; }
EOF
-if { (eval echo configure:5430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5513: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_pam_strerror_args=1
else
/*)
echo $ac_n "checking for Kerberos headers""... $ac_c" 1>&6
-echo "configure:5487: checking for Kerberos headers" >&5
+echo "configure:5570: checking for Kerberos headers" >&5
d=$with_kerberos/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for Kerberos libs""... $ac_c" 1>&6
-echo "configure:5497: checking for Kerberos libs" >&5
+echo "configure:5580: checking for Kerberos libs" >&5
d=$with_kerberos/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
if test "$enable_locking" = yes -a "$with_kerberos" = yes; then
echo $ac_n "checking for Kerberos 4""... $ac_c" 1>&6
-echo "configure:5523: checking for Kerberos 4" >&5
+echo "configure:5606: checking for Kerberos 4" >&5
if eval "test \"`echo '$''{'ac_cv_kerberos'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5534 "configure"
+#line 5617 "configure"
#include "confdefs.h"
#include <krb.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:5541: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5624: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_kerberos=yes
else
echo "$ac_t""$ac_cv_kerberos" 1>&6
echo $ac_n "checking for Kerberos 5""... $ac_c" 1>&6
-echo "configure:5556: checking for Kerberos 5" >&5
+echo "configure:5639: checking for Kerberos 5" >&5
if eval "test \"`echo '$''{'ac_cv_kerberos5'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5567 "configure"
+#line 5650 "configure"
#include "confdefs.h"
#include <kerberosIV/krb.h>
int main() {
; return 0; }
EOF
-if { (eval echo configure:5574: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5657: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_kerberos5=yes
else
if test "$have_kerberos" = yes ; then
echo $ac_n "checking for res_search""... $ac_c" 1>&6
-echo "configure:5621: checking for res_search" >&5
+echo "configure:5704: checking for res_search" >&5
if eval "test \"`echo '$''{'ac_cv_func_res_search'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5626 "configure"
+#line 5709 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char res_search(); below. */
; return 0; }
EOF
-if { (eval echo configure:5649: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_res_search=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for res_search in -lresolv""... $ac_c" 1>&6
-echo "configure:5667: checking for res_search in -lresolv" >&5
+echo "configure:5750: checking for res_search in -lresolv" >&5
ac_lib_var=`echo resolv'_'res_search | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lresolv $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5675 "configure"
+#line 5758 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
res_search()
; return 0; }
EOF
-if { (eval echo configure:5686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for shadow password headers""... $ac_c" 1>&6
-echo "configure:5741: checking for shadow password headers" >&5
+echo "configure:5824: checking for shadow password headers" >&5
d=$with_shadow/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for shadow password libs""... $ac_c" 1>&6
-echo "configure:5751: checking for shadow password libs" >&5
+echo "configure:5834: checking for shadow password libs" >&5
d=$with_shadow/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
if test "$with_shadow" = yes ; then
echo $ac_n "checking for Sun-style shadow passwords""... $ac_c" 1>&6
-echo "configure:5789: checking for Sun-style shadow passwords" >&5
+echo "configure:5872: checking for Sun-style shadow passwords" >&5
if eval "test \"`echo '$''{'ac_cv_sun_adjunct'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5800 "configure"
+#line 5883 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <unistd.h>
const char *pw = p->pwa_passwd;
; return 0; }
EOF
-if { (eval echo configure:5813: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5896: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_sun_adjunct=yes
else
if test "$with_shadow" = yes ; then
echo $ac_n "checking for DEC-style shadow passwords""... $ac_c" 1>&6
-echo "configure:5843: checking for DEC-style shadow passwords" >&5
+echo "configure:5926: checking for DEC-style shadow passwords" >&5
if eval "test \"`echo '$''{'ac_cv_enhanced_passwd'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5854 "configure"
+#line 5937 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <unistd.h>
pw = p->ufld.fd_encrypt;
; return 0; }
EOF
-if { (eval echo configure:5871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5954: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_enhanced_passwd=yes
else
# But on DEC, it's in -lsecurity.
#
echo $ac_n "checking for getprpwnam in -lprot""... $ac_c" 1>&6
-echo "configure:5895: checking for getprpwnam in -lprot" >&5
+echo "configure:5978: checking for getprpwnam in -lprot" >&5
ac_lib_var=`echo prot'_'getprpwnam | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lprot -lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5903 "configure"
+#line 5986 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
getprpwnam()
; return 0; }
EOF
-if { (eval echo configure:5914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for getprpwnam in -lsecurity""... $ac_c" 1>&6
-echo "configure:5933: checking for getprpwnam in -lsecurity" >&5
+echo "configure:6016: checking for getprpwnam in -lsecurity" >&5
ac_lib_var=`echo security'_'getprpwnam | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lsecurity $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5941 "configure"
+#line 6024 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
getprpwnam()
; return 0; }
EOF
-if { (eval echo configure:5952: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6035: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$with_shadow" = yes ; then
echo $ac_n "checking for HP-style shadow passwords""... $ac_c" 1>&6
-echo "configure:5985: checking for HP-style shadow passwords" >&5
+echo "configure:6068: checking for HP-style shadow passwords" >&5
if eval "test \"`echo '$''{'ac_cv_hpux_passwd'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 5996 "configure"
+#line 6079 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <unistd.h>
const char *pw = p->pw_passwd;
; return 0; }
EOF
-if { (eval echo configure:6009: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6092: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_hpux_passwd=yes
else
# on HPUX, bigcrypt is in -lsec
echo $ac_n "checking for bigcrypt in -lsec""... $ac_c" 1>&6
-echo "configure:6030: checking for bigcrypt in -lsec" >&5
+echo "configure:6113: checking for bigcrypt in -lsec" >&5
ac_lib_var=`echo sec'_'bigcrypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lsec $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6038 "configure"
+#line 6121 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
bigcrypt()
; return 0; }
EOF
-if { (eval echo configure:6049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$with_shadow" = yes ; then
echo $ac_n "checking for FreeBSD-style shadow passwords""... $ac_c" 1>&6
-echo "configure:6087: checking for FreeBSD-style shadow passwords" >&5
+echo "configure:6170: checking for FreeBSD-style shadow passwords" >&5
if eval "test \"`echo '$''{'ac_cv_master_passwd'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$with_shadow" = yes ; then
echo $ac_n "checking for generic shadow passwords""... $ac_c" 1>&6
-echo "configure:6113: checking for generic shadow passwords" >&5
+echo "configure:6196: checking for generic shadow passwords" >&5
if eval "test \"`echo '$''{'ac_cv_shadow'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 6124 "configure"
+#line 6207 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <unistd.h>
const char *pw = p->sp_pwdp;
; return 0; }
EOF
-if { (eval echo configure:6136: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6219: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_shadow=yes
else
# On some systems (UnixWare 2.1), getspnam() is in -lgen instead of -lc.
have_getspnam=no
echo $ac_n "checking for getspnam in -lc""... $ac_c" 1>&6
-echo "configure:6157: checking for getspnam in -lc" >&5
+echo "configure:6240: checking for getspnam in -lc" >&5
ac_lib_var=`echo c'_'getspnam | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lc $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6165 "configure"
+#line 6248 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
getspnam()
; return 0; }
EOF
-if { (eval echo configure:6176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$have_getspnam" = no ; then
echo $ac_n "checking for getspnam in -lgen""... $ac_c" 1>&6
-echo "configure:6198: checking for getspnam in -lgen" >&5
+echo "configure:6281: checking for getspnam in -lgen" >&5
ac_lib_var=`echo gen'_'getspnam | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lgen $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6206 "configure"
+#line 6289 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
getspnam()
; return 0; }
EOF
-if { (eval echo configure:6217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6300: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
# On some systems (UnixWare 2.1), crypt() is in -lcrypt instead of -lc.
have_crypt=no
echo $ac_n "checking for crypt in -lc""... $ac_c" 1>&6
-echo "configure:6253: checking for crypt in -lc" >&5
+echo "configure:6336: checking for crypt in -lc" >&5
ac_lib_var=`echo c'_'crypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lc $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6261 "configure"
+#line 6344 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
crypt()
; return 0; }
EOF
-if { (eval echo configure:6272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6355: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$have_crypt" = no ; then
echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:6294: checking for crypt in -lcrypt" >&5
+echo "configure:6377: checking for crypt in -lcrypt" >&5
ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lcrypt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6302 "configure"
+#line 6385 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
crypt()
; return 0; }
EOF
-if { (eval echo configure:6313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6396: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for Motif headers""... $ac_c" 1>&6
-echo "configure:6397: checking for Motif headers" >&5
+echo "configure:6480: checking for Motif headers" >&5
d=$with_motif/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for Motif libs""... $ac_c" 1>&6
-echo "configure:6407: checking for Motif libs" >&5
+echo "configure:6490: checking for Motif libs" >&5
d=$with_motif/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6
-echo "configure:6446: checking for Xm/Xm.h" >&5
+echo "configure:6529: checking for Xm/Xm.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6451 "configure"
+#line 6534 "configure"
#include "confdefs.h"
#include <Xm/Xm.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6456: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6539: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "Xm/ComboBox.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for Xm/ComboBox.h""... $ac_c" 1>&6
-echo "configure:6495: checking for Xm/ComboBox.h" >&5
+echo "configure:6578: checking for Xm/ComboBox.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6500 "configure"
+#line 6583 "configure"
#include "confdefs.h"
#include <Xm/ComboBox.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6505: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6588: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
/*)
echo $ac_n "checking for Gtk headers""... $ac_c" 1>&6
-echo "configure:6568: checking for Gtk headers" >&5
+echo "configure:6651: checking for Gtk headers" >&5
d=$with_gtk/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for Gtk libs""... $ac_c" 1>&6
-echo "configure:6578: checking for Gtk libs" >&5
+echo "configure:6661: checking for Gtk libs" >&5
d=$with_gtk/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
/*)
echo $ac_n "checking for Gnome headers""... $ac_c" 1>&6
-echo "configure:6636: checking for Gnome headers" >&5
+echo "configure:6719: checking for Gnome headers" >&5
d=$with_gnome/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for Gnome libs""... $ac_c" 1>&6
-echo "configure:6646: checking for Gnome libs" >&5
+echo "configure:6729: checking for Gnome libs" >&5
d=$with_gnome/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:6702: checking for $ac_word" >&5
+echo "configure:6785: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_glib_config'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:6742: checking for $ac_word" >&5
+echo "configure:6825: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_gtk_config'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:6784: checking for $ac_word" >&5
+echo "configure:6867: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_gnome_config'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$have_gtk" = yes; then
echo $ac_n "checking Gtk version number""... $ac_c" 1>&6
-echo "configure:6830: checking Gtk version number" >&5
+echo "configure:6913: checking Gtk version number" >&5
if eval "test \"`echo '$''{'ac_cv_gtk_version_string'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$have_gtk" = yes; then
echo $ac_n "checking for Gtk includes""... $ac_c" 1>&6
-echo "configure:6859: checking for Gtk includes" >&5
+echo "configure:6942: checking for Gtk includes" >&5
if eval "test \"`echo '$''{'ac_cv_gtk_config_cflags'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo "$ac_t""$ac_cv_gtk_config_cflags" 1>&6
echo $ac_n "checking for Gtk libs""... $ac_c" 1>&6
-echo "configure:6868: checking for Gtk libs" >&5
+echo "configure:6951: checking for Gtk libs" >&5
if eval "test \"`echo '$''{'ac_cv_gtk_config_libs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Check for Gnome Capplet support.
#
if test "$have_gnome" = yes -a "$have_gtk" = yes; then
- gnome_config_libs="capplet gnomeui"
+ gnome_config_libs="gtk capplet gnomeui"
echo $ac_n "checking for Gnome capplet includes""... $ac_c" 1>&6
-echo "configure:6885: checking for Gnome capplet includes" >&5
+echo "configure:6968: checking for Gnome capplet includes" >&5
if eval "test \"`echo '$''{'ac_cv_gnome_config_cflags'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$have_gnome" = yes -a "$have_gtk" = yes; then
echo $ac_n "checking for Gnome capplet libs""... $ac_c" 1>&6
-echo "configure:6908: checking for Gnome capplet libs" >&5
+echo "configure:6991: checking for Gnome capplet libs" >&5
if eval "test \"`echo '$''{'ac_cv_gnome_config_libs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gnome-help-browser", so it can be a program name with args.
set dummy gnome-help-browser; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:6966: checking for $ac_word" >&5
+echo "configure:7049: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_have_gnome_help'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
have_lesstif=no
if test "$have_motif" = yes ; then
echo $ac_n "checking whether Motif is really LessTif""... $ac_c" 1>&6
-echo "configure:7007: checking whether Motif is really LessTif" >&5
+echo "configure:7090: checking whether Motif is really LessTif" >&5
if eval "test \"`echo '$''{'ac_cv_have_lesstif'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 7018 "configure"
+#line 7101 "configure"
#include "confdefs.h"
#include <Xm/Xm.h>
int main() {
long vers = LesstifVersion;
; return 0; }
EOF
-if { (eval echo configure:7025: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7108: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_lesstif=yes
else
ltv=unknown
echo unknown > conftest-lt
echo $ac_n "checking LessTif version number""... $ac_c" 1>&6
-echo "configure:7050: checking LessTif version number" >&5
+echo "configure:7133: checking LessTif version number" >&5
if eval "test \"`echo '$''{'ac_cv_lesstif_version_string'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_lesstif_version_string=unknown
else
cat > conftest.$ac_ext <<EOF
-#line 7065 "configure"
+#line 7148 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <Xm/Xm.h>
exit(0);
}
EOF
-if { (eval echo configure:7078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7161: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ltv=`cat conftest-lt`
ac_cv_lesstif_version=`echo $ltv | sed 's/ .*//'`
mtv=unknown
echo unknown > conftest-mt
echo $ac_n "checking Motif version number""... $ac_c" 1>&6
-echo "configure:7108: checking Motif version number" >&5
+echo "configure:7191: checking Motif version number" >&5
if eval "test \"`echo '$''{'ac_cv_motif_version_string'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_motif_version_string=unknown
else
cat > conftest.$ac_ext <<EOF
-#line 7123 "configure"
+#line 7206 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <Xm/Xm.h>
exit(0);
}
EOF
-if { (eval echo configure:7136: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
mtv=`cat conftest-mt`
ac_cv_motif_version=`echo $mtv | sed 's/ .*//'`
motif_requires_xpm=no
if test "$have_motif" = yes ; then
echo $ac_n "checking whether Motif requires XPM""... $ac_c" 1>&6
-echo "configure:7180: checking whether Motif requires XPM" >&5
+echo "configure:7263: checking whether Motif requires XPM" >&5
if test "$motif_version" = "unknown" || test "$motif_version" -ge 2000
then
motif_requires_xpm=yes
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XpQueryExtension in -lXp""... $ac_c" 1>&6
-echo "configure:7222: checking for XpQueryExtension in -lXp" >&5
+echo "configure:7305: checking for XpQueryExtension in -lXp" >&5
ac_lib_var=`echo Xp'_'XpQueryExtension | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXp -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7230 "configure"
+#line 7313 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XpQueryExtension()
; return 0; }
EOF
-if { (eval echo configure:7241: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for _Xsetlocale in -lXintl""... $ac_c" 1>&6
-echo "configure:7295: checking for _Xsetlocale in -lXintl" >&5
+echo "configure:7378: checking for _Xsetlocale in -lXintl" >&5
ac_lib_var=`echo Xintl'_'_Xsetlocale | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXintl -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7303 "configure"
+#line 7386 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
_Xsetlocale()
; return 0; }
EOF
-if { (eval echo configure:7314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for GL headers""... $ac_c" 1>&6
-echo "configure:7371: checking for GL headers" >&5
+echo "configure:7454: checking for GL headers" >&5
d=$with_gl/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for GL libs""... $ac_c" 1>&6
-echo "configure:7381: checking for GL libs" >&5
+echo "configure:7464: checking for GL libs" >&5
d=$with_gl/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "GL/gl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for GL/gl.h""... $ac_c" 1>&6
-echo "configure:7417: checking for GL/gl.h" >&5
+echo "configure:7500: checking for GL/gl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7422 "configure"
+#line 7505 "configure"
#include "confdefs.h"
#include <GL/gl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7427: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7510: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "GL/glx.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for GL/glx.h""... $ac_c" 1>&6
-echo "configure:7458: checking for GL/glx.h" >&5
+echo "configure:7541: checking for GL/glx.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7463 "configure"
+#line 7546 "configure"
#include "confdefs.h"
#include <GL/glx.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7468: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7551: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
# to link against.
#
echo $ac_n "checking whether GL is really MesaGL""... $ac_c" 1>&6
-echo "configure:7500: checking whether GL is really MesaGL" >&5
+echo "configure:7583: checking whether GL is really MesaGL" >&5
if eval "test \"`echo '$''{'ac_cv_have_mesa_gl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
cat > conftest.$ac_ext <<EOF
-#line 7512 "configure"
+#line 7595 "configure"
#include "confdefs.h"
#include <GL/glx.h>
EOF
#
if test "$ac_have_mesa_gl" = yes; then
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
-echo "configure:7541: checking for pthread_create in -lpthread" >&5
+echo "configure:7624: checking for pthread_create in -lpthread" >&5
ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lpthread $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7549 "configure"
+#line 7632 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
pthread_create()
; return 0; }
EOF
-if { (eval echo configure:7560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for glXCreateContext in -lMesaGL""... $ac_c" 1>&6
-echo "configure:7607: checking for glXCreateContext in -lMesaGL" >&5
+echo "configure:7690: checking for glXCreateContext in -lMesaGL" >&5
ac_lib_var=`echo MesaGL'_'glXCreateContext | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lMesaGL -lMesaGLU $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7615 "configure"
+#line 7698 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
glXCreateContext()
; return 0; }
EOF
-if { (eval echo configure:7626: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for glXCreateContext in -lGL""... $ac_c" 1>&6
-echo "configure:7672: checking for glXCreateContext in -lGL" >&5
+echo "configure:7755: checking for glXCreateContext in -lGL" >&5
ac_lib_var=`echo GL'_'glXCreateContext | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lGL -lGLU $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7680 "configure"
+#line 7763 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
glXCreateContext()
; return 0; }
EOF
-if { (eval echo configure:7691: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if test "$ac_have_mesa_gl" = yes; then
echo $ac_n "checking MesaGL version number""... $ac_c" 1>&6
-echo "configure:7749: checking MesaGL version number" >&5
+echo "configure:7832: checking MesaGL version number" >&5
if eval "test \"`echo '$''{'ac_cv_mesagl_version_string'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7754 "configure"
+#line 7837 "configure"
#include "confdefs.h"
#include <GL/gl.h>
#ifndef MESA_MAJOR_VERSION
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for glBindTexture in -l$gl_lib_1""... $ac_c" 1>&6
-echo "configure:7825: checking for glBindTexture in -l$gl_lib_1" >&5
+echo "configure:7908: checking for glBindTexture in -l$gl_lib_1" >&5
ac_lib_var=`echo $gl_lib_1'_'glBindTexture | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$gl_lib_1 $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 7833 "configure"
+#line 7916 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
glBindTexture()
; return 0; }
EOF
-if { (eval echo configure:7844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for GLE headers""... $ac_c" 1>&6
-echo "configure:7905: checking for GLE headers" >&5
+echo "configure:7988: checking for GLE headers" >&5
d=$with_gle/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for GLE libs""... $ac_c" 1>&6
-echo "configure:7915: checking for GLE libs" >&5
+echo "configure:7998: checking for GLE libs" >&5
d=$with_gle/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "GL/gle.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for GL/gle.h""... $ac_c" 1>&6
-echo "configure:7951: checking for GL/gle.h" >&5
+echo "configure:8034: checking for GL/gle.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7956 "configure"
+#line 8039 "configure"
#include "confdefs.h"
#include <GL/gle.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8044: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "GL/gutil.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for GL/gutil.h""... $ac_c" 1>&6
-echo "configure:7994: checking for GL/gutil.h" >&5
+echo "configure:8077: checking for GL/gutil.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7999 "configure"
+#line 8082 "configure"
#include "confdefs.h"
#include <GL/gutil.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8004: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8087: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "GL/tube.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for GL/tube.h""... $ac_c" 1>&6
-echo "configure:8035: checking for GL/tube.h" >&5
+echo "configure:8118: checking for GL/tube.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8040 "configure"
+#line 8123 "configure"
#include "confdefs.h"
#include <GL/tube.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8045: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8128: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for gleCreateGC in -lgle""... $ac_c" 1>&6
-echo "configure:8091: checking for gleCreateGC in -lgle" >&5
+echo "configure:8174: checking for gleCreateGC in -lgle" >&5
ac_lib_var=`echo gle'_'gleCreateGC | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lgle $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 8099 "configure"
+#line 8182 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
gleCreateGC()
; return 0; }
EOF
-if { (eval echo configure:8110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8193: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for uview_direction in -lgle""... $ac_c" 1>&6
-echo "configure:8170: checking for uview_direction in -lgle" >&5
+echo "configure:8253: checking for uview_direction in -lgle" >&5
ac_lib_var=`echo gle'_'uview_direction | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lgle $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 8178 "configure"
+#line 8261 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
uview_direction()
; return 0; }
EOF
-if { (eval echo configure:8189: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for uview_direction_d in -lmatrix""... $ac_c" 1>&6
-echo "configure:8234: checking for uview_direction_d in -lmatrix" >&5
+echo "configure:8317: checking for uview_direction_d in -lmatrix" >&5
ac_lib_var=`echo matrix'_'uview_direction_d | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lmatrix $GL_LIBS -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 8242 "configure"
+#line 8325 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
uview_direction_d()
; return 0; }
EOF
-if { (eval echo configure:8253: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for XPM headers""... $ac_c" 1>&6
-echo "configure:8326: checking for XPM headers" >&5
+echo "configure:8409: checking for XPM headers" >&5
d=$with_xpm/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for XPM libs""... $ac_c" 1>&6
-echo "configure:8336: checking for XPM libs" >&5
+echo "configure:8419: checking for XPM libs" >&5
d=$with_xpm/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/xpm.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/xpm.h""... $ac_c" 1>&6
-echo "configure:8369: checking for X11/xpm.h" >&5
+echo "configure:8452: checking for X11/xpm.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8374 "configure"
+#line 8457 "configure"
#include "confdefs.h"
#include <X11/xpm.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8379: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8462: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
/*)
echo $ac_n "checking for XSHM headers""... $ac_c" 1>&6
-echo "configure:8445: checking for XSHM headers" >&5
+echo "configure:8528: checking for XSHM headers" >&5
d=$with_xshm/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for XSHM libs""... $ac_c" 1>&6
-echo "configure:8455: checking for XSHM libs" >&5
+echo "configure:8538: checking for XSHM libs" >&5
d=$with_xshm/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/XShm.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/XShm.h""... $ac_c" 1>&6
-echo "configure:8490: checking for X11/extensions/XShm.h" >&5
+echo "configure:8573: checking for X11/extensions/XShm.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8495 "configure"
+#line 8578 "configure"
#include "confdefs.h"
#include <X11/extensions/XShm.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8500: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8583: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "sys/ipc.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for sys/ipc.h""... $ac_c" 1>&6
-echo "configure:8534: checking for sys/ipc.h" >&5
+echo "configure:8617: checking for sys/ipc.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8539 "configure"
+#line 8622 "configure"
#include "confdefs.h"
#include <sys/ipc.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8544: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8627: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "sys/shm.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for sys/shm.h""... $ac_c" 1>&6
-echo "configure:8579: checking for sys/shm.h" >&5
+echo "configure:8662: checking for sys/shm.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8584 "configure"
+#line 8667 "configure"
#include "confdefs.h"
#include <sys/shm.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8589: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8672: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
LDFLAGS="$LDFLAGS $X_LIBS $X_EXTRA_LIBS"
echo $ac_n "checking for XShmQueryExtension in -lXextSam""... $ac_c" 1>&6
-echo "configure:8641: checking for XShmQueryExtension in -lXextSam" >&5
+echo "configure:8724: checking for XShmQueryExtension in -lXextSam" >&5
ac_lib_var=`echo XextSam'_'XShmQueryExtension | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lXextSam -lX11 -lXext -lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 8649 "configure"
+#line 8732 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
XShmQueryExtension()
; return 0; }
EOF
-if { (eval echo configure:8660: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
/*)
echo $ac_n "checking for DOUBLE-BUFFER headers""... $ac_c" 1>&6
-echo "configure:8727: checking for DOUBLE-BUFFER headers" >&5
+echo "configure:8810: checking for DOUBLE-BUFFER headers" >&5
d=$with_xdbe/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for DOUBLE-BUFFER libs""... $ac_c" 1>&6
-echo "configure:8737: checking for DOUBLE-BUFFER libs" >&5
+echo "configure:8820: checking for DOUBLE-BUFFER libs" >&5
d=$with_xdbe/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/Xdbe.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/Xdbe.h""... $ac_c" 1>&6
-echo "configure:8771: checking for X11/extensions/Xdbe.h" >&5
+echo "configure:8854: checking for X11/extensions/Xdbe.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8776 "configure"
+#line 8859 "configure"
#include "confdefs.h"
#include <X11/extensions/Xdbe.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8781: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8864: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
/*)
echo $ac_n "checking for XReadDisplay headers""... $ac_c" 1>&6
-echo "configure:8844: checking for XReadDisplay headers" >&5
+echo "configure:8927: checking for XReadDisplay headers" >&5
d=$with_readdisplay/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for XReadDisplay libs""... $ac_c" 1>&6
-echo "configure:8854: checking for XReadDisplay libs" >&5
+echo "configure:8937: checking for XReadDisplay libs" >&5
d=$with_readdisplay/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
CPPFLAGS="$CPPFLAGS $X_CFLAGS"
ac_safe=`echo "X11/extensions/readdisplay.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for X11/extensions/readdisplay.h""... $ac_c" 1>&6
-echo "configure:8887: checking for X11/extensions/readdisplay.h" >&5
+echo "configure:8970: checking for X11/extensions/readdisplay.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 8892 "configure"
+#line 8975 "configure"
#include "confdefs.h"
#include <X11/extensions/readdisplay.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8897: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8980: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
case "$with_zippy_req" in
/*)
echo $ac_n "checking for $with_zippy_req""... $ac_c" 1>&6
-echo "configure:8964: checking for $with_zippy_req" >&5
+echo "configure:9047: checking for $with_zippy_req" >&5
if test -x "$with_zippy_req" ; then
echo "$ac_t""yes" 1>&6
else
# Extract the first word of "$with_zippy_req", so it can be a program name with args.
set dummy $with_zippy_req; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:8978: checking for $ac_word" >&5
+echo "configure:9061: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_zip2'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:9028: checking for $ac_word" >&5
+echo "configure:9111: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_emacs_exe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:9062: checking for $ac_word" >&5
+echo "configure:9145: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_xemacs_exe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test -n "$emacs_exe" ; then
echo $ac_n "checking for emacs yow""... $ac_c" 1>&6
-echo "configure:9097: checking for emacs yow" >&5
+echo "configure:9180: checking for emacs yow" >&5
#
# get emacs to tell us where the libexec directory is.
#
if test -z "$ac_cv_zippy_program" ; then
echo $ac_n "checking for xemacs yow""... $ac_c" 1>&6
-echo "configure:9119: checking for xemacs yow" >&5
+echo "configure:9202: checking for xemacs yow" >&5
if test -n "$xemacs_exe" ; then
#
# get xemacs to tell us where the libexec directory is.
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:9178: checking for $ac_word" >&5
+echo "configure:9261: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_fortune'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:9214: checking for $ac_word" >&5
+echo "configure:9297: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_fortune'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
/*)
echo $ac_n "checking for setuid hacks headers""... $ac_c" 1>&6
-echo "configure:9289: checking for setuid hacks headers" >&5
+echo "configure:9372: checking for setuid hacks headers" >&5
d=$setuid_hacks/include
if test -d $d; then
X_CFLAGS="-I$d $X_CFLAGS"
fi
echo $ac_n "checking for setuid hacks libs""... $ac_c" 1>&6
-echo "configure:9299: checking for setuid hacks libs" >&5
+echo "configure:9382: checking for setuid hacks libs" >&5
d=$setuid_hacks/lib
if test -d $d; then
X_LIBS="-L$d $X_LIBS"
struct ip ip;
i.type = ICMP_ECHO;
i.code = 0;
- i.cksum = 0;
+ i.checksum = 0;
i.un.echo.id = 0;
i.un.echo.sequence = 0;
si.sin_family = AF_INET;
#
for version in X11R6 X11R5 X11R4 ; do
# if either pair of directories exists...
- if test -d /usr/lib/$version || test -d /usr/contrib/$version/lib
+ if test -d /usr/include/$version || test -d /usr/contrib/$version/include
then
# if contrib exists, use it...
- if test -d /usr/contrib/$version/lib ; then
+ if test -d /usr/contrib/$version/include ; then
X_CFLAGS="$X_CFLAGS -I/usr/contrib/$version/include"
X_LIBS="$X_LIBS -L/usr/contrib/$version/lib"
fi
# if the "standard" one exists, use it.
- if test -d /usr/lib/$version ; then
+ if test -d /usr/include/$version ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/$version"
X_LIBS="$X_LIBS -L/usr/lib/$version"
fi
# Now find Motif. Thanks for not making xmkmf find this by
# default, you losers.
#
- if test -d /usr/lib/Motif1.2 ; then
+ if test -d /usr/include/Motif2.1 ; then
+ X_CFLAGS="$X_CFLAGS -I/usr/include/Motif2.1"
+ X_LIBS="$X_LIBS -L/usr/lib/Motif2.1"
+ elif test -d /usr/include/Motif1.2 ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.2"
X_LIBS="$X_LIBS -L/usr/lib/Motif1.2"
- elif test -d /usr/lib/Motif1.1 ; then
+ elif test -d /usr/include/Motif1.1 ; then
X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.1"
X_LIBS="$X_LIBS -L/usr/lib/Motif1.1"
fi
# Now let's check for the pseudo-standard locations for OpenGL and XPM.
#
- if test -d /opt/Mesa/lib ; then
+ if test -d /opt/graphics/OpenGL/include ; then
+ # HP-UX 10.20 puts it here
+ X_CFLAGS="-I/opt/graphics/OpenGL/include $X_CFLAGS"
+ X_LIBS="-L/opt/graphics/OpenGL/lib $X_LIBS"
+ elif test -d /opt/Mesa/lib ; then
X_CFLAGS="-I/opt/Mesa/include $X_CFLAGS"
X_LIBS="-L/opt/Mesa/lib $X_LIBS"
fi
+
if test -d /opt/xpm/lib/X11 ; then
X_CFLAGS="-I/opt/xpm/include $X_CFLAGS"
X_LIBS="-L/opt/xpm/lib/X11 $X_LIBS"
###############################################################################
have_xf86gamma=no
+have_xf86gamma_ramp=no
with_xf86gamma_req=unspecified
AC_ARG_WITH(xf86gamma-ext,
[ --with-xf86gamma-ext Include support for XFree86 gamma fading.],
[true], -lXext -lX11)
fi
- # pull in the lib, if we haven't already
- if test "$have_xf86gamma" = yes -a "$have_xf86vmode" = no; then
- SAVER_LIBS="$SAVER_LIBS -lXxf86vm"
+ # check for the Ramp versions of the functions too.
+ if test "$have_xf86gamma" = yes; then
+ have_xf86gamma_ramp=no
+ AC_CHECK_X_LIB(Xxf86vm, XF86VidModeSetGammaRamp,
+ [have_xf86gamma_ramp=yes],
+ [true], -lXext -lX11)
fi
- # if that succeeded, then we've really got it.
+ # if those tests succeeded, then we've really got the functions.
if test "$have_xf86gamma" = yes; then
AC_DEFINE(HAVE_XF86VMODE_GAMMA)
fi
+ if test "$have_xf86gamma_ramp" = yes; then
+ AC_DEFINE(HAVE_XF86VMODE_GAMMA_RAMP)
+ fi
+
+ # pull in the lib, if we haven't already
+ if test "$have_xf86gamma" = yes -a "$have_xf86vmode" = no; then
+ SAVER_LIBS="$SAVER_LIBS -lXxf86vm"
+ fi
+
elif test "$with_xf86gamma" != no; then
echo "error: must be yes or no: --with-xf86gamma-ext=$with_xf86vmode"
exit 1
# Check for Gnome Capplet support.
#
if test "$have_gnome" = yes -a "$have_gtk" = yes; then
- gnome_config_libs="capplet gnomeui"
+ gnome_config_libs="gtk capplet gnomeui"
AC_MSG_CHECKING(for Gnome capplet includes)
AC_CACHE_VAL(ac_cv_gnome_config_cflags,
[if ( $gnome_config --cflags $gnome_config_libs 2>&1 >/dev/null | \
xscreensaver.o: ../config.h
xscreensaver.o: $(srcdir)/xscreensaver.h
xscreensaver.o: $(srcdir)/prefs.h
+xscreensaver.o: $(UTILS_SRC)/version.h
+xscreensaver.o: $(UTILS_SRC)/yarandom.h
+xscreensaver.o: $(UTILS_SRC)/resources.h
+xscreensaver.o: $(UTILS_SRC)/visual.h
+xscreensaver.o: $(UTILS_SRC)/usleep.h
xscreensaver.o: XScreenSaver_ad.h
windows.o: ../config.h
windows.o: $(srcdir)/xscreensaver.h
windows.o: $(srcdir)/prefs.h
+windows.o: $(UTILS_SRC)/visual.h
+windows.o: $(UTILS_SRC)/fade.h
timers.o: ../config.h
timers.o: $(srcdir)/xscreensaver.h
timers.o: $(srcdir)/prefs.h
subprocs.o: ../config.h
subprocs.o: $(srcdir)/xscreensaver.h
subprocs.o: $(srcdir)/prefs.h
+subprocs.o: $(UTILS_SRC)/yarandom.h
+subprocs.o: $(UTILS_SRC)/visual.h
xset.o: ../config.h
xset.o: $(srcdir)/xscreensaver.h
xset.o: $(srcdir)/prefs.h
splash.o: ../config.h
splash.o: $(srcdir)/xscreensaver.h
splash.o: $(srcdir)/prefs.h
+splash.o: $(UTILS_SRC)/resources.h
setuid.o: ../config.h
setuid.o: $(srcdir)/xscreensaver.h
setuid.o: $(srcdir)/prefs.h
stderr.o: ../config.h
stderr.o: $(srcdir)/xscreensaver.h
stderr.o: $(srcdir)/prefs.h
+stderr.o: $(UTILS_SRC)/resources.h
+stderr.o: $(UTILS_SRC)/visual.h
demo-Xm.o: ../config.h
+demo-Xm.o: $(UTILS_SRC)/version.h
demo-Xm.o: $(srcdir)/prefs.h
+demo-Xm.o: $(UTILS_SRC)/resources.h
+demo-Xm.o: $(UTILS_SRC)/visual.h
demo-Xm.o: $(srcdir)/remote.h
+demo-Xm.o: $(UTILS_SRC)/usleep.h
demo-Xm.o: XScreenSaver_ad.h
demo-Xm-widgets.o: ../config.h
demo-Gtk.o: ../config.h
+demo-Gtk.o: $(UTILS_SRC)/version.h
demo-Gtk.o: $(srcdir)/prefs.h
+demo-Gtk.o: $(UTILS_SRC)/resources.h
+demo-Gtk.o: $(UTILS_SRC)/visual.h
demo-Gtk.o: $(srcdir)/remote.h
+demo-Gtk.o: $(UTILS_SRC)/usleep.h
+demo-Gtk.o: $(UTILS_SRC)/logo-50.xpm
+demo-Gtk.o: $(UTILS_SRC)/logo-180.xpm
demo-Gtk.o: $(srcdir)/demo-Gtk-widgets.h
demo-Gtk.o: XScreenSaver_ad.h
demo-Gtk-widgets.o: ../config.h
demo-Gtk-widgets.o: $(srcdir)/demo-Gtk-stubs.h
demo-Gtk-widgets.o: $(srcdir)/demo-Gtk-widgets.h
+xscreensaver-getimage.o: $(UTILS_SRC)/utils.h
xscreensaver-getimage.o: ../config.h
+xscreensaver-getimage.o: $(UTILS_SRC)/yarandom.h
+xscreensaver-getimage.o: $(UTILS_SRC)/grabscreen.h
+xscreensaver-getimage.o: $(UTILS_SRC)/resources.h
+xscreensaver-getimage.o: $(UTILS_SRC)/colorbars.h
xscreensaver-getimage.o: $(srcdir)/prefs.h
+xscreensaver-getimage.o: $(UTILS_SRC)/vroot.h
xscreensaver-getimage.o: XScreenSaver_ad.h
passwd-pwent.o: ../config.h
lock.o: ../config.h
lock.o: $(srcdir)/xscreensaver.h
lock.o: $(srcdir)/prefs.h
+lock.o: $(UTILS_SRC)/resources.h
passwd.o: ../config.h
prefs.o: ../config.h
prefs.o: $(srcdir)/prefs.h
+prefs.o: $(UTILS_SRC)/resources.h
dpms.o: ../config.h
dpms.o: $(srcdir)/xscreensaver.h
dpms.o: $(srcdir)/prefs.h
remote.o: $(srcdir)/remote.h
xscreensaver-command.o: ../config.h
xscreensaver-command.o: $(srcdir)/remote.h
+xscreensaver-command.o: $(UTILS_SRC)/version.h
test-passwd.o: ../config.h
test-passwd.o: $(srcdir)/xscreensaver.h
test-passwd.o: $(srcdir)/prefs.h
+test-passwd.o: $(UTILS_SRC)/resources.h
+test-passwd.o: $(UTILS_SRC)/version.h
+test-passwd.o: $(UTILS_SRC)/visual.h
test-passwd.o: XScreenSaver_ad.h
test-uid.o: ../config.h
test-xdpms.o: ../config.h
test-fade.o: ../config.h
test-fade.o: $(srcdir)/xscreensaver.h
test-fade.o: $(srcdir)/prefs.h
+test-fade.o: $(UTILS_SRC)/fade.h
! a screen saver and locker for the X window system
! by Jamie Zawinski
!
-! version 3.33
-! 03-Jun-2001
+! version 3.34
+! 25-Oct-2001
!
! See "man xscreensaver" for more info. The latest version is always
! available at http://www.jwz.org/xscreensaver/
*chooseRandomImages: False
*imageDirectory:
*nice: 10
-*memoryLimit: 50M
+*memoryLimit: 0
*lock: False
*lockVTs: True
*verbose: False
- "RotZoomer (mobile)" rotzoomer -root -move \n\
- "RotZoomer (sweep)" rotzoomer -root -sweep \n\
whirlwindwarp -root \n\
- "WhirlyGig" whirlygig -root -nlines 20 -whirlies 40 \
- -xspeed 0.5 \n\
+ "WhirlyGig" whirlygig -root \n\
"SpeedMine" speedmine -root \n\
"SpeedWorm" speedmine -root -worm \n\
+ vermiculate -root \n\
color: bubbles -root \n\
default-n: webcollage -root \n\
default-n: "WebCollage (whacked)" \
@GL_KLUDGE@ GL: "Molecule" molecule -root \n\
@GL_KLUDGE@ GL: "Molecule (lumpy)" molecule -root -no-bonds -no-labels \n\
@GL_KLUDGE@ GL: dangerball -root \n\
+@GL_KLUDGE@ GL: circuit -root \n\
\
- xdaliclock -root -builtin3 -cycle \n\
- default-n: xearth -nofork -nostars -ncolors 50 \
-night 3 -wait 0 -timewarp 400.0 -pos \
sunrel/38/-30 \n\
+- xplanetbg -xscreensaver -moonside \
+ -markerfile earth -wait 1 -timewarp 400 \n\
- ssystem -fullscreen :32 \n\
- xmountains -b -M -Z 0 -r 1 \n\
- "XMountains (top)" xmountains -b -M -Z 0 -r 1 -m \n\
-- xaos -root -autopilot -incoloring -1 \
- -nogui -outcoloring -1 \n\
+- xaos -fullscreen -autopilot \
+ -incoloring -1 -outcoloring -1 \n\
- xfishtank -d -s \n\
- xsnow \n\
- goban -root \n\
- electricsheep \n\
-- cosmos -root \n
+- cosmos -root \n\
+- GL: sphereEversion --root \n
! To display a randomized slideshow of images, you can do something like this:
Simulates speeding down a rocky mineshaft, or a funky dancing worm. \
Written by Conrad Parker.
+*hacks.circuit.documentation: \
+Animates a number of 3D electronic components. Written by Ben Buxton.
+
+*hacks.vermiculate.documentation: \
+Draws squiggly worm-like paths. Written by Tyler Pierce.
+
!=============================================================================
!
package, but if you don't have it already, you can find it at \
<http://www.cs.colorado.edu/~tuna/xearth/>.
+*hacks.xplanetbg.name: XPlanet
+*hacks.xplanetbg.documentation: \
+XPlanet is like XEarth, but with more options. It draws an image of \
+the Earth (or other planets!), as seen from your favorite vantage \
+point in space, correctly shaded for the current position of the Sun. \
+Written by Hari Nair. This is not included with the XScreenSaver \
+package, but if you don't have it already, you can find it at \
+<http://xplanet.sourceforge.net/>.
+
*hacks.ssystem.name: SSystem
*hacks.ssystem.documentation: \
SSystem is a GL Solar System simulator. It simulates flybys of Sun, \
Draws fireworks and zooming, fading flares. By Tom Campbell. \
You can find it at <http://www.mindspring.com/~campbell/cosmos/>.
+*hacks.sphereEversion.name: SphereEversion
+*hacks.sphereEversion.documentation: \
+SphereEversion draws an animation of a sphere being turned inside out. \
+A sphere can be turned inside out, without any tears, sharp creases or \
+discontinuities, if the surface of the sphere is allowed to intersect \
+itself. This program animates what is known as the Thurston Eversion. \
+Written by Nathaniel Thurston and Michael McGuffin. This program is \
+not included with the XScreenSaver package, but if you don't have it \
+already, you can find it at <http://www.dgp.utoronto.ca/~mjmcguff/eversion/>.
+
! (xrdb prevention kludge: whole file) */
"*chooseRandomImages: False",
"*imageDirectory: ",
"*nice: 10",
-"*memoryLimit: 50M",
+"*memoryLimit: 0",
"*lock: False",
"*lockVTs: True",
"*verbose: False",
- \"RotZoomer (mobile)\" rotzoomer -root -move \\n\
- \"RotZoomer (sweep)\" rotzoomer -root -sweep \\n\
whirlwindwarp -root \\n\
- \"WhirlyGig\" whirlygig -root -nlines 20 -whirlies 40 \
- -xspeed 0.5 \\n\
+ \"WhirlyGig\" whirlygig -root \\n\
\"SpeedMine\" speedmine -root \\n\
\"SpeedWorm\" speedmine -root -worm \\n\
+ vermiculate -root \\n\
color: bubbles -root \\n\
default-n: webcollage -root \\n\
default-n: \"WebCollage (whacked)\" \
GL: \"Molecule\" molecule -root \\n\
GL: \"Molecule (lumpy)\" molecule -root -no-bonds -no-labels \\n\
GL: dangerball -root \\n\
+ GL: circuit -root \\n\
\
- xdaliclock -root -builtin3 -cycle \\n\
- default-n: xearth -nofork -nostars -ncolors 50 \
-night 3 -wait 0 -timewarp 400.0 -pos \
sunrel/38/-30 \\n\
+- xplanetbg -xscreensaver -moonside \
+ -markerfile earth -wait 1 -timewarp 400 \\n\
- ssystem -fullscreen :32 \\n\
- xmountains -b -M -Z 0 -r 1 \\n\
- \"XMountains (top)\" xmountains -b -M -Z 0 -r 1 -m \\n\
-- xaos -root -autopilot -incoloring -1 \
- -nogui -outcoloring -1 \\n\
+- xaos -fullscreen -autopilot \
+ -incoloring -1 -outcoloring -1 \\n\
- xfishtank -d -s \\n\
- xsnow \\n\
- goban -root \\n\
- electricsheep \\n\
-- cosmos -root \\n",
+- cosmos -root \\n\
+- GL: sphereEversion --root \\n",
"XScreenSaver.pointerPollTime: 0:00:05",
"XScreenSaver.initialDelay: 0:00:00",
"XScreenSaver.windowCreationTimeout: 0:00:30",
"*hacks.speedmine.documentation: \
Simulates speeding down a rocky mineshaft, or a funky dancing worm. \
Written by Conrad Parker.",
+"*hacks.circuit.documentation: \
+Animates a number of 3D electronic components. Written by Ben Buxton.",
+"*hacks.vermiculate.documentation: \
+Draws squiggly worm-like paths. Written by Tyler Pierce.",
"*hacks.xdaliclock.name: XDaliClock",
"*hacks.xdaliclock.documentation: \
XDaliClock draws a large digital clock, the numbers of which change by \
Written by Kirk Johnson. This is not included with the XScreenSaver \
package, but if you don't have it already, you can find it at \
<http://www.cs.colorado.edu/~tuna/xearth/>.",
+"*hacks.xplanetbg.name: XPlanet",
+"*hacks.xplanetbg.documentation: \
+XPlanet is like XEarth, but with more options. It draws an image of \
+the Earth (or other planets!), as seen from your favorite vantage \
+point in space, correctly shaded for the current position of the Sun. \
+Written by Hari Nair. This is not included with the XScreenSaver \
+package, but if you don't have it already, you can find it at \
+<http://xplanet.sourceforge.net/>.",
"*hacks.ssystem.name: SSystem",
"*hacks.ssystem.documentation: \
SSystem is a GL Solar System simulator. It simulates flybys of Sun, \
"*hacks.cosmos.documentation: \
Draws fireworks and zooming, fading flares. By Tom Campbell. \
You can find it at <http://www.mindspring.com/~campbell/cosmos/>.",
+"*hacks.sphereEversion.name: SphereEversion",
+"*hacks.sphereEversion.documentation: \
+SphereEversion draws an animation of a sphere being turned inside out. \
+A sphere can be turned inside out, without any tears, sharp creases or \
+discontinuities, if the surface of the sphere is allowed to intersect \
+itself. This program animates what is known as the Thurston Eversion. \
+Written by Nathaniel Thurston and Michael McGuffin. This program is \
+not included with the XScreenSaver package, but if you don't have it \
+already, you can find it at <http://www.dgp.utoronto.ca/~mjmcguff/eversion/>.",
# include <capplet-widget.h>
#endif
-extern Display *gdk_display;
+#include <gdk/gdkx.h>
#include "version.h"
#include "prefs.h"
while (parent->parent)
parent = parent->parent;
+ if (!GTK_WIDGET (parent)->window) /* too early to pop up transient dialogs */
+ return;
+
head = msg;
while (head)
{
GTK_SIGNAL_FUNC (warning_dialog_dismiss_cb),
(gpointer) dialog);
}
+
gdk_window_set_transient_for (GTK_WIDGET (dialog)->window,
GTK_WIDGET (parent)->window);
int status;
apply_changes_and_save (widget);
- status = xscreensaver_command (gdk_display, command, arg, False, &err);
+ status = xscreensaver_command (GDK_DISPLAY(), command, arg, False, &err);
if (status < 0)
{
char buf [255];
else
{
char *s = 0;
- xscreensaver_command (gdk_display, XA_DEMO, which + 1, False, &s);
+ xscreensaver_command (GDK_DISPLAY(), XA_DEMO, which + 1, False, &s);
if (s) free (s);
}
}
run_cmd (GTK_WIDGET (widget), XA_RESTART, 0);
#else
apply_changes_and_save (GTK_WIDGET (widget));
- xscreensaver_command (gdk_display, XA_EXIT, 0, False, NULL);
+ xscreensaver_command (GDK_DISPLAY(), XA_EXIT, 0, False, NULL);
sleep (1);
system ("xscreensaver -nosplash &");
#endif
{
int countdown = 5;
- Display *dpy = gdk_display;
+ Display *dpy = GDK_DISPLAY();
/* GtkWidget *dialog = 0;*/
char *rversion = 0;
char b[255]; \
sprintf (b, "Error:\n\n" "Directory does not exist: \"%s\"\n", line); \
warning_dialog (GTK_WIDGET (button), b, False, 100); \
+ if ((field)) free ((field)); \
+ (field) = strdup(line); \
} \
else { \
if ((field)) free ((field)); \
if (changed)
{
- Display *dpy = gdk_display;
+ Display *dpy = GDK_DISPLAY();
sync_server_dpms_settings (dpy, p->dpms_enabled_p,
p->dpms_standby / 1000,
p->dpms_suspend / 1000,
int format;
unsigned long nitems, bytesafter;
CARD32 *data = 0;
- Display *dpy = gdk_display;
+ Display *dpy = GDK_DISPLAY();
int which = 0;
GtkList *list;
Bool found_any_writable_cells = False;
Bool dpms_supported = False;
- Display *dpy = gdk_display;
+ Display *dpy = GDK_DISPLAY();
int nscreens = ScreenCount(dpy);
int i;
for (i = 0; i < nscreens; i++)
static void
the_network_is_not_the_computer (GtkWidget *parent)
{
- Display *dpy = gdk_display;
+ Display *dpy = GDK_DISPLAY();
char *rversion, *ruser, *rhost;
char *luser, *lhost;
char *msg = 0;
*/
XtToolkitInitialize ();
app = XtCreateApplicationContext ();
- dpy = gdk_display;
+ dpy = GDK_DISPLAY();
XtAppSetFallbackResources (app, defaults);
XtDisplayInitialize (app, dpy, progname, progclass, 0, 0, &argc, argv);
toplevel_shell = XtAppCreateShell (progname, progclass,
# ifndef XmNtextField /* Lesstif 0.89.4 bug */
# undef HAVE_XMCOMBOBOX
# endif
+# if (XmVersion < 2001) /* Lesstif has two personalities these days */
+# undef HAVE_XMCOMBOBOX
+# endif
#endif /* HAVE_XMCOMBOBOX */
#include "version.h"
#undef countof
#define countof(x) (sizeof((x))/sizeof(*(x)))
+/* Some time between Red Hat 4.2 and 7.0, the words were transposed
+ in the various PAM_x_CRED macro names. Yay!
+ */
+#ifndef PAM_REFRESH_CRED
+# define PAM_REFRESH_CRED PAM_CRED_REFRESH
+#endif
+
static int pam_conversation (int nmsgs,
const struct pam_message **msg,
struct pam_response **resp,
#include <stdio.h>
#include <ctype.h>
#include <string.h>
+#include <time.h>
#include <sys/stat.h>
#include <sys/time.h>
col = string_columns (h2, strlen (h2), 0);
if (wrap_p && col >= tab)
- {
- out = stab_to (out, col, 77);
- *out += strlen(out);
- }
+ out = stab_to (out, col, 77);
else
*out++ = ' ';
if (setrlimit (RLIMIT_AS, &r) != 0)
{
char buf [512];
- sprintf (buf, "%s: setrlimit(RLIMIT_AS, {%d, %d}) failed",
+ sprintf (buf, "%s: setrlimit(RLIMIT_AS, {%lu, %lu}) failed",
blurb(), r.rlim_cur, r.rlim_max);
perror (buf);
return;
/* Call this when user activity (or "simulated" activity) has been noticed.
*/
-static void
+void
reset_timers (saver_info *si)
{
saver_preferences *p = &si->prefs;
catch_signal (si, SIGQUIT, on_p);
catch_signal (si, SIGILL, on_p);
catch_signal (si, SIGTRAP, on_p);
+#ifdef SIGIOT
catch_signal (si, SIGIOT, on_p);
+#endif
catch_signal (si, SIGABRT, on_p);
#ifdef SIGEMT
catch_signal (si, SIGEMT, on_p);
.if n .sp 1
.if t .sp .5
..
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver-command - control a running xscreensaver process
.SH SYNOPSIS
.if n .sp 1
.if t .sp .5
..
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver-demo - interactively control the background xscreensaver daemon
.SH SYNOPSIS
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver-getimage-file - put a randomly-selected image on the root window
.SH SYNOPSIS
use strict;
my $progname = $0; $progname =~ s@.*/@@g;
-my $version = q{ $Revision: 1.4 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
+my $version = q{ $Revision: 1.5 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
my $verbose = 0;
my $tmpdir = $ENV{TMPDIR};
$tmpdir = "/tmp" unless $tmpdir;
-my $tmpfile = "$tmpdir/xssgv.$$";
+my $tmpfile = "$tmpdir/xssgv.$$.ppm";
# this crap is because "vidtomem" can only write to a file, and uses
# a stupid, non-overridable file name format.
"bttvgrab -d q -Q -l 1 -o jpg -f $tmpfile", # BTTV
"qcam > $tmpfile", # Connectix Qcam
- "streamer -o $tmpfile", # XawTV
+ "streamer -s 768x576 -o $tmpfile", # XawTV
"atitv snap $tmpfile", # ATI video capture card
"vidtomem -f $tmpfile 2>- && mv $sgi_bogosity $tmpfile", # Silicon Graphics
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver-getimage-video - put a video frame on the root window
.SH SYNOPSIS
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver-getimage - put some randomly-selected image on the root window
.SH SYNOPSIS
return True;
}
}
- clientmessage_response(si, window, True,
- "ClientMessage DEACTIVATE received while inactive.",
- "not active.");
+ clientmessage_response(si, window, False,
+ "ClientMessage DEACTIVATE received while inactive: resetting idle timer.",
+ "not active: idle timer reset.");
+ reset_timers (si);
}
else if (type == XA_CYCLE)
{
extern void reset_watchdog_timer (saver_info *si, Bool on_p);
extern void idle_timer (XtPointer si, XtIntervalId *id);
extern void sleep_until_idle (saver_info *si, Bool until_idle_p);
+extern void reset_timers (saver_info *si);
/* =======================================================================
remote control
.if n .sp 1
.if t .sp .5
..
-.TH XScreenSaver 1 "03-Jun-2001 (3.33)" "X Version 11"
+.TH XScreenSaver 1 "25-Oct-2001 (3.34)" "X Version 11"
.SH NAME
xscreensaver - graphics hack and screen locker, launched when the user is idle
.SH SYNOPSIS
.EX
xscreensaver &
.EE
+And make sure the sessionetc file is executable.
This will cause \fIxscreensaver\fP to be launched when you log in.
(As always, make sure that xscreensaver and the graphics demos are on
your \fB$PATH\fP; the path needs to be set in \fI.cshrc\fP
phosphor.c xmatrix.c petri.c shadebobs.c xsublim.c ccurve.c \
blaster.c bumps.c ripples.c xteevee.c xspirograph.c \
nerverot.c xrayswarm.c hyperball.c zoom.c whirlwindwarp.c \
- rotzoomer.c whirlygig.c speedmine.c
+ rotzoomer.c whirlygig.c speedmine.c vermiculate.c
SCRIPTS = vidwhacker webcollage
OBJS = attraction.o blitspin.o bouboule.o braid.o bubbles.o \
phosphor.o xmatrix.o petri.o shadebobs.o xsublim.o ccurve.o \
blaster.o bumps.o ripples.o xteevee.o xspirograph.o \
nerverot.o xrayswarm.o hyperball.o zoom.o whirlwindwarp.o \
- rotzoomer.o whirlygig.o speedmine.o
+ rotzoomer.o whirlygig.o speedmine.o vermiculate.o
NEXES = attraction blitspin bouboule braid bubbles decayscreen deco \
drift flag flame forest vines galaxy grav greynetic halo \
wander spotlight critical phosphor xmatrix petri shadebobs \
xsublim ccurve blaster bumps ripples xteevee xspirograph \
nerverot xrayswarm hyperball zoom whirlwindwarp rotzoomer \
- whirlygig speedmine
+ whirlygig speedmine vermiculate
SEXES = sonar
EXES = $(NEXES) $(SEXES)
vidwhacker.man webcollage.man xsublim.man distort.man \
phosphor.man xmatrix.man xteevee.man xflame.man petri.man \
nerverot.man zoom.man whirlwindwarp.man hyperball.man \
- rotzoomer.man whirlygig.man speedmine.man
+ rotzoomer.man whirlygig.man speedmine.man penetrate.man
STAR = *
EXTRAS = README Makefile.in xlock_23.h .gdbinit \
images/$(STAR).xbm \
speedmine: speedmine.o $(HACK_OBJS) $(COL)
$(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(COL) $(HACK_LIBS)
+vermiculate: vermiculate.o $(HACK_OBJS) $(COL)
+ $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(COL) $(HACK_LIBS)
+
# The rules for those hacks which follow the `xlockmore' API.
#
attraction.o: $(srcdir)/screenhack.h
attraction.o: ../config.h
+attraction.o: $(UTILS_SRC)/yarandom.h
+attraction.o: $(UTILS_SRC)/usleep.h
+attraction.o: $(UTILS_SRC)/resources.h
+attraction.o: $(UTILS_SRC)/hsv.h
+attraction.o: $(UTILS_SRC)/colors.h
+attraction.o: $(UTILS_SRC)/grabscreen.h
+attraction.o: $(UTILS_SRC)/visual.h
+attraction.o: $(UTILS_SRC)/spline.h
blitspin.o: $(srcdir)/screenhack.h
blitspin.o: ../config.h
+blitspin.o: $(UTILS_SRC)/yarandom.h
+blitspin.o: $(UTILS_SRC)/usleep.h
+blitspin.o: $(UTILS_SRC)/resources.h
+blitspin.o: $(UTILS_SRC)/hsv.h
+blitspin.o: $(UTILS_SRC)/colors.h
+blitspin.o: $(UTILS_SRC)/grabscreen.h
+blitspin.o: $(UTILS_SRC)/visual.h
blitspin.o: $(srcdir)/images/som.xbm
bouboule.o: $(srcdir)/xlockmore.h
bouboule.o: ../config.h
bouboule.o: $(srcdir)/xlockmoreI.h
bouboule.o: $(srcdir)/screenhack.h
+bouboule.o: $(UTILS_SRC)/yarandom.h
+bouboule.o: $(UTILS_SRC)/usleep.h
+bouboule.o: $(UTILS_SRC)/resources.h
+bouboule.o: $(UTILS_SRC)/hsv.h
+bouboule.o: $(UTILS_SRC)/colors.h
+bouboule.o: $(UTILS_SRC)/grabscreen.h
+bouboule.o: $(UTILS_SRC)/visual.h
+bouboule.o: $(UTILS_SRC)/xshm.h
braid.o: $(srcdir)/xlockmore.h
braid.o: ../config.h
braid.o: $(srcdir)/xlockmoreI.h
braid.o: $(srcdir)/screenhack.h
+braid.o: $(UTILS_SRC)/yarandom.h
+braid.o: $(UTILS_SRC)/usleep.h
+braid.o: $(UTILS_SRC)/resources.h
+braid.o: $(UTILS_SRC)/hsv.h
+braid.o: $(UTILS_SRC)/colors.h
+braid.o: $(UTILS_SRC)/grabscreen.h
+braid.o: $(UTILS_SRC)/visual.h
+braid.o: $(UTILS_SRC)/xshm.h
+braid.o: $(UTILS_SRC)/erase.h
bubbles.o: $(srcdir)/screenhack.h
bubbles.o: ../config.h
+bubbles.o: $(UTILS_SRC)/yarandom.h
+bubbles.o: $(UTILS_SRC)/usleep.h
+bubbles.o: $(UTILS_SRC)/resources.h
+bubbles.o: $(UTILS_SRC)/hsv.h
+bubbles.o: $(UTILS_SRC)/colors.h
+bubbles.o: $(UTILS_SRC)/grabscreen.h
+bubbles.o: $(UTILS_SRC)/visual.h
bubbles.o: $(srcdir)/bubbles.h
bubbles-default.o: ../config.h
bubbles-default.o: $(srcdir)/bubbles.h
+bubbles-default.o: $(UTILS_SRC)/yarandom.h
bubbles-default.o: $(srcdir)/images/bubbles/blood1.xpm
bubbles-default.o: $(srcdir)/images/bubbles/blood2.xpm
bubbles-default.o: $(srcdir)/images/bubbles/blood3.xpm
bubbles-default.o: $(srcdir)/images/bubbles/jade11.xpm
decayscreen.o: $(srcdir)/screenhack.h
decayscreen.o: ../config.h
+decayscreen.o: $(UTILS_SRC)/yarandom.h
+decayscreen.o: $(UTILS_SRC)/usleep.h
+decayscreen.o: $(UTILS_SRC)/resources.h
+decayscreen.o: $(UTILS_SRC)/hsv.h
+decayscreen.o: $(UTILS_SRC)/colors.h
+decayscreen.o: $(UTILS_SRC)/grabscreen.h
+decayscreen.o: $(UTILS_SRC)/visual.h
deco.o: $(srcdir)/screenhack.h
deco.o: ../config.h
+deco.o: $(UTILS_SRC)/yarandom.h
+deco.o: $(UTILS_SRC)/usleep.h
+deco.o: $(UTILS_SRC)/resources.h
+deco.o: $(UTILS_SRC)/hsv.h
+deco.o: $(UTILS_SRC)/colors.h
+deco.o: $(UTILS_SRC)/grabscreen.h
+deco.o: $(UTILS_SRC)/visual.h
drift.o: $(srcdir)/xlockmore.h
drift.o: ../config.h
drift.o: $(srcdir)/xlockmoreI.h
drift.o: $(srcdir)/screenhack.h
+drift.o: $(UTILS_SRC)/yarandom.h
+drift.o: $(UTILS_SRC)/usleep.h
+drift.o: $(UTILS_SRC)/resources.h
+drift.o: $(UTILS_SRC)/hsv.h
+drift.o: $(UTILS_SRC)/colors.h
+drift.o: $(UTILS_SRC)/grabscreen.h
+drift.o: $(UTILS_SRC)/visual.h
+drift.o: $(UTILS_SRC)/xshm.h
+drift.o: $(UTILS_SRC)/erase.h
flag.o: $(srcdir)/xlockmore.h
flag.o: ../config.h
flag.o: $(srcdir)/xlockmoreI.h
flag.o: $(srcdir)/screenhack.h
+flag.o: $(UTILS_SRC)/yarandom.h
+flag.o: $(UTILS_SRC)/usleep.h
+flag.o: $(UTILS_SRC)/resources.h
+flag.o: $(UTILS_SRC)/hsv.h
+flag.o: $(UTILS_SRC)/colors.h
+flag.o: $(UTILS_SRC)/grabscreen.h
+flag.o: $(UTILS_SRC)/visual.h
+flag.o: $(UTILS_SRC)/xshm.h
flag.o: $(srcdir)/images/bob.xbm
flame.o: $(srcdir)/screenhack.h
flame.o: ../config.h
+flame.o: $(UTILS_SRC)/yarandom.h
+flame.o: $(UTILS_SRC)/usleep.h
+flame.o: $(UTILS_SRC)/resources.h
+flame.o: $(UTILS_SRC)/hsv.h
+flame.o: $(UTILS_SRC)/colors.h
+flame.o: $(UTILS_SRC)/grabscreen.h
+flame.o: $(UTILS_SRC)/visual.h
forest.o: ../config.h
forest.o: $(srcdir)/xlockmore.h
forest.o: $(srcdir)/xlockmoreI.h
forest.o: $(srcdir)/screenhack.h
+forest.o: $(UTILS_SRC)/yarandom.h
+forest.o: $(UTILS_SRC)/usleep.h
+forest.o: $(UTILS_SRC)/resources.h
+forest.o: $(UTILS_SRC)/hsv.h
+forest.o: $(UTILS_SRC)/colors.h
+forest.o: $(UTILS_SRC)/grabscreen.h
+forest.o: $(UTILS_SRC)/visual.h
+forest.o: $(UTILS_SRC)/xshm.h
vines.o: $(srcdir)/xlockmore.h
vines.o: ../config.h
vines.o: $(srcdir)/xlockmoreI.h
vines.o: $(srcdir)/screenhack.h
+vines.o: $(UTILS_SRC)/yarandom.h
+vines.o: $(UTILS_SRC)/usleep.h
+vines.o: $(UTILS_SRC)/resources.h
+vines.o: $(UTILS_SRC)/hsv.h
+vines.o: $(UTILS_SRC)/colors.h
+vines.o: $(UTILS_SRC)/grabscreen.h
+vines.o: $(UTILS_SRC)/visual.h
+vines.o: $(UTILS_SRC)/xshm.h
+vines.o: $(UTILS_SRC)/erase.h
galaxy.o: $(srcdir)/xlockmore.h
galaxy.o: ../config.h
galaxy.o: $(srcdir)/xlockmoreI.h
galaxy.o: $(srcdir)/screenhack.h
+galaxy.o: $(UTILS_SRC)/yarandom.h
+galaxy.o: $(UTILS_SRC)/usleep.h
+galaxy.o: $(UTILS_SRC)/resources.h
+galaxy.o: $(UTILS_SRC)/hsv.h
+galaxy.o: $(UTILS_SRC)/colors.h
+galaxy.o: $(UTILS_SRC)/grabscreen.h
+galaxy.o: $(UTILS_SRC)/visual.h
+galaxy.o: $(UTILS_SRC)/xshm.h
grav.o: $(srcdir)/xlockmore.h
grav.o: ../config.h
grav.o: $(srcdir)/xlockmoreI.h
grav.o: $(srcdir)/screenhack.h
+grav.o: $(UTILS_SRC)/yarandom.h
+grav.o: $(UTILS_SRC)/usleep.h
+grav.o: $(UTILS_SRC)/resources.h
+grav.o: $(UTILS_SRC)/hsv.h
+grav.o: $(UTILS_SRC)/colors.h
+grav.o: $(UTILS_SRC)/grabscreen.h
+grav.o: $(UTILS_SRC)/visual.h
+grav.o: $(UTILS_SRC)/xshm.h
greynetic.o: $(srcdir)/screenhack.h
greynetic.o: ../config.h
+greynetic.o: $(UTILS_SRC)/yarandom.h
+greynetic.o: $(UTILS_SRC)/usleep.h
+greynetic.o: $(UTILS_SRC)/resources.h
+greynetic.o: $(UTILS_SRC)/hsv.h
+greynetic.o: $(UTILS_SRC)/colors.h
+greynetic.o: $(UTILS_SRC)/grabscreen.h
+greynetic.o: $(UTILS_SRC)/visual.h
halo.o: $(srcdir)/screenhack.h
halo.o: ../config.h
+halo.o: $(UTILS_SRC)/yarandom.h
+halo.o: $(UTILS_SRC)/usleep.h
+halo.o: $(UTILS_SRC)/resources.h
+halo.o: $(UTILS_SRC)/hsv.h
+halo.o: $(UTILS_SRC)/colors.h
+halo.o: $(UTILS_SRC)/grabscreen.h
+halo.o: $(UTILS_SRC)/visual.h
helix.o: $(srcdir)/screenhack.h
helix.o: ../config.h
+helix.o: $(UTILS_SRC)/yarandom.h
+helix.o: $(UTILS_SRC)/usleep.h
+helix.o: $(UTILS_SRC)/resources.h
+helix.o: $(UTILS_SRC)/hsv.h
+helix.o: $(UTILS_SRC)/colors.h
+helix.o: $(UTILS_SRC)/grabscreen.h
+helix.o: $(UTILS_SRC)/visual.h
+helix.o: $(UTILS_SRC)/erase.h
hopalong.o: $(srcdir)/xlockmore.h
hopalong.o: ../config.h
hopalong.o: $(srcdir)/xlockmoreI.h
hopalong.o: $(srcdir)/screenhack.h
+hopalong.o: $(UTILS_SRC)/yarandom.h
+hopalong.o: $(UTILS_SRC)/usleep.h
+hopalong.o: $(UTILS_SRC)/resources.h
+hopalong.o: $(UTILS_SRC)/hsv.h
+hopalong.o: $(UTILS_SRC)/colors.h
+hopalong.o: $(UTILS_SRC)/grabscreen.h
+hopalong.o: $(UTILS_SRC)/visual.h
+hopalong.o: $(UTILS_SRC)/xshm.h
+hopalong.o: $(UTILS_SRC)/erase.h
hypercube.o: $(srcdir)/screenhack.h
hypercube.o: ../config.h
+hypercube.o: $(UTILS_SRC)/yarandom.h
+hypercube.o: $(UTILS_SRC)/usleep.h
+hypercube.o: $(UTILS_SRC)/resources.h
+hypercube.o: $(UTILS_SRC)/hsv.h
+hypercube.o: $(UTILS_SRC)/colors.h
+hypercube.o: $(UTILS_SRC)/grabscreen.h
+hypercube.o: $(UTILS_SRC)/visual.h
ifs.o: $(srcdir)/xlockmore.h
ifs.o: ../config.h
ifs.o: $(srcdir)/xlockmoreI.h
ifs.o: $(srcdir)/screenhack.h
+ifs.o: $(UTILS_SRC)/yarandom.h
+ifs.o: $(UTILS_SRC)/usleep.h
+ifs.o: $(UTILS_SRC)/resources.h
+ifs.o: $(UTILS_SRC)/hsv.h
+ifs.o: $(UTILS_SRC)/colors.h
+ifs.o: $(UTILS_SRC)/grabscreen.h
+ifs.o: $(UTILS_SRC)/visual.h
+ifs.o: $(UTILS_SRC)/xshm.h
imsmap.o: $(srcdir)/screenhack.h
imsmap.o: ../config.h
+imsmap.o: $(UTILS_SRC)/yarandom.h
+imsmap.o: $(UTILS_SRC)/usleep.h
+imsmap.o: $(UTILS_SRC)/resources.h
+imsmap.o: $(UTILS_SRC)/hsv.h
+imsmap.o: $(UTILS_SRC)/colors.h
+imsmap.o: $(UTILS_SRC)/grabscreen.h
+imsmap.o: $(UTILS_SRC)/visual.h
julia.o: $(srcdir)/xlockmore.h
julia.o: ../config.h
julia.o: $(srcdir)/xlockmoreI.h
julia.o: $(srcdir)/screenhack.h
+julia.o: $(UTILS_SRC)/yarandom.h
+julia.o: $(UTILS_SRC)/usleep.h
+julia.o: $(UTILS_SRC)/resources.h
+julia.o: $(UTILS_SRC)/hsv.h
+julia.o: $(UTILS_SRC)/colors.h
+julia.o: $(UTILS_SRC)/grabscreen.h
+julia.o: $(UTILS_SRC)/visual.h
+julia.o: $(UTILS_SRC)/xshm.h
+kaleidescope.o: $(UTILS_SRC)/spline.h
kaleidescope.o: $(srcdir)/screenhack.h
kaleidescope.o: ../config.h
+kaleidescope.o: $(UTILS_SRC)/yarandom.h
+kaleidescope.o: $(UTILS_SRC)/usleep.h
+kaleidescope.o: $(UTILS_SRC)/resources.h
+kaleidescope.o: $(UTILS_SRC)/hsv.h
+kaleidescope.o: $(UTILS_SRC)/colors.h
+kaleidescope.o: $(UTILS_SRC)/grabscreen.h
+kaleidescope.o: $(UTILS_SRC)/visual.h
laser.o: $(srcdir)/xlockmore.h
laser.o: ../config.h
laser.o: $(srcdir)/xlockmoreI.h
laser.o: $(srcdir)/screenhack.h
+laser.o: $(UTILS_SRC)/yarandom.h
+laser.o: $(UTILS_SRC)/usleep.h
+laser.o: $(UTILS_SRC)/resources.h
+laser.o: $(UTILS_SRC)/hsv.h
+laser.o: $(UTILS_SRC)/colors.h
+laser.o: $(UTILS_SRC)/grabscreen.h
+laser.o: $(UTILS_SRC)/visual.h
+laser.o: $(UTILS_SRC)/xshm.h
lightning.o: $(srcdir)/xlockmore.h
lightning.o: ../config.h
lightning.o: $(srcdir)/xlockmoreI.h
lightning.o: $(srcdir)/screenhack.h
+lightning.o: $(UTILS_SRC)/yarandom.h
+lightning.o: $(UTILS_SRC)/usleep.h
+lightning.o: $(UTILS_SRC)/resources.h
+lightning.o: $(UTILS_SRC)/hsv.h
+lightning.o: $(UTILS_SRC)/colors.h
+lightning.o: $(UTILS_SRC)/grabscreen.h
+lightning.o: $(UTILS_SRC)/visual.h
+lightning.o: $(UTILS_SRC)/xshm.h
lisa.o: $(srcdir)/xlockmore.h
lisa.o: ../config.h
lisa.o: $(srcdir)/xlockmoreI.h
lisa.o: $(srcdir)/screenhack.h
+lisa.o: $(UTILS_SRC)/yarandom.h
+lisa.o: $(UTILS_SRC)/usleep.h
+lisa.o: $(UTILS_SRC)/resources.h
+lisa.o: $(UTILS_SRC)/hsv.h
+lisa.o: $(UTILS_SRC)/colors.h
+lisa.o: $(UTILS_SRC)/grabscreen.h
+lisa.o: $(UTILS_SRC)/visual.h
+lisa.o: $(UTILS_SRC)/xshm.h
lmorph.o: $(srcdir)/screenhack.h
lmorph.o: ../config.h
+lmorph.o: $(UTILS_SRC)/yarandom.h
+lmorph.o: $(UTILS_SRC)/usleep.h
+lmorph.o: $(UTILS_SRC)/resources.h
+lmorph.o: $(UTILS_SRC)/hsv.h
+lmorph.o: $(UTILS_SRC)/colors.h
+lmorph.o: $(UTILS_SRC)/grabscreen.h
+lmorph.o: $(UTILS_SRC)/visual.h
maze.o: $(srcdir)/screenhack.h
maze.o: ../config.h
+maze.o: $(UTILS_SRC)/yarandom.h
+maze.o: $(UTILS_SRC)/usleep.h
+maze.o: $(UTILS_SRC)/resources.h
+maze.o: $(UTILS_SRC)/hsv.h
+maze.o: $(UTILS_SRC)/colors.h
+maze.o: $(UTILS_SRC)/grabscreen.h
+maze.o: $(UTILS_SRC)/visual.h
+maze.o: $(UTILS_SRC)/erase.h
moire.o: $(srcdir)/screenhack.h
moire.o: ../config.h
+moire.o: $(UTILS_SRC)/yarandom.h
+moire.o: $(UTILS_SRC)/usleep.h
+moire.o: $(UTILS_SRC)/resources.h
+moire.o: $(UTILS_SRC)/hsv.h
+moire.o: $(UTILS_SRC)/colors.h
+moire.o: $(UTILS_SRC)/grabscreen.h
+moire.o: $(UTILS_SRC)/visual.h
+moire.o: $(UTILS_SRC)/xshm.h
noseguy.o: $(srcdir)/screenhack.h
noseguy.o: ../config.h
+noseguy.o: $(UTILS_SRC)/yarandom.h
+noseguy.o: $(UTILS_SRC)/usleep.h
+noseguy.o: $(UTILS_SRC)/resources.h
+noseguy.o: $(UTILS_SRC)/hsv.h
+noseguy.o: $(UTILS_SRC)/colors.h
+noseguy.o: $(UTILS_SRC)/grabscreen.h
+noseguy.o: $(UTILS_SRC)/visual.h
noseguy.o: $(srcdir)/images/noseguy/nose-f1.xpm
noseguy.o: $(srcdir)/images/noseguy/nose-f2.xpm
noseguy.o: $(srcdir)/images/noseguy/nose-f3.xpm
noseguy.o: $(srcdir)/images/noseguy/nose-r2.xpm
pedal.o: $(srcdir)/screenhack.h
pedal.o: ../config.h
+pedal.o: $(UTILS_SRC)/yarandom.h
+pedal.o: $(UTILS_SRC)/usleep.h
+pedal.o: $(UTILS_SRC)/resources.h
+pedal.o: $(UTILS_SRC)/hsv.h
+pedal.o: $(UTILS_SRC)/colors.h
+pedal.o: $(UTILS_SRC)/grabscreen.h
+pedal.o: $(UTILS_SRC)/visual.h
penrose.o: $(srcdir)/xlockmore.h
penrose.o: ../config.h
penrose.o: $(srcdir)/xlockmoreI.h
penrose.o: $(srcdir)/screenhack.h
+penrose.o: $(UTILS_SRC)/yarandom.h
+penrose.o: $(UTILS_SRC)/usleep.h
+penrose.o: $(UTILS_SRC)/resources.h
+penrose.o: $(UTILS_SRC)/hsv.h
+penrose.o: $(UTILS_SRC)/colors.h
+penrose.o: $(UTILS_SRC)/grabscreen.h
+penrose.o: $(UTILS_SRC)/visual.h
+penrose.o: $(UTILS_SRC)/xshm.h
pyro.o: $(srcdir)/screenhack.h
pyro.o: ../config.h
+pyro.o: $(UTILS_SRC)/yarandom.h
+pyro.o: $(UTILS_SRC)/usleep.h
+pyro.o: $(UTILS_SRC)/resources.h
+pyro.o: $(UTILS_SRC)/hsv.h
+pyro.o: $(UTILS_SRC)/colors.h
+pyro.o: $(UTILS_SRC)/grabscreen.h
+pyro.o: $(UTILS_SRC)/visual.h
qix.o: $(srcdir)/screenhack.h
qix.o: ../config.h
+qix.o: $(UTILS_SRC)/yarandom.h
+qix.o: $(UTILS_SRC)/usleep.h
+qix.o: $(UTILS_SRC)/resources.h
+qix.o: $(UTILS_SRC)/hsv.h
+qix.o: $(UTILS_SRC)/colors.h
+qix.o: $(UTILS_SRC)/grabscreen.h
+qix.o: $(UTILS_SRC)/visual.h
+qix.o: $(UTILS_SRC)/alpha.h
rocks.o: $(srcdir)/screenhack.h
rocks.o: ../config.h
+rocks.o: $(UTILS_SRC)/yarandom.h
+rocks.o: $(UTILS_SRC)/usleep.h
+rocks.o: $(UTILS_SRC)/resources.h
+rocks.o: $(UTILS_SRC)/hsv.h
+rocks.o: $(UTILS_SRC)/colors.h
+rocks.o: $(UTILS_SRC)/grabscreen.h
+rocks.o: $(UTILS_SRC)/visual.h
rorschach.o: $(srcdir)/screenhack.h
rorschach.o: ../config.h
+rorschach.o: $(UTILS_SRC)/yarandom.h
+rorschach.o: $(UTILS_SRC)/usleep.h
+rorschach.o: $(UTILS_SRC)/resources.h
+rorschach.o: $(UTILS_SRC)/hsv.h
+rorschach.o: $(UTILS_SRC)/colors.h
+rorschach.o: $(UTILS_SRC)/grabscreen.h
+rorschach.o: $(UTILS_SRC)/visual.h
+rorschach.o: $(UTILS_SRC)/erase.h
+screenhack.o: $(UTILS_SRC)/xmu.h
screenhack.o: $(srcdir)/screenhack.h
screenhack.o: ../config.h
+screenhack.o: $(UTILS_SRC)/yarandom.h
+screenhack.o: $(UTILS_SRC)/usleep.h
+screenhack.o: $(UTILS_SRC)/resources.h
+screenhack.o: $(UTILS_SRC)/hsv.h
+screenhack.o: $(UTILS_SRC)/colors.h
+screenhack.o: $(UTILS_SRC)/grabscreen.h
+screenhack.o: $(UTILS_SRC)/visual.h
+screenhack.o: $(UTILS_SRC)/version.h
+screenhack.o: $(UTILS_SRC)/vroot.h
sierpinski.o: $(srcdir)/xlockmore.h
sierpinski.o: ../config.h
sierpinski.o: $(srcdir)/xlockmoreI.h
sierpinski.o: $(srcdir)/screenhack.h
+sierpinski.o: $(UTILS_SRC)/yarandom.h
+sierpinski.o: $(UTILS_SRC)/usleep.h
+sierpinski.o: $(UTILS_SRC)/resources.h
+sierpinski.o: $(UTILS_SRC)/hsv.h
+sierpinski.o: $(UTILS_SRC)/colors.h
+sierpinski.o: $(UTILS_SRC)/grabscreen.h
+sierpinski.o: $(UTILS_SRC)/visual.h
+sierpinski.o: $(UTILS_SRC)/xshm.h
slidescreen.o: $(srcdir)/screenhack.h
slidescreen.o: ../config.h
+slidescreen.o: $(UTILS_SRC)/yarandom.h
+slidescreen.o: $(UTILS_SRC)/usleep.h
+slidescreen.o: $(UTILS_SRC)/resources.h
+slidescreen.o: $(UTILS_SRC)/hsv.h
+slidescreen.o: $(UTILS_SRC)/colors.h
+slidescreen.o: $(UTILS_SRC)/grabscreen.h
+slidescreen.o: $(UTILS_SRC)/visual.h
slip.o: $(srcdir)/xlockmore.h
slip.o: ../config.h
slip.o: $(srcdir)/xlockmoreI.h
slip.o: $(srcdir)/screenhack.h
+slip.o: $(UTILS_SRC)/yarandom.h
+slip.o: $(UTILS_SRC)/usleep.h
+slip.o: $(UTILS_SRC)/resources.h
+slip.o: $(UTILS_SRC)/hsv.h
+slip.o: $(UTILS_SRC)/colors.h
+slip.o: $(UTILS_SRC)/grabscreen.h
+slip.o: $(UTILS_SRC)/visual.h
+slip.o: $(UTILS_SRC)/xshm.h
sphere.o: $(srcdir)/xlockmore.h
sphere.o: ../config.h
sphere.o: $(srcdir)/xlockmoreI.h
sphere.o: $(srcdir)/screenhack.h
+sphere.o: $(UTILS_SRC)/yarandom.h
+sphere.o: $(UTILS_SRC)/usleep.h
+sphere.o: $(UTILS_SRC)/resources.h
+sphere.o: $(UTILS_SRC)/hsv.h
+sphere.o: $(UTILS_SRC)/colors.h
+sphere.o: $(UTILS_SRC)/grabscreen.h
+sphere.o: $(UTILS_SRC)/visual.h
+sphere.o: $(UTILS_SRC)/xshm.h
spiral.o: $(srcdir)/xlockmore.h
spiral.o: ../config.h
spiral.o: $(srcdir)/xlockmoreI.h
spiral.o: $(srcdir)/screenhack.h
+spiral.o: $(UTILS_SRC)/yarandom.h
+spiral.o: $(UTILS_SRC)/usleep.h
+spiral.o: $(UTILS_SRC)/resources.h
+spiral.o: $(UTILS_SRC)/hsv.h
+spiral.o: $(UTILS_SRC)/colors.h
+spiral.o: $(UTILS_SRC)/grabscreen.h
+spiral.o: $(UTILS_SRC)/visual.h
+spiral.o: $(UTILS_SRC)/xshm.h
strange.o: $(srcdir)/xlockmore.h
strange.o: ../config.h
strange.o: $(srcdir)/xlockmoreI.h
strange.o: $(srcdir)/screenhack.h
+strange.o: $(UTILS_SRC)/yarandom.h
+strange.o: $(UTILS_SRC)/usleep.h
+strange.o: $(UTILS_SRC)/resources.h
+strange.o: $(UTILS_SRC)/hsv.h
+strange.o: $(UTILS_SRC)/colors.h
+strange.o: $(UTILS_SRC)/grabscreen.h
+strange.o: $(UTILS_SRC)/visual.h
+strange.o: $(UTILS_SRC)/xshm.h
swirl.o: $(srcdir)/xlockmore.h
swirl.o: ../config.h
swirl.o: $(srcdir)/xlockmoreI.h
swirl.o: $(srcdir)/screenhack.h
+swirl.o: $(UTILS_SRC)/yarandom.h
+swirl.o: $(UTILS_SRC)/usleep.h
+swirl.o: $(UTILS_SRC)/resources.h
+swirl.o: $(UTILS_SRC)/hsv.h
+swirl.o: $(UTILS_SRC)/colors.h
+swirl.o: $(UTILS_SRC)/grabscreen.h
+swirl.o: $(UTILS_SRC)/visual.h
+swirl.o: $(UTILS_SRC)/xshm.h
xlockmore.o: $(srcdir)/screenhack.h
xlockmore.o: ../config.h
+xlockmore.o: $(UTILS_SRC)/yarandom.h
+xlockmore.o: $(UTILS_SRC)/usleep.h
+xlockmore.o: $(UTILS_SRC)/resources.h
+xlockmore.o: $(UTILS_SRC)/hsv.h
+xlockmore.o: $(UTILS_SRC)/colors.h
+xlockmore.o: $(UTILS_SRC)/grabscreen.h
+xlockmore.o: $(UTILS_SRC)/visual.h
xlockmore.o: $(srcdir)/xlockmoreI.h
+xlockmore.o: $(UTILS_SRC)/xshm.h
goop.o: $(srcdir)/screenhack.h
goop.o: ../config.h
+goop.o: $(UTILS_SRC)/yarandom.h
+goop.o: $(UTILS_SRC)/usleep.h
+goop.o: $(UTILS_SRC)/resources.h
+goop.o: $(UTILS_SRC)/hsv.h
+goop.o: $(UTILS_SRC)/colors.h
+goop.o: $(UTILS_SRC)/grabscreen.h
+goop.o: $(UTILS_SRC)/visual.h
+goop.o: $(UTILS_SRC)/spline.h
+goop.o: $(UTILS_SRC)/alpha.h
starfish.o: $(srcdir)/screenhack.h
starfish.o: ../config.h
+starfish.o: $(UTILS_SRC)/yarandom.h
+starfish.o: $(UTILS_SRC)/usleep.h
+starfish.o: $(UTILS_SRC)/resources.h
+starfish.o: $(UTILS_SRC)/hsv.h
+starfish.o: $(UTILS_SRC)/colors.h
+starfish.o: $(UTILS_SRC)/grabscreen.h
+starfish.o: $(UTILS_SRC)/visual.h
+starfish.o: $(UTILS_SRC)/spline.h
munch.o: $(srcdir)/screenhack.h
munch.o: ../config.h
+munch.o: $(UTILS_SRC)/yarandom.h
+munch.o: $(UTILS_SRC)/usleep.h
+munch.o: $(UTILS_SRC)/resources.h
+munch.o: $(UTILS_SRC)/hsv.h
+munch.o: $(UTILS_SRC)/colors.h
+munch.o: $(UTILS_SRC)/grabscreen.h
+munch.o: $(UTILS_SRC)/visual.h
fadeplot.o: $(srcdir)/xlockmore.h
fadeplot.o: ../config.h
fadeplot.o: $(srcdir)/xlockmoreI.h
fadeplot.o: $(srcdir)/screenhack.h
+fadeplot.o: $(UTILS_SRC)/yarandom.h
+fadeplot.o: $(UTILS_SRC)/usleep.h
+fadeplot.o: $(UTILS_SRC)/resources.h
+fadeplot.o: $(UTILS_SRC)/hsv.h
+fadeplot.o: $(UTILS_SRC)/colors.h
+fadeplot.o: $(UTILS_SRC)/grabscreen.h
+fadeplot.o: $(UTILS_SRC)/visual.h
+fadeplot.o: $(UTILS_SRC)/xshm.h
rd-bomb.o: $(srcdir)/screenhack.h
rd-bomb.o: ../config.h
+rd-bomb.o: $(UTILS_SRC)/yarandom.h
+rd-bomb.o: $(UTILS_SRC)/usleep.h
+rd-bomb.o: $(UTILS_SRC)/resources.h
+rd-bomb.o: $(UTILS_SRC)/hsv.h
+rd-bomb.o: $(UTILS_SRC)/colors.h
+rd-bomb.o: $(UTILS_SRC)/grabscreen.h
+rd-bomb.o: $(UTILS_SRC)/visual.h
+rd-bomb.o: $(UTILS_SRC)/xshm.h
coral.o: $(srcdir)/screenhack.h
coral.o: ../config.h
+coral.o: $(UTILS_SRC)/yarandom.h
+coral.o: $(UTILS_SRC)/usleep.h
+coral.o: $(UTILS_SRC)/resources.h
+coral.o: $(UTILS_SRC)/hsv.h
+coral.o: $(UTILS_SRC)/colors.h
+coral.o: $(UTILS_SRC)/grabscreen.h
+coral.o: $(UTILS_SRC)/visual.h
+coral.o: $(UTILS_SRC)/erase.h
mountain.o: $(srcdir)/xlockmore.h
mountain.o: ../config.h
mountain.o: $(srcdir)/xlockmoreI.h
mountain.o: $(srcdir)/screenhack.h
+mountain.o: $(UTILS_SRC)/yarandom.h
+mountain.o: $(UTILS_SRC)/usleep.h
+mountain.o: $(UTILS_SRC)/resources.h
+mountain.o: $(UTILS_SRC)/hsv.h
+mountain.o: $(UTILS_SRC)/colors.h
+mountain.o: $(UTILS_SRC)/grabscreen.h
+mountain.o: $(UTILS_SRC)/visual.h
+mountain.o: $(UTILS_SRC)/xshm.h
triangle.o: $(srcdir)/xlockmore.h
triangle.o: ../config.h
triangle.o: $(srcdir)/xlockmoreI.h
triangle.o: $(srcdir)/screenhack.h
+triangle.o: $(UTILS_SRC)/yarandom.h
+triangle.o: $(UTILS_SRC)/usleep.h
+triangle.o: $(UTILS_SRC)/resources.h
+triangle.o: $(UTILS_SRC)/hsv.h
+triangle.o: $(UTILS_SRC)/colors.h
+triangle.o: $(UTILS_SRC)/grabscreen.h
+triangle.o: $(UTILS_SRC)/visual.h
+triangle.o: $(UTILS_SRC)/xshm.h
lissie.o: $(srcdir)/xlockmore.h
lissie.o: ../config.h
lissie.o: $(srcdir)/xlockmoreI.h
lissie.o: $(srcdir)/screenhack.h
+lissie.o: $(UTILS_SRC)/yarandom.h
+lissie.o: $(UTILS_SRC)/usleep.h
+lissie.o: $(UTILS_SRC)/resources.h
+lissie.o: $(UTILS_SRC)/hsv.h
+lissie.o: $(UTILS_SRC)/colors.h
+lissie.o: $(UTILS_SRC)/grabscreen.h
+lissie.o: $(UTILS_SRC)/visual.h
+lissie.o: $(UTILS_SRC)/xshm.h
worm.o: $(srcdir)/xlockmore.h
worm.o: ../config.h
worm.o: $(srcdir)/xlockmoreI.h
worm.o: $(srcdir)/screenhack.h
+worm.o: $(UTILS_SRC)/yarandom.h
+worm.o: $(UTILS_SRC)/usleep.h
+worm.o: $(UTILS_SRC)/resources.h
+worm.o: $(UTILS_SRC)/hsv.h
+worm.o: $(UTILS_SRC)/colors.h
+worm.o: $(UTILS_SRC)/grabscreen.h
+worm.o: $(UTILS_SRC)/visual.h
+worm.o: $(UTILS_SRC)/xshm.h
rotor.o: $(srcdir)/xlockmore.h
rotor.o: ../config.h
rotor.o: $(srcdir)/xlockmoreI.h
rotor.o: $(srcdir)/screenhack.h
+rotor.o: $(UTILS_SRC)/yarandom.h
+rotor.o: $(UTILS_SRC)/usleep.h
+rotor.o: $(UTILS_SRC)/resources.h
+rotor.o: $(UTILS_SRC)/hsv.h
+rotor.o: $(UTILS_SRC)/colors.h
+rotor.o: $(UTILS_SRC)/grabscreen.h
+rotor.o: $(UTILS_SRC)/visual.h
+rotor.o: $(UTILS_SRC)/xshm.h
ant.o: $(srcdir)/xlockmore.h
ant.o: ../config.h
ant.o: $(srcdir)/xlockmoreI.h
ant.o: $(srcdir)/screenhack.h
+ant.o: $(UTILS_SRC)/yarandom.h
+ant.o: $(UTILS_SRC)/usleep.h
+ant.o: $(UTILS_SRC)/resources.h
+ant.o: $(UTILS_SRC)/hsv.h
+ant.o: $(UTILS_SRC)/colors.h
+ant.o: $(UTILS_SRC)/grabscreen.h
+ant.o: $(UTILS_SRC)/visual.h
+ant.o: $(UTILS_SRC)/xshm.h
+ant.o: $(UTILS_SRC)/erase.h
ant.o: $(srcdir)/automata.h
xjack.o: $(srcdir)/screenhack.h
xjack.o: ../config.h
+xjack.o: $(UTILS_SRC)/yarandom.h
+xjack.o: $(UTILS_SRC)/usleep.h
+xjack.o: $(UTILS_SRC)/resources.h
+xjack.o: $(UTILS_SRC)/hsv.h
+xjack.o: $(UTILS_SRC)/colors.h
+xjack.o: $(UTILS_SRC)/grabscreen.h
+xjack.o: $(UTILS_SRC)/visual.h
xlyap.o: $(srcdir)/screenhack.h
xlyap.o: ../config.h
+xlyap.o: $(UTILS_SRC)/yarandom.h
+xlyap.o: $(UTILS_SRC)/usleep.h
+xlyap.o: $(UTILS_SRC)/resources.h
+xlyap.o: $(UTILS_SRC)/hsv.h
+xlyap.o: $(UTILS_SRC)/colors.h
+xlyap.o: $(UTILS_SRC)/grabscreen.h
+xlyap.o: $(UTILS_SRC)/visual.h
+xlyap.o: $(UTILS_SRC)/vroot.h
jigsaw.o: $(srcdir)/screenhack.h
jigsaw.o: ../config.h
+jigsaw.o: $(UTILS_SRC)/yarandom.h
+jigsaw.o: $(UTILS_SRC)/usleep.h
+jigsaw.o: $(UTILS_SRC)/resources.h
+jigsaw.o: $(UTILS_SRC)/hsv.h
+jigsaw.o: $(UTILS_SRC)/colors.h
+jigsaw.o: $(UTILS_SRC)/grabscreen.h
+jigsaw.o: $(UTILS_SRC)/visual.h
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_a_h.xbm
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_a_n_h.xbm
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_a_ne_h.xbm
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_b_sw_f.xbm
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_b_w_f.xbm
jigsaw.o: $(srcdir)/images/jigsaw/jigsaw_b_nw_f.xbm
+xscreensaver-sgigl.o: $(UTILS_SRC)/vroot.h
cynosure.o: $(srcdir)/screenhack.h
cynosure.o: ../config.h
+cynosure.o: $(UTILS_SRC)/yarandom.h
+cynosure.o: $(UTILS_SRC)/usleep.h
+cynosure.o: $(UTILS_SRC)/resources.h
+cynosure.o: $(UTILS_SRC)/hsv.h
+cynosure.o: $(UTILS_SRC)/colors.h
+cynosure.o: $(UTILS_SRC)/grabscreen.h
+cynosure.o: $(UTILS_SRC)/visual.h
moire2.o: $(srcdir)/screenhack.h
moire2.o: ../config.h
+moire2.o: $(UTILS_SRC)/yarandom.h
+moire2.o: $(UTILS_SRC)/usleep.h
+moire2.o: $(UTILS_SRC)/resources.h
+moire2.o: $(UTILS_SRC)/hsv.h
+moire2.o: $(UTILS_SRC)/colors.h
+moire2.o: $(UTILS_SRC)/grabscreen.h
+moire2.o: $(UTILS_SRC)/visual.h
+moire2.o: $(UTILS_SRC)/xdbe.h
flow.o: $(srcdir)/xlockmore.h
flow.o: ../config.h
flow.o: $(srcdir)/xlockmoreI.h
flow.o: $(srcdir)/screenhack.h
+flow.o: $(UTILS_SRC)/yarandom.h
+flow.o: $(UTILS_SRC)/usleep.h
+flow.o: $(UTILS_SRC)/resources.h
+flow.o: $(UTILS_SRC)/hsv.h
+flow.o: $(UTILS_SRC)/colors.h
+flow.o: $(UTILS_SRC)/grabscreen.h
+flow.o: $(UTILS_SRC)/visual.h
+flow.o: $(UTILS_SRC)/xshm.h
+flow.o: $(UTILS_SRC)/erase.h
epicycle.o: $(srcdir)/screenhack.h
epicycle.o: ../config.h
+epicycle.o: $(UTILS_SRC)/yarandom.h
+epicycle.o: $(UTILS_SRC)/usleep.h
+epicycle.o: $(UTILS_SRC)/resources.h
+epicycle.o: $(UTILS_SRC)/hsv.h
+epicycle.o: $(UTILS_SRC)/colors.h
+epicycle.o: $(UTILS_SRC)/grabscreen.h
+epicycle.o: $(UTILS_SRC)/visual.h
+epicycle.o: $(UTILS_SRC)/erase.h
interference.o: $(srcdir)/screenhack.h
interference.o: ../config.h
+interference.o: $(UTILS_SRC)/yarandom.h
+interference.o: $(UTILS_SRC)/usleep.h
+interference.o: $(UTILS_SRC)/resources.h
+interference.o: $(UTILS_SRC)/hsv.h
+interference.o: $(UTILS_SRC)/colors.h
+interference.o: $(UTILS_SRC)/grabscreen.h
+interference.o: $(UTILS_SRC)/visual.h
+interference.o: $(UTILS_SRC)/xdbe.h
truchet.o: $(srcdir)/screenhack.h
truchet.o: ../config.h
+truchet.o: $(UTILS_SRC)/yarandom.h
+truchet.o: $(UTILS_SRC)/usleep.h
+truchet.o: $(UTILS_SRC)/resources.h
+truchet.o: $(UTILS_SRC)/hsv.h
+truchet.o: $(UTILS_SRC)/colors.h
+truchet.o: $(UTILS_SRC)/grabscreen.h
+truchet.o: $(UTILS_SRC)/visual.h
bsod.o: $(srcdir)/screenhack.h
bsod.o: ../config.h
+bsod.o: $(UTILS_SRC)/yarandom.h
+bsod.o: $(UTILS_SRC)/usleep.h
+bsod.o: $(UTILS_SRC)/resources.h
+bsod.o: $(UTILS_SRC)/hsv.h
+bsod.o: $(UTILS_SRC)/colors.h
+bsod.o: $(UTILS_SRC)/grabscreen.h
+bsod.o: $(UTILS_SRC)/visual.h
bsod.o: $(srcdir)/images/amiga.xpm
bsod.o: $(srcdir)/images/atari.xbm
bsod.o: $(srcdir)/images/mac.xbm
crystal.o: ../config.h
crystal.o: $(srcdir)/xlockmoreI.h
crystal.o: $(srcdir)/screenhack.h
+crystal.o: $(UTILS_SRC)/yarandom.h
+crystal.o: $(UTILS_SRC)/usleep.h
+crystal.o: $(UTILS_SRC)/resources.h
+crystal.o: $(UTILS_SRC)/hsv.h
+crystal.o: $(UTILS_SRC)/colors.h
+crystal.o: $(UTILS_SRC)/grabscreen.h
+crystal.o: $(UTILS_SRC)/visual.h
+crystal.o: $(UTILS_SRC)/xshm.h
discrete.o: $(srcdir)/xlockmore.h
discrete.o: ../config.h
discrete.o: $(srcdir)/xlockmoreI.h
discrete.o: $(srcdir)/screenhack.h
+discrete.o: $(UTILS_SRC)/yarandom.h
+discrete.o: $(UTILS_SRC)/usleep.h
+discrete.o: $(UTILS_SRC)/resources.h
+discrete.o: $(UTILS_SRC)/hsv.h
+discrete.o: $(UTILS_SRC)/colors.h
+discrete.o: $(UTILS_SRC)/grabscreen.h
+discrete.o: $(UTILS_SRC)/visual.h
+discrete.o: $(UTILS_SRC)/xshm.h
+discrete.o: $(UTILS_SRC)/erase.h
distort.o: $(srcdir)/screenhack.h
distort.o: ../config.h
+distort.o: $(UTILS_SRC)/yarandom.h
+distort.o: $(UTILS_SRC)/usleep.h
+distort.o: $(UTILS_SRC)/resources.h
+distort.o: $(UTILS_SRC)/hsv.h
+distort.o: $(UTILS_SRC)/colors.h
+distort.o: $(UTILS_SRC)/grabscreen.h
+distort.o: $(UTILS_SRC)/visual.h
+distort.o: $(UTILS_SRC)/xshm.h
kumppa.o: $(srcdir)/screenhack.h
kumppa.o: ../config.h
+kumppa.o: $(UTILS_SRC)/yarandom.h
+kumppa.o: $(UTILS_SRC)/usleep.h
+kumppa.o: $(UTILS_SRC)/resources.h
+kumppa.o: $(UTILS_SRC)/hsv.h
+kumppa.o: $(UTILS_SRC)/colors.h
+kumppa.o: $(UTILS_SRC)/grabscreen.h
+kumppa.o: $(UTILS_SRC)/visual.h
+kumppa.o: $(UTILS_SRC)/xdbe.h
sonar.o: $(srcdir)/screenhack.h
sonar.o: ../config.h
+sonar.o: $(UTILS_SRC)/yarandom.h
+sonar.o: $(UTILS_SRC)/usleep.h
+sonar.o: $(UTILS_SRC)/resources.h
+sonar.o: $(UTILS_SRC)/hsv.h
+sonar.o: $(UTILS_SRC)/colors.h
+sonar.o: $(UTILS_SRC)/grabscreen.h
+sonar.o: $(UTILS_SRC)/visual.h
demon.o: $(srcdir)/xlockmore.h
demon.o: ../config.h
demon.o: $(srcdir)/xlockmoreI.h
demon.o: $(srcdir)/screenhack.h
+demon.o: $(UTILS_SRC)/yarandom.h
+demon.o: $(UTILS_SRC)/usleep.h
+demon.o: $(UTILS_SRC)/resources.h
+demon.o: $(UTILS_SRC)/hsv.h
+demon.o: $(UTILS_SRC)/colors.h
+demon.o: $(UTILS_SRC)/grabscreen.h
+demon.o: $(UTILS_SRC)/visual.h
+demon.o: $(UTILS_SRC)/xshm.h
demon.o: $(srcdir)/automata.h
loop.o: $(srcdir)/xlockmore.h
loop.o: ../config.h
loop.o: $(srcdir)/xlockmoreI.h
loop.o: $(srcdir)/screenhack.h
+loop.o: $(UTILS_SRC)/yarandom.h
+loop.o: $(UTILS_SRC)/usleep.h
+loop.o: $(UTILS_SRC)/resources.h
+loop.o: $(UTILS_SRC)/hsv.h
+loop.o: $(UTILS_SRC)/colors.h
+loop.o: $(UTILS_SRC)/grabscreen.h
+loop.o: $(UTILS_SRC)/visual.h
+loop.o: $(UTILS_SRC)/xshm.h
loop.o: $(srcdir)/automata.h
t3d.o: $(srcdir)/screenhack.h
t3d.o: ../config.h
+t3d.o: $(UTILS_SRC)/yarandom.h
+t3d.o: $(UTILS_SRC)/usleep.h
+t3d.o: $(UTILS_SRC)/resources.h
+t3d.o: $(UTILS_SRC)/hsv.h
+t3d.o: $(UTILS_SRC)/colors.h
+t3d.o: $(UTILS_SRC)/grabscreen.h
+t3d.o: $(UTILS_SRC)/visual.h
penetrate.o: $(srcdir)/screenhack.h
penetrate.o: ../config.h
+penetrate.o: $(UTILS_SRC)/yarandom.h
+penetrate.o: $(UTILS_SRC)/usleep.h
+penetrate.o: $(UTILS_SRC)/resources.h
+penetrate.o: $(UTILS_SRC)/hsv.h
+penetrate.o: $(UTILS_SRC)/colors.h
+penetrate.o: $(UTILS_SRC)/grabscreen.h
+penetrate.o: $(UTILS_SRC)/visual.h
deluxe.o: $(srcdir)/screenhack.h
deluxe.o: ../config.h
+deluxe.o: $(UTILS_SRC)/yarandom.h
+deluxe.o: $(UTILS_SRC)/usleep.h
+deluxe.o: $(UTILS_SRC)/resources.h
+deluxe.o: $(UTILS_SRC)/hsv.h
+deluxe.o: $(UTILS_SRC)/colors.h
+deluxe.o: $(UTILS_SRC)/grabscreen.h
+deluxe.o: $(UTILS_SRC)/visual.h
+deluxe.o: $(UTILS_SRC)/alpha.h
+deluxe.o: $(UTILS_SRC)/xdbe.h
compass.o: $(srcdir)/screenhack.h
compass.o: ../config.h
+compass.o: $(UTILS_SRC)/yarandom.h
+compass.o: $(UTILS_SRC)/usleep.h
+compass.o: $(UTILS_SRC)/resources.h
+compass.o: $(UTILS_SRC)/hsv.h
+compass.o: $(UTILS_SRC)/colors.h
+compass.o: $(UTILS_SRC)/grabscreen.h
+compass.o: $(UTILS_SRC)/visual.h
+compass.o: $(UTILS_SRC)/xdbe.h
squiral.o: $(srcdir)/screenhack.h
squiral.o: ../config.h
+squiral.o: $(UTILS_SRC)/yarandom.h
+squiral.o: $(UTILS_SRC)/usleep.h
+squiral.o: $(UTILS_SRC)/resources.h
+squiral.o: $(UTILS_SRC)/hsv.h
+squiral.o: $(UTILS_SRC)/colors.h
+squiral.o: $(UTILS_SRC)/grabscreen.h
+squiral.o: $(UTILS_SRC)/visual.h
+squiral.o: $(UTILS_SRC)/erase.h
xflame.o: $(srcdir)/screenhack.h
xflame.o: ../config.h
+xflame.o: $(UTILS_SRC)/yarandom.h
+xflame.o: $(UTILS_SRC)/usleep.h
+xflame.o: $(UTILS_SRC)/resources.h
+xflame.o: $(UTILS_SRC)/hsv.h
+xflame.o: $(UTILS_SRC)/colors.h
+xflame.o: $(UTILS_SRC)/grabscreen.h
+xflame.o: $(UTILS_SRC)/visual.h
+xflame.o: $(UTILS_SRC)/xshm.h
xflame.o: $(srcdir)/images/bob.xbm
wander.o: $(srcdir)/screenhack.h
wander.o: ../config.h
+wander.o: $(UTILS_SRC)/yarandom.h
+wander.o: $(UTILS_SRC)/usleep.h
+wander.o: $(UTILS_SRC)/resources.h
+wander.o: $(UTILS_SRC)/hsv.h
+wander.o: $(UTILS_SRC)/colors.h
+wander.o: $(UTILS_SRC)/grabscreen.h
+wander.o: $(UTILS_SRC)/visual.h
+wander.o: $(UTILS_SRC)/erase.h
spotlight.o: $(srcdir)/screenhack.h
spotlight.o: ../config.h
+spotlight.o: $(UTILS_SRC)/yarandom.h
+spotlight.o: $(UTILS_SRC)/usleep.h
+spotlight.o: $(UTILS_SRC)/resources.h
+spotlight.o: $(UTILS_SRC)/hsv.h
+spotlight.o: $(UTILS_SRC)/colors.h
+spotlight.o: $(UTILS_SRC)/grabscreen.h
+spotlight.o: $(UTILS_SRC)/visual.h
critical.o: $(srcdir)/screenhack.h
critical.o: ../config.h
+critical.o: $(UTILS_SRC)/yarandom.h
+critical.o: $(UTILS_SRC)/usleep.h
+critical.o: $(UTILS_SRC)/resources.h
+critical.o: $(UTILS_SRC)/hsv.h
+critical.o: $(UTILS_SRC)/colors.h
+critical.o: $(UTILS_SRC)/grabscreen.h
+critical.o: $(UTILS_SRC)/visual.h
+critical.o: $(UTILS_SRC)/erase.h
phosphor.o: $(srcdir)/screenhack.h
phosphor.o: ../config.h
+phosphor.o: $(UTILS_SRC)/yarandom.h
+phosphor.o: $(UTILS_SRC)/usleep.h
+phosphor.o: $(UTILS_SRC)/resources.h
+phosphor.o: $(UTILS_SRC)/hsv.h
+phosphor.o: $(UTILS_SRC)/colors.h
+phosphor.o: $(UTILS_SRC)/grabscreen.h
+phosphor.o: $(UTILS_SRC)/visual.h
xmatrix.o: $(srcdir)/screenhack.h
xmatrix.o: ../config.h
+xmatrix.o: $(UTILS_SRC)/yarandom.h
+xmatrix.o: $(UTILS_SRC)/usleep.h
+xmatrix.o: $(UTILS_SRC)/resources.h
+xmatrix.o: $(UTILS_SRC)/hsv.h
+xmatrix.o: $(UTILS_SRC)/colors.h
+xmatrix.o: $(UTILS_SRC)/grabscreen.h
+xmatrix.o: $(UTILS_SRC)/visual.h
xmatrix.o: $(srcdir)/images/matrix.xpm
xmatrix.o: $(srcdir)/images/matrix2.xpm
xmatrix.o: $(srcdir)/images/matrix.xbm
xmatrix.o: $(srcdir)/images/matrix2.xbm
petri.o: $(srcdir)/screenhack.h
petri.o: ../config.h
+petri.o: $(UTILS_SRC)/yarandom.h
+petri.o: $(UTILS_SRC)/usleep.h
+petri.o: $(UTILS_SRC)/resources.h
+petri.o: $(UTILS_SRC)/hsv.h
+petri.o: $(UTILS_SRC)/colors.h
+petri.o: $(UTILS_SRC)/grabscreen.h
+petri.o: $(UTILS_SRC)/visual.h
+petri.o: $(UTILS_SRC)/spline.h
shadebobs.o: $(srcdir)/screenhack.h
shadebobs.o: ../config.h
+shadebobs.o: $(UTILS_SRC)/yarandom.h
+shadebobs.o: $(UTILS_SRC)/usleep.h
+shadebobs.o: $(UTILS_SRC)/resources.h
+shadebobs.o: $(UTILS_SRC)/hsv.h
+shadebobs.o: $(UTILS_SRC)/colors.h
+shadebobs.o: $(UTILS_SRC)/grabscreen.h
+shadebobs.o: $(UTILS_SRC)/visual.h
+xsublim.o: $(UTILS_SRC)/usleep.h
+xsublim.o: $(UTILS_SRC)/yarandom.h
+xsublim.o: $(UTILS_SRC)/resources.h
ccurve.o: $(srcdir)/screenhack.h
ccurve.o: ../config.h
+ccurve.o: $(UTILS_SRC)/yarandom.h
+ccurve.o: $(UTILS_SRC)/usleep.h
+ccurve.o: $(UTILS_SRC)/resources.h
+ccurve.o: $(UTILS_SRC)/hsv.h
+ccurve.o: $(UTILS_SRC)/colors.h
+ccurve.o: $(UTILS_SRC)/grabscreen.h
+ccurve.o: $(UTILS_SRC)/visual.h
+ccurve.o: $(UTILS_SRC)/erase.h
blaster.o: $(srcdir)/screenhack.h
blaster.o: ../config.h
+blaster.o: $(UTILS_SRC)/yarandom.h
+blaster.o: $(UTILS_SRC)/usleep.h
+blaster.o: $(UTILS_SRC)/resources.h
+blaster.o: $(UTILS_SRC)/hsv.h
+blaster.o: $(UTILS_SRC)/colors.h
+blaster.o: $(UTILS_SRC)/grabscreen.h
+blaster.o: $(UTILS_SRC)/visual.h
bumps.o: $(srcdir)/bumps.h
bumps.o: $(srcdir)/screenhack.h
bumps.o: ../config.h
+bumps.o: $(UTILS_SRC)/yarandom.h
+bumps.o: $(UTILS_SRC)/usleep.h
+bumps.o: $(UTILS_SRC)/resources.h
+bumps.o: $(UTILS_SRC)/hsv.h
+bumps.o: $(UTILS_SRC)/colors.h
+bumps.o: $(UTILS_SRC)/grabscreen.h
+bumps.o: $(UTILS_SRC)/visual.h
ripples.o: $(srcdir)/screenhack.h
ripples.o: ../config.h
+ripples.o: $(UTILS_SRC)/yarandom.h
+ripples.o: $(UTILS_SRC)/usleep.h
+ripples.o: $(UTILS_SRC)/resources.h
+ripples.o: $(UTILS_SRC)/hsv.h
+ripples.o: $(UTILS_SRC)/colors.h
+ripples.o: $(UTILS_SRC)/grabscreen.h
+ripples.o: $(UTILS_SRC)/visual.h
+ripples.o: $(UTILS_SRC)/xshm.h
xteevee.o: $(srcdir)/screenhack.h
xteevee.o: ../config.h
+xteevee.o: $(UTILS_SRC)/yarandom.h
+xteevee.o: $(UTILS_SRC)/usleep.h
+xteevee.o: $(UTILS_SRC)/resources.h
+xteevee.o: $(UTILS_SRC)/hsv.h
+xteevee.o: $(UTILS_SRC)/colors.h
+xteevee.o: $(UTILS_SRC)/grabscreen.h
+xteevee.o: $(UTILS_SRC)/visual.h
+xteevee.o: $(UTILS_SRC)/colorbars.h
xspirograph.o: $(srcdir)/screenhack.h
xspirograph.o: ../config.h
+xspirograph.o: $(UTILS_SRC)/yarandom.h
+xspirograph.o: $(UTILS_SRC)/usleep.h
+xspirograph.o: $(UTILS_SRC)/resources.h
+xspirograph.o: $(UTILS_SRC)/hsv.h
+xspirograph.o: $(UTILS_SRC)/colors.h
+xspirograph.o: $(UTILS_SRC)/grabscreen.h
+xspirograph.o: $(UTILS_SRC)/visual.h
+xspirograph.o: $(UTILS_SRC)/erase.h
nerverot.o: $(srcdir)/screenhack.h
nerverot.o: ../config.h
+nerverot.o: $(UTILS_SRC)/yarandom.h
+nerverot.o: $(UTILS_SRC)/usleep.h
+nerverot.o: $(UTILS_SRC)/resources.h
+nerverot.o: $(UTILS_SRC)/hsv.h
+nerverot.o: $(UTILS_SRC)/colors.h
+nerverot.o: $(UTILS_SRC)/grabscreen.h
+nerverot.o: $(UTILS_SRC)/visual.h
xrayswarm.o: $(srcdir)/screenhack.h
xrayswarm.o: ../config.h
+xrayswarm.o: $(UTILS_SRC)/yarandom.h
+xrayswarm.o: $(UTILS_SRC)/usleep.h
+xrayswarm.o: $(UTILS_SRC)/resources.h
+xrayswarm.o: $(UTILS_SRC)/hsv.h
+xrayswarm.o: $(UTILS_SRC)/colors.h
+xrayswarm.o: $(UTILS_SRC)/grabscreen.h
+xrayswarm.o: $(UTILS_SRC)/visual.h
hyperball.o: $(srcdir)/screenhack.h
hyperball.o: ../config.h
+hyperball.o: $(UTILS_SRC)/yarandom.h
+hyperball.o: $(UTILS_SRC)/usleep.h
+hyperball.o: $(UTILS_SRC)/resources.h
+hyperball.o: $(UTILS_SRC)/hsv.h
+hyperball.o: $(UTILS_SRC)/colors.h
+hyperball.o: $(UTILS_SRC)/grabscreen.h
+hyperball.o: $(UTILS_SRC)/visual.h
zoom.o: $(srcdir)/screenhack.h
zoom.o: ../config.h
+zoom.o: $(UTILS_SRC)/yarandom.h
+zoom.o: $(UTILS_SRC)/usleep.h
+zoom.o: $(UTILS_SRC)/resources.h
+zoom.o: $(UTILS_SRC)/hsv.h
+zoom.o: $(UTILS_SRC)/colors.h
+zoom.o: $(UTILS_SRC)/grabscreen.h
+zoom.o: $(UTILS_SRC)/visual.h
whirlwindwarp.o: $(srcdir)/screenhack.h
whirlwindwarp.o: ../config.h
+whirlwindwarp.o: $(UTILS_SRC)/yarandom.h
+whirlwindwarp.o: $(UTILS_SRC)/usleep.h
+whirlwindwarp.o: $(UTILS_SRC)/resources.h
+whirlwindwarp.o: $(UTILS_SRC)/hsv.h
+whirlwindwarp.o: $(UTILS_SRC)/colors.h
+whirlwindwarp.o: $(UTILS_SRC)/grabscreen.h
+whirlwindwarp.o: $(UTILS_SRC)/visual.h
+whirlwindwarp.o: $(UTILS_SRC)/erase.h
rotzoomer.o: $(srcdir)/screenhack.h
rotzoomer.o: ../config.h
+rotzoomer.o: $(UTILS_SRC)/yarandom.h
+rotzoomer.o: $(UTILS_SRC)/usleep.h
+rotzoomer.o: $(UTILS_SRC)/resources.h
+rotzoomer.o: $(UTILS_SRC)/hsv.h
+rotzoomer.o: $(UTILS_SRC)/colors.h
+rotzoomer.o: $(UTILS_SRC)/grabscreen.h
+rotzoomer.o: $(UTILS_SRC)/visual.h
+rotzoomer.o: $(UTILS_SRC)/xshm.h
whirlygig.o: $(srcdir)/screenhack.h
whirlygig.o: ../config.h
+whirlygig.o: $(UTILS_SRC)/yarandom.h
+whirlygig.o: $(UTILS_SRC)/usleep.h
+whirlygig.o: $(UTILS_SRC)/resources.h
+whirlygig.o: $(UTILS_SRC)/hsv.h
+whirlygig.o: $(UTILS_SRC)/colors.h
+whirlygig.o: $(UTILS_SRC)/grabscreen.h
+whirlygig.o: $(UTILS_SRC)/visual.h
speedmine.o: $(srcdir)/screenhack.h
speedmine.o: ../config.h
+speedmine.o: $(UTILS_SRC)/yarandom.h
+speedmine.o: $(UTILS_SRC)/usleep.h
+speedmine.o: $(UTILS_SRC)/resources.h
+speedmine.o: $(UTILS_SRC)/hsv.h
+speedmine.o: $(UTILS_SRC)/colors.h
+speedmine.o: $(UTILS_SRC)/grabscreen.h
+speedmine.o: $(UTILS_SRC)/visual.h
+speedmine.o: $(UTILS_SRC)/erase.h
+vermiculate.o: $(srcdir)/screenhack.h
+vermiculate.o: ../config.h
+vermiculate.o: $(UTILS_SRC)/yarandom.h
+vermiculate.o: $(UTILS_SRC)/usleep.h
+vermiculate.o: $(UTILS_SRC)/resources.h
+vermiculate.o: $(UTILS_SRC)/hsv.h
+vermiculate.o: $(UTILS_SRC)/colors.h
+vermiculate.o: $(UTILS_SRC)/grabscreen.h
+vermiculate.o: $(UTILS_SRC)/visual.h
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) T3D.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRIANGLE.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRUCHET.C
+$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VERMICULATE.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VINES.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WANDER.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WHIRLWINDWARP.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) T3D.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRIANGLE.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) TRUCHET.C
+$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VERMICULATE.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) VINES.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WANDER.C
$ CC/DECC/PREFIX=ALL/DEFINE=(VMS,HAVE_CONFIG_H,STANDALONE)/INCL=([],[-],[-.UTILS]) WHIRLWINDWARP.C
#define OUT 10
#define MELT 11
#define STRETCH 12
+#define FUZZ 13
static void
init_decay (Display *dpy, Window window)
else if (s && !strcmp(s, "out")) mode = OUT;
else if (s && !strcmp(s, "melt")) mode = MELT;
else if (s && !strcmp(s, "stretch")) mode = STRETCH;
+ else if (s && !strcmp(s, "fuzz")) mode = FUZZ;
else {
if (s && *s && !!strcmp(s, "random"))
fprintf(stderr, "%s: unknown mode %s\n", progname, s);
- mode = random() % (STRETCH+1);
+ mode = random() % (FUZZ+1);
}
delay = get_integer_resource ("delay", "Integer");
case OUT: bias = no_bias; break;
case MELT: bias = no_bias; break;
case STRETCH: bias = no_bias; break;
+ case FUZZ: bias = no_bias; break;
default: abort();
}
toleft = left;
totop = top+1;
+ } else if (mode == FUZZ) { /* By Vince Levey <vincel@vincel.org>;
+ inspired by the "melt" mode of the
+ "scrhack" IrisGL program by Paul Haeberli
+ circa 1991. */
+ static int toggle = 0;
+
+ left = nrnd(sizex - 1);
+ top = nrnd(sizey - 1);
+ toggle = !toggle;
+ if (toggle)
+ {
+ totop = top;
+ height = 1;
+ toleft = nrnd(sizex - 1);
+ if (toleft > left)
+ {
+ width = toleft-left;
+ toleft = left;
+ left++;
+ }
+ else
+ {
+ width = left-toleft;
+ left = toleft;
+ toleft++;
+ }
+ }
+ else
+ {
+ toleft = left;
+ width = 1;
+ totop = nrnd(sizey - 1);
+ if (totop > top)
+ {
+ height = totop-top;
+ totop = top;
+ top++;
+ }
+ else
+ {
+ height = top-totop;
+ top = totop;
+ totop++;
+ }
+ }
+
} else {
left = nrnd(sizex - 1);
\fIdown\fP, \fIupleft\fP, \fIdownleft\fP, \fIupright\fP, \fIdownright\fP,
\fIshuffle\fP (meaning perfer no particular direction), \fIin\fP (meaning
move things toward the center), \fIout\fP (meaning move things away
-from the center), \fImelt\fP (meaning melt straight downward),
-and \fIstretch\fP (meaning stretch the screen downward).
+from the center), \fImelt\fP (meaning melt straight
+downward), \fIstretch\fP (meaning stretch the screen downward),
+and \fIfuzz\fP (meaning go blurry instead of melty).
.SH ENVIRONMENT
.PP
.TP 8
forest - draws a fractal forest
.SH SYNOPSIS
.B forest
-[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP]
+[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP]
.SH DESCRIPTION
The \fIforest\fP program draws a fractal forest.
.TP 8
.B \-ncolors \fIinteger\fP
How many colors should be used (if possible). Default 100.
-.TP 8
-.B \-cycles \fIinteger\fP
-
-.TP 8
-.B \-count \fIinteger\fP
.SH ENVIRONMENT
.PP
extrusion-taper.c extrusion-twistoid.c sierpinski3d.c \
gflux.c stonerview.c stonerview-move.c stonerview-osc.c \
stonerview-view.c starwars.c glut_stroke.c glut_swidth.c \
- gltext.c molecule.c dangerball.c sphere.c tube.c
+ gltext.c molecule.c dangerball.c sphere.c tube.c circuit.c
OBJS = xscreensaver-gl-helper.o \
atlantis.o b_draw.o b_lockglue.o b_sphere.o bubble3d.o \
extrusion-taper.o extrusion-twistoid.o sierpinski3d.o \
gflux.o stonerview.o stonerview-move.o stonerview-osc.o \
stonerview-view.o starwars.o glut_stroke.o glut_swidth.o \
- gltext.o molecule.o dangerball.o sphere.o tube.o
+ gltext.o molecule.o dangerball.o sphere.o tube.o circuit.o
GL_EXES = cage gears moebius pipes sproingies stairs superquadrics \
morph3d rubik atlantis lament bubble3d glplanet pulsar \
sierpinski3d gflux stonerview starwars gltext molecule \
- dangerball
+ dangerball circuit
GLE_EXES = extrusion
GL_UTIL_EXES = xscreensaver-gl-helper
HACK_EXES = @GL_EXES@ @GLE_EXES@
# the xscreensaver-gl-helper program, in $bindir
install-program:: $(EXES)
- @exes="$(GL_UTIL_EXES)" ; \
+ @exes="@GL_UTIL_EXES@" ; \
idir="$(install_prefix)$(bindir)" ; \
if [ "$$exes" != "" ]; then \
if [ ! -d $$idir ]; then \
dangerball: dangerball.o sphere.o tube.o $(HACK_OBJS)
$(CC_HACK) -o $@ $@.o sphere.o tube.o $(HACK_OBJS) $(HACK_LIBS)
+circuit: circuit.o $(HACK_OBJS)
+ $(CC_HACK) -o $@ $@.o $(HACK_OBJS) $(HACK_LIBS)
+
# This one works differently (it's not xlock-like.)
#
STONER_OBJS=stonerview.o stonerview-move.o stonerview-osc.o stonerview-view.o \
molecule: molecule.o sphere.o tube.o $(HACK_OBJS)
$(CC_HACK) -o $@ $@.o sphere.o tube.o $(HACK_OBJS) $(HACK_LIBS)
+dnalogo: dnalogo.o tube.o $(HACK_OBJS)
+ $(CC_HACK) -o $@ $@.o tube.o $(HACK_OBJS) $(HACK_LIBS)
##############################################################################
#
# DO NOT DELETE: updated by make distdepend
# $(srcdir)/DO $(srcdir)/NOT $(srcdir)/DELETE: $(srcdir)/updated $(srcdir)/by $(srcdir)/make $(srcdir)/distdepend
+xscreensaver-gl-helper.o: $(UTILS_SRC)/utils.h
xscreensaver-gl-helper.o: ../../config.h
+xscreensaver-gl-helper.o: $(UTILS_SRC)/visual.h
+atlantis.o: $(HACK_SRC)/xlockmore.h
atlantis.o: ../../config.h
+atlantis.o: $(HACK_SRC)/xlockmoreI.h
+atlantis.o: $(HACK_SRC)/screenhack.h
+atlantis.o: $(UTILS_SRC)/yarandom.h
+atlantis.o: $(UTILS_SRC)/usleep.h
+atlantis.o: $(UTILS_SRC)/resources.h
+atlantis.o: $(UTILS_SRC)/hsv.h
+atlantis.o: $(UTILS_SRC)/colors.h
+atlantis.o: $(UTILS_SRC)/grabscreen.h
+atlantis.o: $(UTILS_SRC)/visual.h
+atlantis.o: $(UTILS_SRC)/xshm.h
atlantis.o: $(srcdir)/atlantis.h
atlantis.o: $(srcdir)/xpm-ximage.h
atlantis.o: $(HACK_SRC)/images/sea-texture.xpm
b_draw.o: $(srcdir)/bubble3d.h
+b_draw.o: $(HACK_SRC)/xlockmoreI.h
+b_draw.o: $(HACK_SRC)/screenhack.h
b_draw.o: ../../config.h
+b_draw.o: $(UTILS_SRC)/yarandom.h
+b_draw.o: $(UTILS_SRC)/usleep.h
+b_draw.o: $(UTILS_SRC)/resources.h
+b_draw.o: $(UTILS_SRC)/hsv.h
+b_draw.o: $(UTILS_SRC)/colors.h
+b_draw.o: $(UTILS_SRC)/grabscreen.h
+b_draw.o: $(UTILS_SRC)/visual.h
+b_draw.o: $(UTILS_SRC)/xshm.h
b_lockglue.o: $(srcdir)/bubble3d.h
+b_lockglue.o: $(HACK_SRC)/xlockmoreI.h
+b_lockglue.o: $(HACK_SRC)/screenhack.h
b_lockglue.o: ../../config.h
+b_lockglue.o: $(UTILS_SRC)/yarandom.h
+b_lockglue.o: $(UTILS_SRC)/usleep.h
+b_lockglue.o: $(UTILS_SRC)/resources.h
+b_lockglue.o: $(UTILS_SRC)/hsv.h
+b_lockglue.o: $(UTILS_SRC)/colors.h
+b_lockglue.o: $(UTILS_SRC)/grabscreen.h
+b_lockglue.o: $(UTILS_SRC)/visual.h
+b_lockglue.o: $(UTILS_SRC)/xshm.h
+b_lockglue.o: $(HACK_SRC)/xlockmore.h
b_sphere.o: $(srcdir)/bubble3d.h
+b_sphere.o: $(HACK_SRC)/xlockmoreI.h
+b_sphere.o: $(HACK_SRC)/screenhack.h
b_sphere.o: ../../config.h
+b_sphere.o: $(UTILS_SRC)/yarandom.h
+b_sphere.o: $(UTILS_SRC)/usleep.h
+b_sphere.o: $(UTILS_SRC)/resources.h
+b_sphere.o: $(UTILS_SRC)/hsv.h
+b_sphere.o: $(UTILS_SRC)/colors.h
+b_sphere.o: $(UTILS_SRC)/grabscreen.h
+b_sphere.o: $(UTILS_SRC)/visual.h
+b_sphere.o: $(UTILS_SRC)/xshm.h
bubble3d.o: $(srcdir)/bubble3d.h
+bubble3d.o: $(HACK_SRC)/xlockmoreI.h
+bubble3d.o: $(HACK_SRC)/screenhack.h
bubble3d.o: ../../config.h
+bubble3d.o: $(UTILS_SRC)/yarandom.h
+bubble3d.o: $(UTILS_SRC)/usleep.h
+bubble3d.o: $(UTILS_SRC)/resources.h
+bubble3d.o: $(UTILS_SRC)/hsv.h
+bubble3d.o: $(UTILS_SRC)/colors.h
+bubble3d.o: $(UTILS_SRC)/grabscreen.h
+bubble3d.o: $(UTILS_SRC)/visual.h
+bubble3d.o: $(UTILS_SRC)/xshm.h
buildlwo.o: $(srcdir)/buildlwo.h
+cage.o: $(HACK_SRC)/xlockmore.h
cage.o: ../../config.h
+cage.o: $(HACK_SRC)/xlockmoreI.h
+cage.o: $(HACK_SRC)/screenhack.h
+cage.o: $(UTILS_SRC)/yarandom.h
+cage.o: $(UTILS_SRC)/usleep.h
+cage.o: $(UTILS_SRC)/resources.h
+cage.o: $(UTILS_SRC)/hsv.h
+cage.o: $(UTILS_SRC)/colors.h
+cage.o: $(UTILS_SRC)/grabscreen.h
+cage.o: $(UTILS_SRC)/visual.h
+cage.o: $(UTILS_SRC)/xshm.h
cage.o: $(srcdir)/e_textures.h
dolphin.o: $(srcdir)/atlantis.h
+gears.o: $(HACK_SRC)/xlockmore.h
gears.o: ../../config.h
+gears.o: $(HACK_SRC)/xlockmoreI.h
+gears.o: $(HACK_SRC)/screenhack.h
+gears.o: $(UTILS_SRC)/yarandom.h
+gears.o: $(UTILS_SRC)/usleep.h
+gears.o: $(UTILS_SRC)/resources.h
+gears.o: $(UTILS_SRC)/hsv.h
+gears.o: $(UTILS_SRC)/colors.h
+gears.o: $(UTILS_SRC)/grabscreen.h
+gears.o: $(UTILS_SRC)/visual.h
+gears.o: $(UTILS_SRC)/xshm.h
+lament.o: $(HACK_SRC)/xlockmore.h
lament.o: ../../config.h
+lament.o: $(HACK_SRC)/xlockmoreI.h
+lament.o: $(HACK_SRC)/screenhack.h
+lament.o: $(UTILS_SRC)/yarandom.h
+lament.o: $(UTILS_SRC)/usleep.h
+lament.o: $(UTILS_SRC)/resources.h
+lament.o: $(UTILS_SRC)/hsv.h
+lament.o: $(UTILS_SRC)/colors.h
+lament.o: $(UTILS_SRC)/grabscreen.h
+lament.o: $(UTILS_SRC)/visual.h
+lament.o: $(UTILS_SRC)/xshm.h
lament.o: $(srcdir)/xpm-ximage.h
lament.o: $(HACK_SRC)/images/lament.xpm
+moebius.o: $(HACK_SRC)/xlockmore.h
moebius.o: ../../config.h
+moebius.o: $(HACK_SRC)/xlockmoreI.h
+moebius.o: $(HACK_SRC)/screenhack.h
+moebius.o: $(UTILS_SRC)/yarandom.h
+moebius.o: $(UTILS_SRC)/usleep.h
+moebius.o: $(UTILS_SRC)/resources.h
+moebius.o: $(UTILS_SRC)/hsv.h
+moebius.o: $(UTILS_SRC)/colors.h
+moebius.o: $(UTILS_SRC)/grabscreen.h
+moebius.o: $(UTILS_SRC)/visual.h
+moebius.o: $(UTILS_SRC)/xshm.h
moebius.o: $(srcdir)/e_textures.h
+morph3d.o: $(HACK_SRC)/xlockmore.h
morph3d.o: ../../config.h
+morph3d.o: $(HACK_SRC)/xlockmoreI.h
+morph3d.o: $(HACK_SRC)/screenhack.h
+morph3d.o: $(UTILS_SRC)/yarandom.h
+morph3d.o: $(UTILS_SRC)/usleep.h
+morph3d.o: $(UTILS_SRC)/resources.h
+morph3d.o: $(UTILS_SRC)/hsv.h
+morph3d.o: $(UTILS_SRC)/colors.h
+morph3d.o: $(UTILS_SRC)/grabscreen.h
+morph3d.o: $(UTILS_SRC)/visual.h
+morph3d.o: $(UTILS_SRC)/xshm.h
pipeobjs.o: $(srcdir)/buildlwo.h
+pipes.o: $(HACK_SRC)/xlockmore.h
pipes.o: ../../config.h
+pipes.o: $(HACK_SRC)/xlockmoreI.h
+pipes.o: $(HACK_SRC)/screenhack.h
+pipes.o: $(UTILS_SRC)/yarandom.h
+pipes.o: $(UTILS_SRC)/usleep.h
+pipes.o: $(UTILS_SRC)/resources.h
+pipes.o: $(UTILS_SRC)/hsv.h
+pipes.o: $(UTILS_SRC)/colors.h
+pipes.o: $(UTILS_SRC)/grabscreen.h
+pipes.o: $(UTILS_SRC)/visual.h
+pipes.o: $(UTILS_SRC)/xshm.h
pipes.o: $(srcdir)/buildlwo.h
+rubik.o: $(HACK_SRC)/xlockmore.h
rubik.o: ../../config.h
+rubik.o: $(HACK_SRC)/xlockmoreI.h
+rubik.o: $(HACK_SRC)/screenhack.h
+rubik.o: $(UTILS_SRC)/yarandom.h
+rubik.o: $(UTILS_SRC)/usleep.h
+rubik.o: $(UTILS_SRC)/resources.h
+rubik.o: $(UTILS_SRC)/hsv.h
+rubik.o: $(UTILS_SRC)/colors.h
+rubik.o: $(UTILS_SRC)/grabscreen.h
+rubik.o: $(UTILS_SRC)/visual.h
+rubik.o: $(UTILS_SRC)/xshm.h
s1_1.o: $(srcdir)/buildlwo.h
s1_2.o: $(srcdir)/buildlwo.h
s1_3.o: $(srcdir)/buildlwo.h
s1_6.o: $(srcdir)/buildlwo.h
s1_b.o: $(srcdir)/buildlwo.h
shark.o: $(srcdir)/atlantis.h
+sproingies.o: $(HACK_SRC)/xlockmoreI.h
+sproingies.o: $(HACK_SRC)/screenhack.h
sproingies.o: ../../config.h
+sproingies.o: $(UTILS_SRC)/yarandom.h
+sproingies.o: $(UTILS_SRC)/usleep.h
+sproingies.o: $(UTILS_SRC)/resources.h
+sproingies.o: $(UTILS_SRC)/hsv.h
+sproingies.o: $(UTILS_SRC)/colors.h
+sproingies.o: $(UTILS_SRC)/grabscreen.h
+sproingies.o: $(UTILS_SRC)/visual.h
+sproingies.o: $(UTILS_SRC)/xshm.h
sproingies.o: $(srcdir)/buildlwo.h
+sproingiewrap.o: $(HACK_SRC)/xlockmore.h
sproingiewrap.o: ../../config.h
+sproingiewrap.o: $(HACK_SRC)/xlockmoreI.h
+sproingiewrap.o: $(HACK_SRC)/screenhack.h
+sproingiewrap.o: $(UTILS_SRC)/yarandom.h
+sproingiewrap.o: $(UTILS_SRC)/usleep.h
+sproingiewrap.o: $(UTILS_SRC)/resources.h
+sproingiewrap.o: $(UTILS_SRC)/hsv.h
+sproingiewrap.o: $(UTILS_SRC)/colors.h
+sproingiewrap.o: $(UTILS_SRC)/grabscreen.h
+sproingiewrap.o: $(UTILS_SRC)/visual.h
+sproingiewrap.o: $(UTILS_SRC)/xshm.h
+stairs.o: $(HACK_SRC)/xlockmore.h
stairs.o: ../../config.h
+stairs.o: $(HACK_SRC)/xlockmoreI.h
+stairs.o: $(HACK_SRC)/screenhack.h
+stairs.o: $(UTILS_SRC)/yarandom.h
+stairs.o: $(UTILS_SRC)/usleep.h
+stairs.o: $(UTILS_SRC)/resources.h
+stairs.o: $(UTILS_SRC)/hsv.h
+stairs.o: $(UTILS_SRC)/colors.h
+stairs.o: $(UTILS_SRC)/grabscreen.h
+stairs.o: $(UTILS_SRC)/visual.h
+stairs.o: $(UTILS_SRC)/xshm.h
stairs.o: $(srcdir)/e_textures.h
+superquadrics.o: $(HACK_SRC)/xlockmore.h
superquadrics.o: ../../config.h
+superquadrics.o: $(HACK_SRC)/xlockmoreI.h
+superquadrics.o: $(HACK_SRC)/screenhack.h
+superquadrics.o: $(UTILS_SRC)/yarandom.h
+superquadrics.o: $(UTILS_SRC)/usleep.h
+superquadrics.o: $(UTILS_SRC)/resources.h
+superquadrics.o: $(UTILS_SRC)/hsv.h
+superquadrics.o: $(UTILS_SRC)/colors.h
+superquadrics.o: $(UTILS_SRC)/grabscreen.h
+superquadrics.o: $(UTILS_SRC)/visual.h
+superquadrics.o: $(UTILS_SRC)/xshm.h
+swim.o: $(HACK_SRC)/xlockmoreI.h
+swim.o: $(HACK_SRC)/screenhack.h
swim.o: ../../config.h
+swim.o: $(UTILS_SRC)/yarandom.h
+swim.o: $(UTILS_SRC)/usleep.h
+swim.o: $(UTILS_SRC)/resources.h
+swim.o: $(UTILS_SRC)/hsv.h
+swim.o: $(UTILS_SRC)/colors.h
+swim.o: $(UTILS_SRC)/grabscreen.h
+swim.o: $(UTILS_SRC)/visual.h
+swim.o: $(UTILS_SRC)/xshm.h
swim.o: $(srcdir)/atlantis.h
whale.o: $(srcdir)/atlantis.h
+xlock-gl.o: $(HACK_SRC)/screenhack.h
xlock-gl.o: ../../config.h
+xlock-gl.o: $(UTILS_SRC)/yarandom.h
+xlock-gl.o: $(UTILS_SRC)/usleep.h
+xlock-gl.o: $(UTILS_SRC)/resources.h
+xlock-gl.o: $(UTILS_SRC)/hsv.h
+xlock-gl.o: $(UTILS_SRC)/colors.h
+xlock-gl.o: $(UTILS_SRC)/grabscreen.h
+xlock-gl.o: $(UTILS_SRC)/visual.h
+xlock-gl.o: $(HACK_SRC)/xlockmoreI.h
+xlock-gl.o: $(UTILS_SRC)/xshm.h
fps.o: ../../config.h
+fps.o: $(HACK_SRC)/screenhack.h
+fps.o: $(UTILS_SRC)/yarandom.h
+fps.o: $(UTILS_SRC)/usleep.h
+fps.o: $(UTILS_SRC)/resources.h
+fps.o: $(UTILS_SRC)/hsv.h
+fps.o: $(UTILS_SRC)/colors.h
+fps.o: $(UTILS_SRC)/grabscreen.h
+fps.o: $(UTILS_SRC)/visual.h
+fps.o: $(HACK_SRC)/xlockmoreI.h
+fps.o: $(UTILS_SRC)/xshm.h
xpm-ximage.o: ../../config.h
+glplanet.o: $(HACK_SRC)/xlockmore.h
glplanet.o: ../../config.h
+glplanet.o: $(HACK_SRC)/xlockmoreI.h
+glplanet.o: $(HACK_SRC)/screenhack.h
+glplanet.o: $(UTILS_SRC)/yarandom.h
+glplanet.o: $(UTILS_SRC)/usleep.h
+glplanet.o: $(UTILS_SRC)/resources.h
+glplanet.o: $(UTILS_SRC)/hsv.h
+glplanet.o: $(UTILS_SRC)/colors.h
+glplanet.o: $(UTILS_SRC)/grabscreen.h
+glplanet.o: $(UTILS_SRC)/visual.h
+glplanet.o: $(UTILS_SRC)/xshm.h
glplanet.o: $(srcdir)/sphere.h
glplanet.o: $(HACK_SRC)/images/earth.xbm
glplanet.o: $(srcdir)/xpm-ximage.h
+pulsar.o: $(HACK_SRC)/xlockmore.h
pulsar.o: ../../config.h
+pulsar.o: $(HACK_SRC)/xlockmoreI.h
+pulsar.o: $(HACK_SRC)/screenhack.h
+pulsar.o: $(UTILS_SRC)/yarandom.h
+pulsar.o: $(UTILS_SRC)/usleep.h
+pulsar.o: $(UTILS_SRC)/resources.h
+pulsar.o: $(UTILS_SRC)/hsv.h
+pulsar.o: $(UTILS_SRC)/colors.h
+pulsar.o: $(UTILS_SRC)/grabscreen.h
+pulsar.o: $(UTILS_SRC)/visual.h
+pulsar.o: $(UTILS_SRC)/xshm.h
extrusion.o: ../../config.h
+extrusion.o: $(HACK_SRC)/xlockmore.h
+extrusion.o: $(HACK_SRC)/xlockmoreI.h
+extrusion.o: $(HACK_SRC)/screenhack.h
+extrusion.o: $(UTILS_SRC)/yarandom.h
+extrusion.o: $(UTILS_SRC)/usleep.h
+extrusion.o: $(UTILS_SRC)/resources.h
+extrusion.o: $(UTILS_SRC)/hsv.h
+extrusion.o: $(UTILS_SRC)/colors.h
+extrusion.o: $(UTILS_SRC)/grabscreen.h
+extrusion.o: $(UTILS_SRC)/visual.h
+extrusion.o: $(UTILS_SRC)/xshm.h
extrusion-helix2.o: ../../config.h
extrusion-helix3.o: ../../config.h
extrusion-helix4.o: ../../config.h
extrusion-screw.o: ../../config.h
extrusion-taper.o: ../../config.h
extrusion-twistoid.o: ../../config.h
+sierpinski3d.o: $(HACK_SRC)/xlockmore.h
sierpinski3d.o: ../../config.h
+sierpinski3d.o: $(HACK_SRC)/xlockmoreI.h
+sierpinski3d.o: $(HACK_SRC)/screenhack.h
+sierpinski3d.o: $(UTILS_SRC)/yarandom.h
+sierpinski3d.o: $(UTILS_SRC)/usleep.h
+sierpinski3d.o: $(UTILS_SRC)/resources.h
+sierpinski3d.o: $(UTILS_SRC)/hsv.h
+sierpinski3d.o: $(UTILS_SRC)/colors.h
+sierpinski3d.o: $(UTILS_SRC)/grabscreen.h
+sierpinski3d.o: $(UTILS_SRC)/visual.h
+sierpinski3d.o: $(UTILS_SRC)/xshm.h
+gflux.o: $(HACK_SRC)/xlockmore.h
gflux.o: ../../config.h
+gflux.o: $(HACK_SRC)/xlockmoreI.h
+gflux.o: $(HACK_SRC)/screenhack.h
+gflux.o: $(UTILS_SRC)/yarandom.h
+gflux.o: $(UTILS_SRC)/usleep.h
+gflux.o: $(UTILS_SRC)/resources.h
+gflux.o: $(UTILS_SRC)/hsv.h
+gflux.o: $(UTILS_SRC)/colors.h
+gflux.o: $(UTILS_SRC)/grabscreen.h
+gflux.o: $(UTILS_SRC)/visual.h
+gflux.o: $(UTILS_SRC)/xshm.h
stonerview.o: ../../config.h
+stonerview.o: $(UTILS_SRC)/yarandom.h
stonerview.o: $(srcdir)/stonerview-move.h
stonerview-move.o: ../../config.h
+stonerview-move.o: $(UTILS_SRC)/yarandom.h
stonerview-move.o: $(srcdir)/stonerview-osc.h
stonerview-move.o: $(srcdir)/stonerview-move.h
stonerview-osc.o: ../../config.h
+stonerview-osc.o: $(UTILS_SRC)/yarandom.h
stonerview-osc.o: $(srcdir)/stonerview-osc.h
stonerview-view.o: ../../config.h
+stonerview-view.o: $(UTILS_SRC)/vroot.h
+stonerview-view.o: $(UTILS_SRC)/version.h
+stonerview-view.o: $(UTILS_SRC)/yarandom.h
stonerview-view.o: $(srcdir)/stonerview-osc.h
stonerview-view.o: $(srcdir)/stonerview-move.h
+starwars.o: $(HACK_SRC)/xlockmore.h
starwars.o: ../../config.h
+starwars.o: $(HACK_SRC)/xlockmoreI.h
+starwars.o: $(HACK_SRC)/screenhack.h
+starwars.o: $(UTILS_SRC)/yarandom.h
+starwars.o: $(UTILS_SRC)/usleep.h
+starwars.o: $(UTILS_SRC)/resources.h
+starwars.o: $(UTILS_SRC)/hsv.h
+starwars.o: $(UTILS_SRC)/colors.h
+starwars.o: $(UTILS_SRC)/grabscreen.h
+starwars.o: $(UTILS_SRC)/visual.h
+starwars.o: $(UTILS_SRC)/xshm.h
starwars.o: $(srcdir)/glutstroke.h
starwars.o: $(srcdir)/glut_roman.h
glut_stroke.o: ../../config.h
glut_stroke.o: $(srcdir)/glutstroke.h
glut_swidth.o: ../../config.h
glut_swidth.o: $(srcdir)/glutstroke.h
+gltext.o: $(HACK_SRC)/xlockmore.h
gltext.o: ../../config.h
+gltext.o: $(HACK_SRC)/xlockmoreI.h
+gltext.o: $(HACK_SRC)/screenhack.h
+gltext.o: $(UTILS_SRC)/yarandom.h
+gltext.o: $(UTILS_SRC)/usleep.h
+gltext.o: $(UTILS_SRC)/resources.h
+gltext.o: $(UTILS_SRC)/hsv.h
+gltext.o: $(UTILS_SRC)/colors.h
+gltext.o: $(UTILS_SRC)/grabscreen.h
+gltext.o: $(UTILS_SRC)/visual.h
+gltext.o: $(UTILS_SRC)/xshm.h
gltext.o: $(srcdir)/tube.h
gltext.o: $(srcdir)/glutstroke.h
gltext.o: $(srcdir)/glut_roman.h
+molecule.o: $(HACK_SRC)/xlockmore.h
molecule.o: ../../config.h
+molecule.o: $(HACK_SRC)/xlockmoreI.h
+molecule.o: $(HACK_SRC)/screenhack.h
+molecule.o: $(UTILS_SRC)/yarandom.h
+molecule.o: $(UTILS_SRC)/usleep.h
+molecule.o: $(UTILS_SRC)/resources.h
+molecule.o: $(UTILS_SRC)/hsv.h
+molecule.o: $(UTILS_SRC)/colors.h
+molecule.o: $(UTILS_SRC)/grabscreen.h
+molecule.o: $(UTILS_SRC)/visual.h
+molecule.o: $(UTILS_SRC)/xshm.h
molecule.o: $(srcdir)/sphere.h
molecule.o: $(srcdir)/tube.h
molecule.o: molecules.h
+dangerball.o: $(HACK_SRC)/xlockmore.h
dangerball.o: ../../config.h
+dangerball.o: $(HACK_SRC)/xlockmoreI.h
+dangerball.o: $(HACK_SRC)/screenhack.h
+dangerball.o: $(UTILS_SRC)/yarandom.h
+dangerball.o: $(UTILS_SRC)/usleep.h
+dangerball.o: $(UTILS_SRC)/resources.h
+dangerball.o: $(UTILS_SRC)/hsv.h
+dangerball.o: $(UTILS_SRC)/colors.h
+dangerball.o: $(UTILS_SRC)/grabscreen.h
+dangerball.o: $(UTILS_SRC)/visual.h
+dangerball.o: $(UTILS_SRC)/xshm.h
dangerball.o: $(srcdir)/sphere.h
dangerball.o: $(srcdir)/tube.h
sphere.o: ../../config.h
sphere.o: $(srcdir)/tube.h
tube.o: ../../config.h
tube.o: $(srcdir)/tube.h
+circuit.o: $(HACK_SRC)/xlockmore.h
+circuit.o: ../../config.h
+circuit.o: $(HACK_SRC)/xlockmoreI.h
+circuit.o: $(HACK_SRC)/screenhack.h
+circuit.o: $(UTILS_SRC)/yarandom.h
+circuit.o: $(UTILS_SRC)/usleep.h
+circuit.o: $(UTILS_SRC)/resources.h
+circuit.o: $(UTILS_SRC)/hsv.h
+circuit.o: $(UTILS_SRC)/colors.h
+circuit.o: $(UTILS_SRC)/grabscreen.h
+circuit.o: $(UTILS_SRC)/visual.h
+circuit.o: $(UTILS_SRC)/xshm.h
}
+/* jwz -- this doesn't really work very well.
+
+ All I want to do is give the tank a gradient-filled background, instead
+ of just solid blue. The following was my guess as to how to do this,
+ but it kills my frame rate. I guess there's a more efficient way to do
+ this, but I don't see it...
+
+ I mean, all I want to do is dump some non-projected bytes into the color
+ buffer, then zero out the depth buffer. That *can't* be expensive, can
+ it?
+ */
static void
clear_tank (atlantisstruct * ap)
{
--- /dev/null
+/*
+ * circuit - Random electronic components floating around
+ *
+ * version 1.3
+ *
+ * Since version 1.1: added to-220 transistor, added fuse
+ * Since version 1.2: random display digits, LED improvements (flickering)
+ *
+ * Copyright (C) 2001 Ben Buxton (bb@cactii.net)
+ *
+ * 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.
+ */
+
+/* Written over a few days in a (successful) bid to learn GL coding
+ *
+ * -seven option is dedicated to all the Slarkeners
+ *
+ * try "-rotate -rotate-speed 0"
+ *
+ * This hack uses lookup tables for sin, cos and tan - it can do a lot
+ */
+
+
+#include <X11/Intrinsic.h>
+
+#ifdef STANDALONE
+# define PROGCLASS "Circuit"
+# define HACK_INIT init_circuit
+# define HACK_DRAW draw_circuit
+# define HACK_RESHAPE reshape_circuit
+# define circuit_opts xlockmore_opts
+/* insert defaults here */
+
+#define DEF_SPIN "True"
+#define DEF_SEVEN "False"
+#define DEF_PARTS "10"
+
+
+#define DEFAULTS "*parts: " DEF_PARTS " \n" \
+ "*spin: " DEF_SPIN "\n" \
+ "*delay: 20000 \n" \
+ "*showFPS: False \n" \
+ "*seven: " DEF_SEVEN "\n" \
+ "*light: True \n" \
+ "*rotate: False\n" \
+ "*rotatespeed: 1\n" \
+
+# include "xlockmore.h" /* from the xscreensaver distribution */
+#else /* !STANDALONE */
+# include "xlock.h" /* from the xlockmore distribution */
+#endif /* !STANDALONE */
+
+/* lifted from lament.c */
+#define RAND(n) ((long) ((random() & 0x7fffffff) % ((long) (n))))
+#define RANDSIGN() ((random() & 1) ? 1 : -1)
+
+
+#ifdef USE_GL
+
+#include <GL/glu.h>
+
+
+static int maxparts;
+static int spin;
+static int seven;
+static int rotate;
+static int rotatespeed;
+static int uselight;
+int def_parts = 10;
+
+#undef countof
+#define countof(x) (sizeof((x))/sizeof((*x)))
+
+static XrmOptionDescRec opts[] = {
+ {"-parts", ".circuit.parts", XrmoptionSepArg, "10" },
+ {"-rotate-speed", ".circuit.rotatespeed", XrmoptionSepArg, "1" },
+ {"+spin", ".circuit.spin", XrmoptionNoArg, (caddr_t) "false" },
+ {"-spin", ".circuit.spin", XrmoptionNoArg, (caddr_t) "true" },
+ {"+light", ".circuit.light", XrmoptionNoArg, (caddr_t) "false" },
+ {"-light", ".circuit.light", XrmoptionNoArg, (caddr_t) "true" },
+ {"+seven", ".circuit.seven", XrmoptionNoArg, (caddr_t) "false" },
+ {"-seven", ".circuit.seven", XrmoptionNoArg, (caddr_t) "true" },
+ {"+rotate", ".circuit.rotate", XrmoptionNoArg, (caddr_t) "false" },
+ {"-rotate", ".circuit.rotate", XrmoptionNoArg, (caddr_t) "true" },
+};
+
+static argtype vars[] = {
+ {(caddr_t *) &maxparts, "parts", "Parts", DEF_PARTS, t_Int},
+ {(caddr_t *) &rotatespeed, "rotatespeed", "Rotatespeed", "1", t_Int},
+ {(caddr_t *) &spin, "spin", "Spin", DEF_SPIN, t_Bool},
+ {(caddr_t *) &rotate, "rotate", "Rotate", "False", t_Bool},
+ {(caddr_t *) &uselight, "light", "Light", "True", t_Bool},
+ {(caddr_t *) &seven, "seven", "Seven", DEF_SEVEN, t_Bool},
+};
+
+ModeSpecOpt circuit_opts = {countof(opts), opts, countof(vars), vars, NULL};
+
+#ifdef USE_MODULES
+ModStruct circuit_description =
+{"circuit", "init_circuit", "draw_circuit", "release_circuit",
+ "draw_circuit", "init_circuit", NULL, &circuit_opts,
+ 1000, 1, 2, 1, 4, 1.0, "",
+ "Flying electronic components", 0, NULL};
+
+#endif
+
+
+typedef struct {
+ GLXContext *glx_context;
+ Window window;
+} Circuit;
+
+static Circuit *circuit = NULL;
+
+#include <math.h>
+#include <sys/time.h>
+#include <stdio.h>
+#include <stdlib.h>
+
+#ifndef M_PI
+#define M_PI 3.14159265
+#endif
+
+/* window width, height */
+int win_w, win_h;
+
+/* width and height of viewport */
+
+#define XMAX 30
+#define YMAX 30
+
+#define MAX_COMPONENTS 30
+
+#define MOVE_MULT 0.05
+
+static float f_rand(void) {
+ return ((float)RAND(10000)/(float)10000);
+}
+
+#define RAND_RANGE(min, max) ((min) + (max - min) * f_rand())
+
+/* one lucky led gets to be a light source , unless -no-light*/
+int light = 0;
+int lighton = 0;
+
+static GLfloat viewer[] = {0.0, 0.0, 14.0};
+static GLfloat lightpos[] = {7.0, 7.0, 15, 1.0};
+
+float sin_table[720];
+float cos_table[720];
+float tan_table[720];
+
+
+/* Represents a band on a resistor/diode/etc */
+typedef struct {
+ float pos; /* relative position from start/previous band */
+ GLfloat r, g, b; /* colour of the band */
+ float len; /* length as a fraction of total length */
+} Band;
+
+typedef struct {
+ Band *b1, *b2, *b3, *b4; /* bands */
+ int b[4];
+} Resistor;
+
+typedef struct {
+ Band *band;
+ GLfloat r, g, b; /* body colour */
+} Diode;
+
+typedef struct {
+ int type; /* package type. 0 = to-92, 1 = to-220 */
+} Transistor;
+
+typedef struct {
+ GLfloat r,g,b; /* LED colour */
+ int light; /* are we the light source? */
+} LED;
+
+typedef struct {
+ int type; /* 0 = electro, 1 = ceramic */
+ float width; /* width of an electro/ceramic */
+ float length; /* length of an electro */
+} Capacitor;
+
+typedef struct {
+ int type; /* 0 = DIL, 1 = flat square */
+ int pins;
+} IC;
+
+/* 7 segment display */
+
+typedef struct {
+ int value; /* displayed number */
+} Disp;
+
+typedef struct {
+ GLfloat l, w;
+} Fuse;
+
+typedef struct {
+ GLfloat x, y, z; /* current co-ordinates */
+ GLfloat dx, dy, dz; /* current direction */
+ GLfloat rotx, roty, rotz; /* rotation vector */
+ GLfloat drot; /* rotation velocity (degrees per frame) */
+ int norm; /* Normalize this component (for shine) */
+ int rdeg; /* current rotation degrees */
+ int angle; /* angle about the z axis */
+ int alpha; /* 0 if not a transparent component */
+ int type; /* 0 = resistor, 1 = diode, 2 = transistor, 3 = LED, 4 = cap, 5=IC,
+ 6 = 7 seg disp */
+ void * c; /* pointer to the component */
+} Component;
+
+static int band_list[12];
+
+/* standard colour codes */
+
+static GLfloat colorcodes [12][3] = {
+ {0.0,0.0,0.0}, /* black 0 */
+ {0.49,0.25,0.08}, /* brown 1 */
+ {1.0,0.0,0.0}, /* red 2 */
+ {1.0,0.5,0.0}, /* orange 3 */
+ {1.0,1.0,0.0}, /* yellow 4 */
+ {0.0,1.0,0.0}, /* green 5 */
+ {0.0,0.5,1.0}, /* blue 6 */
+ {0.7,0.2,1.0}, /* violet 7 */
+ {0.5,0.5,0.5}, /* grey 8 */
+ {1.0,1.0,1.0}, /* white 9 */
+ {0.66,0.56,0.2}, /* gold 10 */
+ {0.8,0.8,0.8}, /* silver 11 */
+};
+
+/* base values for components - we can multiply by 0 - 1M */
+static int values [9][2] = {
+ {1,0},
+ {2,2},
+ {3,3},
+ {4,7},
+ {5,6},
+ {6,8},
+ {7,5},
+ {8,2},
+ {9,1}
+};
+
+void DrawResistor(Resistor *);
+void DrawDiode(Diode *);
+void DrawTransistor(Transistor *);
+void DrawLED(LED *);
+void DrawIC(IC *);
+void DrawCapacitor(Capacitor *);
+void DrawDisp(Disp *);
+void DrawFuse(Fuse *);
+
+void reorder(Component *[]);
+void circle(float, int,int);
+void bandedCylinder(float, float , GLfloat, GLfloat , GLfloat, Band **, int);
+Resistor *NewResistor(void);
+Diode *NewDiode(void);
+Transistor *NewTransistor(void);
+LED * NewLED(void);
+Capacitor *NewCapacitor(void);
+IC* NewIC(void);
+Disp* NewDisp(void);
+Fuse *NewFuse(void);
+
+/* we use trig tables to speed things up - 200 calls to sin()
+ in one frame can be a bit harsh..
+*/
+
+void make_tables(void) {
+int i;
+float f;
+
+ f = 360 / (M_PI * 2);
+ for (i = 0 ; i < 720 ; i++) {
+ sin_table[i] = sin(i/f);
+ }
+ for (i = 0 ; i < 720 ; i++) {
+ cos_table[i] = cos(i/f);
+ }
+ for (i = 0 ; i < 720 ; i++) {
+ tan_table[i] = tan(i/f);
+ }
+}
+
+
+void createCylinder (float length, float radius, int endcaps, int half) {
+int a; /* current angle around cylinder */
+int angle, norm;
+float z1, y1, z2, y2, ex;
+int nsegs;
+
+ glPushMatrix();
+ nsegs = radius*MAX(win_w, win_h)/10;
+ nsegs = MAX(nsegs, 6);
+ if (nsegs % 2)
+ nsegs += 1;
+ angle = (half) ? (180 - 90/nsegs) : 374;
+ z1 = radius; y1 = 0;
+ glBegin(GL_QUADS);
+ for (a = 0 ; a <= angle ; a+= angle/nsegs) {
+ y2=radius*(float)sin_table[(int)a];
+ z2=radius*(float)cos_table[(int)a];
+ glNormal3f(0, y1, z1);
+ glVertex3f(0,y1,z1);
+ glVertex3f(length,y1,z1);
+ glVertex3f(length,y2,z2);
+ glVertex3f(0,y2,z2);
+ z1=z2;
+ y1=y2;
+ }
+ glEnd();
+ if (half) {
+ glBegin(GL_POLYGON);
+ glNormal3f(0, 1, 0);
+ glVertex3f(0, 0, radius);
+ glVertex3f(length, 0, radius);
+ glVertex3f(length, 0, 0 - radius);
+ glVertex3f(0, 0, 0 - radius);
+ glEnd();
+ }
+ if (endcaps) {
+ for(ex = 0 ; ex <= length ; ex += length) {
+ z1 = radius; y1 = 0;
+ norm = (ex == length) ? 1 : -1;
+ for (a = 0 ; a <= angle ; a+= angle/nsegs) {
+ y2=radius*(float)sin_table[(int)a];
+ z2=radius*(float)cos_table[(int)a];
+ glBegin(GL_TRIANGLES);
+ glNormal3f(norm, 0, 0);
+ glVertex3f(ex,0, 0);
+ glVertex3f(ex,y1,z1);
+ glVertex3f(ex,y2,z2);
+ glEnd();
+ z1=z2;
+ y1=y2;
+ }
+ }
+ }
+ glPopMatrix();
+}
+
+void circle(float radius, int segments, int half) {
+float x1 = 0, x2 = 0;
+float y1 = 0, y2 = 0;
+int i, t, s;
+
+ if (half) {
+ t = 270; s = 90;
+ x1 = radius, y1 = 0;
+ } else {
+ t = 360, s = 0;
+ }
+ glBegin(GL_TRIANGLES);
+ glNormal3f(1, 0, 0);
+ for(i=s;i<=t;i+=10)
+ {
+ float angle=i;
+ x2=radius*(float)cos_table[(int)angle];
+ y2=radius*(float)sin_table[(int)angle];
+ glVertex3f(0,0,0);
+ glVertex3f(0,y1,x1);
+ glVertex3f(0,y2,x2);
+ x1=x2;
+ y1=y2;
+ }
+ glEnd();
+}
+
+void wire(float len) {
+static GLfloat col[] = {0.3, 0.3, 0.3, 1.0};
+static GLfloat spec[] = {0.9, 0.9, 0.9, 1.0};
+static GLfloat nospec[] = {0.4, 0.4, 0.4, 1.0};
+GLfloat shin = 30;
+int n;
+
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shin);
+ n = glIsEnabled(GL_NORMALIZE);
+ if (!n) glEnable(GL_NORMALIZE);
+ createCylinder(len, 0.05, 1, 0);
+ if (!n) glDisable(GL_NORMALIZE);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, nospec);
+}
+
+void ring(GLfloat inner, GLfloat outer, int nsegs) {
+GLfloat z1, z2, y1, y2;
+GLfloat Z1, Z2, Y1, Y2;
+int i;
+
+ z1 = inner; y1 = 0;
+ Z1 = outer; Y1 = 0;
+ glBegin(GL_QUADS);
+ glNormal3f(1, 0, 0);
+ for(i=0; i <=360 ; i+= 360/nsegs)
+ {
+ float angle=i;
+ z2=inner*(float)sin_table[(int)angle];
+ y2=inner*(float)cos_table[(int)angle];
+ Z2=outer*(float)sin_table[(int)angle];
+ Y2=outer*(float)cos_table[(int)angle];
+ glVertex3f(0, Y1, Z1);
+ glVertex3f(0, y1, z1);
+ glVertex3f(0, y2, z2);
+ glVertex3f(0, Y2, Z2);
+ z1=z2;
+ y1=y2;
+ Z1=Z2;
+ Y1=Y2;
+ }
+ glEnd();
+}
+
+void sphere(GLfloat r, float stacks, float slices,
+ int startstack, int endstack, int startslice,
+ int endslice) {
+GLfloat d, d1, dr, dr1, Dr, Dr1, D, D1, z1, z2, y1, y2, Y1, Z1, Y2, Z2;
+int a, a1, b, b1, c, c1;
+GLfloat step, sstep;
+
+ step = 180/stacks;
+ sstep = 360/slices;
+ a1 = startstack * step;
+ b1 = startslice * sstep;
+ y1 = z1 = Y1 = Z1 = 0;
+ c = (endslice / slices) * 360;
+ c1 = (endstack/stacks)*180;
+ glBegin(GL_QUADS);
+ for (a = startstack * step ; a <= c1 ; a+= step) {
+ d=sin_table[a];
+ d1=sin_table[a1];
+ D=cos_table[a];
+ D1=cos_table[a1];
+ dr = d * r;
+ dr1 = d1 * r;
+ Dr = D * r;
+ Dr1 = D1 * r;
+ for (b = b1 ; b <= c ; b+= sstep) {
+ y2=dr*sin_table[b];
+ z2=dr*cos_table[b];
+ Y2=dr1*sin_table[b];
+ Z2=dr1*cos_table[b];
+ glNormal3f(D, y1, z1);
+ glVertex3f(Dr,y1,z1);
+ glVertex3f(Dr,y2,z2);
+ glVertex3f(Dr1,Y2,Z2);
+ glVertex3f(Dr1,Y1,Z1);
+ z1=z2;
+ y1=y2;
+ Z1=Z2;
+ Y1=Y2;
+ }
+ a1 = a;
+ }
+ glEnd();
+}
+
+int DrawComponent(Component *c) {
+int ret = 0; /* return 1 if component is freed */
+
+ glPushMatrix();
+ glTranslatef(c->x, c->y, c->z);
+ if (c->angle > 0) {
+ glRotatef(c->angle, 0, 0, 1);
+ }
+ if (spin) {
+ glRotatef(c->rdeg, c->rotx, c->roty, c->rotz);
+ c->rdeg += c->drot;
+ }
+
+ if (c->norm)
+ glEnable(GL_NORMALIZE);
+ else
+ glDisable(GL_NORMALIZE);
+
+ /* call object draw routine here */
+ if (c->type == 0) {
+ DrawResistor(c->c);
+ } else if (c->type == 1) {
+ DrawDiode(c->c);
+ } else if (c->type == 2) {
+ DrawTransistor(c->c);
+ } else if (c->type == 3) {
+ if (((LED *)c->c)->light && light) {
+ GLfloat lp[] = {0.1, 0, 0, 1};
+ glEnable(GL_LIGHT1);
+ glLightfv(GL_LIGHT1, GL_POSITION, lp);
+ }
+ DrawLED(c->c);
+ } else if (c->type == 4) {
+ DrawCapacitor(c->c);
+ } else if (c->type == 5) {
+ DrawIC(c->c);
+ } else if (c->type == 6) {
+ DrawDisp(c->c);
+ } else if (c->type == 7) {
+ DrawFuse(c->c);
+ }
+ c->x += c->dx * MOVE_MULT;
+ c->y += c->dy * MOVE_MULT;
+ if (c->x > XMAX/2 || c->x < 0 - XMAX/2 ||
+ c->y > YMAX/2 || c->y < 0 - YMAX/2) {
+ if (c->type == 3 && ((LED *)c->c)->light && light) {
+ glDisable(GL_LIGHT1);
+ light = 0; lighton = 0;
+ }
+ free(c->c);
+ ret = 1;
+ }
+
+ glPopMatrix();
+ glDisable(GL_NORMALIZE);
+ return ret;
+}
+/* draw a resistor */
+
+void DrawResistor(Resistor *r) {
+int i;
+GLfloat col[] = {0.74, 0.62, 0.46, 1.0};
+GLfloat spec[] = {0.8, 0.8, 0.8, 1.0};
+GLfloat shine = 30;
+
+ glTranslatef(-4, 0, 0);
+ wire(3);
+ glTranslatef(3, 0, 0);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shine);
+ createCylinder(1.8, 0.4, 1, 0);
+ glPushMatrix();
+ for (i = 0 ; i < 4 ; i++) {
+ glTranslatef(0.35, 0, 0);
+ glCallList(band_list[r->b[i]]);
+ }
+ glPopMatrix();
+ glTranslatef(1.8, 0, 0);
+ wire(3);
+}
+
+void DrawFuse(Fuse *f) {
+static GLfloat col[] = {0.5, 0.5, 0.5, 1.0}; /* endcaps */
+static GLfloat glass[] = {0.4, 0.4, 0.4, 0.3}; /* glass */
+static GLfloat spec[] = {1, 1, 1, 1}; /* glass */
+
+ glPushMatrix();
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMateriali(GL_FRONT, GL_SHININESS, 40);
+ createCylinder(0.8, 0.45, 1, 0);
+ glTranslatef(0.8, 0, 0);
+ glEnable(GL_BLEND);
+ glDepthMask(GL_FALSE);
+ glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, glass);
+ glMateriali(GL_FRONT_AND_BACK, GL_SHININESS, 40);
+ createCylinder(2, 0.4, 0, 0);
+ createCylinder(2, 0.3, 0, 0);
+ glDisable(GL_BLEND);
+ glDepthMask(GL_TRUE);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMateriali(GL_FRONT, GL_SHININESS, 40);
+ glBegin(GL_LINES);
+ glVertex3f(0, 0, 0);
+ glVertex3f(2, 0. ,0);
+ glEnd();
+ glTranslatef(2, 0, 0);
+ createCylinder(0.8, 0.45, 1, 0);
+ glPopMatrix();
+}
+
+
+void DrawCapacitor(Capacitor *c) {
+static GLfloat col[] = {0, 0, 0, 0};
+static GLfloat spec[] = {0.8, 0.8, 0.8, 0};
+GLfloat brown[] = {0.84, 0.5, 0};
+static GLfloat shine = 40;
+
+ glPushMatrix();
+ if (c->type) {
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, brown);
+ sphere(c->width, 20, 20, 0, 5 ,0, 20);
+ glTranslatef(1.45*c->width, 0, 0);
+ sphere(c->width, 20, 20, 15, 20, 0, 20);
+ glRotatef(90, 0, 0, 1);
+ glTranslatef(0, 0.7*c->width, 0.3*c->width);
+ wire(3*c->width);
+ glTranslatef(0, 0, -0.6*c->width);
+ wire(3*c->width);
+ } else {
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, &shine);
+ glBegin(GL_POLYGON);
+ glVertex3f(0, 0.82*c->width, -0.1);
+ glVertex3f(3*c->length, 0.82*c->width, -0.1);
+ glVertex3f(3*c->length, 0.82*c->width, 0.1);
+ glVertex3f(0, 0.82*c->width, 0.1);
+ glEnd();
+ col[0] = 0.7;
+ col[1] = 0.7;
+ col[2] = 0.7;
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ circle(0.6*c->width, 30, 0);
+ col[0] = 0.0;
+ col[1] = 0.2;
+ col[2] = 0.9;
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ ring(0.6*c->width, 0.8*c->width, 30);
+ glTranslatef(0.01, 0.0, 0);
+ createCylinder(3.0*c->length, 0.8*c->width, 1, 0);
+ col[0] = 0;
+ col[1] = 0;
+ col[2] = 0;
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ glTranslatef(3.01*c->length, 0.0, 0);
+ circle(0.6*c->width, 30, 0);
+ glTranslatef(0, 0.4*c->width, 0);
+ wire(3*c->length);
+ glTranslatef(0.0, -0.8*c->width, 0);
+ wire(3.3*c->length);
+ }
+ glPopMatrix();
+}
+
+void DrawLED(LED *l) {
+GLfloat col[] = {0, 0, 0, 0.6};
+
+ col[0] = l->r; col[1] = l->g; col[2] = l->b;
+ if (l->light && light) {
+ GLfloat dir[] = {-1, 0, 0};
+ glLightfv(GL_LIGHT1, GL_SPOT_DIRECTION, dir);
+ if (!lighton) {
+ glLightfv(GL_LIGHT1, GL_SPECULAR, col);
+ glLightfv(GL_LIGHT1, GL_AMBIENT, col);
+ glLightfv(GL_LIGHT1, GL_DIFFUSE, col);
+ glLighti(GL_LIGHT1, GL_SPOT_CUTOFF, (GLint) 90);
+ glLighti(GL_LIGHT1, GL_CONSTANT_ATTENUATION, (GLfloat)1);
+ glLighti(GL_LIGHT1, GL_LINEAR_ATTENUATION, (GLfloat)0);
+ glLighti(GL_LIGHT1, GL_QUADRATIC_ATTENUATION, (GLfloat)0);
+ glLighti(GL_LIGHT1, GL_SPOT_EXPONENT, (GLint) 20);
+ lighton = 1;
+ }
+ }
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, col);
+ /* no transparency when LED is lit */
+ if (!l->light) {
+ glEnable(GL_BLEND);
+ glDepthMask(GL_FALSE);
+ glBlendFunc(GL_ONE_MINUS_SRC_ALPHA, GL_SRC_ALPHA);
+ }
+ createCylinder(1.2, 0.3, 0, 0);
+ if (l->light && light) {
+ glDisable(GL_LIGHTING);
+ glColor3fv(col);
+ }
+ sphere(0.3, 10, 10, 5, 10, 0, 10);
+ if (l->light && light) {
+ glEnable(GL_LIGHTING);
+ } else {
+ glDepthMask(GL_TRUE);
+ glDisable(GL_BLEND);
+ }
+
+ glTranslatef(1.2, 0, 0);
+ createCylinder(0.1, 0.38, 1, 0);
+ glTranslatef(-0.3, 0.15, 0);
+ wire(3);
+ glTranslatef(0, -0.3, 0);
+ wire(3.3);
+ if (random() % 50 == 25) {
+ if (l->light) {
+ l->light = 0; light = 0; lighton = 0;
+ glDisable(GL_LIGHT1);
+ } else if (!light) {
+ l->light = 1; light = 1;
+ }
+ }
+}
+
+
+
+void DrawDiode(Diode *d) {
+GLfloat shine = 40;
+GLfloat col[] = {0.3, 0.3, 0.3, 0};
+GLfloat spec[] = {0.7, 0.7, 0.7, 0};
+
+ glPushMatrix();
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shine);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glTranslatef(-4, 0, 0);
+ wire(3);
+ glTranslatef(3, 0, 0);
+ bandedCylinder(0.3, 1.5, d->r, d->g, d->b, &(d->band), 1);
+ glTranslatef(1.5, 0, 0);
+ wire(3);
+ glPopMatrix();
+}
+
+void Rect(GLfloat x, GLfloat y, GLfloat z, GLfloat w, GLfloat h,
+ GLfloat t) {
+GLfloat yh;
+GLfloat xw;
+GLfloat zt;
+
+ yh = y+h; xw = x+w; zt = z - t;
+
+ glBegin(GL_QUADS); /* front */
+ glNormal3f(0, 0, 1);
+ glVertex3f(x, y, z);
+ glVertex3f(x, yh, z);
+ glVertex3f(xw, yh, z);
+ glVertex3f(xw, y, z);
+ /* back */
+ glNormal3f(0, 0, -1);
+ glVertex3f(x, y, zt);
+ glVertex3f(x, yh, zt);
+ glVertex3f(xw, yh, zt);
+ glVertex3f(xw, y, zt);
+ /* top */
+ glNormal3f(0, 1, 0);
+ glVertex3f(x, yh, z);
+ glVertex3f(x, yh, zt);
+ glVertex3f(xw, yh, zt);
+ glVertex3f(xw, yh, z);
+ /* bottom */
+ glNormal3f(0, -1, 0);
+ glVertex3f(x, y, z);
+ glVertex3f(x, y, zt);
+ glVertex3f(xw, y, zt);
+ glVertex3f(xw, y, z);
+ /* left */
+ glNormal3f(-1, 0, 0);
+ glVertex3f(x, y, z);
+ glVertex3f(x, y, zt);
+ glVertex3f(x, yh, zt);
+ glVertex3f(x, yh, z);
+ /* right */
+ glNormal3f(1, 0, 0);
+ glVertex3f(xw, y, z);
+ glVertex3f(xw, y, zt);
+ glVertex3f(xw, yh, zt);
+ glVertex3f(xw, yh, z);
+ glEnd();
+}
+
+/* IC pins */
+
+void ICLeg(GLfloat x, GLfloat y, GLfloat z, int dir) {
+
+
+ if (dir) {
+ Rect(x-0.1, y, z, 0.1, 0.1, 0.02);
+ Rect(x-0.1, y, z, 0.02, 0.1, 0.1);
+ Rect(x-0.1, y+0.03, z-0.1, 0.02, 0.05, 0.3);
+ } else {
+ Rect(x, y, z, 0.1, 0.1, 0.02);
+ Rect(x+0.8*0.1, y, z, 0.02, 0.1, 0.1);
+ Rect(x+0.8*0.1, y+0.03, z-0.1, 0.02, 0.05, 0.3);
+ }
+
+}
+
+
+void DrawIC(IC *c) {
+GLfloat w, h, d;
+int z;
+GLfloat col[] = {0.1, 0.1, 0.1, 0};
+GLfloat spec[] = {0.6, 0.6, 0.6, 0};
+GLfloat shine = 40;
+GLfloat lspec[] = {0.6, 0.6, 0.6, 0};
+GLfloat lcol[] = {0.4, 0.4, 0.4, 0};
+GLfloat lshine = 40;
+
+ glPushMatrix();
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shine);
+ switch(c->pins) {
+ case 8:
+ w = 1.0; h = 1.5;
+ break;
+ case 14:
+ w = 1.0; h = 3;
+ break;
+ case 16:
+ w = 1.0; h = 3;
+ break;
+ case 24:
+ default:
+ w = 1.5; h = 3.5;
+ break;
+ }
+ w = w/2; h = h/2;
+ glBegin(GL_QUADS);
+ glNormal3f(0, 0, 1);
+ glVertex3f(w, h, 0.1);
+ glVertex3f(w, -h, 0.1);
+ glVertex3f(-w, -h, 0.1);
+ glVertex3f(-w, h, 0.1);
+ glNormal3f(0, 0, -1);
+ glVertex3f(w, h, -0.1);
+ glVertex3f(w, -h, -0.1);
+ glVertex3f(-w, -h, -0.1);
+ glVertex3f(-w, h, -0.1);
+ glNormal3f(1, 0, 0);
+ glVertex3f(w, h, -0.1);
+ glVertex3f(w, -h, -0.1);
+ glVertex3f(w, -h, 0.1);
+ glVertex3f(w, h, 0.1);
+ glNormal3f(0, -1, 0);
+ glVertex3f(w, -h, -0.1);
+ glVertex3f(w, -h, 0.1);
+ glVertex3f(-w, -h, 0.1);
+ glVertex3f(-w, -h, -0.1);
+ glNormal3f(-1, 0, 0);
+ glVertex3f(-w, h, -0.1);
+ glVertex3f(-w, h, 0.1);
+ glVertex3f(-w, -h, 0.1);
+ glVertex3f(-w, -h, -0.1);
+ glNormal3f(0, -1, 0);
+ glVertex3f(-w, h, -0.1);
+ glVertex3f(w, h, -0.1);
+ glVertex3f(w, h, 0.1);
+ glVertex3f(-w, h, 0.1);
+ glEnd();
+ d = (h*2-0.1) / c->pins;
+ d*=2;
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, lcol);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, lspec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &lshine);
+ for (z = 0 ; z < c->pins/2 ; z++) {
+ ICLeg(w, -h + z*d + d/2, 0, 0);
+ }
+ for (z = 0 ; z < c->pins/2 ; z++) {
+ ICLeg(-w, -h + z*d + d/2, 0, 1);
+ }
+ glPopMatrix();
+}
+
+void DrawDisp(Disp *d) {
+GLfloat col[] = {0.8, 0.8, 0.8, 1.0}; /* body colour */
+GLfloat front[] = {0.2, 0.2, 0.2, 1.0}; /* front colour */
+GLfloat on[] = {0.9, 0, 0, 1}; /* 'on' segment */
+GLfloat off[] = {0.3, 0, 0, 1}; /* 'off' segment */
+int i, j, k;
+GLfloat x, y; /* for the pins */
+GLfloat spec[] = {0.6, 0.6, 0.6, 0};
+GLfloat lcol[] = {0.4, 0.4, 0.4, 0};
+GLfloat shine = 40;
+static GLfloat vdata_h[6][2] =
+{
+ {0, 0},
+ {0.1, 0.1},
+ {0.9, 0.1},
+ {1, 0},
+ {0.9, -0.1},
+ {0.1, -0.1}
+};
+static GLfloat vdata_v[6][2] =
+{
+ {0.27, 0},
+ {0.35, -0.1},
+ {0.2, -0.9},
+ {0.1, -1},
+ {0, -0.9},
+ {0.15, -0.15}
+};
+
+static GLfloat seg_start[7][2] =
+{
+
+ {0.55, 2.26},
+ {1.35, 2.26},
+ {1.2, 1.27},
+ {0.25, 0.25},
+ {0.06, 1.25},
+ {0.25, 2.25},
+ {0.39, 1.24}
+};
+
+static int nums[10][7] =
+{
+ {1, 1, 1, 1, 1, 1, 0}, /* 0 */
+ {0, 1, 1, 0, 0, 0, 0}, /* 1 */
+ {1, 1, 0, 1, 1, 0, 1}, /* 2 */
+ {1, 1, 1, 1, 0, 0, 1}, /* 3 */
+ {0, 1, 1, 0, 0, 1, 1}, /* 4 */
+ {1, 0, 1, 1, 0, 1, 1}, /* 5 */
+ {1, 0, 1, 1, 1, 1, 1}, /* 6 */
+ {1, 1, 1, 0, 0, 0, 0}, /* 7 */
+ {1, 1, 1, 1, 1, 1, 1}, /* 8 */
+ {1, 1, 1, 0, 0, 1, 1} /* 9 */
+};
+
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ Rect(0, 0, -0.01, 1.8, 2.6, 0.7);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, front);
+ glBegin(GL_QUADS);
+ glVertex2f(-0.05, -0.05);
+ glVertex2f(-0.05, 2.65);
+ glVertex2f(1.85, 2.65);
+ glVertex2f(1.85, -0.05);
+ glEnd();
+ glDisable(GL_LIGHTING); /* lit segments dont need light */
+ if (!seven && (random() % 30) == 19) { /* randomly change value */
+ d->value = random() % 10;
+ }
+ for (j = 0 ; j < 7 ; j++) { /* draw the segments */
+ GLfloat xx[6], yy[6];
+ if (nums[d->value][j])
+ glColor3fv(on);
+ else
+ glColor3fv(off);
+ for (k = 0 ; k < 6 ; k++) {
+ if (j == 0 || j == 3 || j == 6) {
+ xx[k] = seg_start[j][0] + vdata_h[k][0];
+ yy[k] = seg_start[j][1] + vdata_h[k][1];
+ } else {
+ xx[k] = seg_start[j][0] + vdata_v[k][0];
+ yy[k] = seg_start[j][1] + vdata_v[k][1];
+ }
+ }
+ glBegin(GL_POLYGON);
+ for(i = 0 ; i < 6 ; i++) {
+ glVertex3f(xx[i], yy[i], 0.01);
+ }
+ glEnd();
+ }
+ glColor3fv(on);
+ glPointSize(4);
+ glBegin(GL_POINTS);
+ glVertex3f(1.5, 0.2, 0.01);
+ glEnd();
+ glEnable(GL_LIGHTING);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, lcol);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shine);
+ for (x = 0.35 ; x <= 1.5 ; x+= 1.15) {
+ for ( y = 0.2 ; y <= 2.4 ; y += 0.3) {
+ ICLeg(x, y, -0.7, 1);
+ }
+ }
+}
+
+void HoledRectangle(GLfloat w, GLfloat h, GLfloat d, GLfloat radius, int p) {
+int step, a;
+GLfloat x1, y1, x2, y2;
+GLfloat yr, yr1, xr, xr1, side, side1;
+GLfloat nx, ny;
+
+ step = 360 / p;
+ x1 = radius; y1 = 0;
+ xr1 = w/2; yr1 = 0;
+ side = w/2;
+ side1 = h/2;
+ glBegin(GL_QUADS);
+ for (a = 0 ; a <= 360 ; a+= step) {
+ y2=radius*(float)sin_table[(int)a];
+ x2=radius*(float)cos_table[(int)a];
+
+ if (a < 45 || a > 315) {
+ xr = side;
+ yr = side1 * tan_table[a];
+ nx = 1; ny = 0;
+ } else if (a <= 135 || a >= 225) {
+ xr = side/tan_table[a];
+ if (a >= 225) {
+ yr = -side1;
+ xr = 0 - xr;
+ nx = 0; ny = -1;
+ } else {
+ yr = side1;
+ nx = 0; ny = 1;
+ }
+ } else {
+ xr = -side;
+ yr = -side1 * tan_table[a];
+ nx = -1; ny = 0;
+ }
+
+ glNormal3f(-x1, -y1, 0); /* cylinder */
+ glVertex3f(x1,y1,0);
+ glVertex3f(x1,y1,-d);
+ glVertex3f(x2,y2,-d);
+ glVertex3f(x2,y2,0);
+
+ glNormal3f(0, 0, 1); /* front face */
+ glVertex3f(x1,y1,0);
+ glVertex3f(xr1, yr1, 0);
+ glVertex3f(xr, yr, 0);
+ glVertex3f(x2, y2, 0);
+
+ glNormal3f(nx, ny, 0); /* side */
+ glVertex3f(xr, yr, 0);
+ glVertex3f(xr, yr, -d);
+ glVertex3f(xr1, yr1, -d);
+ glVertex3f(xr1, yr1, 0);
+
+ glNormal3f(0, 0, -1); /* back */
+ glVertex3f(xr, yr, -d);
+ glVertex3f(x2, y2, -d);
+ glVertex3f(x1, y1, -d);
+ glVertex3f(xr1, yr1, -d);
+
+ x1=x2;
+ y1=y2;
+ xr1 = xr; yr1 = yr;
+ }
+ glEnd();
+}
+
+void DrawTransistor(Transistor *t) {
+static GLfloat col[] = {0.3, 0.3, 0.3, 1.0};
+static GLfloat spec[] = {0.9, 0.9, 0.9, 1.0};
+static GLfloat nospec[] = {0.4, 0.4, 0.4, 1.0};
+GLfloat shin = 30;
+
+ glPushMatrix();
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shin);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, col);
+ if (t->type == 1) {
+ glRotatef(90, 0, 1, 0);
+ glRotatef(90, 0, 0, 1);
+ createCylinder(1.0, 0.4, 1, 1);
+ Rect(0, -0.2, 0.4, 1, 0.2, 0.8);
+ glTranslatef(-2, 0, -0.2);
+ wire(2);
+ glTranslatef(0, 0, 0.2);
+ wire(2);
+ glTranslatef(0, 0, 0.2);
+ wire(2);
+ } else {
+ Rect(0, 0, 0, 1.5, 1.5, 0.75);
+ glTranslatef(0.75, 1.875, -0.5);
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT, GL_SHININESS, &shin);
+ if (glIsEnabled(GL_NORMALIZE)) glEnable(GL_NORMALIZE);
+ HoledRectangle(1.5, 0.75, 0.25, 0.2, 8);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, nospec);
+ glTranslatef(-0.375, -1.875, 0);
+ glRotatef(90, 0, 0, -1);
+ wire(2);
+ glTranslatef(0, 0.375, 0);
+ wire(2);
+ glTranslatef(0, 0.375, 0);
+ wire(2);
+ }
+ glPopMatrix();
+}
+
+Component * NewComponent(void) {
+Component *c;
+float rnd;
+
+ c = malloc(sizeof(Component));
+ c->angle = RAND_RANGE(0,360);
+ rnd = f_rand();
+ if (rnd < 0.25) { /* come from the top */
+ c->y = YMAX/2;
+ c->x = RAND_RANGE(0, XMAX) - XMAX/2;
+ if (c->x > 0)
+ c->dx = 0 - RAND_RANGE(0.5, 2);
+ else
+ c->dx = RAND_RANGE(0.5, 2);
+ c->dy = 0 - RAND_RANGE(0.5, 2);
+ } else if (rnd < 0.5) { /* come from the bottom */
+ c->y = 0 - YMAX/2;
+ c->x = RAND_RANGE(0, XMAX) - XMAX/2;
+ if (c->x > 0)
+ c->dx = 0 - RAND_RANGE(0.5, 2);
+ else
+ c->dx = RAND_RANGE(0.5, 2);
+ c->dy = RAND_RANGE(0.5, 2);
+ } else if (rnd < 0.75) { /* come from the left */
+ c->x = 0 - XMAX/2;
+ c->y = RAND_RANGE(0, YMAX) - YMAX/2;
+ c->dx = RAND_RANGE(0.5, 2);
+ if (c->y > 0)
+ c->dy = 0 - RAND_RANGE(0.5, 2);
+ else
+ c->dy = RAND_RANGE(0.5, 2);
+ } else { /* come from the right */
+ c->x = XMAX/2;
+ c->y = RAND_RANGE(0, YMAX) - YMAX/2;
+ c->dx = 0 - RAND_RANGE(0.5, 2);
+ if (c->y > 0)
+ c->dy = 0 - RAND_RANGE(0.5, 2);
+ else
+ c->dy = RAND_RANGE(0.5, 2);
+ }
+ c->z = RAND_RANGE(0, 7) - 9;
+ c->rotx = f_rand();
+ c->roty = f_rand();
+ c->rotz = f_rand();
+ c->drot = f_rand() * 7;
+ c->rdeg = 0;
+ c->dz = f_rand()*2 - 1;
+ c->norm = 0;
+ c->alpha = 0; /* explicitly set to 1 later */
+ rnd = f_rand();
+ if (rnd < 0.1) {
+ c->c = NewResistor();
+ c->type = 0;
+ if (f_rand() < 0.4)
+ c->norm = 1; /* some resistors shine */
+ } else if (rnd < 0.2) {
+ c->c = NewDiode();
+ if (f_rand() < 0.4)
+ c->norm = 1; /* some diodes shine */
+ c->type = 1;
+ } else if (rnd < 0.3) {
+ c->c = NewTransistor();
+ c->norm = 1;
+ c->type = 2;
+ } else if (rnd < 0.4) {
+ c->c = NewCapacitor();
+ if (f_rand() < 0.4)
+ c->norm = 1; /* some capacitors shine */
+ c->type = 4;
+ } else if (rnd < 0.6) {
+ c->c = NewIC();
+ c->type = 5;
+ } else if (rnd < 0.7) {
+ c->c = NewLED();
+ c->type = 3;
+ c->norm = 1;
+ c->alpha = 1;
+ } else if (rnd < 0.8) {
+ c->c = NewFuse();
+ c->norm = 1;
+ c->type = 7;
+ c->alpha = 1;
+ } else {
+ c->c = NewDisp();
+ c->type = 6;
+ }
+ return c;
+}
+
+Transistor *NewTransistor(void) {
+Transistor *t;
+
+ t = malloc(sizeof(Transistor));
+ t->type = (f_rand() < 0.5);
+ return t;
+}
+
+Capacitor *NewCapacitor(void) {
+Capacitor *c;
+
+ c = malloc(sizeof(Capacitor));
+ c->type = (f_rand() < 0.5);
+ if (!c->type) {
+ c->length = RAND_RANGE(0.5, 1);
+ c->width = RAND_RANGE(0.5, 1);
+ } else {
+ c->width = RAND_RANGE(1, 2);
+ }
+ return c;
+}
+
+/* 7 segment display */
+
+Disp *NewDisp(void) {
+Disp *d;
+
+ d = malloc(sizeof(Disp));
+ if (seven)
+ d->value = 7;
+ else
+ d->value = RAND_RANGE(0, 10);
+ return d;
+}
+
+
+IC *NewIC(void) {
+IC *c;
+int pins;
+
+ c = malloc(sizeof(IC));
+ c->type = 0;
+ switch((int)RAND_RANGE(0,4)) {
+ case 0:
+ pins = 8;
+ break;
+ case 1:
+ pins = 14;
+ break;
+ case 2:
+ pins = 16;
+ break;
+ case 3:
+ default:
+ pins = 24;
+ break;
+ }
+ c->pins = pins;
+ return c;
+}
+
+LED *NewLED(void) {
+LED *l;
+float r;
+
+ l = malloc(sizeof(LED));
+ r = f_rand();
+ l->light = 0;
+ if (!light && (f_rand() < 0.4)) {
+ light = 1;
+ l->light = 1;
+ }
+ if (r < 0.2) {
+ l->r = 0.9; l->g = 0; l->b = 0;
+ } else if (r < 0.4) {
+ l->r = 0.3; l->g = 0.9; l->b = 0;
+ } else if (r < 0.6) {
+ l->r = 0.8; l->g = 0.9; l->b = 0;
+ } else if (r < 0.8) {
+ l->r = 0.0; l->g = 0.2; l->b = 0.8;
+ } else {
+ l->r = 0.9, l->g = 0.55, l->b = 0;
+ }
+ return l;
+}
+
+Fuse *NewFuse(void) {
+Fuse *f;
+
+ f = malloc(sizeof(Fuse));
+ return f;
+}
+
+Diode *NewDiode(void) {
+Band *b;
+Diode *ret;
+
+ ret = malloc(sizeof(Diode));
+ b = malloc(sizeof(Band));
+ b->pos = 0.8;
+ b->len = 0.1;
+ if (f_rand() < 0.5) {
+ b->r = 1;
+ b->g = 1;
+ b->b = 1;
+ ret->r = 0.7; ret->g = 0.1 ; ret->b = 0.1;
+ } else {
+ b->r = 1;
+ b->g = 1;
+ b->b = 1;
+ ret->r = 0.2; ret->g = 0.2 ; ret->b = 0.2;
+ }
+ ret->band = b;
+ return ret;
+}
+
+
+Resistor * NewResistor(void) {
+int v, m, t; /* value, multiplier, tolerance */
+Resistor *ret;
+
+ v = RAND(9);
+ m = RAND(5);
+ t = (RAND(10) < 5) ? 10 : 11;
+ ret = malloc(sizeof(Resistor));
+
+ if (seven) {
+ ret->b[0] = ret->b[1] = ret->b[2] = 7;
+ } else {
+ ret->b[0] = values[v][0];
+ ret->b[1] = values[v][1];
+ ret->b[2] = m;
+ }
+ ret->b[3] = t;
+
+ return ret;
+}
+
+void makebandlist(void) {
+int i;
+GLfloat col[] = {0,0,0,0};
+GLfloat spec[] = {0.8,0.8,0.8,0};
+GLfloat shine = 40;
+
+ for (i = 0 ; i < 12 ; i++) {
+ band_list[i] = glGenLists(i);
+ glNewList(band_list[i], GL_COMPILE);
+ col[0] = colorcodes[i][0];
+ col[1] = colorcodes[i][1];
+ col[2] = colorcodes[i][2];
+ glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, col);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, spec);
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, &shine);
+ createCylinder(0.1, 0.42, 0, 0);
+ glEndList();
+ }
+}
+
+
+void bandedCylinder(float radius, float l, GLfloat r, GLfloat g, GLfloat bl,
+ Band **b, int nbands) {
+int n; /* band number */
+int p = 0; /* prev number + 1; */
+GLfloat col[] = {0,0,0,0};
+
+ col[0] = r; col[1] = g; col[2] = bl;
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ createCylinder(l, radius, 1, 0); /* body */
+ for (n = 0 ; n < nbands ; n++) {
+ glPushMatrix();
+ glTranslatef(b[n]->pos*l, 0, 0);
+ col[0] = b[n]->r; col[1] = b[n]->g; col[2] = b[n]->b;
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, col);
+ createCylinder(b[n]->len*l, radius*1.05, 0, 0); /* band */
+ glPopMatrix();
+ p = n+1;
+ }
+}
+
+void drawgrid(void) {
+GLfloat x, y;
+static GLfloat col[] = {0, 0.25, 0.05};
+static GLfloat col2[] = {0, 0.125, 0.05};
+GLfloat col3[] = {0, 0.8, 0};
+static GLfloat sx, sy; /* bright spot co-ords */
+static int sdir; /* 0 = left-right, 1 = right-left, 2 = up->dn, 3 = dn->up */
+static int s = 0; /* if spot is enabled */
+static float ds; /* speed of spot */
+
+ if (!s) {
+ if (f_rand() < ((rotate) ? 0.05 : 0.01)) {
+ sdir = RAND_RANGE(0, 4);
+ ds = RAND_RANGE(0.4, 0.8);
+ switch (sdir) {
+ case 0:
+ sx = -XMAX/2;
+ sy = ((int)RAND_RANGE(0, YMAX/2))*2 - YMAX/2;
+ break;
+ case 1:
+ sx = XMAX/2;
+ sy = ((int)RAND_RANGE(0, YMAX/2))*2 - YMAX/2;
+ break;
+ case 2:
+ sy = YMAX/2;
+ sx = ((int)RAND_RANGE(0, XMAX/2))*2 - XMAX/2;
+ break;
+ case 3:
+ sy = -YMAX/2;
+ sx = ((int)RAND_RANGE(0, XMAX/2))*2 - XMAX/2;
+ break;
+ }
+ s = 1;
+ }
+ } else if (!rotate) {
+ if (col[1] < 0.25) {
+ col[1] += 0.025; col[2] += 0.005;
+ col2[1] += 0.015 ; col2[2] += 0.005;
+ }
+ }
+
+ glDisable(GL_LIGHTING);
+ if (s) {
+ glColor3fv(col3);
+ glPushMatrix();
+ glTranslatef(sx, sy, -10);
+ sphere(0.1, 10, 10, 0, 10, 0, 10);
+ if (sdir == 0)
+ glTranslatef(-ds, 0, 0);
+ if (sdir == 1)
+ glTranslatef(ds, 0, 0);
+ if (sdir == 2)
+ glTranslatef(0, ds, 0);
+ if (sdir == 3)
+ glTranslatef(0, -ds, 0);
+ sphere(0.05, 10, 10, 0, 10, 0, 10);
+ glPopMatrix();
+ if (sdir == 0) {
+ sx += ds;
+ if (sx > XMAX/2)
+ s = 0;
+ }
+ if (sdir == 1) {
+ sx -= ds;
+ if (sx < -XMAX/2)
+ s = 0;
+ }
+ if (sdir == 2) {
+ sy -= ds;
+ if (sy < YMAX/2)
+ s = 0;
+ }
+ if (sdir == 3) {
+ sy += ds;
+ if (sy > YMAX/2)
+ s = 0;
+ }
+ } else if (!rotate) {
+ if (col[1] > 0) {
+ col[1] -= 0.0025; col[2] -= 0.0005;
+ col2[1] -= 0.0015 ; col2[2] -= 0.0005;
+ }
+ }
+ for (x = -XMAX/2 ; x <= XMAX/2 ; x+= 2) {
+ glColor3fv(col);
+ glBegin(GL_LINES);
+ glVertex3f(x, YMAX/2, -10);
+ glVertex3f(x, -YMAX/2, -10);
+ glColor3fv(col2);
+ glVertex3f(x-0.02, YMAX/2, -10);
+ glVertex3f(x-0.02, -YMAX/2, -10);
+ glVertex3f(x+0.02, YMAX/2, -10);
+ glVertex3f(x+0.02, -YMAX/2, -10);
+ glEnd();
+ }
+ for (y = -YMAX/2 ; y <= YMAX/2 ; y+= 2) {
+ glColor3fv(col);
+ glBegin(GL_LINES);
+ glVertex3f(-XMAX/2, y, -10);
+ glVertex3f(XMAX/2, y, -10);
+ glColor3fv(col2);
+ glVertex3f(-XMAX/2, y-0.02, -10);
+ glVertex3f(XMAX/2, y-0.02, -10);
+ glVertex3f(-XMAX/2, y+0.02, -10);
+ glVertex3f(XMAX/2, y+0.02, -10);
+ glEnd();
+ }
+ glEnable(GL_LIGHTING);
+}
+
+void display(void) {
+static Component *c[MAX_COMPONENTS];
+static int i = 0;
+GLfloat light_sp[] = {0.8, 0.8, 0.8, 1.0};
+GLfloat black[] = {0, 0, 0, 1.0};
+static GLfloat rotate_angle = 0; /* when 'rotate' is enabled */
+int j;
+
+ if (i == 0) {
+ for (i = 0 ; i < maxparts ; i++) {
+ c[i] = NULL;
+ }
+ }
+ glEnable(GL_LIGHTING);
+ glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT);
+ glLoadIdentity();
+ gluLookAt(viewer[0], viewer[1], viewer[2], 0.0, 0.0, 0.0, 0.0, 1.0, 0.0);
+ glPushMatrix();
+ if (rotate) {
+ glRotatef(rotate_angle, 0, 0, 1);
+ rotate_angle += 0.01 * (float)rotatespeed;
+ if (rotate_angle >= 360) rotate_angle = 0;
+ }
+ glLightfv(GL_LIGHT0, GL_POSITION, lightpos);
+ glLightfv(GL_LIGHT0, GL_SPECULAR, light_sp);
+ glLightfv(GL_LIGHT0, GL_DIFFUSE, light_sp);
+ glLighti(GL_LIGHT0, GL_CONSTANT_ATTENUATION, (GLfloat)1);
+ glLighti(GL_LIGHT0, GL_LINEAR_ATTENUATION, (GLfloat)0.5);
+ glLighti(GL_LIGHT0, GL_QUADRATIC_ATTENUATION, (GLfloat)0);
+ drawgrid();
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, light_sp);
+ if (f_rand() < 0.05) {
+ for (j = 0 ; j < maxparts ; j++) {
+ if (c[j] == NULL) {
+ c[j] = NewComponent();
+ j = maxparts;
+ }
+ }
+ reorder(&c[0]);
+ }
+ for (j = 0 ; j < maxparts ; j++) {
+ glMaterialfv(GL_FRONT, GL_AMBIENT_AND_DIFFUSE, black);
+ glMaterialfv(GL_FRONT, GL_EMISSION, black);
+ glMaterialfv(GL_FRONT, GL_SPECULAR, black);
+ if (c[j] != NULL) {
+ if (DrawComponent(c[j])) {
+ free(c[j]); c[j] = NULL;
+ }
+ }
+ }
+ glPopMatrix();
+ glFlush();
+}
+
+/* ensure transparent components are at the end */
+void reorder(Component *c[]) {
+int i, j, k;
+Component *c1[MAX_COMPONENTS];
+Component *c2[MAX_COMPONENTS];
+
+ j = 0;
+ for (i = 0 ; i < maxparts ; i++) { /* clear old matrix */
+ c1[i] = NULL;
+ c2[i] = NULL;
+ }
+ for (i = 0 ; i < maxparts ; i++) {
+ if (c[i] == NULL) continue;
+ if (c[i]->alpha) { /* transparent parts go to c1 */
+ c1[j] = c[i];
+ j++;
+ } else { /* opaque parts go to c2 */
+ c2[i] = c[i];
+ }
+ }
+ for (i = 0 ; i < maxparts ; i++) { /* clear old matrix */
+ c[i] = NULL;
+ }
+ k = 0;
+ for (i = 0 ; i < maxparts ; i++) { /* insert opaque part */
+ if (c2[i] != NULL) {
+ c[k] = c2[i];
+ k++;
+ }
+ }
+ for (i = 0 ; i < j ; i++) { /* insert transparent parts */
+ c[k] = c1[i];
+ k++;
+ }
+}
+
+void reshape_circuit(ModeInfo *mi, int width, int height)
+{
+
+ glViewport(0,0,(GLint)width, (GLint) height);
+ glMatrixMode(GL_PROJECTION);
+ glLoadIdentity();
+ glFrustum(-1.0,1.0,-1.0,1.0,1.5,35.0);
+ glMatrixMode(GL_MODELVIEW);
+ win_h = height; win_w = width;
+}
+
+
+void init_circuit(ModeInfo *mi)
+{
+int screen = MI_SCREEN(mi);
+Circuit *c;
+
+ if (circuit == NULL) {
+ if ((circuit = (Circuit *) calloc(MI_NUM_SCREENS(mi),
+ sizeof(Circuit))) == NULL)
+ return;
+ }
+ c = &circuit[screen];
+ c->window = MI_WINDOW(mi);
+
+
+ if ((c->glx_context = init_GL(mi)) != NULL) {
+ reshape_circuit(mi, MI_WIDTH(mi), MI_HEIGHT(mi));
+ } else {
+ MI_CLEARWINDOW(mi);
+ }
+ if (uselight == 0)
+ light = 1;
+ glClearColor(0.0,0.0,0.0,0.0);
+ glShadeModel(GL_SMOOTH);
+ glPolygonMode(GL_FRONT_AND_BACK,GL_FILL);
+ glEnable(GL_DEPTH_TEST);
+ glEnable(GL_LIGHTING);
+ glEnable(GL_LIGHT0);
+ make_tables();
+ makebandlist();
+
+}
+
+void draw_circuit(ModeInfo *mi) {
+Circuit *c = &circuit[MI_SCREEN(mi)];
+Window w = MI_WINDOW(mi);
+Display *disp = MI_DISPLAY(mi);
+
+ if (!c->glx_context)
+ return;
+
+ glXMakeCurrent(disp, w, *(c->glx_context));
+
+ display();
+
+ if(mi->fps_p) do_fps(mi);
+ glFinish();
+ glXSwapBuffers(disp, w);
+}
+
+void release_circuit(ModeInfo *mi) {
+
+ if (circuit != NULL) {
+ (void) free((void *) circuit);
+ circuit = NULL;
+ }
+ FreeAllGL(MI);
+}
+
+#endif
- I'm not sure the text labels are being done in the best way;
they are sometimes, but not always, occluded by spheres that
pass in front of them.
+
+ GENERAL OPENGL NAIVETY:
+
+ I don't understand the *right* way to place text in front of the
+ atoms. What I'm doing now is close, but has glitches. I think I
+ understand glPolygonOffset(), but I think it doesn't help me.
+
+ Here's how I'd phrase the problem I'm trying to solve:
+
+ - I have a bunch of spherical objects of various sizes
+ - I want a piece of text in the scene, between each object
+ and the observer
+ - the position of this text should be apparently tangential
+ to the surface of the sphere, so that:
+ - it is never inside the sphere;
+ - but can be occluded by other objects in the scene.
+
+ So I was trying to use glPolygonOffset() to say "pretend all
+ polygons are N units deeper than they actually are" where N was
+ somewhere around the maximal radius of the objects. Which wasn't a
+ perfect solution, but was close. But it turns out that can't work,
+ because the second arg to glPolygonOffset() is multiplied by some
+ minimal depth quantum which is not revealed, so I can't pass it an
+ offset in scene units -- only in multiples of the quantum. So I
+ don't know how many quanta in radius my spheres are.
+
+ I think I need to position and render the text with glRasterPos3f()
+ so that the text is influenced by the depth buffer. If I used 2f,
+ or an explicit constant Z value, then the text would always be in
+ front of each sphere, and text would be visible for spheres that
+ were fully occluded, which isn't what I want.
+
+ So my only guess at this point is that I need to position the text
+ exactly where I want it, tangential to the spheres -- but that
+ means I need to be able to compute that XYZ position, which is
+ dependent on the position of the observer! Which means two things:
+ first, while generating my scene, I need to take into account the
+ position of the observer, and I don't have a clue how to do that;
+ and second, it means I can't put my whole molecule in a display
+ list, because the XYZ position of the text in the scene changes at
+ every frame, as the molecule rotates.
+
+ This just *can't* be as hard as it seems!
*/
#include <X11/Intrinsic.h>
return;
}
- if (*s == '\n' || col > sc->columns)
+ if (*s == '\r' || *s == '\n' || col > sc->columns)
{
int L = s - sc->buf;
- if (*s == '\n')
- *s++ = 0;
+ if (*s == '\r' || *s == '\n')
+ {
+ if (*s == '\r' && s[1] == '\n') /* swallow CRLF too */
+ *s++ = 0;
+
+ *s++ = 0;
+ }
else
{
/* We wrapped -- try to back up to the previous word boundary. */
--- /dev/null
+.de EX \"Begin example
+.ne 5
+.if n .sp 1
+.if t .sp .5
+.nf
+.in +.5i
+..
+.de EE
+.fi
+.in -.5i
+.if n .sp 1
+.if t .sp .5
+..
+.TH XScreenSaver 1 "18-Jun-01" "X Version 11"
+.SH NAME
+penetrate - simulates a classic arcade shooting game
+.SH SYNOPSIS
+.B penetrate
+[\-display \fIhost:display.screen\fP] [\-root] [\-window]
+[\-install] [\-noinstall] [\-visual \fIvisual\fP]
+[\-bgrowth \fImicroseconds\fP] [\-lrate \fInumber\fP] [\-smart \fInumber\fP]
+.SH DESCRIPTION
+.PP
+\fIPenetrate\fP simulates the arcade classic with the cities and the stuff
+shooting down from the sky and stuff. The computer plays against itself,
+desperately defending the forces of good against those thingies raining
+down. Bonus cities are awarded at ever-increasing intervals. Every five
+levels appears a bonus round. The computer player gets progressively
+more intelligent as the game progresses. Better aim, more economical with
+ammo, and better target selection. Points are in the bottom right, and
+high score is in the bottom left. Start with -smart to have the computer
+player skip the learning process.
+.SH OPTIONS
+.TP 8
+.B \-display \fIhost:display.screen\fP
+Specifies which X display we should use.
+.TP 8
+.B \-root
+Draw on the root window.
+.TP 8
+.B \-window
+Draw on a newly-created window. This is the default.
+.TP 8
+.B \-install
+Install a private colormap for the window.
+.TP 8
+.B \-noinstall
+Don't install a private colormap for the window.
+.TP 8
+.B \-visual \fIvisual\fP
+Specify which visual to use. Legal values are the name of a visual
+class, or the id number (decimal or hex) of a specific visual.
+Possible choices include
+
+.RS
+default, best, mono, monochrome, gray, grey, color, staticgray, staticcolor,
+truecolor, grayscale, greyscale, pseudocolor, directcolor, \fInumber\fP
+
+If a decimal or hexadecimal number is used,
+.BR XGetVisualInfo (3X)
+is consulted to obtain the required visual.
+.RE
+.TP 8
+.B \-foreground \fIcolor\fP
+Specifies the default foreground color.
+.TP 8
+.B \-background \fIcolor\fP
+Specifies the default background color.
+.TP 8
+.B \-bgrowth \fIinteger\fP
+Specifies the growth rate of the bomb explosions.
+.TP 8
+.B \-lrate \fIinteger\fP
+Set the initial rate of laser fire.
+.TP 8
+.B -smart
+Have the computer player skip the learning process.
+.SH BUGS
+The layout of the screen isn't quite the same as the game this program
+tries to emulate. In this this program, the missles come out of the
+cities; when really, there are supposed to be three missile bases on
+hills, with the cities in the valleys between them.
+
+See http://www.mame.net/ for details.
+.SH COPYRIGHT
+Copyright \(co 1999 Adam Miller. Permission to use, copy, modify,
+distribute, and sell this software and its documentation for any purpose is
+hereby granted without fee, provided that the above copyright notice appear
+in all copies and that both that copyright notice and this permission notice
+appear in supporting documentation. No representations are made about the
+suitability of this software for any purpose. It is provided "as is" without
+express or implied warranty.
+.SH AUTHOR
+Adam Miller <adum@aya.yale.edu>, 1999.
static void
print_char (p_state *state, int c)
{
+ static char last_c = 0;
+
p_cell *cell = &state->cells[state->grid_width * state->cursor_y
+ state->cursor_x];
if (c == '\r' || c == '\n')
{
- state->cursor_x = 0;
- if (state->cursor_y == state->grid_height - 1)
- scroll (state);
+ if (c == '\n' && last_c == '\r')
+ ; /* CRLF -- do nothing */
else
- state->cursor_y++;
+ {
+ state->cursor_x = 0;
+ if (state->cursor_y == state->grid_height - 1)
+ scroll (state);
+ else
+ state->cursor_y++;
+ }
}
else if (c == '\014')
{
}
}
set_cursor (state, True);
+
+ last_c = c;
}
* software for any purpose. It is provided "as is" without express or
* implied warranty.
*
- * $Revision: 1.19 $
+ * $Revision: 1.20 $
*
* Version 1.0 April 27, 1998.
* - Initial version
typedef struct ping_target {
char *name; /* The name of the target */
+#ifdef HAVE_PING
struct sockaddr address; /* The address of the target */
+#endif /* HAVE_PING */
struct ping_target *next; /* The next one in the list */
} ping_target;
char *name;
struct sigaction sa;
struct itimerval it;
+ fd_set rfds;
+ struct timeval tv;
/* Set up a signal to interupt our wait for a packet */
/* Wait for a result packet */
fromlen = sizeof(from);
- while (! timer_expired &&
- (result = recvfrom(pi->icmpsock, packet, sizeof(packet),
- 0, &from, &fromlen)) > 0) {
+ while (! timer_expired) {
+ tv.tv_usec=pi->timeout;
+ tv.tv_sec=0;
+ FD_ZERO(&rfds);
+ FD_SET(pi->icmpsock,&rfds);
+ /* only wait a little while, in case we raced with the timer expiration.
+ From Valentijn Sessink <valentyn@openoffice.nl> */
+ if (select(pi->icmpsock+1, &rfds, NULL, NULL, &tv) >0) {
+ result = recvfrom(pi->icmpsock, packet, sizeof(packet),
+ 0, &from, &fromlen);
/* Check the packet */
new->distance = delta(then, &now) / 100;
if (new->distance == 0)
new->distance = 2; /* HACK */
+ }
}
/* Done */
while (token < end)
{
char *next;
+# ifdef HAVE_PING
ping_target *new;
struct stat st;
unsigned int n0=0, n1=0, n2=0, n3=0, m=0;
char d;
+# endif /* HAVE_PING */
for (next = token;
*next != ',' && *next != ' ' && *next != '\t' && *next != '\n';
return 0;
}
+#ifdef HAVE_PING
if ((4 == sscanf (token, "%d.%d.%d/%d %c", &n0,&n1,&n2, &m,&d)) ||
(5 == sscanf (token, "%d.%d.%d.%d/%d %c", &n0,&n1,&n2,&n3,&m,&d)))
{
sensor = ping;
}
+#endif /* HAVE_PING */
token = next + 1;
while (token < end &&
debug_p = get_boolean_resource ("debug", "Debug");
sensor = 0;
+# ifdef HAVE_PING
sensor_info = (void *) init_ping();
+# else /* !HAVE_PING */
+ sensor_info = 0;
+ parse_mode (0); /* just to check argument syntax */
+# endif /* !HAVE_PING */
if (sensor == 0)
{
X server and reading the resource database) so this is \fIbelieved\fP
to be a safe thing to do, but it is usually recommended that you
have as few setuid programs around as possible, on general principles.
+.EX
+chown root.root sonar
+chmod u+s sonar
+.EE
.SH SEE ALSO
.BR X (1),
.BR xscreensaver (1),
zfactor = (double)depth* (12.0 - TERRAIN_LENGTH/8.0) * zf;
for (j=0; j < TERRAIN_BREADTH; j++) {
jj = direction * j; MODULO(jj, TERRAIN_BREADTH);
- xx = (worldx[i][jj]-(vertigo*xcc))/zfactor;
- yy = (worldy[i][j]-(vertigo*ycc))/zfactor;
-
+ /* jwz: not totally sure if this is right, but it avoids div0 */
+ if (zfactor != 0) {
+ xx = (worldx[i][jj]-(vertigo*xcc))/zfactor;
+ yy = (worldy[i][j]-(vertigo*ycc))/zfactor;
+ } else {
+ xx = 0;
+ yy = 0;
+ }
r = rotation_bias + (int)(vertigo*zcc); MODULO(r, ROTS);
xvals[t][j] = xoffset + width/2 +
swirl - draws swirly color-cycling patterns
.SH SYNOPSIS
.B swirl
-[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP] [\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install] [\-visual \fIvisual\fP] [\-ncolors \fIinteger\fP] [\-delay \fImicroseconds\fP] [\-cycles \fIinteger\fP] [\-count \fIinteger\fP]
+[\-display \fIhost:display.screen\fP] [\-foreground \fIcolor\fP]
+[\-background \fIcolor\fP] [\-window] [\-root] [\-mono] [\-install]
+[\-visual \fIvisual\fP]
+[\-ncolors \fIinteger\fP]
+[\-delay \fImicroseconds\fP]
+[\-count \fIinteger\fP]
.SH DESCRIPTION
The \fIswirl\fP program draws swirly color-cycling patterns.
.TP 8
.B \-ncolors \fIinteger\fP
How many colors should be used (if possible). Default 200.
-.TP 8
-.B \-cycles \fIinteger\fP
-
.TP 8
.B \-count \fIinteger\fP
--- /dev/null
+/*
+ * @(#) vermiculate.c
+ * @(#) Copyright (C) 2001 Tyler Pierce (tyler@alumni.brown.edu)
+ * The full program, with documentation, is available at:
+ * http://freshmeat.net/projects/fdm
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation. No representations are made about the suitability of this
+ * software for any purpose. It is provided "as is" without express or
+ * implied warranty.
+ */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <ctype.h>
+#include <unistd.h>
+#include <sys/time.h>
+#include <math.h>
+
+#ifdef VERMICULATE_STANDALONE
+#include "yarandom.h"
+#include "usleep.h"
+#include <X11/Xlib.h>
+#include <X11/Xutil.h>
+#include <X11/Xatom.h>
+#include <X11/Xresource.h>
+#else
+#include "screenhack.h"
+#include "config.h"
+#endif /* VERMICULATE_STANDALONE */
+
+#define degs 360
+#define degs2 (degs/2)
+#define degs4 (degs/4)
+#define degs8 (degs/8)
+#define dtor 0.0174532925 /* pi / degs2; */
+#define thrmax 120
+#define tailmax (thrmax * 2 + 1)
+#define tmodes '7'
+#define ymax (hei - 1)
+#define ymin 0
+#define xmax (wid - 1)
+#define xmin 0
+#define rlmax 200
+#define SPEEDINC 10
+#define SPEEDMAX 1000
+#define wraparound(VAL,LOWER,UPPER) { \
+ if (VAL >= UPPER) \
+ VAL -= UPPER - LOWER; \
+ else if (VAL < LOWER) \
+ VAL += UPPER - LOWER; }
+#define arrcpy(DEST,SRC) memcpy (DEST, SRC, sizeof(DEST))
+
+typedef double real;
+typedef unsigned char banktype[thrmax];
+
+typedef struct linedata
+{
+ int deg, spiturn, turnco, turnsize;
+ unsigned char col;
+ Bool dead;
+
+ char orichar;
+ real x, y;
+ int tmode, tsc, tslen, tclim, otslen, ctinc, reclen, recpos, circturn, prey,
+ slice;
+ int xrec[rlmax + 1], yrec[rlmax + 1];
+ int turnseq[50];
+ Bool filled, killwalls, vhfollow,
+ selfbounce, tailfollow, realbounce, little;
+}
+linedata;
+
+#ifdef VERMICULATE_STANDALONE
+static XEvent myevent;
+static Bool use_root = False;
+static unsigned char rgb[256][3];
+
+#else
+char *progclass = "Vermiculate";
+
+char *defaults[] = {
+ ".ticks: 20000",
+ 0
+};
+
+XrmOptionDescRec options[] = {
+ {"-speed", ".speed", XrmoptionSepArg, 0},
+ {"-instring", ".instring", XrmoptionSepArg, 0},
+ {0, 0, 0, 0}
+};
+#endif /* VERMICULATE_STANDALONE */
+
+static Display *mydpy;
+static Window mywindow;
+static GC mygc;
+static Colormap mycmap;
+static XWindowAttributes xgwa;
+static Bool neednewkey = True;
+static XColor mycolors[tailmax];
+
+static int hei = 500, wid = 500, speed = 100;
+static Bool erasing = True;
+static char *instring = 0;
+static int max_ticks;
+
+static struct stringAndSpeed
+{
+ char *str;
+ int speed;
+}
+sampleStrings[] =
+{
+ { "]]]]]]]]7ces123400-9-8#c123456#s9998880004#ma3#car9ma6#c-#r1", 600} ,
+ { "bmarrrr#c1234#lc5678#lyet]", 600} ,
+ { "AEBMN222222223#CAR9CAD4CAOV", 150} ,
+ { "mn333#c23#f1#]]]]]]]]]]]3bc9#r9#c78#f9#ma4#", 600} ,
+ { "AEBMN22222#CAD4CAORc1#f2#c1#r6", 100} ,
+/* { "mn6666666#c1i#f1#y2#sy2#vyety1#ry13i#l", 40} , */
+ { "aebmnrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr#", 500} ,
+ { "bg+++++++++++++++++++++++#mnrrrrrrrrrrrrrrrrrrrrrrr#y1#k", 500} ,
+ { "BMN22222223#CAD4CAOVYAS", 150} ,
+/* { "aebmnrrrrrrrrrrrrrrrr#yaryakg--#", 100} , */
+ { "mn6rrrrrrrrrrrrrrr#by1i#lcalc1#fnyav", 200 } ,
+ { "mn1rrrrrrrrrrrrrrr#by1i#lcalc1#fn", 200 }
+};
+
+static real sinof[degs], cosof[degs], tanof[degs];
+static unsigned char *point;
+
+static linedata thread[thrmax];
+static banktype bank;
+static int bankt, boxw, boxh, curviness, gridden, ogd, bordcorn;
+static unsigned char bordcol, threads;
+static char ch, boolop;
+
+static Bool
+wasakeypressed (void)
+{
+ if (!neednewkey || *instring != 0)
+ return True;
+ else
+#ifdef VERMICULATE_STANDALONE
+ return !(neednewkey =
+ !XCheckWindowEvent (mydpy, mywindow, KeyPressMask, &myevent));
+#else
+ return False;
+#endif /* VERMICULATE_STANDALONE */
+}
+
+static char
+readkey (void)
+{
+ char readkey_result;
+ if (*instring == 0)
+ {
+#ifdef VERMICULATE_STANDALONE
+ char key_buffer[1];
+ KeySym key_sym;
+ if (neednewkey)
+ XWindowEvent (mydpy, mywindow, KeyPressMask, &myevent);
+ XLookupString (&myevent.xkey, key_buffer, 1, &key_sym, NULL);
+ readkey_result = key_sym;
+#else
+ readkey_result = '#';
+#endif /* VERMICULATE_STANDALONE */
+ neednewkey = True;
+ }
+ else
+ {
+ readkey_result = *instring;
+ instring++;
+ };
+ return toupper (readkey_result);
+}
+
+static unsigned int
+random1 (unsigned int i)
+{
+ return (ya_random () % i);
+}
+
+static void
+waitabit (void)
+{
+ static int cyc = 0;
+ cyc += threads;
+ while (cyc > speed)
+ {
+ usleep (10000);
+ cyc -= speed;
+ }
+}
+
+static void
+clearscreen (void)
+{
+ XClearWindow (mydpy, mywindow);
+ memset (point, 0, wid * hei);
+}
+
+static void
+sp (int x, int y, int c)
+{
+ XSetForeground (mydpy, mygc, mycolors[c].pixel);
+ XDrawPoint (mydpy, mywindow, mygc, x, y);
+ point[(wid * y) + x] = c;
+}
+
+static int
+gp (int x, int y)
+{
+ return point[(wid * y) + x];
+}
+
+static void
+redraw (int x, int y, int width, int height)
+{
+ int xc, yc;
+ for (xc = x; xc <= x + width - 1; xc++)
+ for (yc = y; yc <= y + height - 1; yc++)
+ if (point[wid * yc + xc] != 0)
+ sp (xc, yc, point[wid * yc + xc]);
+}
+
+static void
+palupdate (Bool forceUpdate)
+{
+ if (forceUpdate || *instring == 0)
+ {
+#ifdef VERMICULATE_STANDALONE
+ int colnum;
+ for (colnum = 0; colnum < tailmax; colnum++)
+ {
+ mycolors[colnum].red = rgb[colnum][0] << 10;
+ mycolors[colnum].green = rgb[colnum][1] << 10;
+ mycolors[colnum].blue = rgb[colnum][2] << 10;
+ mycolors[colnum].flags = DoRed | DoBlue | DoGreen;
+ XAllocColor (mydpy, mycmap, &mycolors[colnum]);
+ };
+#endif /* VERMICULATE_STANDALONE */
+ redraw (xmin, ymin, wid, hei);
+ }
+}
+
+static void
+randpal (void)
+{
+#ifdef VERMICULATE_STANDALONE
+ int co, ro;
+ for (co = 1; co <= 255; co++)
+ for (ro = 0; ro <= 2; ro++)
+ if (co > tailmax)
+ rgb[co][ro] = random1 (20);
+ else
+ rgb[co][ro] = random1 (64);
+ for (ro = 0; ro <= 2; ro++)
+ rgb[0][ro] = 0;
+#else
+ int ncolors = tailmax - 1;
+ make_random_colormap (mydpy,
+ xgwa.visual,
+ mycmap, &mycolors[1], &ncolors, True, True, 0, True);
+ if (ncolors < tailmax - 1)
+ {
+ int c;
+ for (c = 1; c < tailmax; c++)
+ mycolors[c].pixel = WhitePixel (mydpy, DefaultScreen (mydpy));
+ }
+#endif /* VERMICULATE_STANDALONE */
+}
+
+static void
+gridupdate (Bool interruptible)
+{
+ int x, y;
+ if (gridden > 0)
+ for (x = 0; x <= xmax && !(wasakeypressed () && interruptible); x += boxw)
+ for (y = 0; y <= ymax; y += boxh)
+ {
+ if (random1 (15) < gridden)
+ {
+#define lesser(A,B) ( ((A)<(B)) ? (A) : (B) )
+ int max = lesser (x + boxw, xmax);
+ int xc;
+ for (xc = x; xc <= max; xc++)
+ sp (xc, y, 1);
+ }
+ if (random1 (15) < gridden)
+ {
+ int max = lesser (y + boxh, ymax);
+ int yc;
+ for (yc = y; yc <= max; yc++)
+ sp (x, yc, 1);
+ }
+ }
+}
+
+static void
+bordupdate (void)
+{
+ int xbord, ybord;
+
+ if (bordcorn == 0 || bordcorn == 1)
+ ybord = ymin;
+ else
+ ybord = ymax;
+ if (bordcorn == 0 || bordcorn == 3)
+ xbord = xmin;
+ else
+ xbord = xmax;
+ {
+ int x, y;
+ for (x = xmin; x <= xmax; x++)
+ sp (x, ybord, bordcol);
+ for (y = ymin; y <= ymax; y++)
+ sp (ybord, y, bordcol);
+ }
+}
+
+static Bool
+inbank (unsigned char thr)
+{
+ int c;
+ if (bankt > 0)
+ for (c = 1; c <= bankt; c++)
+ if (bank[c - 1] == thr)
+ return True;
+ return False;
+}
+
+static void
+pickbank (void)
+{
+ unsigned char thr = 1;
+#ifdef VERMICULATE_STANDALONE
+ int co, ro;
+ unsigned char orgb[256][3];
+
+ arrcpy (orgb, rgb);
+ for (co = 2; co <= tailmax; co++)
+ for (ro = 0; ro <= 2; ro++)
+ rgb[co][ro] = 25;
+#endif /* VERMICULATE_STANDALONE */
+ bankt = 0;
+ ch = '\0';
+ do
+ {
+ while (inbank (thr))
+ thr = thr % threads + 1;
+#ifdef VERMICULATE_STANDALONE
+ for (co = 1; co <= threads; co++)
+ {
+ for (ro = 0; ro <= 2; ro++)
+ rgb[co + 1][ro] = 25;
+ if (inbank (co))
+ for (ro = 0; ro <= 1; ro++)
+ rgb[co + 1][ro] = 60;
+ }
+ for (ro = 0; ro <= 2; ro++)
+ rgb[thr + 1][ro] = 60;
+#endif /* VERMICULATE_STANDALONE */
+ palupdate (False);
+ ch = readkey ();
+ palupdate (False);
+ switch (ch)
+ {
+ case '+':
+ case '-':
+ do
+ {
+ if (ch == '+')
+ thr++;
+ else
+ thr--;
+ wraparound (thr, 1, threads + 1);
+ }
+ while (inbank (thr));
+ break;
+ case ' ':
+ bank[++bankt - 1] = thr;
+ break;
+ case '1'...'9':
+ bank[++bankt - 1] = ch - '0';
+ if (bank[bankt - 1] > threads)
+ bankt--;
+ break;
+ case 'I':
+ {
+ banktype tbank;
+ int tbankt = 0;
+ int c;
+ for (c = 1; c <= threads; c++)
+ if (!inbank (c))
+ tbank[++tbankt - 1] = c;
+ bankt = tbankt;
+ arrcpy (bank, tbank);
+ }
+ break;
+ case 'T':
+ ch = readkey ();
+ switch (ch)
+ {
+ case '1'...tmodes:
+ {
+ int c;
+ for (c = 1; c <= threads; c++)
+ if (thread[c - 1].tmode == ch - '0')
+ bank[++bankt - 1] = c;
+ }
+ break;
+ }
+ break;
+ case 'A':
+ for (bankt = 1; bankt <= threads; bankt++)
+ bank[bankt - 1] = bankt;
+ bankt = threads;
+ break;
+ case 'E':
+ for (bankt = 1; bankt <= thrmax; bankt++)
+ bank[bankt - 1] = bankt;
+ bankt = thrmax;
+ break;
+ }
+ }
+ while (!(bankt >= threads || ch == 'N' || ch == '\15' || ch == '#'));
+ if (bankt == 0 && ch != 'N')
+ {
+ bankt = 1;
+ bank[0] = thr;
+ }
+#ifdef VERMICULATE_STANDALONE
+ arrcpy (rgb, orgb);
+#endif /* VERMICULATE_STANDALONE */
+ palupdate (False);
+}
+
+static void
+bankmod (Bool * Bool_)
+{
+ switch (boolop)
+ {
+ case 'T':
+ *Bool_ = !*Bool_;
+ break;
+ case 'Y':
+ *Bool_ = True;
+ break;
+ case 'N':
+ *Bool_ = False;
+ break;
+ }
+}
+
+static void
+newonscreen (unsigned char thr)
+{
+ linedata *LP = &thread[thr - 1];
+ LP->filled = False;
+ LP->dead = False;
+ LP->reclen = (LP->little) ?
+ random1 (10) + 5 : random1 (rlmax - 30) + 30;
+ LP->deg = random1 (degs);
+ LP->y = random1 (hei);
+ LP->x = random1 (wid);
+ LP->recpos = 0;
+ LP->turnco = 2;
+ LP->turnsize = random1 (4) + 2;
+}
+
+static void
+firstinit (unsigned char thr)
+{
+ linedata *LP = &thread[thr - 1];
+ LP->col = thr + 1;
+ LP->prey = 0;
+ LP->tmode = 1;
+ LP->slice = degs / 3;
+ LP->orichar = 'R';
+ LP->spiturn = 5;
+ LP->selfbounce = False;
+ LP->realbounce = False;
+ LP->vhfollow = False;
+ LP->tailfollow = False;
+ LP->killwalls = False;
+ LP->little = False;
+ LP->ctinc = random1 (2) * 2 - 1;
+ LP->circturn = ((thr % 2) * 2 - 1) * ((thr - 1) % 7 + 1);
+ LP->tsc = 1;
+ LP->tslen = 6;
+ LP->turnseq[0] = 6;
+ LP->turnseq[1] = -6;
+ LP->turnseq[2] = 6;
+ LP->turnseq[3] = 6;
+ LP->turnseq[4] = -6;
+ LP->turnseq[5] = 6;
+ LP->tclim = (unsigned char) (((real) degs) / 2 / 12);
+}
+
+static void
+maininit (void)
+{
+ if (!instring)
+ {
+ int n = random1 (sizeof (sampleStrings) / sizeof (sampleStrings[0]));
+ instring = sampleStrings[n].str;
+ speed = sampleStrings[n].speed;
+ }
+ boxh = 10;
+ boxw = 10;
+ gridden = 0;
+ bordcorn = 0;
+ threads = 4;
+ curviness = 30;
+ bordcol = 1;
+ ogd = 8;
+ ch = '\0';
+ erasing = True;
+ {
+ unsigned char thr;
+ for (thr = 1; thr <= thrmax; thr++)
+ {
+ firstinit (thr);
+ newonscreen (thr);
+ }
+ }
+ {
+ int d;
+ for (d = degs - 1; d >= 0; d--)
+ {
+ sinof[d] = sin (d * dtor);
+ cosof[d] = cos (d * dtor);
+ if (d % degs4 == 0)
+ tanof[d] = tanof[d + 1];
+ else
+ tanof[d] = tan (d * dtor);
+ }
+ }
+ randpal ();
+}
+
+static Bool
+move (unsigned char thr)
+{
+ linedata *LP = &thread[thr - 1];
+ if (LP->dead)
+ return (False);
+ if (LP->prey == 0)
+ switch (LP->tmode)
+ {
+ case 1:
+ LP->deg += random1 (2 * LP->turnsize + 1) - LP->turnsize;
+ break;
+ case 2:
+ if (LP->slice == degs || LP->slice == degs2 || LP->slice == degs4)
+ {
+ if (LP->orichar == 'D')
+ {
+ if (LP->deg % degs4 != degs8)
+ LP->deg = degs4 * random1 (4) + degs8;
+ }
+ else if (LP->orichar == 'V')
+ if (LP->deg % degs4 != 0)
+ LP->deg = degs4 * random1 (4);
+ }
+ if (random1 (100) == 0)
+ {
+ if (LP->slice == 0)
+ LP->deg = LP->deg - degs4 + random1 (degs2);
+ else
+ LP->deg += (random1 (2) * 2 - 1) * LP->slice;
+ }
+ break;
+ case 3:
+ LP->deg += LP->circturn;
+ break;
+ case 4:
+ if (abs (LP->spiturn) > 11)
+ LP->spiturn = 5;
+ else
+ LP->deg += LP->spiturn;
+ if (random1 (15 - abs (LP->spiturn)) == 0)
+ {
+ LP->spiturn += LP->ctinc;
+ if (abs (LP->spiturn) > 10)
+ LP->ctinc *= -1;
+ }
+ break;
+ case 5:
+ LP->turnco = abs (LP->turnco) - 1;
+ if (LP->turnco == 0)
+ {
+ LP->turnco = curviness + random1 (10);
+ LP->circturn *= -1;
+ }
+ LP->deg += LP->circturn;
+ break;
+ case 6:
+ if (abs (LP->turnco) == 1)
+ LP->turnco *= -1 * (random1 (degs2 / abs (LP->circturn)) + 5);
+ else if (LP->turnco == 0)
+ LP->turnco = 2;
+ else if (LP->turnco > 0)
+ {
+ LP->turnco--;
+ LP->deg += LP->circturn;
+ }
+ else
+ LP->turnco++;
+ break;
+ case 7:
+ LP->turnco++;
+ if (LP->turnco > LP->tclim)
+ {
+ LP->turnco = 1;
+ LP->tsc = (LP->tsc % LP->tslen) + 1;
+ }
+ LP->deg += LP->turnseq[LP->tsc - 1];
+ break;
+ }
+ else
+ {
+ int desdeg;
+ real dy, dx;
+ if (LP->tailfollow || LP->prey == thr)
+ {
+ dx = thread[LP->prey - 1].xrec[thread[LP->prey - 1].recpos] - LP->x;
+ dy = thread[LP->prey - 1].yrec[thread[LP->prey - 1].recpos] - LP->y;
+ }
+ else
+ {
+ dx = thread[LP->prey - 1].x - LP->x;
+ dy = thread[LP->prey - 1].y - LP->y;
+ }
+ desdeg =
+ (LP->vhfollow) ?
+ ((fabs (dx) > fabs (dy)) ?
+ ((dx > 0) ?
+ 0 * degs4
+ :
+ 2 * degs4)
+ :
+ ((dy > 0) ?
+ 1 * degs4
+ :
+ 3 * degs4))
+ :
+ ((dx > 0) ?
+ ((dy > 0) ?
+ 1 * degs8 : 7 * degs8) : ((dy > 0) ? 3 * degs8 : 5 * degs8));
+ if (desdeg - desdeg % degs4 != LP->deg - LP->deg % degs4
+ || LP->vhfollow)
+ {
+ if (!LP->vhfollow)
+ {
+ /* Using atan2 here doesn't seem to slow things down: */
+ desdeg = atan2 (dy, dx) / dtor;
+ wraparound (desdeg, 0, degs);
+ }
+ if (abs (desdeg - LP->deg) <= abs (LP->circturn))
+ LP->deg = desdeg;
+ else
+ LP->deg +=
+ (desdeg > LP->deg) ?
+ ((desdeg - LP->deg > degs2) ?
+ -abs (LP->circturn) : abs (LP->circturn))
+ : ((LP->deg - desdeg > degs2) ?
+ abs (LP->circturn) : -abs (LP->circturn));
+ }
+ else
+ LP->deg +=
+ (tanof[LP->deg] >
+ dy / dx) ? -abs (LP->circturn) : abs (LP->circturn);
+ }
+
+ wraparound (LP->deg, 0, degs);
+ {
+ unsigned char oldcol;
+ real oldy = LP->y, oldx = LP->x;
+ LP->x += cosof[LP->deg];
+ wraparound (LP->x, xmin, xmax + 1);
+ LP->y += sinof[LP->deg];
+ wraparound (LP->y, ymin, ymax + 1);
+#define xi ((int) LP->x)
+#define yi ((int) LP->y)
+
+ oldcol = gp (xi, yi);
+ if (oldcol != 0)
+ {
+ Bool vertwall = False, horiwall = False;
+ if (oldcol == 1 && ((LP->killwalls && gridden > 0) || LP->realbounce))
+ {
+ vertwall = (gp (xi, (int) oldy) == 1);
+ horiwall = (gp ((int) oldx, yi) == 1);
+ }
+ if (oldcol == 1 && LP->realbounce && (vertwall || horiwall))
+ {
+ if (vertwall)
+ LP->deg = -LP->deg + degs2;
+ else
+ LP->deg = -LP->deg;
+ }
+ else
+ {
+ if ((oldcol != LP->col && LP->realbounce)
+ || (oldcol == LP->col && LP->selfbounce))
+ LP->deg += degs4 * (random1 (2) * 2 - 1);
+ else if (oldcol != LP->col)
+ LP->deg += degs2;
+ }
+ if (LP->killwalls && gridden > 0 && oldcol == 1)
+ {
+ if (vertwall && xi + 1 <= xmax)
+ {
+ int yy;
+ for (yy = yi - yi % boxh;
+ yy <= yi - yi % boxh + boxh && yy <= ymax; yy++)
+ if (gp (xi + 1, yy) != 1 || yy == ymax)
+ sp (xi, yy, 0);
+ }
+ if (horiwall && yi + 1 <= ymax)
+ {
+ int xx;
+ for (xx = xi - xi % boxw;
+ xx <= xi - xi % boxw + boxw && xx <= xmax; xx++)
+ if (gp (xx, yi + 1) != 1 || xx == xmax)
+ sp (xx, yi, 0);
+ }
+ }
+ if (oldcol != LP->col || LP->selfbounce)
+ {
+ LP->x = oldx;
+ LP->y = oldy;
+ }
+ wraparound (LP->deg, 0, degs);
+ }
+ }
+
+ sp (xi, yi, LP->col);
+ if (LP->filled)
+ {
+ if (erasing)
+ sp (LP->xrec[LP->recpos], LP->yrec[LP->recpos], 0);
+ else
+ sp (LP->xrec[LP->recpos], LP->yrec[LP->recpos], LP->col + thrmax);
+ }
+ LP->yrec[LP->recpos] = yi;
+ LP->xrec[LP->recpos] = xi;
+ if (LP->recpos == LP->reclen - 1)
+ LP->filled = True;
+ if (LP->filled && !erasing)
+ {
+ int co = LP->recpos;
+ LP->dead = True;
+ do
+ {
+ int nextco = co + 1;
+ wraparound (nextco, 0, LP->reclen);
+ if (LP->yrec[co] != LP->yrec[nextco]
+ || LP->xrec[co] != LP->xrec[nextco])
+ LP->dead = False;
+ co = nextco;
+ }
+ while (!(!LP->dead || co == LP->recpos));
+ }
+ LP->recpos++;
+ wraparound (LP->recpos, 0, LP->reclen);
+ return (!LP->dead);
+}
+
+static void
+vermiculate_main (void)
+{
+ int had_instring = (instring != 0);
+ int tick = 0;
+ Bool halted = False, autopal = False, cleared;
+ point = (unsigned char *) malloc (wid * hei);
+ maininit ();
+ palupdate (True);
+
+ do
+ {
+ clearscreen ();
+ {
+ unsigned char thr;
+ for (thr = 1; thr <= threads; thr++)
+ newonscreen (thr);
+ }
+ if (autopal)
+ {
+ randpal ();
+ palupdate (False);
+ }
+ bordupdate ();
+ gridupdate (False);
+ cleared = False;
+ do
+ {
+ while (wasakeypressed ())
+ {
+ ch = readkey ();
+ switch (ch)
+ {
+ case 'M':
+ ch = readkey ();
+ switch (ch)
+ {
+ case 'A':
+ case 'N':
+ {
+ unsigned char othreads = threads;
+ if (ch == 'N')
+ threads = 0;
+ do
+ {
+ ch = readkey ();
+ switch (ch)
+ {
+ case '1'...tmodes:
+ thread[++threads - 1].tmode = ch - '0';
+ break;
+ case 'R':
+ thread[++threads - 1].tmode =
+ random1 (tmodes - '0') + 1;
+ break;
+ }
+ }
+ while (!(ch == '\15' || ch == '#'
+ || threads == thrmax));
+ if (threads == 0)
+ threads = othreads;
+ cleared = True;
+ }
+ break;
+ }
+ break;
+ case 'C':
+ pickbank ();
+ if (bankt > 0)
+ {
+ ch = readkey ();
+ switch (ch)
+ {
+ case 'D':
+ ch = readkey ();
+ switch (ch)
+ {
+ case '1'...'9':
+/* Careful! The following macro needs to be at the beginning of any
+block in which it's invoked, since it declares variables: */
+#define forallinbank(LDP) linedata *LDP; int bankc; \
+ for (bankc = 1; \
+ (LDP = &thread[bank[bankc - 1] - 1], \
+ bankc <= bankt); bankc++)
+ {
+ forallinbank (L) L->slice = degs / (ch - '0');
+ }
+ break;
+ case 'M':
+ {
+ forallinbank (L) L->slice = 0;
+ }
+ break;
+ }
+ break;
+ case 'S':
+ {
+ forallinbank (L)
+ {
+ L->otslen = L->tslen;
+ L->tslen = 0;
+ }
+ }
+ do
+ {
+ char oldch = ch;
+ ch = readkey ();
+ {
+ forallinbank (L)
+ {
+ switch (ch)
+ {
+ case '0'...'9':
+ L->tslen++;
+ L->turnseq[L->tslen - 1] = ch - '0';
+ if (oldch == '-')
+ L->turnseq[L->tslen - 1] *= -1;
+ if (bankc % 2 == 0)
+ L->turnseq[L->tslen - 1] *= -1;
+ break;
+ }
+ }
+ }
+ }
+ while (!(ch == '\15' || ch == '#'
+ || thread[bank[0] - 1].tslen == 50));
+ {
+ forallinbank (L)
+ {
+ int seqSum = 0, c;
+
+ if (L->tslen == 0)
+ L->tslen = L->otslen;
+ for (c = 1; c <= L->tslen; c++)
+ seqSum += L->turnseq[c - 1];
+ if (seqSum == 0)
+ L->tclim = 1;
+ else
+ L->tclim =
+ (int) (((real) degs2) / abs (seqSum));
+ L->tsc = random1 (L->tslen) + 1;
+ }
+ }
+ break;
+ case 'T':
+ {
+ ch = readkey ();
+ {
+ forallinbank (L)
+ {
+ switch (ch)
+ {
+ case '1'...tmodes:
+ L->tmode = ch - '0';
+ break;
+ case 'R':
+ L->tmode = random1 (tmodes - '0') + 1;
+ break;
+ }
+ }
+ }
+ }
+ break;
+ case 'O':
+ ch = readkey ();
+ {
+ forallinbank (L) L->orichar = ch;
+ }
+ break;
+ case 'F':
+ {
+ banktype fbank;
+ arrcpy (fbank, bank);
+ {
+ int fbankt = bankt;
+ int bankc;
+ pickbank ();
+ for (bankc = 1; bankc <= fbankt; bankc++)
+ {
+ linedata *L = &thread[fbank[bankc - 1] - 1];
+ if (ch == 'N')
+ L->prey = 0;
+ else
+ L->prey = bank[0 + (bankc - 1) % bankt];
+ }
+ }
+ }
+ break;
+ case 'L':
+ {
+ forallinbank (L) L->prey = bank[bankc % bankt];
+ }
+ break;
+ case 'R':
+ ch = readkey ();
+ {
+ forallinbank (L) switch (ch)
+ {
+ case '1'...'9':
+ L->circturn = 10 - (ch - '0');
+ break;
+ case 'R':
+ L->circturn = random1 (7) + 1;
+ break;
+ }
+ }
+ break;
+ }
+ }
+ break;
+ case 'T':
+ case 'Y':
+ case 'N':
+ boolop = ch;
+ pickbank ();
+ if (bankt > 0)
+ {
+ ch = readkey ();
+ {
+ forallinbank (L)
+ {
+ switch (ch)
+ {
+ case 'S':
+ bankmod (&L->selfbounce);
+ break;
+ case 'V':
+ bankmod (&L->vhfollow);
+ break;
+ case 'R':
+ bankmod (&L->realbounce);
+ break;
+ case 'L':
+ bankmod (&L->little);
+ cleared = True;
+ break;
+ case 'T':
+ bankmod (&L->tailfollow);
+ break;
+ case 'K':
+ bankmod (&L->killwalls);
+ break;
+ }
+ }
+ }
+ }
+ break;
+ case 'R':
+ if (bordcol == 1)
+ {
+ bordcol = 0;
+ bordupdate ();
+ bordcorn = (bordcorn + 1) % 4;
+ bordcol = 1;
+ bordupdate ();
+ }
+ break;
+ case '\33':
+ halted = True;
+ break;
+ case '1'...tmodes:
+ {
+ int c;
+ for (c = 1; c <= thrmax; c++)
+ thread[c - 1].tmode = ch - '0';
+ }
+ break;
+ case '\40':
+ cleared = True;
+ break;
+ case 'E':
+ erasing = !erasing;
+ break;
+ case 'P':
+ randpal ();
+ palupdate (True);
+ break;
+ case 'G':
+ {
+ char dimch = 'B';
+ Bool gridchanged = True;
+ if (gridden == 0)
+ gridden = ogd;
+ do
+ {
+ int msize = 0;
+ if (gridchanged)
+ {
+ clearscreen ();
+ gridupdate (True);
+ }
+ ch = readkey ();
+ gridchanged = True;
+ switch (ch)
+ {
+ case '+':
+ msize = 1;
+ break;
+ case '-':
+ msize = -1;
+ break;
+ case ']':
+ if (gridden < 15)
+ gridden++;
+ break;
+ case '[':
+ if (gridden > 0)
+ gridden--;
+ break;
+ case 'O':
+ ogd = gridden;
+ gridden = 0;
+ break;
+ case 'S':
+ boxw = boxh;
+ case 'W':
+ case 'H':
+ case 'B':
+ dimch = ch;
+ break;
+ default:
+ gridchanged = False;
+ }
+ if (dimch == 'W' || dimch == 'B')
+ boxw += msize;
+ if (dimch == 'H' || dimch == 'B')
+ boxh += msize;
+ if (boxw == 0)
+ boxw = 1;
+ if (boxh == 0)
+ boxh = 1;
+ }
+ while (!(ch == '\15' || ch == '#' || ch == 'O'));
+ cleared = True;
+ }
+ break;
+ case 'A':
+ autopal = !autopal;
+ break;
+ case 'B':
+ bordcol = 1 - bordcol;
+ bordupdate ();
+ break;
+ case '-':
+ speed -= SPEEDINC;
+ if (speed < 1)
+ speed = 1;
+ break;
+ case '+':
+ speed += SPEEDINC;
+ if (speed > SPEEDMAX)
+ speed = SPEEDMAX;
+ break;
+ case '/':
+ if (curviness > 5)
+ curviness -= 5;
+ break;
+ case '*':
+ if (curviness < 50)
+ curviness += 5;
+ break;
+ case ']':
+ if (threads < thrmax)
+ newonscreen (++threads);
+ break;
+ case '[':
+ if (threads > 1)
+ {
+ linedata *L = &thread[threads - 1];
+ int lastpos = (L->filled) ? L->reclen - 1 : L->recpos;
+ int c;
+ for (c = 0; c <= lastpos; c++)
+ sp (L->xrec[c], L->yrec[c], 0);
+ threads--;
+ }
+ break;
+ }
+ }
+
+#ifdef VERMICULATE_STANDALONE
+ {
+ XEvent xe;
+ while (XCheckWindowEvent
+ (mydpy, mywindow, StructureNotifyMask | ExposureMask, &xe))
+ switch (xe.type)
+ {
+ case ConfigureNotify:
+ wid = xe.xconfigure.width;
+ hei = xe.xconfigure.height;
+ free (point);
+ point = (unsigned char *) malloc (wid * hei);
+ cleared = True;
+ break;
+ case Expose:
+ if (!cleared)
+ redraw (xe.xexpose.x,
+ xe.xexpose.y, xe.xexpose.width,
+ xe.xexpose.height);
+ break;
+ }
+ }
+#else
+ screenhack_handle_events (mydpy);
+#endif /* VERMICULATE_STANDALONE */
+
+ if (!cleared)
+ {
+ Bool alltrap = True;
+ unsigned char thr;
+ for (thr = 1; thr <= threads; thr++)
+ if (move (thr))
+ alltrap = False;
+ if (alltrap) /* all threads are trapped */
+ cleared = True;
+ if (speed != SPEEDMAX)
+ waitabit ();
+ }
+
+ if (tick++ > max_ticks && !had_instring)
+ {
+ tick = 0;
+ instring = 0;
+ maininit();
+ cleared = True;
+ autopal = False;
+ }
+ }
+ while (!(halted || cleared));
+ }
+ while (!halted);
+}
+
+void
+commonXinit (void)
+{
+ XSetWindowBackground (mydpy, mywindow,
+ BlackPixel (mydpy, DefaultScreen (mydpy)));
+ {
+ XGetWindowAttributes (mydpy, mywindow, &xgwa);
+ wid = xgwa.width;
+ hei = xgwa.height;
+ mycmap = xgwa.colormap;
+ }
+ {
+ XGCValues mygcv;
+ XGetGCValues (mydpy, XDefaultGC (mydpy, XDefaultScreen (mydpy)),
+ GCForeground, &mygcv);
+ mygc = XCreateGC (mydpy, mywindow, GCForeground, &mygcv);
+ }
+}
+
+#ifdef VERMICULATE_STANDALONE
+/* Function Name: GetVRoot (slightly changed from the X Windows FAQ)
+ * Description: Gets the root window, even if it's a virtual root
+ * Arguments: the display and the screen
+ * Returns: the root window for the client
+ */
+static Window
+GetVRoot (Display * dpy, int scr)
+{
+ Window rootReturn, parentReturn, *children;
+ unsigned int numChildren;
+ Window root = RootWindow (dpy, scr);
+ Atom __SWM_VROOT = None;
+ int i;
+
+ __SWM_VROOT = XInternAtom (dpy, "__SWM_VROOT", False);
+ XQueryTree (dpy, root, &rootReturn, &parentReturn, &children, &numChildren);
+ for (i = 0; i < numChildren; i++)
+ {
+ Atom actual_type;
+ int actual_format;
+ unsigned long int nitems, bytesafter;
+ Window *newRoot = NULL;
+
+ if (XGetWindowProperty (dpy, children[i], __SWM_VROOT, 0, 1,
+ False, XA_WINDOW, &actual_type, &actual_format,
+ &nitems, &bytesafter,
+ (unsigned char **) &newRoot) == Success
+ && newRoot)
+ {
+ root = *newRoot;
+ break;
+ }
+ }
+
+ XFree ((char *) children);
+ return root;
+}
+
+int
+main (int argc, char **argv)
+{
+ int argnum;
+ if ((mydpy = XOpenDisplay (NULL)) == NULL)
+ {
+ fprintf (stderr, "%s: cannot connect to X server %s\n", argv[0],
+ XDisplayName (NULL));
+ exit (1);
+ }
+
+ for (argnum = 1; argnum < argc; argnum++)
+ {
+ if (!strcmp (argv[argnum], "-geometry"))
+ {
+ int x, y;
+ unsigned int uh, uw;
+ XParseGeometry (argv[++argnum], &x, &y, &uw, &uh);
+ hei = (int) uh;
+ wid = (int) uw;
+ }
+ else if (!strcmp (argv[argnum], "-instring"))
+ instring = argv[++argnum];
+ else if (!strcmp (argv[argnum], "-root"))
+ use_root = True;
+ else if (!strcmp (argv[argnum], "-speed"))
+ speed = atoi (argv[++argnum]);
+ else
+ {
+ fprintf (stderr,
+ "\nvermiculate options are:"
+ "\n -speed NUMBER: set speed, can be from 1 to %d."
+ "\n -root: use root window."
+ "\n -instring STRING: put STRING in kbd buffer."
+ "\n -geometry WIDTHxHEIGHT \n", SPEEDMAX);
+ exit (1);
+ }
+ }
+
+ if (use_root)
+ mywindow = GetVRoot (mydpy, DefaultScreen (mydpy));
+ else
+ mywindow = XCreateSimpleWindow (mydpy, DefaultRootWindow (mydpy), 0, 0,
+ wid, hei, 0, 0, BlackPixel (mydpy,
+ DefaultScreen
+ (mydpy)));
+ XStoreName (mydpy, mywindow, "vermiculate");
+ XMapWindow (mydpy, mywindow);
+ commonXinit ();
+ XSelectInput (mydpy, mywindow,
+ KeyPressMask | ExposureMask | StructureNotifyMask);
+
+#undef ya_rand_init
+ ya_rand_init (0);
+
+ vermiculate_main ();
+ return 0;
+}
+
+#else
+
+void
+screenhack (Display * d, Window w)
+{
+ mydpy = d;
+ mywindow = w;
+ instring = get_string_resource ("instring", "Instring");
+ max_ticks = get_integer_resource ("ticks", "Integer");
+ {
+ int temp = get_integer_resource ("speed", "Speed");
+ if (temp != 0)
+ speed = temp;
+ }
+ commonXinit ();
+ mycolors[0].pixel = BlackPixel (mydpy, DefaultScreen (mydpy));
+ vermiculate_main ();
+}
+#endif /* VERMICULATE_STANDALONE */
use strict;
my $progname = $0; $progname =~ s@.*/@@g;
-my $version = q{ $Revision: 1.17 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
+my $version = q{ $Revision: 1.18 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
my $verbose = 0;
my $use_stdin = 0;
local *IN;
open (IN, "<$conf") || error "reading $conf: $!";
while (<IN>) {
- if (!$imagedir && m/^imageDirectory:\s+([^\s]+)\s*$/i) { $imagedir = $1; }
+ if (!$imagedir && m/^imageDirectory:\s+(.*)\s*$/i) { $imagedir = $1; }
elsif (m/^grabVideoFrames:\s+true\s*$/i) { $video_p = 1; }
elsif (m/^grabVideoFrames:\s+false\s*$/i) { $video_p = 0; }
elsif (m/^chooseRandomImages:\s+true\s*$/i) { $file_p = 1; }
$file_p = 1 if $had_dir;
+ $imagedir = undef unless ($imagedir && $imagedir ne '');
if (!$file_p && !$video_p) {
# error "neither grabVideoFrames nor chooseRandomImages are set\n\t" .
my $v = ($verbose <= 1 ? "" : "-" . ("v" x ($verbose-1)));
my $cmd;
if ($do_file_p) {
- $cmd = "xscreensaver-getimage-file $v --name $imagedir";
+ $cmd = "xscreensaver-getimage-file $v --name \"$imagedir\"";
} else {
$cmd = "xscreensaver-getimage-video $v --stdout";
}
print STDERR "$progname: selected file $fn\n" if ($verbose > 1);
- if ($fn =~ m/\.gif/i) { $cmd = "giftopnm < $fn"; }
- elsif ($fn =~ m/\.jpe?g/i) { $cmd = "djpeg < $fn"; }
+ if ($fn =~ m/\.gif/i) { $cmd = "giftopnm < \"$fn\""; }
+ elsif ($fn =~ m/\.jpe?g/i) { $cmd = "djpeg < \"$fn\""; }
else {
error "unrecognized file extension on $fn";
}
read_config;
if (!$use_stdout) {
- $_ = `xdpyinfo 2>-`;
+ $_ = `xdpyinfo 2>&-`;
($screen_width) =~ m/ dimensions: +(\d+)x(\d+) pixels/;
$screen_width = 800 unless $screen_width > 0;
}
my $progname = $0; $progname =~ s@.*/@@g;
-my $version = q{ $Revision: 1.77 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
+my $version = q{ $Revision: 1.78 $ }; $version =~ s/^[^0-9]+([0-9.]+).*$/$1/;
my $copyright = "WebCollage $version, Copyright (c) 1999-2001" .
" Jamie Zawinski <jwz\@jwz.org>\n" .
" http://www.jwz.org/xscreensaver/\n";
-my @search_methods = ( 35, "imagevista", \&pick_from_alta_vista_images,
- 33, "altavista", \&pick_from_alta_vista_text,
- 20, "yahoorand", \&pick_from_yahoo_random_link,
+my @search_methods = ( 30, "imagevista", \&pick_from_alta_vista_images,
+ 28, "altavista", \&pick_from_alta_vista_text,
+ 18, "yahoorand", \&pick_from_yahoo_random_link,
+ 14, "googleimgs", \&pick_from_google_images,
2, "yahoonews", \&pick_from_yahoo_news_text,
- 10, "lycos", \&pick_from_lycos_text,
+ 8, "lycos", \&pick_from_lycos_text,
# Hotbot gives me "no matches" just about every time.
# Then I try the same URL again, and it works. I guess
);
#@search_methods=(100, "lycos", \&pick_from_lycos_text);
+@search_methods=(100, "googleimgs",\&pick_from_google_images);
# programs we can use to write to the root window (tried in ascending order.)
#
my $no_output_p = 0;
my $urls_only_p = 0;
-my $wordlist = "/usr/dict/words";
-
-if (!-r $wordlist) {
- $wordlist = "/usr/share/dict/words"; # BSD
-}
-if (!-r $wordlist) {
- $wordlist = "/usr/share/lib/dict/words"; # Irix
-}
-die "$progname: $wordlist doesn't exist!\n" unless (-r $wordlist);
+my $wordlist;
my %rejected_urls;
my @tripwire_words = ("aberrate", "abode", "amorphous", "antioch",
my $cookie = $cookies{$them};
+ my $user_agent = "$progname/$version";
+ if ($url =~ m@^http://www\.altavista\.com/@) {
+ # block this, you turkeys.
+ $user_agent = "Mozilla/4.76 [en] (X11; U; Linux 2.2.16-22 i686; Nav)";
+ }
+
my $hdrs = "GET " . ($http_proxy ? $url : "/$path") . " HTTP/1.0\r\n" .
"Host: $them\r\n" .
- "User-Agent: $progname/$version\r\n";
+ "User-Agent: $user_agent\r\n";
if ($referer) {
$hdrs .= "Referer: $referer\r\n";
}
############################################################################
+sub pick_dictionary {
+ my @dicts = ("/usr/dict/words",
+ "/usr/share/dict/words",
+ "/usr/share/lib/dict/words");
+ foreach my $f (@dicts) {
+ if (-f $f) {
+ $wordlist = $f;
+ last;
+ }
+ }
+ error ("$dicts[0] does not exist") unless defined($wordlist);
+}
+
# returns a random word from the dictionary
#
sub random_word {
}
+\f
+############################################################################
+#
+# Pick images by feeding random words into Google Image Search
+# By Charles Gales <gales@us.ibm.com>
+#
+############################################################################
+
+
+my $google_images_url = "http://images.google.com/images" .
+ "?site=images" . # photos
+ "&btnG=Search" . # graphics
+ "&safe=off" . # no screening
+ "&imgsafe=off" .
+ "&q=";
+
+# googleimgs
+sub pick_from_google_images {
+ my ( $timeout ) = @_;
+
+ my $words = random_word; # only one word for Google
+ my $page = (int(rand(9)) + 1);
+ my $num = 20; # 20 images per page
+ my $search_url = $google_images_url . $words;
+
+ if ($page > 1) {
+ $search_url .= "&start=" . $page*$num; # page number
+ $search_url .= "&num=" . $num; #images per page
+ }
+
+ my ($search_hit_count, @subpages) =
+ pick_from_search_engine ($timeout, $search_url, $words);
+
+ my @candidates = ();
+ foreach my $u (@subpages) {
+ next unless ($u =~ m@imgres\?imgurl@i); # All pics start with this
+ next if ($u =~ m@[/.]google\.com\b@i); # skip google builtins
+
+ if ($u =~ m@^/imgres\?imgurl=(.*?)\&imgrefurl=(.*?)\&@) {
+ my $urlf = $2;
+ LOG ($verbose_filter, " candidate: $urlf");
+ push @candidates, $urlf;
+ }
+ }
+
+ return pick_image_from_pages ($search_url, $search_hit_count, $#subpages+1,
+ $timeout, @candidates);
+}
+
+
\f
############################################################################
#
srand(time ^ $$);
my $verbose = 0;
+ my $dict;
$current_state = "init";
$load_method = "none";
}
} elsif ($_ eq "-proxy" || $_ eq "-http-proxy") {
$http_proxy = shift @ARGV;
+ } elsif ($_ eq "-dictionary" || $_ eq "-dict") {
+ $dict = shift @ARGV;
} else {
print STDERR "$copyright\nusage: $progname [-root]" .
" [-display dpy] [-root] [-verbose] [-timeout secs]\n" .
"\t\t [-delay secs] [-filter cmd] [-filter2 cmd]\n" .
+ "\t\t [-dictionary dictionary-file]\n" .
"\t\t [-http-proxy host[:port]]\n";
exit 1;
}
$verbose_exec = 1;
}
+ if ($dict) {
+ error ("$dict does not exist") unless (-f $dict);
+ $wordlist = $dict;
+ } else {
+ pick_dictionary();
+ }
if ($urls_only_p) {
url_only_output;
* by the beauty of the shapes one receives when playing with sine waves
* Here is a little experiment to show that beauty is simple
*/
+#include <stdio.h>
#include <math.h>
#include "screenhack.h"
-#include <stdio.h>
-static XColor colors[1000];
-static int ncolors = 1000;
-static int current_color = 0;
-
-int
-draw_dot(Display *dpy,
- Window window,
- Colormap cmap,
- GC fgc, GC bgc,
- int current_time,
- int origin_x, int origin_y,
- int screen_num, double xspeed, double yspeed,
- int whirlies, int nlines)
-{
- int size, last_size; /* The size of my dot */
- int start_arc = 0; /* Start my circle at 0 degrees */
- int end_arc = 23040; /* The number of degrees in a X circle (360 * 64) */
- int horiz, vert; /* These will contain the new x,y coordinates to put my dot */
- int last_horiz ,last_vert; /* These contain the positions to black out */
- int last_time;
- int count, line_count;
- int line_offset, last_line_offset;
- int color_offset;
- XWindowAttributes xgwa;
- XGetWindowAttributes (dpy, window, &xgwa);
- if (++current_color >= ncolors)
- current_color = 0;
- for (count = 0; count < whirlies; count++) {
- color_offset = (current_color + (10 * count )) % ncolors;
- if (current_time == count) {
- last_time = current_time;
- }
- else {
- current_time = current_time + count;
- last_time = current_time - 1;
- }
- last_horiz = compute_x(last_time, origin_x, xspeed);
- last_vert = compute_y(last_time, origin_y, yspeed);
- horiz = compute_x(current_time, origin_x, xspeed);
- vert = compute_y(current_time, origin_y, yspeed);
- for (line_count = 0; line_count < nlines; line_count++) {
- last_line_offset = (int)(80.0 * line_count * sin((double)last_time / 90));
- line_offset = (int)(80.0 * line_count * sin((double)current_time / 90));
- last_size = (int)(15.0 + 5.0 * sin((double)last_time / 180.0));
- size = (int)(15.0 + 5.0 * sin((double)current_time / 180.0));
- /* Get rid of the old circle */
- XSetForeground(dpy, bgc, BlackPixel(dpy, screen_num));
- XFillArc(dpy, window, bgc, last_horiz, last_line_offset+last_vert, last_size, last_size, start_arc, end_arc);
- /* Draw in the new circle */
- XSetForeground(dpy, bgc, colors[color_offset].pixel);
- XFillArc(dpy, window, bgc, horiz, line_offset+vert, size, size, start_arc, end_arc);
- }
- }
- XSync (dpy, False);
- if (current_time == 23040)
- {
- return(1);
- }
- else
- {
- return(0);
- }
-}
+#define NCOLORS 1000
+#define FULL_CYCLE 429496729
+#define START_ARC 0
+#define END_ARC 23040
-int compute_x(int the_time, int origin, double xspeed)
-{
- double funky = (((the_time % 360) * 1.0) / 180.0) * M_PI;
- double the_cosine = cos((double)the_time / (180.0 * xspeed));
- double dist_mod_x = cos((double)funky) * (origin - 50);
- int horiz_pos = origin + (the_cosine * dist_mod_x);
- return(horiz_pos);
-}
+struct info {
+ Bool writable; /* Is the screen writable */
+ double xspeed; /* A factor to modify the horizontal movement */
+ double yspeed; /* A factor to modify vertical movement */
+ double xamplitude;
+ double yamplitude;
+ int whirlies; /* How many whirlies per line do you want? */
+ int nlines; /* How many lines of whirlies do you want? */
+ int half_width; /* 1/2 the width of the screen */
+ int half_height;
+ int speed;
+ int trail;
+ int color_modifier;
+ double xoffset;
+ double yoffset;
+ double offset_period;
+ int wrap;
+};
-int compute_y(int the_time, int origin, double yspeed)
-{
- double funky = (((the_time % 360) * 1.0) / 180.0) * M_PI;
- double the_sine = sin((double)the_time / (180.0 * yspeed));
- double dist_mod_y = sin((double)funky) * (origin - 50);
- int vert_pos = origin + (the_sine * dist_mod_y);
- return(vert_pos);
-}
+enum object_mode {
+ spin_mode, funky_mode, circle_mode, linear_mode, test_mode, fun_mode, innie_mode, lissajous_mode
+} mode;
+
+static void explain(int, struct info *, Display *, Window, GC);
+static void spin(unsigned long int, struct info *, int *, int);
+static void funky(unsigned long int, struct info *, int *, int);
+static void circle(unsigned long int, struct info *, int *, int);
+static void fun(unsigned long int, struct info *, int *, int);
+static void linear(unsigned long int, struct info *, int *, int);
+static void lissajous(unsigned long int, struct info *, int *, int);
+static void test(unsigned long int, struct info *, int *, int);
+static void innie(unsigned long int, struct info *, int *, int, double);
+
+
+
+XColor colors[NCOLORS];
+int ncolors = NCOLORS;
char *progclass = "Whirlygig";
char *defaults [] = {
- ".background: black",
- ".foreground: white",
- "*xspeed: 1.0",
- "*yspeed: 1.0",
- "*whirlies: 10",
- "*nlines: 1",
+ ".background: black",
+ ".foreground: white",
+ "*xspeed: 1.0",
+ "*yspeed: 1.0",
+ "*xamplitude: 1.0",
+ "*yamplitude: 1.0",
+ "*whirlies: -1",
+ "*nlines: -1",
+ "*xmode: change",
+ "*ymode: change",
+ "*speed: 1",
+ "*trail: 0",
+ "*color_modifier: -1",
+ "*start_time: -1",
+ "*explain: 0",
+ "*xoffset: 1.0",
+ "*yoffset: 1.0",
+ "*offset_period: 1",
+ "*wrap: 0",
0
};
XrmOptionDescRec options [] = {
{ "-xspeed", ".xspeed", XrmoptionSepArg, 0 },
+ /* xspeed is a modifier of the argument to cos -- changing it thus
+ changes the frequency of cos */
{ "-yspeed", ".yspeed", XrmoptionSepArg, 0 },
+ /* Similiarly, yspeed changes the frequency of sin */
+ { "-xamplitude", ".xamplitude", XrmoptionSepArg, 0 },
+ /* A factor by which to increase/decrease the amplitude of the sin */
+ { "-yamplitude", ".yamplitude", XrmoptionSepArg, 0 },
+ /* A factor by which to increase/decrease the amplitude of the cos */
{ "-whirlies", ".whirlies",XrmoptionSepArg, 0 },
+ /* whirlies defines the number of circles to draw per line */
{ "-nlines", ".nlines",XrmoptionSepArg, 0 },
+ /* nlines is the number of lines of whirlies to draw */
+ { "-xmode", ".xmode", XrmoptionSepArg, 0 },
+ /* There are a few different modes that I have written -- each mode
+ is in theory a different experiment with the possible modifiers to sin/cos */
+ { "-ymode", ".ymode", XrmoptionSepArg, 0 },
+ { "-speed", ".speed", XrmoptionSepArg, 0 },
+ /* This will modify how often it should draw, changing it will probably suck */
+ { "-trail", ".trail", XrmoptionSepArg, 0 },
+ /* Control whether or not you want the old circles to be erased */
+ { "-color_modifier", ".color_modifier", XrmoptionSepArg, 0 },
+ /* How many colors away from the current should the next whirly be? */
+ { "-start_time", ".start_time", XrmoptionSepArg, 0 },
+ /* Specify exactly at what time to start graphing... */
+ { "-xoffset", ".xoffset", XrmoptionSepArg, 0 },
+ /* Tell the whirlies to be offset by this factor of a sin */
+ { "-yoffset", ".yoffset", XrmoptionSepArg, 0 },
+ /* Tell the whirlies to be offset by this factor of a cos */
+ { "-offset_period", ".offset_period", XrmoptionSepArg, 0 },
+ /* Change the period of an offset cycle */
+ { "-explain", ".explain", XrmoptionSepArg, 0 },
+ /* Specify whether or not to print an explanation of the function used. */
+ { "-wrap", ".wrap", XrmoptionSepArg, 0 },
+ /* Specify if you want whirlies which are out of the boundary of the screen to be
+ wrapped around to the other side */
{ 0, 0, 0, 0 }
};
-void screenhack (Display *dpy, Window window)
+
+static const char funky_explanation[] =
+"Funky mode is me goofing off.";
+
+static const char test_explanation[] =
+"Test mode is a mode that I play around with ideas in.";
+
+static const char spin_explanation[] =
+"Spin mode is a simple sin/cos with every argument modified";
+
+static const char circle_explanation[] =
+"Circle mode graphs the x and y positions as you trace the edge of a circle over time.";
+
+static const char fun_explanation[] =
+"Fun mode is the coolest.";
+
+static const char linear_explanation[] =
+"I draw a straight line -- woo hoo";
+
+static const char lissajous_explanation[] =
+"This draws a slightly modified lissajous curve";
+
+static void
+explain(int mode, struct info *info, Display *display, Window window, GC fgc)
+{
+ XClearWindow(display, window);
+ switch(mode) {
+ case spin_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, spin_explanation, strlen(spin_explanation));
+ break;
+ case funky_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, funky_explanation, strlen(funky_explanation));
+ break;
+ case circle_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, circle_explanation, strlen(circle_explanation));
+ break;
+ case fun_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, fun_explanation, strlen(fun_explanation));
+ break;
+ case linear_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, linear_explanation, strlen(linear_explanation));
+ break;
+ case lissajous_mode:
+ XDrawString(display, window, fgc, 50, info->half_height-100, lissajous_explanation, strlen(linear_explanation));
+
+ }
+ XSync(display, False);
+ sleep(3);
+ XClearWindow(display, window);
+}
+
+static void
+funky(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ double new_time = ((the_time % 360 ) / 180.0) * M_PI;
+ if (index == 0) {
+ double time_modifier = cos(new_time / 180.0);
+ double the_cos = cos((new_time * (double)info->xspeed) + (time_modifier * 80.0));
+ double dist_mod_x = cos(new_time) * (info->half_width - 50);
+ pos[index]= info->xamplitude * (the_cos * dist_mod_x) + info->half_width;
+ }
+ else {
+ double new_time = ((the_time % 360 ) / 180.0) * M_PI;
+ double time_modifier = sin(new_time / 180.0);
+ double the_sin = sin((new_time * (double)info->yspeed) + (time_modifier * 80.0));
+ double dist_mod_y = sin(new_time) * (info->half_height - 50);
+ pos[index] = info->yamplitude * (the_sin * dist_mod_y) + info->half_height;
+ }
+}
+
+static void
+innie(unsigned long int the_time, struct info *info, int pos[], int index, double modifier)
+{
+ double frequency = 2000000.0 + (modifier * cos(((double)the_time / 100.0)));
+ double arg = (double)the_time / frequency;
+ double amplitude = 200.0 * cos(arg);
+ double fun = 150.0 * cos((double)the_time / 2000.0);
+ int vert_mod, horiz_mod;
+ if (index == 0) {
+ horiz_mod = (int)(fun * cos((double)the_time / 100.0)) + info->half_width;
+ pos[index] = (amplitude * cos((double)the_time / 100.0 * info->xspeed)) + horiz_mod;
+ }
+ else {
+ vert_mod = (int)(fun * sin((double)the_time / 100.0)) + info->half_height;
+ pos[index] = (amplitude * sin((double)the_time / 100.0 * info->yspeed)) + vert_mod;
+ }
+}
+
+static void
+lissajous(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ /* This is a pretty standard lissajous curve
+ x = a sin(nt + c)
+ y = b sin(t)
+ The n and c modifiers are cyclic as well, however... */
+ int result;
+ double time = (double)the_time / 100.0;
+ double fun = 15.0 * cos((double)the_time / 800.0);
+ double weird = cos((time / 1100000.0) / 1000.0);
+
+ if (index == 0) {
+ result = info->xamplitude * 200.0 * sin((weird * time) + fun) + info->half_width;
+ }
+ else {
+ result = info->yamplitude * 200.0 * sin(time) + info->half_height;
+ }
+ pos[index] = result;
+}
+
+static void
+circle(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ int result;
+ if (index == 0) {
+ result = info->xamplitude * (cos((double)the_time / 100.0 * info->xspeed) * (info->half_width / 2)) + info->half_width;
+ }
+ else {
+ result = info->yamplitude * (sin((double)the_time / 100.0 * info->yspeed) * (info->half_height / 2)) + info->half_height;
+ }
+ pos[index] = result;
+}
+
+#if 0
+static void
+mod(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ int amplitude;
+ int max = info->half_width;
+ if ((the_time % (max * 2)) < max)
+ amplitude = max - ((the_time % (max * 2)) - max);
+ else
+ amplitude = the_time % (max * 2);
+ amplitude = amplitude - max;
+}
+#endif
+
+static void
+spin(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ double funky = (((the_time % 360) * 1.0) / 180.0) * M_PI;
+ if (index ==0) {
+ double the_cos = cos((double)the_time / (180.0 * info->xspeed));
+ double dist_mod_x = cos((double)funky) * (info->half_width - 50);
+ pos[index] = info->xamplitude * (the_cos * dist_mod_x) + info->half_width;
+ }
+ else {
+ double the_sin = sin((double)the_time / (180.0 * info->yspeed));
+ double dist_mod_y = sin((double)funky) * (info->half_height - 50);
+ pos[index] = info->yamplitude * (the_sin * dist_mod_y) + info->half_height;
+ }
+}
+
+static void
+fun(unsigned long int the_time, struct info *info, int pos[], int index)
{
- GC fgc, bgc; /* the foreground and background graphics contexts */
+ int amplitude;
+ int max = info->half_width;
+ if ((the_time % (max * 2)) < max)
+ amplitude = max - ((the_time % (max * 2)) - max);
+ else
+ amplitude = the_time % (max * 2);
+ amplitude = amplitude - max;
+ if (index ==0) {
+ pos[index] = (amplitude * cos((double)the_time / 100.0 * info->xspeed)) + info->half_width;
+ }
+ else {
+ pos[index] = (amplitude * sin((double)the_time / 100.0 * info->yspeed)) + info->half_height;
+ }
+}
+
+static void
+linear(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ if (index == 0) /* Calculate for the x axis */
+ pos[index] = ((the_time / 2) % (info->half_width * 2));
+ else
+ pos[index] = ((the_time / 2) % (info->half_height * 2));
+}
+
+static void
+test(unsigned long int the_time, struct info *info, int pos[], int index)
+{
+ if (index == 0) {
+ pos[index] = info->xamplitude * (cos((double)the_time / 100.0 * info->xspeed) * (info->half_width / 2)) + info->half_width;
+ }
+ else {
+ pos[index] = info->yamplitude * (sin((double)the_time / 100.0 * info->yspeed) * (info->half_height / 2)) + info->half_height;
+ }
+}
+
+static int preen(int current, int max) {
+ if (current > max)
+ current=current-max;
+ if (current < 0)
+ current=current+max;
+ return(current);
+}
+
+static void
+smoothen(int x, int lastx, int y, int lasty, int size, int last_color, XColor *colors, Display *display, Window window, GC bgc, int screen, struct info *info)
+{
+ double xdistance = abs((double)x-(double)lastx);
+ double ydistance = abs((double)y-(double)lasty);
+ double distance = sqrt(((xdistance * xdistance) + (ydistance * ydistance)) );
+ double slope = (((double)y-(double)lasty) / ((double)x-(double)lastx));
+ printf("Starting smoothen with values: %f, %f, %f, %f\n", xdistance, ydistance, distance, slope);
+ if (distance > 2.0) {
+ int newx = (int)((xdistance / distance) * slope);
+ int newy = (int)((ydistance / distance) * slope);
+ if (! info->trail) {
+ XSetForeground(display, bgc, BlackPixel(display, screen));
+ XFillArc(display, window, bgc, lastx, lasty, size, size, START_ARC, END_ARC);
+ }
+ XSetForeground(display, bgc, colors[last_color].pixel);
+ XFillArc(display, window, bgc, newx, newy, size, size, START_ARC, END_ARC);
+ XSync(display, False);
+ smoothen(newx, x, newy, y, size, last_color, colors, display, window, bgc, screen, info);
+ }
+}
+
+
+void
+screenhack (Display *display, Window window)
+{
+ /* The following are all X related toys */
XGCValues gcv; /* The structure to hold the GC data */
XWindowAttributes xgwa; /* A structure to hold window data */
- Bool writable = get_boolean_resource ("cycle", "Boolean");
- double xspeed = get_float_resource( "xspeed", "Float");
- double yspeed = get_float_resource( "yspeed", "Float");
- int whirlies = get_integer_resource( "whirlies", "Integer");
- int nlines = get_integer_resource( "nlines", "Integer");
- int time_counter = 0; /* This will be incremented in my while loop so that I can move my circle */
- int screen_num = DefaultScreen(dpy);
- int half_width, half_height;
- XGetWindowAttributes (dpy, window, &xgwa);
-
- half_width = xgwa.width / 2;
- half_height = xgwa.height / 2;
-
- gcv.foreground = get_pixel_resource("foreground", "Foreground", dpy, xgwa.colormap);
- fgc = XCreateGC (dpy, window, GCForeground, &gcv);
- gcv.foreground = get_pixel_resource("background", "Background", dpy, xgwa.colormap);
- bgc = XCreateGC (dpy, window, GCForeground, &gcv);
- make_uniform_colormap (dpy, xgwa.visual, xgwa.colormap,
- colors, &ncolors,
- True, &writable, True);
- mono_p = True;
- if (!mono_p)
- {
- GC tmp = fgc;
- fgc = bgc;
- bgc = tmp;
+ GC fgc, bgc;
+ int screen;
+
+ unsigned long int current_time = 0; /* The global int telling the current time */
+ unsigned long int start_time = current_time;
+ struct info *info = (struct info *)malloc(sizeof(struct info)); /* Dont forget to call free() later */
+ char *xmode_str, *ymode_str; /* holds the current mode for x and y computation */
+ /* pos is the current position x,y -- last_x contains one cell of every x coordinate
+ for every position of every whirly in every line up to 100 whirlies in 100 lines
+ -- lasy_y and last_size hold the same information for y and size respectively */
+ int pos[2], last_x[100][100], last_y[100][100], last_size[100][100];
+ int current_color;
+ int wrap;
+ int xmode, ymode;
+ double modifier; /* for innie */
+ /* Set up the X toys that I will be using later */
+ screen = DefaultScreen(display);
+ XGetWindowAttributes (display, window, &xgwa);
+ gcv.foreground = get_pixel_resource("foreground", "Foreground", display, xgwa.colormap);
+ fgc = XCreateGC (display, window, GCForeground, &gcv);
+ gcv.foreground = get_pixel_resource("background", "Background", display, xgwa.colormap);
+ bgc = XCreateGC (display, window, GCForeground, &gcv);
+ make_uniform_colormap (display, xgwa.visual, xgwa.colormap, colors, &ncolors, True, &info->writable, True);
+ /* info is a structure holding all the random pieces of information I may want to
+ pass to my baby functions -- much of it I may never use, but it is nice to
+ have around just in case I want it to make a funky function funkier */
+ info->writable = get_boolean_resource ("cycle", "Boolean");
+ info->xspeed = get_float_resource("xspeed" , "Float");
+ info->yspeed = get_float_resource("yspeed" , "Float");
+ info->xamplitude = get_float_resource("xamplitude", "Float");
+ info->yamplitude = get_float_resource("yamplitude", "Float");
+ info->offset_period = get_float_resource("offset_period", "Float");
+ info->whirlies = get_integer_resource("whirlies", "Integer");
+ info->nlines = get_integer_resource("nlines", "Integer");
+ info->half_width = xgwa.width / 2;
+ info->half_height = xgwa.height / 2;
+ info->speed = get_integer_resource("speed" , "Integer");
+ info->trail = get_integer_resource("trail", "Integer");
+ info->color_modifier = get_integer_resource("color_modifier", "Integer");
+ info->xoffset = get_float_resource("xoffset", "Float");
+ info->yoffset = get_float_resource("yoffset", "Float");
+ xmode_str = get_string_resource("xmode", "Mode");
+ ymode_str = get_string_resource("ymode", "Mode");
+ wrap = get_integer_resource("wrap", "Integer");
+ modifier = 3000.0 + (1500.0 * random() / (RAND_MAX + 1.0));
+ if (! xmode_str) xmode = spin_mode;
+ else if (! strcmp (xmode_str, "spin")) xmode = spin_mode;
+ else if (! strcmp (xmode_str, "funky")) xmode = funky_mode;
+ else if (! strcmp (xmode_str, "linear")) xmode = linear_mode;
+ else if (! strcmp (xmode_str, "fun")) xmode = fun_mode;
+ else if (! strcmp (xmode_str, "innie")) xmode = innie_mode;
+ else if (! strcmp (xmode_str, "lissajous")) xmode = lissajous_mode;
+ else if (! strcmp (xmode_str, "test")) xmode = test_mode;
+ else {
+ xmode = spin_mode;
+ }
+ if (! ymode_str) ymode = spin_mode;
+ else if (! strcmp (ymode_str, "spin")) ymode = spin_mode;
+ else if (! strcmp (ymode_str, "funky")) ymode = funky_mode;
+ else if (! strcmp (ymode_str, "linear")) ymode = linear_mode;
+ else if (! strcmp (ymode_str, "fun")) ymode = fun_mode;
+ else if (! strcmp (ymode_str, "innie")) ymode = innie_mode;
+ else if (! strcmp (ymode_str, "lissajous")) ymode = lissajous_mode;
+ else if (! strcmp (ymode_str, "test")) ymode = test_mode;
+ else {
+ ymode = spin_mode;
}
- while (1)
- {
- /* draw_dot will return an interger. If this interger is 0, then continue incrementing
- time_counter, if it is 1, then reset it to zero... It should only become 1 with the sine
- is 0 and the cosine is 1 */
- if (draw_dot(dpy, window, xgwa.colormap, fgc, bgc, time_counter, half_width, half_height, screen_num, xspeed , yspeed, whirlies, nlines) == 1) {
- time_counter = 1;
+ if (get_integer_resource("start_time", "Integer") == -1)
+ current_time = (unsigned long int)(random());
+ else
+ current_time = get_integer_resource("start_time", "Integer");
+ if (info->whirlies == -1)
+ info->whirlies = 1 + (int)(15.0 * random() / (RAND_MAX + 1.0));
+ if (info->nlines == -1)
+ info->nlines = 1 + (int)(5.0 * random() / (RAND_MAX + 1.0));
+ if (info->color_modifier == -1)
+ info->color_modifier = 1 + (int)(25.0 * random() / (RAND_MAX + 1.0));
+ if (get_integer_resource("explain", "Integer") == 1)
+ explain(mode, info, display, window, fgc);
+ current_color = 1 + (int)((double)NCOLORS * random() / (RAND_MAX + 1.0));
+ /* Now that info is full, lets play! */
+
+ while (1) {
+ int wcount; /* wcount is a counter incremented for every whirly take note of
+ internal_time before you mess with it */
+ int change_time = 4000;
+ if (! strcmp (xmode_str, "change") && ! strcmp (ymode_str, "change")) {
+ if ((current_time - start_time) > change_time) {
+ start_time = current_time;
+ xmode = 1 + (int)(4.0 * random() / (RAND_MAX + 1.0));
+ ymode = 1 + (int)(4.0 * random() / (RAND_MAX + 1.0));
+ }
}
- else {
- time_counter++;
+ else if (! strcmp (xmode_str, "change")) {
+ if ((current_time - start_time) > change_time) {
+ start_time = current_time;
+ xmode = 1 + (int)(3.5 * random() / (RAND_MAX + 1.0));
+ }
}
- screenhack_handle_events (dpy);
-
- if (!writable)
- usleep(10);
- }
+ else if (! strcmp (ymode_str, "change")) {
+ if ((current_time - start_time) > change_time) {
+ start_time = current_time;
+ ymode = 1 + (int)(3.0 * random() / (RAND_MAX + 1.0));
+ printf("Changing ymode to %d\n", ymode);
+ }
+ }
+ if (++current_color >= NCOLORS)
+ current_color = 0;
+ for (wcount = 0; wcount < info->whirlies; wcount++) {
+ int lcount; /* lcount is a counter for every line -- take note of the offsets changing */
+ int internal_time = current_time;
+ int color_offset = (current_color + (info->color_modifier * wcount)) % NCOLORS;
+ if (current_time == 0)
+ internal_time = 0;
+ else
+ /* I want the distance between whirlies to increase more each whirly */
+ internal_time = current_time + (10 * wcount) + (wcount * wcount);
+ switch (xmode) {
+ /* All these functions expect an int time, the struct info, a pointer to an array of positions,
+ and the index that the the function will fill of the array */
+ case spin_mode:
+ spin(internal_time, info, pos, 0);
+ break;
+ case funky_mode:
+ funky(internal_time, info, pos, 0);
+ break;
+ case circle_mode:
+ circle(internal_time, info, pos, 0);
+ break;
+ case linear_mode:
+ linear(internal_time, info, pos, 0);
+ break;
+ case fun_mode:
+ fun(internal_time, info, pos, 0);
+ break;
+ case test_mode:
+ test(internal_time, info, pos, 0);
+ break;
+ case innie_mode:
+ innie(internal_time, info, pos, 0, modifier);
+ break;
+ case lissajous_mode:
+ lissajous(internal_time, info, pos, 0);
+ break;
+ default:
+ spin(internal_time, info, pos, 0);
+ break;
+ } /* End of the switch for the x position*/
+ switch (ymode) {
+ case spin_mode:
+ spin(internal_time, info, pos, 1);
+ break;
+ case funky_mode:
+ funky(internal_time, info, pos, 1);
+ break;
+ case circle_mode:
+ circle(internal_time, info, pos, 1);
+ break;
+ case linear_mode:
+ linear(internal_time, info, pos, 1);
+ break;
+ case fun_mode:
+ fun(internal_time, info, pos, 1);
+ break;
+ case test_mode:
+ test(internal_time, info, pos, 1);
+ break;
+ case innie_mode:
+ innie(internal_time, info, pos, 1, modifier);
+ break;
+ case lissajous_mode:
+ lissajous(internal_time, info, pos, 1);
+ break;
+ default:
+ spin(internal_time, info, pos, 1);
+ break;
+ } /* End of the switch for the y position*/
+ for (lcount = 0; lcount < info->nlines; lcount++) {
+ double arg = (double)((internal_time * info->offset_period) / 90.0);
+ double line_offset = 20.0 * (double)lcount * sin(arg);
+ int size;
+ size = (int)(15.0 + 5.0 * sin((double)internal_time / 180.0));
+/* First delete the old circle... */
+ if (! info->trail) {
+ XSetForeground(display, bgc, BlackPixel(display, screen));
+ XFillArc(display, window, bgc, last_x[wcount][lcount], last_y[wcount][lcount], last_size[wcount][lcount], last_size[wcount][lcount], START_ARC, END_ARC);
+ }
+ /* Now, lets draw in the new circle */
+ { /* Starting new scope for local x_pos and y_pos */
+ int xpos, ypos;
+ if (wrap) {
+ xpos = preen((int)(info->xoffset*line_offset)+pos[0], info->half_width * 2);
+ ypos = preen((int)(info->yoffset*line_offset)+pos[1], info->half_height * 2);
+ }
+ else {
+ xpos = (int)(info->xoffset*line_offset)+pos[0];
+ ypos = (int)(info->yoffset*line_offset)+pos[1];
+ }
+ if (start_time == current_time) {
+ /* smoothen should move from one mode to another prettily... */
+/*
+ smoothen(xpos, last_x[wcount][lcount], ypos, last_y[wcount][lcount], size, color_offset, colors, display, window, bgc, screen, info);
+ */
+ }
+ last_x[wcount][lcount] = xpos;
+ last_y[wcount][lcount] = ypos;
+ last_size[wcount][lcount] = size;
+ XSetForeground(display, bgc, colors[color_offset].pixel);
+ XFillArc(display, window, bgc, xpos, ypos, size, size, START_ARC, END_ARC);
+ } /* End of my temporary scope for xpos and ypos */
+ } /* End of the for each line in nlines */
+ } /* End of the for each whirly in whirlies */
+ XSync(display, False);
+ if (current_time == FULL_CYCLE)
+ current_time = 1;
+ else
+ current_time = current_time + info->speed;
+ screenhack_handle_events(display);
+ if (!info->writable)
+ usleep(10000);
+ } /* End the while loop! */
+ free(info);
}
-
SIGQUIT,
SIGILL,
SIGTRAP,
+#if defined(SIGIOT)
SIGIOT,
+#endif
SIGABRT,
#if defined(SIGEMT)
SIGEMT,
$ t3d :== $'mydir't3d
$ triangle :== $'mydir'triangle
$ truchet :== $'mydir'truchet
+$ vermiculate :== $'mydir'vermiculate
$ vines :== $'mydir'vines
$ wander :== $'mydir'wander
$ whirlwindwarp :== $'mydir'whirlwindwarp
for (j = 0; j < granularity; j++)
{
int ii = i * granularity + j;
+
+ if (ii >= horiz_p ? height : width) /* don't go off array */
+ break;
+
if (horiz_p)
XDrawLine (dpy, window, gc, 0, lines[ii], width, lines[ii]);
else
#include <X11/extensions/xf86vmode.h>
-static Bool xf86_whack_gamma(Display *dpy, int screen,
- XF86VidModeGamma *info, float ratio);
-static Bool xf86_check_gamma_extension (Display *dpy);
+typedef struct {
+ XF86VidModeGamma vmg;
+ int size;
+ unsigned short *r, *g, *b;
+} xf86_gamma_info;
+
+static int xf86_check_gamma_extension (Display *dpy);
+static Bool xf86_whack_gamma (Display *dpy, int screen,
+ xf86_gamma_info *ginfo, float ratio);
static int
xf86_gamma_fade (Display *dpy,
#endif
int i, screen;
int status = -1;
- XF86VidModeGamma *info = 0;
+ xf86_gamma_info *info = 0;
static int ext_ok = -1;
/* Only probe the extension once: the answer isn't going to change. */
if (ext_ok == -1)
- ext_ok = (xf86_check_gamma_extension (dpy) ? 1 : 0);
+ ext_ok = xf86_check_gamma_extension (dpy);
/* If this server doesn't have the gamma extension, bug out. */
if (ext_ok == 0)
goto FAIL;
- info = (XF86VidModeGamma *) calloc(nscreens, sizeof(*info));
+# ifndef HAVE_XF86VMODE_GAMMA_RAMP
+ if (ext_ok == 2) ext_ok = 1; /* server is newer than client! */
+# endif
+
+ info = (xf86_gamma_info *) calloc(nscreens, sizeof(*info));
/* Get the current gamma maps for all screens.
Bug out and return -1 if we can't get them for some screen.
*/
for (screen = 0; screen < nscreens; screen++)
{
- if (!XF86VidModeGetGamma(dpy, screen, &info[screen]))
- goto FAIL;
+ if (ext_ok == 1) /* only have gamma parameter, not ramps. */
+ {
+ if (!XF86VidModeGetGamma(dpy, screen, &info[screen].vmg))
+ goto FAIL;
+ }
+ else if (ext_ok == 2) /* have ramps */
+ {
+ if (!XF86VidModeGetGammaRampSize(dpy, screen, &info[screen].size))
+ goto FAIL;
+ if (info[screen].size <= 0)
+ goto FAIL;
+
+ info[screen].r = (unsigned short *)
+ calloc(info[screen].size, sizeof(unsigned short));
+ info[screen].g = (unsigned short *)
+ calloc(info[screen].size, sizeof(unsigned short));
+ info[screen].b = (unsigned short *)
+ calloc(info[screen].size, sizeof(unsigned short));
+
+ if (!(info[screen].r && info[screen].g && info[screen].b))
+ goto FAIL;
+
+ if (!XF86VidModeGetGammaRamp(dpy, screen, info[screen].size,
+ info[screen].r,
+ info[screen].g,
+ info[screen].b))
+ goto FAIL;
+ }
+ else
+ abort();
}
#ifdef GETTIMEOFDAY_TWO_ARGS
status = 0;
FAIL:
- if (info) free(info);
+ if (info)
+ {
+ for (screen = 0; screen < nscreens; screen++)
+ {
+ if (info[screen].r) free(info[screen].r);
+ if (info[screen].g) free(info[screen].g);
+ if (info[screen].b) free(info[screen].b);
+ }
+ free(info);
+ }
return status;
}
-/* VidModeExtension version 2.0 or better is needed to do gamma. */
+/* VidModeExtension version 2.0 or better is needed to do gamma.
+ 2.0 added gamma values; 2.1 added gamma ramps.
+ */
# define XF86_VIDMODE_NAME "XFree86-VidModeExtension"
-# define XF86_VIDMODE_MIN_MAJOR 2
-# define XF86_VIDMODE_MIN_MINOR 0
+# define XF86_VIDMODE_GAMMA_MIN_MAJOR 2
+# define XF86_VIDMODE_GAMMA_MIN_MINOR 0
+# define XF86_VIDMODE_GAMMA_RAMP_MIN_MAJOR 2
+# define XF86_VIDMODE_GAMMA_RAMP_MIN_MINOR 1
-static Bool
+/* Returns 0 if gamma fading not available; 1 if only gamma value setting
+ is available; 2 if gamma ramps are available.
+ */
+static int
xf86_check_gamma_extension (Display *dpy)
{
int op, event, error, major, minor;
if (!XQueryExtension (dpy, XF86_VIDMODE_NAME, &op, &event, &error))
- return False; /* display doesn't have the extension. */
+ return 0; /* display doesn't have the extension. */
if (!XF86VidModeQueryVersion (dpy, &major, &minor))
- return False; /* unable to get version number? */
+ return 0; /* unable to get version number? */
+
+ if (major < XF86_VIDMODE_GAMMA_MIN_MAJOR ||
+ (major == XF86_VIDMODE_GAMMA_MIN_MAJOR &&
+ minor < XF86_VIDMODE_GAMMA_MIN_MINOR))
+ return 0; /* extension is too old for gamma. */
- if (major < XF86_VIDMODE_MIN_MAJOR ||
- (major == XF86_VIDMODE_MIN_MAJOR &&
- minor < XF86_VIDMODE_MIN_MINOR))
- return False; /* extension is too old. */
+ if (major < XF86_VIDMODE_GAMMA_RAMP_MIN_MAJOR ||
+ (major == XF86_VIDMODE_GAMMA_RAMP_MIN_MAJOR &&
+ minor < XF86_VIDMODE_GAMMA_RAMP_MIN_MINOR))
+ return 1; /* extension is too old for gamma ramps. */
/* Copacetic */
- return True;
+ return 2;
}
static Bool
-xf86_whack_gamma(Display *dpy, int screen, XF86VidModeGamma *info,
+xf86_whack_gamma(Display *dpy, int screen, xf86_gamma_info *info,
float ratio)
{
Bool status;
- XF86VidModeGamma g2;
if (ratio < 0) ratio = 0;
if (ratio > 1) ratio = 1;
- g2.red = info->red * ratio;
- g2.green = info->green * ratio;
- g2.blue = info->blue * ratio;
+ if (info->size == 0) /* we only have a gamma number, not a ramp. */
+ {
+ XF86VidModeGamma g2;
+
+ g2.red = info->vmg.red * ratio;
+ g2.green = info->vmg.green * ratio;
+ g2.blue = info->vmg.blue * ratio;
# ifdef XF86_MIN_GAMMA
- if (g2.red < XF86_MIN_GAMMA) g2.red = XF86_MIN_GAMMA;
- if (g2.green < XF86_MIN_GAMMA) g2.green = XF86_MIN_GAMMA;
- if (g2.blue < XF86_MIN_GAMMA) g2.blue = XF86_MIN_GAMMA;
+ if (g2.red < XF86_MIN_GAMMA) g2.red = XF86_MIN_GAMMA;
+ if (g2.green < XF86_MIN_GAMMA) g2.green = XF86_MIN_GAMMA;
+ if (g2.blue < XF86_MIN_GAMMA) g2.blue = XF86_MIN_GAMMA;
# endif
-/* #### printf(" G %4.2f %4.2f\n", ratio, g2.red); */
+ status = XF86VidModeSetGamma (dpy, screen, &g2);
+ }
+ else
+ {
+# ifdef HAVE_XF86VMODE_GAMMA_RAMP
+
+ unsigned short *r, *g, *b;
+ int i;
+ r = (unsigned short *) malloc(info->size * sizeof(unsigned short));
+ g = (unsigned short *) malloc(info->size * sizeof(unsigned short));
+ b = (unsigned short *) malloc(info->size * sizeof(unsigned short));
+
+ for (i = 0; i < info->size; i++)
+ {
+ r[i] = info->r[i] * ratio;
+ g[i] = info->g[i] * ratio;
+ b[i] = info->b[i] * ratio;
+ }
+
+ status = XF86VidModeSetGammaRamp(dpy, screen, info->size, r, g, b);
+
+ free (r);
+ free (g);
+ free (b);
+
+# else /* !HAVE_XF86VMODE_GAMMA_RAMP */
+ abort();
+# endif /* !HAVE_XF86VMODE_GAMMA_RAMP */
+ }
- status = XF86VidModeSetGamma (dpy, screen, &g2);
XSync(dpy, False);
return status;
}
unsigned long *pixels;
XImage *ximage = 0;
- if (4 != sscanf (*data, "%d %d %d %d %c", &w, &h, &ncolors, &nbytes, &c))
+ if (4 != sscanf ((const char *) *data,
+ "%d %d %d %d %c", &w, &h, &ncolors, &nbytes, &c))
abort();
if (ncolors < 1 || ncolors > 255)
abort();
if (mask_ret)
{
int s = (w8 * h) + 1;
- *mask_ret = (char *) malloc (s);
+ *mask_ret = (unsigned char *) malloc (s);
if (!*mask_ret)
mask_ret = 0;
else
if (mask_ret && mask)
{
- *mask_ret = XCreatePixmapFromBitmapData (dpy, window, mask,
- iw, ih, 1L, 0L, 1);
+ *mask_ret = (Pixmap)
+ XCreatePixmapFromBitmapData (dpy, window, (char *) mask,
+ iw, ih, 1L, 0L, 1);
free (mask);
}
}
static const char screensaver_id[] =
- "@(#)xscreensaver 3.33 (19-May-2001), by Jamie Zawinski (jwz@jwz.org)";
+ "@(#)xscreensaver 3.34 (25-Oct-2001), by Jamie Zawinski (jwz@jwz.org)";
# ifdef GLX_VISUAL_CAVEAT_EXT
if (!glXGetConfig (dpy, vi_out, GLX_VISUAL_CAVEAT_EXT, &value) &&
value != GLX_NONE_EXT)
+# ifdef GLX_NON_CONFORMANT_EXT
printf (" GLX rating: %s\n",
(value == GLX_NONE_EXT ? "none" :
value == GLX_SLOW_VISUAL_EXT ? "slow" :
-# ifdef GLX_NON_CONFORMANT_EXT
value == GLX_NON_CONFORMANT_EXT ? "non-conformant" :
-# endif /* GLX_NON_CONFORMANT_EXT */
"???"));
+# else
+ printf (" GLX rating: %s\n",
+ (value == GLX_NONE_EXT ? "none" :
+ value == GLX_SLOW_VISUAL_EXT ? "slow" :
+ "???"));
+# endif /* GLX_NON_CONFORMANT_EXT */
# endif /* GLX_VISUAL_CAVEAT_EXT */
if (!glXGetConfig (dpy, vi_out, GLX_DOUBLEBUFFER, &value))
Begin3
Title: xscreensaver
-Version: 3.33
-Entered-date: 03JUN01
+Version: 3.34
+Entered-date: 25OCT01
Description: A modular screen saver and locker for the X Window System.
Highly customizable: allows the use of any program that
can draw on the root window as a display mode.
Author: jwz@jwz.org (Jamie Zawinski)
Maintained-by: jwz@jwz.org (Jamie Zawinski)
Primary-site: http://www.jwz.org/xscreensaver/
- 1630K xscreensaver-3.33.tar.gz
- 49K xscreensaver.README
+ 1661K xscreensaver-3.34.tar.gz
+ 51K xscreensaver.README
1K xscreensaver.lsm
Alternate-site: sunsite.unc.edu /pub/Linux/X11/screensavers/
- 1630K xscreensaver-3.33.tar.gz
- 49K xscreensaver.README
+ 1661K xscreensaver-3.34.tar.gz
+ 51K xscreensaver.README
1K xscreensaver.lsm
Alternate-site: ftp.x.org /contrib/applications/
- 1630K xscreensaver-3.33.tar.gz
- 49K xscreensaver.README
+ 1661K xscreensaver-3.34.tar.gz
+ 51K xscreensaver.README
1K xscreensaver.lsm
Platforms: Linux, Irix, SunOS, Solaris, HPUX, AIX, FreeBSD, NetBSD,
BSDI, SCO, OSF1, Ultrix, VMS.
%define name xscreensaver
-%define version 3.33
+%define version 3.34
%define release 1
%define serial 1
%define x11_prefix /usr/X11R6