Imported Upstream version 1.4.1
[routino] / doc / html / output.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2 <HTML>
3
4 <!--
5  Routino documentation - output
6
7  Part of the Routino routing software.
8
9  This file Copyright 2008-2010 Andrew M. Bishop
10
11  This program is free software: you can redistribute it and/or modify
12  it under the terms of the GNU Affero General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15
16  This program is distributed in the hope that it will be useful,
17  but WITHOUT ANY WARRANTY; without even the implied warranty of
18  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19  GNU Affero General Public License for more details.
20
21  You should have received a copy of the GNU Affero General Public License
22  along with this program.  If not, see http://www.gnu.org/licenses/.
23 -->
24
25 <HEAD>
26 <TITLE>Routino : Output</TITLE>
27 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
28 <LINK href="style.css" type="text/css" rel="stylesheet">
29 </HEAD>
30
31 <BODY>
32
33 <!-- Header Start -->
34
35 <div class="header" align="center">
36
37 <h1>Routino : Output</h1>
38
39 <hr>
40 </div>
41
42 <!-- Header End -->
43
44 <!-- Content Start -->
45
46 <div class="content">
47
48 <h2><a name="H_1_1"></a>Router Output</h2>
49
50 There are three different formats of output from the router, HTML,
51 <a class="ext" title="GPX format" href="http://www.topografix.com/gpx.asp">GPX (GPS eXchange) XML format</a>
52 and plain text with a total of five possible output files:
53 <ul>
54   <li>HTML route instructions for each interesting junction.
55   <li>GPX track file containing every node.
56   <li>GPX route file with waypoints at interesting junctions.
57   <li>Plain text description with the interesting junctions.
58   <li>Plain text file with every node.
59 </ul>
60
61 The "interesting junctions" referred to above are junctions where the route
62 changes to a different type of highway, more than two highways of the same type
63 meet, or where the route meets but does not take a more major highway.  When the
64 route follows a major road this definition eliminates all junctions with minor
65 roads.
66
67 <p>
68
69 The output files are written to the current directory and are named depending on
70 the selection of shortest or quickest route. For the shortest route the file
71 names are "shortest.html", "shortest-track.gpx", "shortest-route.gpx",
72 "shortest.txt" and "shortest-all.txt", for the quickest route the names are
73 "quickest.html", "quickest-track.gpx", "quickest-route.gpx", "quickest.txt" and
74 "quickest-all.txt".
75
76 <p>
77
78 The HTML file and GPX files are written out according to the selected language
79 using the translations contained in the translations.xml configuration file.
80
81 <!-- For reference the examples were produced from the following URL:
82      http://www.gedanken.org.uk/mapping/routino/customrouter.cgi?transport=motorcar;lon1=-0.12790;lat1=51.52468;lon2=-0.10365;lat2=51.47824 -->
83
84 <h3><a name="H_1_1_1" title="HTML file"></a>HTML Route Instructions</h3>
85
86 The HTML route instructions file contains one line for each of the interesting
87 junctions in the route and one line for the highway that connects them.
88
89 <p>
90
91 An example HTML file output is below (some parts are missing, for example the
92 style definitions):
93
94 <pre class="boxed">
95 &lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt;
96 &lt;HTML&gt;
97 &lt;!-- Creator : Routino - http://www.routino.org/ --&gt;
98 &lt;!-- Source : Based on OpenStreetMap data from http://www.openstreetmap.org/ --&gt;
99 &lt;!-- License : http://creativecommons.org/licenses/by-sa/2.0/ --&gt;
100 &lt;HEAD&gt;
101 &lt;TITLE&gt;Shortest Route&lt;/TITLE&gt;
102 ...
103 &lt;/HEAD&gt;
104 &lt;BODY&gt;
105 &lt;H1&gt;Shortest Route&lt;/H1&gt;
106 &lt;table&gt;
107 &lt;tr class='c'&gt;&lt;td class='l'&gt;&lt;td class='r'&gt;51.524677 -0.127896
108 &lt;tr class='n'&gt;&lt;td class='l'&gt;Start:&lt;td class='r'&gt;At &lt;span class='w'&gt;Waypoint&lt;/span&gt;, head &lt;span class='b'&gt;South-East&lt;/span&gt;
109
110 &lt;tr class='s'&gt;&lt;td class='l'&gt;Follow:&lt;td class='r'&gt;&lt;span class='h'&gt;Russell Square&lt;/span&gt; for &lt;span class='d'&gt;0.391 km, 0.5 min&lt;/span&gt; [&lt;span class='j'&gt;0.4 km, 0 minutes&lt;/span&gt;]
111 ...
112 &lt;tr class='t'&gt;&lt;td class='l'&gt;Total:&lt;td class='r'&gt;&lt;span class='j'&gt;6.3 km, 5 minutes&lt;/span&gt;
113 &lt;tr&gt;&lt;td class='l'&gt;Stop:&lt;td class='r'&gt;&lt;span class='w'&gt;Waypoint&lt;/span&gt;
114 &lt;/table&gt;
115 &lt;/BODY&gt;
116 &lt;/HTML&gt;
117 </pre>
118
119 The coordinates are included in the file but are not visible because of the
120 style definitions.
121
122 <h3><a name="H_1_1_2" title="GPX track file"></a>GPX Track File</h3>
123
124 The GPX track file contains a track with all of the individual nodes that the
125 route passes through.
126
127 <p>
128
129 An example GPX track file output is below:
130
131 <pre class="boxed">
132 &lt;?xml version="1.0" encoding="UTF-8"?&gt;
133 &lt;gpx version="1.1" creator="Routino" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.topografix.com/GPX/1/1" xsi:schemaLocation="http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd"&gt;
134 &lt;metadata&gt;
135 &lt;desc&gt;Creator : Routino - http://www.routino.org/&lt;/desc&gt;
136 &lt;copyright author="Based on OpenStreetMap data from http://www.openstreetmap.org/"&gt;
137 &lt;license&gt;http://creativecommons.org/licenses/by-sa/2.0/&lt;/license&gt;
138 &lt;/copyright&gt;
139 &lt;/metadata&gt;
140 &lt;trk&gt;
141 &lt;name&gt;Shortest route&lt;/name&gt;
142 &lt;desc&gt;Shortest route between 'start' and 'finish' waypoints&lt;/desc&gt;
143 &lt;trkpt lat="51.524677" lon="-0.127896"/&gt;
144 &lt;trkpt lat="51.523830" lon="-0.126993"/&gt;
145 ...
146 &lt;trkpt lat="51.478353" lon="-0.103561"/&gt;
147 &lt;trkpt lat="51.478244" lon="-0.103652"/&gt;
148 &lt;/trkseg&gt;
149 &lt;/trk&gt;
150 &lt;/gpx&gt;
151 </pre>
152
153
154 <h3><a name="H_1_1_3" title="GPX route file"></a>GPX Route File</h3>
155
156 The GPX route file contains a route (ordered set of waypoints) with all of the
157 interesting junctions that the route passes through.
158
159 <p>
160
161 An example GPX route file output is below:
162
163 <pre class="boxed">
164 &lt;?xml version="1.0" encoding="UTF-8"?&gt;
165 &lt;gpx version="1.1" creator="Routino" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.topografix.com/GPX/1/1" xsi:schemaLocation="http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd"&gt;
166 &lt;metadata&gt;
167 &lt;desc&gt;Creator : Routino - http://www.routino.org/&lt;/desc&gt;
168 &lt;copyright author="Based on OpenStreetMap data from http://www.openstreetmap.org/"&gt;
169 &lt;license&gt;http://creativecommons.org/licenses/by-sa/2.0/&lt;/license&gt;
170 &lt;/copyright&gt;
171 &lt;/metadata&gt;
172 &lt;rte&gt;
173 &lt;name&gt;Shortest route&lt;/name&gt;
174 &lt;desc&gt;Shortest route between 'start' and 'finish' waypoints&lt;/desc&gt;
175 &lt;rtept lat="51.524677" lon="-0.127896"&gt;&lt;name&gt;START&lt;/name&gt;
176 &lt;desc&gt;South-East on 'Russell Square' for 0.391 km, 0.5 min&lt;/desc&gt;&lt;/rtept&gt;
177 &lt;rtept lat="51.521815" lon="-0.124577"&gt;&lt;name&gt;TRIP001&lt;/name&gt;
178 &lt;desc&gt;South-East on 'Russell Square' for 0.055 km, 0.1 min&lt;/desc&gt;&lt;/rtept&gt;
179 ...
180 &lt;rtept lat="51.478244" lon="-0.103652"&gt;&lt;name&gt;FINISH&lt;/name&gt;
181 &lt;desc&gt;Total Journey 6.3 km, 5 minutes&lt;/desc&gt;&lt;/rtept&gt;
182 &lt;/rte&gt;
183 &lt;/gpx&gt;
184 </pre>
185
186
187 <h3><a name="H_1_1_4" title="Text file"></a>Text File</h3>
188
189 The text file format contains one entry for all of the interesting junctions in
190 the route and is intended to be easy to interpret.
191
192 <p>
193
194 An example text file output is below:
195
196 <pre class="boxed">
197 # Creator : Routino - http://www.routino.org/
198 # Source : Based on OpenStreetMap data from http://www.openstreetmap.org/
199 # License : http://creativecommons.org/licenses/by-sa/2.0/
200 #
201 #Latitude       Longitude       Section         Section         Total           Total           Point   Turn    Bearing Highway
202 #                               Distance        Duration        Distance        Duration        Type                           
203  51.524677        -0.127896      0.000 km        0.0 min          0.0 km           0 min        Waypt            +3     
204  51.521815        -0.124577      0.391 km        0.5 min          0.4 km           0 min        Junct    +0      +3     Russell Square
205 ...
206  51.478353        -0.103561      0.598 km        0.4 min          6.2 km           5 min        Junct    +2      -3     Camberwell New Road (A202)
207  51.478244        -0.103652      0.013 km        0.0 min          6.3 km           5 min        Waypt                   Vassall Road
208 </pre>
209
210 <p>
211
212 The text file output contains a header (indicated by the lines starting with
213 '#') and then one line for each junction.  Each line contains the information
214 for the route up to that point and the direction to go next.
215
216 For each of the lines the individual fields contain the following:
217
218 <table>
219   <tr>
220     <th>Item
221     <th class=left>Description
222   <tr>
223     <td>Latitude
224     <td>Location of the point (degrees)
225   <tr>
226     <td>Longitude
227     <td>Location of the point (degrees)
228   <tr>
229     <td>Section Distance
230     <td>The distance travelled on the section of the journey that ends at this
231       point (defined on this line).
232   <tr>
233     <td>Section Duration
234     <td>The duration of travel on the section of the journey that ends at this
235       point (defined on this line).
236   <tr>
237     <td>Total Distance
238     <td>The total distance travelled up to this point.
239   <tr>
240     <td>Total Duration
241     <td>The total duration of travel up to this point.
242   <tr>
243     <td>Point Type
244     <td>The type of point; either a waypoint <em>Waypt</em> or
245       junction <em>Junct</em>.
246   <tr>
247     <td>Turn
248     <td>The direction to turn at this point (missing for the first point since
249       the journey has not started yet and the last point because it has
250       finished).  This can take one of nine values between -4 and +4 defined by:
251       0 = <em>Straight</em>, +2 = <em>Right</em>, -2 = <em>Left</em> and +/-4
252       = <em>Reverse</em>.
253   <tr>
254     <td>Bearing
255     <td>The direction to head at this point (missing for the last point since
256       the journey has finished).  This can take one of nine values between -4
257       and +4 defined by: 0 = <em>North</em>, +2 = <em>East</em>, -2
258       = <em>West</em> and +/-4 = <em>South</em>.
259   <tr>
260     <td>Highway
261     <td>The name (or description) of the highway to follow (missing on the first
262       line).
263 </table>
264
265 <p>
266
267 The individual items are separated by tabs but some of the items contain spaces
268 as well.
269
270
271 <h3><a name="H_1_1_5" title="All nodes text file"></a>All Nodes Text File</h3>
272
273 The all nodes text file format contains one entry for each of the nodes on the
274 route.
275
276 <p>
277
278 An example all nodes text file output is below:
279
280 <pre class="boxed">
281 # Creator : Routino - http://www.routino.org/
282 # Source : Based on OpenStreetMap data from http://www.openstreetmap.org/
283 # License : http://creativecommons.org/licenses/by-sa/2.0/
284 #
285 #Latitude       Longitude           Node        Type    Segment Segment Total   Total   Speed   Bearing Highway
286 #                                                       Dist    Durat'n Dist    Durat'n                        
287  51.524677        -0.127896      7485978*       Waypt   0.000    0.00    0.00     0.0                   
288  51.523830        -0.126993      7485047*       Junct   0.113    0.14    0.11     0.1    96      146    Woburn Place
289 ...
290  51.478353        -0.103561      7576939*       Junct   0.104    0.07    6.25     5.0    96      126    Camberwell New Road (A202)
291  51.478244        -0.103652      7581605        Waypt   0.013    0.01    6.26     5.0    64      207    Vassall Road
292 </pre>
293
294 <p>
295
296 The all nodes text file output is similar to the text file output except that a
297 line is printed for each of the nodes rather than just the interesting junctions.
298
299 For each of the lines the individual fields contain the following:
300
301 <table>
302   <tr>
303     <th>Item
304     <th class=left>Description
305   <tr>
306     <td>Latitude
307     <td>Location of the point in degrees.
308   <tr>
309     <td>Longitude
310     <td>Location of the point in degrees.
311   <tr>
312     <td>Node
313     <td>The internal node number and an indicator "*" if the node is a super-node.
314   <tr>
315     <td>Type
316     <td>The type of point; a waypoint <em>Waypt</em>, junction <em>Junct</em>,
317       change of highway <em>Change</em> or intermediate node <em>Inter</em>.
318   <tr>
319     <td>Segment Distance
320     <td>The distance travelled on the segment defined on this line.
321   <tr>
322     <td>Segment Duration
323     <td>The duration of travel on the segment defined on this line.
324   <tr>
325     <td>Total Distance
326     <td>The total distance travelled up to this point.
327   <tr>
328     <td>Total Duration
329     <td>The total duration of travel up to this point.
330   <tr>
331     <td>Speed
332     <td>The speed of travel on the segment defined on this line (missing on the
333       first line).
334   <tr>
335     <td>Bearing
336     <td>The direction that the segment defined on this line travels in degrees
337       (missing on the first line).
338   <tr>
339     <td>Highway
340     <td>The name (or description) of the highway segment (missing on the first
341       line).
342 </table>
343
344
345 </div>
346
347 <!-- Content End -->
348
349 <!-- Footer Start -->
350
351 <div class="footer" align="center">
352 <hr>
353
354 <address>
355 &copy; Andrew M. Bishop = &lt;amb "at" gedanken.demon.co.uk&gt;
356 </address>
357
358 </div>
359
360 <!-- Footer End -->
361
362 </BODY>
363
364 </HTML>