Mapnik
Encyclopedia
Mapnik is an open source mapping toolkit, written in C++
C++
C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...

 and useful for both desktop- and server-based map rendering
Rendering (computer graphics)
Rendering is the process of generating an image from a model , by means of computer programs. A scene file contains objects in a strictly defined language or data structure; it would contain geometry, viewpoint, texture, lighting, and shading information as a description of the virtual scene...

. One of its many users is the OpenStreetMap
OpenStreetMap
OpenStreetMap is a collaborative project to create a free editable map of the world. Two major driving forces behind the establishment and growth of OSM have been restrictions on use or availability of map information across much of the world and the advent of inexpensive portable GPS devices.The...

 project (OSM) which uses it in combination with an Apache Web Server module (mod_tile) to render tiles that make up the OSM 'Slippy Map' Layer. An XML
XML
Extensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....

 file can also be used to define a collection of mapping objects that determine the appearance of a map, or objects can be constructed programatically in C++ or Python. Artem Pavlenko, the original developer of Mapnik, set out with the explicit goal of creating beautiful maps by employing the subpixel anti-aliasing of the Anti-Grain Geometry
Anti-Grain Geometry
Anti-Grain Geometry is a high-quality 2D rendering library written in C++. It features anti-aliasing and sub-pixel resolution.The library is operating system independent and renders to an abstract memory object. It comes with examples interfaced to the X Window System, Microsoft Windows, Mac OS X,...

 (AGG) library. Mapnik now also has a powerful Cairo
Cairo (graphics)
cairo is a software library used to provide a vector graphics-based, device-independent API for software developers. It is designed to provide primitives for 2-dimensional drawing across a number of different backends...

 rendering backend. When it comes to handling common software tasks such as memory management, filesystem access, regular expressions, and XML parsing, Mapnik utilizes the Boost C++ Libraries.

Data Format

A number of data formats are supported in Mapnik using a plugin framework. Current plugins exist that utilize OGR
GDAL
GDAL is a library for reading and writing raster geospatial data formats, and is released under the permissive X/MIT style free software license by the Open Source Geospatial Foundation. As a library, it presents a single abstract data model to the calling application for all supported formats...

 and GDAL
GDAL
GDAL is a library for reading and writing raster geospatial data formats, and is released under the permissive X/MIT style free software license by the Open Source Geospatial Foundation. As a library, it presents a single abstract data model to the calling application for all supported formats...

 to read a range of vector and raster datasets. Mapnik also has custom Shapefile
Shapefile
The Esri Shapefile or simply a shapefile is a popular geospatial vector data format for geographic information systems software. It is developed and regulated by Esri as a open specification for data interoperability among Esri and other software products.Shapefiles spatially describe geometries:...

, PostGIS
PostGIS
PostGIS is an open source software program that adds support for geographic objects to the PostgreSQL object-relational database. PostGIS follows the Simple Features for SQL specification from the Open Geospatial Consortium .-Features:...

 and GeoTIFF
GeoTIFF
GeoTIFF is a public domain metadata standard which allows georeferencing information to be embedded within a TIFF file. The potential additional information includes map projection, coordinate systems, ellipsoids, datums, and everything else necessary to establish the exact spatial reference for...

 readers. More data access plug-ins will be available in the future. There is also an osm2pgsql utility, that converts OpenStreetMap
OpenStreetMap
OpenStreetMap is a collaborative project to create a free editable map of the world. Two major driving forces behind the establishment and growth of OSM have been restrictions on use or availability of map information across much of the world and the advent of inexpensive portable GPS devices.The...

 data into a format that can be loaded into PostgreSQL
PostgreSQL
PostgreSQL, often simply Postgres, is an object-relational database management system available for many platforms including Linux, FreeBSD, Solaris, MS Windows and Mac OS X. It is released under the PostgreSQL License, which is an MIT-style license, and is thus free and open source software...

. Mapnik can then be used to render the OSM data into maps with the appearance you want.

Platforms

Mapnik is a cross platform toolkit that runs on Windows, Mac, Unix-like
Unix-like
A Unix-like operating system is one that behaves in a manner similar to a Unix system, while not necessarily conforming to or being certified to any version of the Single UNIX Specification....

 systems like Linux and Solaris (since release 0.4).

Usage

Mapnik is used as the rendering backend of OpenStreetMap
OpenStreetMap
OpenStreetMap is a collaborative project to create a free editable map of the world. Two major driving forces behind the establishment and growth of OSM have been restrictions on use or availability of map information across much of the world and the advent of inexpensive portable GPS devices.The...

's default layer, but is also used by CloudMade
CloudMade
CloudMade is a company which produces APIs, rendered maps, and geographic-related services. Unlike many other companies in the same field, CloudMade uses exclusively Creative Commons-licensed OpenStreetMap data, and was cofounded by the founder of OpenStreetMap, Steve Coast...

, MapQuest
MapQuest
MapQuest is an American free online web mapping service owned by AOL. The company was founded in 1967 as Cartographic Services, a division of R.R. Donnelley & Sons in Chicago, Illinois, United States. It moved to Lancaster, Pennsylvania in 1969. When it became an independent company in 1994, it was...

, and Development Seed.

External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK