home *** CD-ROM | disk | FTP | other *** search
-
- PlotMap V0.85
- *************
-
- Documentation by Thies Wellpott
- (excuse my bad English, please)
-
-
- 1. Copyright
- ************
-
- PlotMap is FreeWare (c) 1992 Thies Wellpott. You may copy it for free
- provided that
- - no profit is made with it
- - PlotMap is not included with commercial software without
- written agreement from the owner of the copyright
- - no file is missing (six map files, "PlotMap", "PlotMap.doc")
- - PlotMap is distributed with this documentation file,
- "PlotMap.doc" and both files are unmodified
-
- The source code is for personal use only. It need not to be distributed
- along with the program, but if it is the whole source code must be kept
- with it.
-
-
- 1.1. Warrenty
- *************
-
- YOU USE THIS PROGRAM COMPLETELY ON YOUR OWN RISK! If you destroy any file,
- your computer, your car or even the whole universe or any part of it while
- using it, do not blame me, it is not my fault!
-
-
- 2. Introduction
- ***************
-
- Perhaps you know DrawMap by Bryan Brown. I got this nice program and used
- it a short while when I noticed that there is missing a lot and that it is
- ugly slow (sorry, Bryan). It needs over one minute to load the map files
- (not directly Bryan`s fault, fread() needs that long time), PlotMap needs
- just about 3 seconds (68000, ALF-2, Quantum-HD) !
- PlotMap uses exactly the same map files like DrawMap 4.0/4.1.
-
- PlotMap has the following improvements towards DrawMap 4.0:
-
- - drawing speed up by a factor of round about 2 (see table below)
- - runs on 512 KB Amigas (perhaps also on a 256 KB machine)
- - runs with one floppy drive
- - more edit commands
- - zoom a box from a box
- - definable screen mode (PAL/NTSC, number of colors, lace or not, etc.)
- - OS 2.0 look
- - more configurable
- - WHOLE configuration saveable
- - auto detail level
- - abort function for drawing (ever accidentaly drawn a full map with highest
- detail level?)
- - some more I forgot
-
- This version requires OS 2.04!
-
- PlotMap only exists because Bryan included the source code with his
- distribution. Thanks a lot Bryan!! I used it as a kind of reference to
- learn the structure of the map files and the way the maps are displayed. I
- did not copy or even steal his source code but some parts may look similar
- because the basic idea of the drawing algorithms does not differ. So
- PlotMap is no copy of DrawMap with some improvements, it is a new program
- with similarities to DrawMap.
-
- Here are some interesting information I collected through the development:
-
- times (V0.50/V0.51) (all maps, flat map, Hires/Lace/PAL/16 colors):
- DrawMap4.0 (NTSC) needs (low) 14-15s and (medium) 59s.
-
- detail level | algorithm | normal | draw.c optimized (-O)
- -------------+--------------+--------+----------------------
- low | FFP-math | 19s | 9s
- | Lattice-math | 21-22s | 11s
- | integer | 17-18s | 7-8s
- -------------+--------------+--------+----------------------
- medium | FFP-math | 47s | 36s
- | Lattice-math | 61s | 49s
- | integer | 39s | 27-28s
-
-
- memory usage (OS 2.04, PAL display):
-
- no map loaded, flood fill disabled, screen: Hires/Lace/16 colors,
- coord. window on (all display types)
- chip: 172720 other: 135344 total: 308064
-
- some as above, but only 8 colors
- total: 264920
-
- no map loaded, flood fill disabled, screen: Hires/NoLace/4 colors,
- no coord. window
- chip: 43504 other: 133976 total: 177480
-
- all maps loaded, flood fill enabled, screen: Hires/Lace/16 colors/overscan,
- coord. window on (all display types)
- chip: 269816 other: 1164560 total: 1434376
-
-
- 3. Installation
- ***************
-
- For the installation you need LhA by Stefan Boberg.
-
- 3.1. On a harddisk
- ******************
-
- You need at least 1.2 MB free space on your hard disk. The destination
- directory in this example is called "DH0:Utilities/PlotMap". You may give
- it a name of your choice.
-
- Copy the files "PlotMap", "PlotMap.info", "PlotMap.doc",
- "PlotMap.doc.info" and "PlotMap.config" to your destination directory.
-
- 1> Copy PlotMap(%|.info|.doc|.doc.info|.config) DH0:Utilities/PlotMap
-
- Unarchive the archive "maps.lha" with the following line:
-
- 1> LhA x -ab64 maps.lha DH0:Utilities/PlotMap/
-
- If you want to have the source code then unarchive the archive "source.lha":
-
- 1> LhA x -ab64 source.lha DH0:Utilities/PlotMap/source/
-
-
- 3.2. On a floppy based system
- *****************************
-
- You need two empty, formatted disks. The first that will contain the
- program may have a name of your choice (I use "PM_1" in this example), the
- second MUST have the name "PM_DATA". You must boot from the Workbench or
- you must install all necessary files on disk 1 (libs, handler, etc.) and
- boot from it then.
-
- 1> Format DRIVE df0: NAME PM_1 NOICONS
-
- 1> Format DRIVE df0: NAME PM_DATA NOICONS
-
- Copy the files "PlotMap", "PlotMap.info", "PlotMap.doc",
- "PlotMap.doc.info" and "PlotMap.config" to the first disk.
-
- 1> Copy PlotMap(%|.info|.doc|.doc.info|.config) PM_1:
-
- Execute the following lines:
-
- 1> LhA x -ab64 maps.lha map.limits.bin coast.pnt island.pnt PM_1:
-
- 1> LhA x -ab64 maps.lha country.pnt state.pnt river.pnt lake.pnt PM_DATA:
-
-
- 4. Getting started
- ******************
-
- Start PlotMap either by double clicking its icon or by typing "PlotMap"
- in the Shell. If PM cannot load the configuration file "PlotMap.config" it
- will beep the screen. Afterwards the configuration window will pop up.
-
-
- 4.1. The configuration window
- *****************************
-
- Here you may define the screen mode either my selecting/toggling the
- gadgets or by pressing the underlined keys (e. g. "h" for SuperHires). The
- screen size and the used memory are displayed below. Note: In SuperHires
- mode you can use a maximum of 4 colors (but you can select more, this will
- be fixed in later versions). Overscan toggles between text overscan
- (defined with Preferences) and maximum overscan (Intuition hard coded). The
- six gadgets below "Load map" define which maps should be loaded completely.
- The numbers behind the names show the memory used by each map. Maps which
- are not loaded completely will be loaded part by part when they are drawn.
- This slows down the drawing but saves memory (the only way for users with
- less then 1.5 MB of memory). The last checkbox is another memory saving
- option. If disabled you cannot use flood fill or fill oceans but you save
- one bitplane (40 KB with 640 x 512) of chip memory. "Save" saves the
- options and starts PM (you have the possibility to save them later, too)
- and "Use" starts PM.
-
- You will find yourself on an empty screen with the defined resolution.
- The only way to control PM is via menus (and their shortcuts, of course).
-
-
- 4.2. The menus
- **************
-
- The description of each menu follows (items with no description are not
- implemented yet):
-
- 4.2.1. Project
- **************
-
- ** Help
-
- ** Save map
- Please use a screen grabber like GrabIFF, Snap, etc.
-
- ** Save configuration
- Saves the configuration file to the current directory. The following things
- will be saved (items marked with a * are definable in the config window at
- startup):
-
- - * superhires yes/no
- - * interlace yes/no
- - * overscan yes/no
- - * mode (PAL/NTSC)
- - * number of bitplanes (number of colors)
- - * which maps should be completely loaded
- - * flood fill option yes/no
- - default vert. factor
- - status of "Cls before draw"
- - status of "Coord. window", "Coord. mouse-X/Y", "Coord. degrees"
- - position of the coord. window
- - which maps should be plot
- - current detail level
- - color palette
- - all definable colors (background, oceans, maps, grid, grid highlight,
- shadow, line, box, text, flood fill)
-
- ** Print map
- You may use GraphicDump for this (do not forget to switch off the title
- bar, via Amiga-t).
-
- ** About
- Displays programm information.
-
- ** Quit
- Cuts the power cable of your computer :-)
-
-
- 4.2.2. Preferences
- ******************
-
- ** Vert. factor
- With this option you can adjust the plot to your screen. The current
- vfactor is displayed in this item-title. The subitem "Use default" sets the
- vfactor to that displayed in the subitem-title. With "Set" you can change
- the vfactor. A requester pops up where you can enter a number. The input is
- limited to four chars. "Cancel" cancelles the operation, nothing is
- changed, "Ok" accepts the entered value and "Use as default" sets the
- default vfactor to the enter value.
-
- ** Cls before draw
- If enabled, the screen will be cleared before a map is drawn.
-
- ** Coord. window
- If enabled, the coordinate window is displayed. You close the window by
- disabling this item or by clicking the close gadget of the coord. window.
- You may move the coord. window around, but it is impossible to activate it
- (I hope!) so do not try it (and waste hours with it).
-
- ** Coord. mouse-X/Y
- Display the mouse coordinates in the coord. window.
-
- ** Coord. degrees
- Display the lattitude and longitude in the coord. window.
-
- ** Coastlines, Islands, Countries, States, Rivers, Lakes
- Specifies which maps should be drawn.
-
- ** Detail level
- Specifies the detail level the maps are drawn with. "High" till "Low"
- directly specify one of the five levels. "Auto high" .. "Auto low"
- automatically selects a detail level depending on the size of the part
- currently displayed.
-
-
- 4.2.3. Colors
- *************
-
- ** Palette
-
- ** Background
- Specifies the background color of the map
-
- ** Oceans
- Color of the oceans (for "Fill oceans")
-
- ** Coastlines, Islands, Countries, States, Rivers, Lakes
- Color of each map.
-
- ** Grid
- Color of the grid ("Grid")
-
- ** Grid highlight
- Color of the longitude 0° and the lattitude 0° ("Grid")
-
- ** Shadow
- Color of the shadow (not implemented yet)
-
- ** Line, Box, Text, Flood fill
- Color for the edit commands. If you draw a line the line color will be
- used, difficult to understand?
-
-
- 4.2.4. Maps
- ***********
-
- ** Plane
- "Flat" draws a flat map like DrawMap 4.0.
- "Mercator" draws the same map as DrawMap 4.0.
- The drawing is interruptable by pressing the right mouse button. It is
- possible that PM needs a bit to react on your mouse click so do not panic
- if the drawing does not interrupt immediately.
-
- ** Box
- With "Select box1" you may specify a box of the currently displayed map to
- be drawn. A distortion is impossible because the height of the box is
- calculated from the width which you may specify.
- "Select box2" works like "Select box1" but you can specify the width and
- the height.
- If you select "Select box" the mouse pointer becomes a cross hair and the
- title bar displayes a short description what to do. Press and hold the left
- mouse button, the first point is set, move the mouse and a box appears
- that indicates which part of the map will be drawn. Release the left mouse
- button if you found your box; the map will be drawn. Press the right mouse
- button to abort this operation.
- "Zoom in" and "Zoom out" are not implemented yet.
-
- ** Sphere
-
- ** Redraw
- Redraws the current map with the selected colors and detail level.
-
-
- 4.2.5. Edit
- ***********
-
- ** Clear screen
- Clears the screen with the current background color.
-
- ** Fill oceans
- This item will fill all oceans oceans with the ocean color if it differs
- from the background color. This may take a while (Flood() needs a bit
- during intensive DMA-usage) !
- Why did I implement this function you may think perhaps? Ok, I tell you the
- secret. (You must use the default configuration, delete or rename your
- config-file if you have changed colors.) Try the following: Set the
- background color to light green (color no. 8), leave all other colors at
- their current setting! Now draw a flat map and then select "Fill oceans".
- Now you have filled continents! It is possible that some parts of the
- continents are filled with the ocean color. Select a higher detail level or
- use "Draw line" to repair "damaged coastlines".
- At the moment this function is in its test phase, I just fill a few
- oceans. If you fill oceans of a part of a map (menu Maps->Box) you will
- realize it. I will improve it in the next versions.
-
- ** Grid
- A requester with two sliders pops up. Via the two sliders you can specify
- the distance between the grid lines in degrees. (Hint: The key "x"
- increases the "X step" value and "Shift x" decreases it. Commo-guidelines
- for sliders). "Ok" draws the grid and "Cancel", well, I forgot its function
- perhaps you will figure out :-).
-
- ** Shadow
-
- ** Toggle title
- Toggle the status of the screen`s title bar.
-
- ** Draw line
- This item allows you to draw a line with the current line color. The
- specification of the start and the end point works similar to the
- specification of Maps->Box->Select box.
-
- ** Draw box
- Like "Draw line", but draws a rectangle/box.
-
- ** Draw filled box
- Draws a filled box.
-
- ** Text
- A requester pops up where you can enter a text. "Cancel" cancelles the
- operation. If you select "Ok" the entered text follows the movement of your
- mouse pointer. The RMB aborts the operation, the LMB puts the text to its
- current position.
-
- ** Flood fill
- Fills all adjacent pixels that have same pen number/color as the one at the
- mouse click position. This may take a while if your screen needs a lot of
- DMA time (hires-interlace-16 colors/superhires-4 colors).
-
-
- 5. What else?
- *************
-
- Enjoy the program and wait for new versions. I released this version
- because it is possible to work with it and solves a lot of problems DrawMap
- 4.0 has (memory usage, HD required, speed).
-
- Perhaps I will program a version for Kick 1.2/1.3. A version for
- 68020/30/40 and 68881/2 will follow!
-
-
- 6. History
- **********
-
- V0.10 19.06.92
- first code
- V0.20 24.06.92
- draw_fullmap, some menus and some routines finished
- V0.30 01.07.92
- config window finished; draw_fullmap improved
- V0.40 07.07.92
- color menus corrected, manually (bug in OS!);
- start of draw box map coding (not working)
- V0.41 07.07.92
- draw (filled) box feature added
- V0.50 09.07.92
- use of FFP, it is faster (see above)
- V0.51 10.07.92
- draw-algorithms improved, I use integer-operations now (where possible)
- V0.60 11.07.92
- part-wise loading of maps added (for users with few memory)
- V0.61 14.07.92
- handling of MOUSEMOVE (draw line/box) improved, during the inner loop
- I set only a flag, the drawing is performed outside
- V0.62 14.07.92
- I use the OS 2.04 screen and window routines (open, get size,
- overscan, etc.) now
- V0.70 16.07.92
- changes in gadget alloc. (internal); background color changeable;
- draw_boxmap completely new coded; draw routines changed (no continue;
- anymore), you can read them better now; Move() only after WritePixel()
- not after Draw(); key shortcuts for config-wd gadgets; some minor
- improvements
- V0.71 16.07.92
- select box coord corrected; coordinate display window added
- V0.72 17.07.92
- coordinate display during draw line/box; coordinates are now correct
- for a box map, too
- V0.73 19.07.92
- INTUITICKS instead of MOUSEMOVE for draw_line/box (because of coord
- window which needs time); errors with draw_boxmap corrected
- V0.74 19.07.92
- bug fixed! I got a Intui-message, afterwards I checked for ende; the
- message could be left unreplied (on exit of function)
- V0.80 19.07.92
- ocean color, fill oceans, clear screen, clear screen before draw
- menuitems added; minor improvements in draw line/box (avoid flicker)
- V0.81 20.07.92
- coord. window routines put into their own module; coord display
- during text and flood fill; a bit more rounding (coords, etc.);
- code added which feigns a faster reaction during mouse movement (draw
- box/line, text); OS 2.0 like waiting pointer; menu data put into
- their own module
- V0.82 20.07.92
- bug in calc_box_coord fixed, select box from box now works
- V0.83 22.07.92
- vfactor changable during execution; edit routines put into their own
- module; minor bugs fixed; minor internal changes
- V0.84 23.07.92
- set vfactor/enter text requester added; coord. calc rounding improved;
- auto detail level added
- V0.85 23.07.92
- grid, shadow color menuitems added; fill oceans implemented; color menu
- correction changed; draw grid implemented; minor internal changes
-
-
- TODO
-
- - support of packed data files (powerpacker, lh, ...)
- - more screen modes (productivy, lores, A2024)
- - more speed, of course :-)
- - more display types (like DrawMap 4.1 ??)
- - ARexx-port (?)
-
-
-
- Send bug reports, hints, ideas and 68040-cards :-) to (sorry, no e-mail
- available):
-
- Thies Wellpott
- Moorhauser Weg 14
- 2948 Schortens 1
-
- Germany
-
-