source: subversion/applications/rendering/history/README @ 34399

Last change on this file since 34399 was 3500, checked in by frederik, 12 years ago

add loop

File size: 3.0 KB
Line 
1The scripts in this directory together form the "history service"
2as operated on http://openstreetmap.gryph.de/history/.
3
4All are written by Frederik Ramm <frederik@remote.org> and released
5into the Public Domain.
6
7The scripts are not really designed to be operated by others and
8thus some things are not well documented and some assumptions are
9hard-coded but I'll give a quick overview:
10
11* You need a MySQL database holding your data. The bulk of data
12  will reside in the "nodes" table, basically having the lat/lon
13  of every node plus information about the planet file where the
14  node first appeared and where it was last seen (in case it has
15  been deleted). Another table simply lists the planet files that
16  have been imported, and one keeps track of user requests (jobs).
17  The create table statement for the job table is at the end of
18  this readme.
19
20  That database is assumed to be named "osmhistory" and accessible
21  without password.
22
23  The program uses integer values for dates (2007-10-05 becoming
24  71005) and for lat/lon values (multiplying them by 10,000).
25
26* The "import.pl" script takes a planet file on stdin and updates
27  the "nodes" and "planet" tables. It creates these if they do not
28  exist. It updates existing "node" records (extending their life
29  time so to speak) or inserts new records. It is important that
30  planet files are imported in a strict chronological order.
31  Give the date for the planet file on the command line, e.g.
32  71005 if you're importing planet-071005.osm.
33
34* The "index.cgi" script displays existing jobs and accepts new
35  jobs into the queue. It is really just a simple CGI, working with
36  the "jobs" table exclusively.
37
38* The "hqrun.pl" script is the queue runner. It reads jobs from the
39  queue and creates the animated gif images. It requires the Proj
40  and GD modules, plus the external application "gifsicle" for
41  creating the animations. hqrun.pl makes some assumptions about
42  the image destination paths; adjust these.
43
44
45                      -----------------------
46
47
48
49CREATE TABLE `jobs` (
50  `id` int(11) NOT NULL auto_increment,
51  `minlat` float default NULL,
52  `maxlat` float default NULL,
53  `minlon` float default NULL,
54  `maxlon` float default NULL,
55  `projection` int(11) default NULL,
56  `width` int(11) default NULL,
57  `height` int(11) default NULL,
58  `status` enum('waiting','processing','failed','finished') default NULL,
59  `errmsg` varchar(255) default NULL,
60  `filename` varchar(255) default NULL,
61  `filesize` int(11) default NULL,
62  `num_frames` int(11) default NULL,
63  `label` varchar(255) default NULL,
64  `user` varchar(255) default NULL,
65  `fromdate` int(11) default NULL,
66  `todate` int(11) default NULL,
67  `frequency` int(11) default NULL,
68  `bgimage` int(11) default NULL,
69  `color` int(11) default NULL,
70  `pixel` int(11) default NULL,
71  `delay` int(11) default NULL,
72  `loopflag` int(11) default NULL,
73  `date_entered` int(11) default NULL,
74  `date_started` int(11) default NULL,
75  `date_finished` int(11) default NULL,
76  `max_nodes` int(11) default NULL,
77  PRIMARY KEY  (`id`)
78)
Note: See TracBrowser for help on using the repository browser.