|  |  | Routes

## Routes

Routes may happen to have waypoints that were permanently deleted by the user (`Forget` button in waypoint window). In this case the values of distances and bearings for such points and the total distance will not be shown. Saving, exporting or displaying a route with undefined waypoints will be prevented with a warning.

Routes have a colour and a width (in pixels) used in displaying it in the map.

A map background image name can be given for each route, so that when the route is displayed on the map window the named image is automatically loaded if the map is empty. See below for the details.

A route can be created from a track : see below.

A route can be changed or created by drawing on the map as explained below.

To change a route stage a double-click with the mouse left-button should be made on one of the stage fields in the route edit window. An edit window will pop up that must be used and closed before going on.

Changes in a waypoint belonging to a route being edited/inspected will be reflected in the route window.

When modifying a route the coherence of its waypoints and its stages cannot be checked by GPSMan. For instance, when adding a new waypoint after another one the stage starting from the latter is not affected, and when replacing a waypoint by another one the stages ending on and starting from it are not affected.

The edit window for routes allows some operations on routes that may be useful. They are:

- "Invert": take the route from the last to the first waypoint;
- "Chop head": all waypoints from the first to and including the one selected are deleted; if there is no selection the first waypoint is deleted;
- "Chop tail": all waypoints from and including the one selected to the last are deleted; if there is no selection the last waypoint is deleted;
- "Include before", or "Include after": include the route (whose number was selected in the sub-menu) before or after the selected waypoint; if there is no selection, the inclusion will be done before the first or after the last waypoint, respectively.
- "Clear": delete all waypoints.

A route can be converted into a track from the route window.

An elevation graph for a route can be plotted, as a side view or in perspective, from the route window if there are at least 3 waypoints with a valid altitude field.

Clicking with the mouse left-button in a side-view graph will draw a line with the numbers of the waypoints at that horizontal coordinate. The `Shift` key and mouse left-button will clear all these lines.

The perspective graph is shown from South but different viewing directions can be obtained by using the N-E-S-W buttons, or the `Show` button after the `+15`, `-15` (degrees) buttons. The bearing scale shows the viewing direction in degrees that is the current one only when the `Show` button is disabled (this button updates the graph). The scale can also be used to change the viewing direction if the `animate` button is checked. As the animation or a change of viewing direction may lead to a long computation, there is an `Abort` button to stop it. The menu from the `View` button allows for changes in the vertical or horizontal scales, and to hiding/displaying labels in the graph. A N-E-S-W cross is displayed in the graph and can be moved by using the mouse left-button. Clicking with the left-button on a point of the route and then using the mouse middle-button (or left- and right-buttons in a two-button mouse) will move the whole graph.

Elevation graphs can be saved as a Postscript file or further processed (e.g., printed) in Postscript -- cf. the "print command" option), or saved in other graphics formats if the Img Tcl/Tk library is available. This library has two problems when saving an image:

- any window or icon over it will also be part of the saved image; and
- depending on the format, errors can occur if the image has too many colours.

The area enclosed by a route can be computed under the following conditions -- badly wrong values will result if they are not met! The route stages are taken as sides of a polygon and if the last waypoint is not the same as the first, a "virtual" side from the first to the last waypoint is considered. The polygon must be non-intersecting: there can be no multiple occurrences of waypoints (apart from the first one being also the last) and no intersections of the polygon sides. GPSMan will only check for multiple occurrences of waypoints. The method for computing areas is an approximate method that is not reliable when there are sides of the polygon too small when compared to others or there are very small angles between the sides. Results of area computations should be used with care and if possible checked against results of other forms of area measurement.

The details of the area computation are as follows. An algorithm for computing the area of a (non-self intersecting) polygon on the sphere is first tried out. If there are very small intermediate values that may indicate approximation errors, the area is computed by first projecting the polygon onto the plane (using the Transverse Mercator projection centred at the first point of the polygon) and applying then an algorithm for computing the area of a (non-self intersecting) polygon on the plane. A warning message is issued if this happens.

|  |  | Routes