wmclockmon: update change-log
[dockapps.git] / wmglobe / README
blob49b2ab71689ed65d2a889b8e3351f2cd5695872e
1 WMGlobe 1.3  -  The Whole Earth spinning on you desktop... as a dockable app
2 Copyright (C) 1998,99,2000,01 Jerome Dumonteil <jerome.dumonteil@linuxfr.org>
3 This program is licensed under the terms of the GNU GPL, see below.
7 Description
8 ----------------------------------------
9 WMGlobe is a WindowMaker dock.app that displays the earth on an icon. It's
10 an adaptation of XGlobe to WMaker environnement. WMGlobe uses a map which is
11 rendered on a sphere by raytracing. Yes, for a 64x64 pixel result :-)
16 Installation
17 ----------------------------------------
18 You need WindowMaker to build WMGlobe. WMGlobe needs libwraster to compile,
19 this lib is built by WindowMaker. No more need at run time if statically
20 linked, but then, you need WindowMaker to get the full magic :-)
21 Warning : this version won't work with WindowMaker < 0.62
23 Before compiling, you must have the required development libraries.
24 On Ubuntu/Debian/Devuan based distros, install via:
25         sudo apt-get install -y libwmaker-dev libdockapp-dev libwraster-dev
26         # libwmaker-dev also installs libwmaker1
30 Poikilos (autotools input files author) says:
31 If you are using a git version run:
32         ./autogen.sh  # generate a new configure script
33         # then skip to step 2
35 Extract and compile a packaged version:
36         tar -xvzf wmglobe-1.3.tar.gz
37         cd wmglobe-1.3
40         ./configure && make
43         then move wmglobe in /usr/local/bin and man page somewhere or do
44         (as root) :
45         make install
48 If it doesn't work, look for the graphic libraries.
50 The old Makefile (Makefile.old) is "quite crude" says the original author.
51 Sun the following to generate a new one:
52         ./autogen.sh  # or autoreconf --verbose --install --force  # or autoreconf -vfi
53         # requires: autoreconf automake
55 WMGlobe is developped on Linux (WMaker 0.65.1 and linux 2.4.x/ix86).
56 If you are successful on other platforms, please tell me so.
59 Platforms with successful build reported (wmglobe 1.0 for older WMaker):
60 (Poikilos says: ./autogen.sh should automatically set -lungif or -lgif
61 in the resulting Makefile, so changing it manually as noted below
62 shouldn't be necessary.)
63 * NetBSD 1.3.2 / SPARC    (wmaker 0.20.3) , with Makefile adaptations for libs
64 * Linux 2.0.36 / RedHat 5.1
65 * Linux 2.0.36 / SuSE 5.3 (wmaker 0.20.3)  ,  -lungif -> -lgif
66 * Linux 2.0.36 / RedHat 5.2 (wmaker 0.53)
67 * Linux 2.2.0-pre4 / Debian    :-)
68 * FreeBSD-3.0     with -ltiff -> -ltiff34 and -lungif -> -lgif
69 * Solaris 2.6  / Sun Sparc (wmaker 0.20.3) , with Makefile adaptations for libs
70 * AIX 4.2.1    / IBM RS/6000-250 (wmaker 0.50.2)
71 * Linux 2.3.14 / Mandrake (wmaker but also blackbox !)
72 * LinuxPPC 1999
73 * Linux 2.2.10 / Alpha (wmglobe 1.1+)
76 RPM & DEBIAN linux packages coming soon. Or you can directly use the binary.
78 compile time problems :
80 Xlib.h, Xpm.h ... :
81 If you compile wmglobe on a computer installed with packages (.rpm), you may
82 lack of these header files. Just install the "xxx-dev.rpm" packages for XFree86
83 and graphics libs, or install a rpm version of wmglobe.
85 libwraster :
86 WindowMaker 0.20.3 uses a libwraster.a , so if you use it, you can execute
87 the binary on a computer without WindowMaker on it, and displaying on a
88 remote computer (this one using WindowMaker). WM > 0.51.0 creates a dynamic
89 libwraster.so, so it's necessary to have it on the computer running wmglobe
90 if you buit WMGlobe with this one. Both versions of WMGlobe run on WM 0.20.3
91 and 0.51.0
92 For wmglobe 1.2+, you need WMaker 0.62 or more recent. And wmglobe 1.0 won't
93 run on these recent versions of WindowMaker. You need to have wraster.h
94 in the include path to compile wmglobe.
95 For wmglobe 1.3+, you probably need WMaker 0.64 or more recent.
97 graphic libs :
98 you can use libgif or libungif. If your version of WindowMaker is built
99 without support for some graphic type, you don't need it (just remove it
100 from the makefile).
101 This problem may happen with RedHat 5.2, if you get this kind of message,
102 just add a libtiff to your system :
103 /usr/local/lib/libwraster.so: undefined reference to `TIFFReadDirectory'
105 make: *** [wmglobe] Error 1
108 compile time options :
109 You can modify the file wmgoption.h where many options are set up in defines :
111 To disable the builtin default map, just comment out the line in wmgoptions.h
112 #define DEFMAPOK
113 to remove the shift+left/left method of rotate earth, uncomment the lines
114 #define MOUSE_LAT_FULL
116 you can also suppress some options screen in wmgoption.h (or even suppress
117 new features of wmglobe 1.2)
122 Maps
123 ----------------------------------------
124 Like XGlobe, WMGlobe needs a longitude/latitude map to work. By default,
125 it uses a low quality built-in map of earth. But you will probably want
126 to use better ones.
128 You can get maps usable with WMGlobe on the net. See the LINKS chapter.
130 using custom maps :
131 - For the image to be mapped correctly, position 0°North 0°West must be in
132   the center of the image and the latitude must be linear from 90°N to 90°S.
133 - You can safely use a night map of different size than the day map.
135 By the way, you can use maps of Mars, Luna ... and text.
139 Configuration options
140 ----------------------------------------
142 Configuration is done through command line options.
144 -v                      version
145 -h                      short help
147 -zoom zoom_value        Value > 1 to magnify the view, value < 1 to lower.
148                         Default : 1.0
150 -pos latitude long.     Initial viewing fixed at this position, don't follow
151                         the sun rotation. Accepted values in the form
152                         45°12'36 or 45.21 or 45:12:36
153                         Default : the initial position is "under" the sun, and
154                         the point of view follows the sun.
156 -sun                    The point of view follows the Sun (default).
158 -moon                   The point of view follows the Moon (i.e. you see the
159                         Earth as you were on the Moon).
161 -rand                   New random position at every refresh of screen
163 -map     map_file       Map used for the rendering. Can be JPEG, GIF, XPM
164                         PNM, TIFF but none BMP
165                         Default : use internal map of earth.
167 -nimap   night_file     Map used for the dark side of the earth. Must be of
168                         the same width x height as the day side map.
169                         Default : if the default internal day map is used, use
170                         a default internal night file (see -nonimap option).
172 -defnimap               Use the default night map (with a custom map).
174 -nonimap                Don't use the default night map.
176 -delay   seconds        Time in seconds between each calculation of a new
177                         position. Limited to 0.04 at compile time (25 frames
178                         per second should be enough). The sun position move
179                         only once per minute, so if you use wmglobe without
180                         -dlong or -accel option, the CPU cost of WMGlobe is
181                         *very* low. The use of very low value for -delay plus
182                         -dlong and -accel can be CPU costly (but very nice...)
183                         Default : 1.0 sec.
185 -dlat   delta_latitude  Move the point of view by delta_lat degrees per second,
186                         with a value of 6 the earth make a full rotation in
187                         one minute. The value can be formated as -pos option.
188                         Default : 0°0'0
190 -dlong  delta_long      Move the point of view by delta_long degrees per
191                         second. With a value of -0°0'15" the earth make a full
192                         rotation in 24 hours toward the west. By default,
193                         -dlong and -dlat are null. If they are used, the view
194                         follow their values. Going back to "follow sun" mode
195                         in parameters screen put -dlat and -dlong to zero.
197 -light  light_value     Level of light of the dark side when there is no
198                         night map, from 0 to 1.
199                         Default : 0.25
201 -dawn   dawn_value      Level of continuity for dawn limit, from 0 to 1. With
202                         a value of 1, the border line between night and day is
203                         at maximum contrast.
204                         Default : 0.2
206 -bord   border_num      0 1 or 2. There are 3 different borders for the icon.
207                         Default : 0
209 -accel  time_multi      Time warp factor. With -accel 24, the sun make a full
210                         rotation in one hour (or the earth, I'm not sure).
211                         Default : 1.0
213 -time   seconds         Time to display in seconds since 01-01-1970 (see the
214                         date command). Necessary if you need to be sure that
215                         WMGlobe is Y2K compliant without changing system time.
216                         Negative values for dates before 1970 accepted.
217                         Default : not set, use current time.
219 -mk latitude long.      Put a fixed marker at latitude/longitude.
220                         -mk sun : put a marker under the Sun position.
221                         -mk moon : put a marker under the Moon.
222                         5 markers can be defined simultaneously, so you can
223                         use wmglobe to predict when Moon will meet the Sun :-)
225 -fun dx dy              Move the earth image by dx dy pixels in the icon. See
226                         puzzle.sh to understand why.
228 -oz                     Start in "austral" mode (for "down under" people)
230 -stable                 Keep the globe from going over the poles.
232 -d display              Select another display
234 -w  -shape              Useless, since it is set by default (WMaker dockable
235                         application)
237 mouse :
238 left button             Change longitude while pressed, change longitude &
239                         latitude if shift+left button.
241 middle button           Zoom in, shift + middle button : zoom out
243 right button            Displays 7 screens of parameters. On every screen, just
244                         clic with left or right button on the figures to change
245                         their value. The TIME screen shows an approximation
246                         of date and time of the earth zone currently displayed,
247                         using GMT time + longitude offset, it's close to the
248                         real local time by one or two hours. Others options
249                         don't need more help. Intuitive they said...
253 Links : Some sites dealing with WindowMaker
254 -------------------------------------------
256 Official Window Maker Website :
257 http://www.windowmaker.org/
259 The Dock App Warehouse :
260 http://www.bensinclair.com/dockapp/
264 Links : Where to find maps and similar softs
265 --------------------------------------------
266 where to find the sources of wmglobe :
267 http://perso.linuxfr.org/jdumont/wmg/wmglobe-1.0.tar.gz
269 the web page of WMGlobe (made by Sylvestre Taburet) :
270 http://perso.linuxfr.org/jdumont/wmg/
273 where to find maps and similar softs :
275 Earth image by a cgi :
276 http://www.fourmilab.ch/cgi-bin/uncgi/Earth
278 two softs running under X :
279 XGlobe Homepage: http://www.uni-karlsruhe.de/~uddn/xglobe
280 (the recent 0.2 version brings a very nice map of earth)
282 Xearth Homepage: http://www.cs.colorado.edu/~tuna/xearth/
285 For the maps XGlobe doc says :
287 « WHERE TO GET MAPS:
289 1. LivingEarth Inc.
291 http://livingearth.com/LE/LivEarthImg.html
292 http://livingearth.com/LE/BrillEarthImg.html
294 Livingearth Inc. has some nice (day and night) images on their web pages.
295 With these you can test the -nightmap option of XEarth. Unfortunately
296 they are pretty low-res (400x200).
297 You can find a higher-resolution (but heavily compressed) version of this
298 day map at the "Earth View" page:
300 http://www.fourmilab.ch/cgi-bin/uncgi/Earth
302 Check "No night" and set display to "map", then save the image.
305 2. NOAA NGDC Marine Geology & Geophysics
307 http://www.ngdc.noaa.gov:80/mgg/image/mggd.gif
309 This image is definitely not "photo-realistic" but nonetheless pretty
310 interesting. It also has a rather high resolution. »
314 Todo
315 ----------------------------------------
316 - add interface module to allow plugins
317 - test on different platforms, better makefile
318 - changing map "on the fly", map generator, clouds generator...
319 - must work on every current WindowMaker platform (hug...)
320 - rewrite some ugly things in the code
321 - see how to minimize CPU load
322 - feature : load a local detailed map of some part of the globe when zooming
323   (country maps, city maps)
324 - maybe port to other window manager
328 Bugs
329 ----------------------------------------
330 - Wmglobe depends on WindowMaker version
331 - The Makefile
332 - if you use the  --enable-single-icon compile time option of WindowMaker,
333   you can not display more than one WMGlobe.
334 - WMGlobe hopes that an overflow of a long integer dont generate an error
335   and that LONG_MAX +1 = LONG_MIN . This happens with high values of -accel
336   when the date go over year 2038. The expected result is wmglobe
337   continuing smoothly from 1901.
338 - Using WMGlobe at high speed through a LAN may induce some load on the net.
341 License
342 ----------------------------------------
343 WMGlobe is Copyright (C) 1998,99,2000,2001 by Jerome Dumonteil and licensed
344 through the GNU General Public License.
345 Read the COPYING file for the complete GNU license.
349 Credits
350 ----------------------------------------
351 Original idea, tests, logos : Sylvestre Taburet <Sylvestre.Taburet@free.fr>
353 WindowMaker 0.62 fix : Charles G Waldman <cgw@fnal.gov>
355 The code in 'sunpos.cpp' is taken from Xearth by Kirk Lauritz Johnson.
356 (Actually, it uses now the 1.1 version of Xearth)
359  * sunpos.c
360  * kirk johnson
361  * july 1993
363  * code for calculating the position on the earth's surface for which
364  * the sun is directly overhead (adapted from _practical astronomy
365  * with your calculator, third edition_, peter duffett-smith,
366  * cambridge university press, 1988.)
369  * Copyright (C) 1989, 1990, 1993, 1994, 1995 Kirk Lauritz Johnson
371  * Parts of the source code (as marked) are:
372  *   Copyright (C) 1989, 1990, 1991 by Jim Frost
373  *   Copyright (C) 1992 by Jamie Zawinski <jwz@lucid.com>
375  * Permission to use, copy, modify and freely distribute xearth for
376  * non-commercial and not-for-profit purposes is hereby granted
377  * without fee, provided that both the above copyright notice and this
378  * permission notice appear in all copies and in supporting
379  * documentation.
380  */
382 The rendering engine is taken from XGlobe by Thorsten Scheuermann
383 XGlobe Homepage: http://www.uni-karlsruhe.de/~uddn/xglobe
385 Raster graphics library by Alfredo K. Kojima, & stuff of Window Maker
386 <http://windowmaker.org> by A. K. Kojima, Dan Pascu, Matthew Hawkins & team
390 Feedback
391 ----------------------------------------
392 For your questions, bugs, remarks, please contact our representative on
393 planet Earth : jerome dumonteil <jerome.dumonteil@linuxfr.org>