1
/*! \mainpage GRASS 6 Programmer's Manual
2
<!-- * doxygenized from "GRASS 5 Programmer's Manual"
4
* updated 8/2005, 2006, 2007, 2008
7
<a href="http://grass.osgeo.org">GRASS GIS</a> (Geographic Resources
8
Analysis Support System) is an open source, Free Software
9
<em>Geographical Information System</em> (GIS) with raster,
10
topological %vector, image processing, and graphics production
11
functionality that operates on various platforms through a graphical
12
user interface (GUI) or command line interface (CLI). It is released under GNU
13
General Public License (GPL).
15
This manual introduces the reader to the <i>Geographic Resources Analysis
16
Support System</i> from the programming perspective. Design theory, system
17
support libraries, system maintenance, and system enhancement are all
18
presented. Standard GRASS 4.x conventions are still used in much of the
19
code. This work is part of ongoing research being performed by the
20
<a href="http://grass.osgeo.org/community/team.php">GRASS Development Team</a>,
21
an international team of programmers,
22
GRASS module authors are cited within their module's source code and the
23
contributed manual pages.
25
© 2000-2009 Markus Neteler / GRASS Development Team<br>
26
Published under GNU Free Documentation License (GFDL)
27
http://www.fsf.org/copyleft/fdl.html
29
This manual comes with ABSOLUTELY NO WARRANTY. The development of GRASS
30
software and this manual is kindly supported by the
31
<a href="http://www.osgeo.org">Open Source Geospatial Foundation</a>,
32
who provides the GRASS main infrastructure.
34
Main web site: <a href="http://grass.osgeo.org">http://grass.osgeo.org</a>
36
<h2>Table of contents</h2>
45
<i>Missing entries below are either not yet uploaded to SVN (need to be migrated
46
from GRASS 5 Programmer's manual) or are simply undocumented.</i>
49
http://trac.osgeo.org/grass/browser/grass-web/trunk/images/grass6_arch.odp
51
\image html "grass6_arch.png" "GRASS 6 Architecture"
53
\section corelibs Principal library
55
(the name refers to the directory name in lib/ in the source code)
57
- gis: \ref gislib, with following subsection
60
- Sites File Processing (legacy, merged into \ref gisvectorlib)
62
\section libs Further libraries
64
(the name refers to the directory name in lib/ in the source code)
66
- arraystats: Library of statistics for arrays of doubles - \ref arraystats (new, under development)
67
- bitmap: Bitmap library for X Window Bitmaps - \ref bitmap
68
- btree: Binary tree library - \ref btree
69
- cairodriver: <a href="http://cairographics.org">Cairo</a> display driver library - \ref cairodriver
70
- cdhc: Library for testing normality and exponentiality - \ref cdhc
71
- cluster: Library for cluster analysis (image processing) - \ref cluster
72
- datetime: DateTime library - \ref datetime
74
- display: \ref displaylib
75
- %driver: Graphics monitor driver
76
- dspf: DSPF libary - \ref dspf (obsolete?)
77
- edit: Raster edit library (cellhd, history, cats) - \ref edit
78
- external: External libraries from other projects (such as shapelib or bwidget) - \ref external
79
- fonts: Hershey library - \ref fonts
80
- form: TCL/TK forms library - \ref form (obsolete?)
82
- gmath: \ref gmathlib (generic mathematical functions and BLAS/LAPACK library wrapper)
83
- gpde: \ref gpdelib (partial differential equations library)
84
- gtcltk: Tcl/Tk stuff - \ref gtcltk
85
- imagery: \ref imagerylib
86
- init: \ref init (GRASS initialization code + scripts)
87
- linkm: Linked list memory manager - \ref linkm (obsolete?)
88
- ogsf: \ref ogsflib (OpenGL (R) ported gsurf library (required for NVIZ))
89
- pngdriver: PNG display driver library - \ref pngdriver
90
- proj: \ref projlib (wrapper to PROJ4 projection library)
91
- psdriver: PostScript display driver library - \ref psdriver
92
- python: \ref pythonlib
93
- raster: \ref rastergraphicslib (note: raster map functions are in \ref gislib)
94
- rowio: Raster row in/out library - \ref rowio
95
- rst: Library for interpolation with regularized splines with tension - \ref rst
96
- segment: \ref segmentlib (segment library for segmented raster reading)
97
- sites: Old Sites library, now interfaced to \ref Vector_Library - \ref sites
98
- stats: Raster stats library - \ref stats
99
- symbol: Drawing symbols for %point %vector data library - \ref symbol
100
- vask: Cursor management library - \ref vask
101
- %vector: \ref Vector_Library (GRASS Vector and Direct Graph Library)
102
- vedit: \ref Vedit_Library - %vector editing
103
- nviz: \ref nvizlib (used by wxGUI Nviz extension and CLI-based Nviz module)
104
<!--<li>image3: extra imagery library (mainly still unused) - \ref image3lib-->
105
<!--<li>D: display library - \ref d_displaylib-->
106
<!--<li>front.end: interface for interactive modules library - \ref frontend-->
108
\section interfaces Interfaces
110
- GRASS <a href="http://download.osgeo.org/grass/grass6_progman/swig/">SWIG interface</a>
115
- <a href="http://download.osgeo.org/grass/grass6_progman/gui/wxpython/">wxGUI</a></li>
117
\section location File structure of GRASS Location
119
A GRASS <b>raster map</b> consists of several files in several subdirectories in a mapset,
120
organized as follows:
123
map header including projection code, coordinates representing
124
the spatial extent of the raster map, number of rows and columns, resolution,
125
and information about map compression;</li>
126
- <b>cell/, fcell/ or grid3/</b>:
127
generic matrix of values in a compressed, portable
128
format which depends on the raster data type (integer, floating %point or 3D grid);</li>
130
history file which contains metadata such as the data source,
131
the command that was used to generate the raster map, or
132
other information provided by the user;</li>
134
optional category file which contains text or numeric labels assigned
135
to the raster map categories;</li>
137
optional color table;</li>
139
optional timestamp, range of values, quantization rules (for floating %point maps)
140
and null (no-data) files; </li>
142
A GRASS <b>%vector maps</b> are stored in several separate files in a single
143
directory. While the attributes are stored in either a DBF file, a SQLite file
144
or in an external DBMS (PostgreSQL, MySQL, ODBC), the geometric data are saved
147
- <b>head</b>: %vector map ASCII header with information about the map creation
148
(date and name), its scale and threshold;</li>
149
- <b>coor</b>: binary geometry file which includes the coordinates of graphic
150
elements (primitives) that define the %vector feature;</li>
151
- <b>topo</b>: binary topology file describes the spatial relationships between the
152
map's graphic elements;</li>
153
- <b>hist</b>: history ASCII file with complete commands that were used to
154
create the %vector map, as well as the name and date/time of the map
156
- <b>cidx</b>: binary category index file which is used to %link the %vector
157
object IDs to the attribute table rows;</li>
158
- <b>dbln</b>: ASCII file which contains definition(s) of %link to attribute
159
storage in database (DBMS).</li>
162
http://trac.osgeo.org/grass/browser/grass-web/trunk/images/loc_struct.odg
164
\image html "loc_struct.png" "Diagram of GRASS file structure"