Questions tagged [mapnik]

Mapnik is an open source mapping toolkit, written in C++ and can be scripted using binding languages such as JavaScript (Node.js), Python, Ruby, and Java. Useful for both Desktop- and Server-based map rendering. It is used by Tilemill, OpenStreetMap, Mapbox, CartoDB, Stamen, MapQuest and Kosmtik.

Filter by
Sorted by
Tagged with
0
votes
0answers
13 views

How can I fix the error “failed to initialize projection” on Mapnik?

I have the "failed to initialize projection" problem in the current mac version 3.1.0. The error text: RuntimeError: failed to initialize projection with: '&srs900913;' In older issues ...
0
votes
0answers
20 views

installing MAPNIK problems

I'm trying to install MAPNIK in ubuntu 16.04. I downloaded the files from here: https://github.com/mapnik/mapnik, and follow the instructions from here: https://github.com/mapnik/mapnik/blob/master/...
1
vote
0answers
27 views

Pre-rendering tiles fail, only once in a while

I've customized the https://github.com/Overv/openstreetmap-tile-server and broken it down into two images, a Tile-Server and a Postgis-Server. Both Tile Server and PostGIS Server are up and running in ...
1
vote
0answers
55 views

How to create a tile from a TIFF stored in PostGIS using Mapnik in nodejs

I stored TIFF in the database using: raster2pgsql -c -C -s 4326 -f geom_raster -F -I evapo_01_201.tif -t 200x200 public.rasters | psql -U postgres -d gaaf -h localhost -p 5432 I think it's alright ...
0
votes
0answers
7 views

Mapnik doesn't find fonts

OS=Ubuntu 20.04 I have imported OSM data into a postgis database. I'm now trying to render tiles with generate_tiles.py which is in the repo mapnik-stylesheets. However, this doesn't work as mapnik ...
0
votes
0answers
21 views

Convert styles to Mapnik 3 XML

I am using Ordnance Survey's OpenMap - Local in Mapnik 3.0. Ordnance Survey make stylesheets available here: https://github.com/OrdnanceSurvey/OS-OpenMap-Local-stylesheets Is there a way to convert ...
1
vote
0answers
18 views

I get a transparent/empty image with Mapnik in python from a raster file

I start by selecting a raster from the website of the Swiss Federal Office. Therefore, I know, with certainty, the projection in which this layer is located. Source : https://shop.swisstopo.admin.ch/...
0
votes
0answers
53 views

Using Mapproxy parameters as input to Mapnik data source

I'm using a structure of Mapproxy and Mapnik to render raster data through a WMS. I was able to connect the Mapnik source on Mapproxy and render a unique file from my XML Mapnik data source ...
1
vote
1answer
48 views

Applying color style to GeoTIFF layer using Mapnik and Python

I am trying to apply a color style to a GeoTIFF using Mapnik. The code I'm using is: import mapnik map = mapnik.Map(800,600) map.srs = '+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs' style = ...
0
votes
0answers
22 views

Is there a way to fix the polygon-pattern scale to the zoom level in CartoCSS

I'm using openstreetmap-carto for my own tileserver and added a new landuse to the style. But I can't wrap my head around, how I could fix the scaling of my polygon-pattern to a specific zoom level. ...
0
votes
0answers
14 views

CartoCSS: Always display polygon labels

I am labeling my polygons with text-placement: interior; which places the label at the center of each polygon. When I zoom in so that the center of the polygon with the label is not inside the map ...
0
votes
0answers
37 views

Mapproxy generating plain tiles using mapnik

I am using MapProxy 1.12 and Mapnik 3 for map creation. Plain tiles are genererating, no map. Some tiles are showing 404 error(The requested tile is outside the bounding box of the tile map.). sample....
0
votes
1answer
50 views

Changing Mapnik style — generating empty tiles/images

I got my osm2pgsql/PostGIS/Mapnik/Nik4 setup up and running. I have tested it with the openstreetmap-carto style and everything works well. Now I want to change the style to Mapbox' pencil style (...
1
vote
1answer
32 views

How to draw a marker with Mapnik?

After setting up a tile server accordingly this instruction https://switch2osm.org/serving-tiles/manually-building-a-tile-server-20-04-lts/ my offline tile server working nicely. And after helping of ...
3
votes
1answer
86 views

How to create a map to PNG file with specific box coordinates by Mapnik?

I recently manually built a tile server with this instruction -> https://switch2osm.org/serving-tiles/manually-building-a-tile-server-20-04-lts/. I downloaded location data for Russia from ...
2
votes
1answer
75 views

Styling a contour line to indicate the direction of elevation

I've just got a slippy map set-up using Mapnik to render OpenStreetMap data. I've loaded SRTM elevation data following the PostGIS steps here and can now see contour lines on the map. I'm trying to ...
0
votes
1answer
206 views

imposm3 on PostGIS to mapnik conversions

I am working with osm2psql and imposm3 to load a postgres db with OSM data. The performance of imposm3 is seemingly far in advance of osm2psql (to a factor of 4 i am finding). However I cannot find ...
1
vote
1answer
115 views

Serve multiple map styles with mapnik and mod_tile from one server & database

I struggle to set up two different map styles for the mapnik-osm rendering tool chain. According to some help I already found on gis.stackexchange, I set up the renderd.conf for two map styles. But I ...
1
vote
1answer
34 views

How to put a watermark at Mapnik tiles?

Maybe I have to add new layer with my PNG watermark at XML style, but how? I already tried to change somthing at XML, but don't understand how to add one global layer.
1
vote
1answer
15 views

Incorrect tiles from a shapefile are generated by mapnik

I used mapnik_node_tile_server to generate tiles from a shapefile created by gdal_contour. The tile generation function is: function fetchTile(layer, z, x, y, callback) { var map = new mapnik.Map(...
3
votes
0answers
32 views

Mapnik: Cannot get markers to overlap

I'm using the Natural Earth shapefile to generate maps of ethnographic data. For every location where I have evidence of (for example) whether men or women had the job of brewing beer, I want to show ...
1
vote
1answer
46 views

How can insert properties on a vector tile

I am trying to set up a web server in Node.js that serves vector tiles to be displayed in a browser using MapboxGL JS. The data for the vector tiles is stored in a Postgressql database with PostGIS ...
0
votes
0answers
103 views

Import error with Mapnik in Anaconda 2

I'm using Anaconda to write geographic programs, so I need to use packages like Mapnik. After installing Mapnik in Anaconda2, it started to error. First about Mapnik itself and after do some actions ...
1
vote
0answers
66 views

How to simulate way_pixels rules in GeoServer like in Mapnik?

Openstreetmap-carto project.mml have a queries like this: way_area/NULLIF(POW(!scale_denominator!*0.001*0.28,2),0) AS way_pixels Do I understand correctly that way_pixels just shows how many times ...
2
votes
0answers
74 views

Mapnik XML mapfile projection of multiply layers [closed]

How to apply a multiply layer with Mapnik from EPSG:4326 TIFFs to EPSG:3875 projected tiles? I have two TIFF files, one containing the color-relief and the other the slope-shade (generated with GDAL, ...
0
votes
1answer
258 views

Local OSM Tile Server not rendering

I searched this issue in other topics but only found outdated topics with previous versions of Ubuntu. I'm using Ubuntu 18.04 in my laptop and I'm following the tutorial available at https://...
3
votes
1answer
287 views

mapnik offline maps using generate_tiles_multiprocess.py

I've been working for a couple of days to get offline map tiles working for use in JXMapviewer2 but I am having trouble when using generate_tiles_multiprocess.py to process the tiles. My intention is ...
0
votes
1answer
27 views

Mapnik: Can you draw outline/ strokes on Polygon geometries?

My data consists of a lot of polygons which need to be outlined. Unfortunately I cannot find any option on the PolygonSymbolizer - and my LineSymbolizer seems to be without effect. Here is my ...
1
vote
0answers
18 views

Overlapping polygons produce rendering artifacts a low zoom [duplicate]

I have duplicated this problem in both QGIS and mapnik. For this question, I will show the problem using QGIS. I have imported heightmap images along a coastal area. I then added an overlay layer ...
2
votes
1answer
151 views

Prerendering OSM tiles with CartoCSS?

I've set up a PostGIS database and imported my map data. Then I ran render_list to render my tiles. Serving them through mod-tile works just fine. However, the files on my HDD are *.meta files and ...
1
vote
0answers
142 views

Mapnik Slow tile generation with i9-990K, 64GB ram and NVME SSD Database

I have setup an OSM tile server following the guide at: https://switch2osm.org/manually-building-a-tile-server-18-04-lts and https://github.com/giggls/openstreetmap-carto-de. My database is stored on ...
1
vote
1answer
77 views

TileStache Internal Server Error

I was installing TileStache and and followed all the necessary steps, Upon running the tilestache-server.py file, It starts the server at http://127.0.0.1:8080/. And opening this into my browser gives ...
1
vote
2answers
159 views

Split long lines in PostGIS

I would like to render contours using Mapnik. The problem is that some contours are very long which makes rendering too slow and so I decided to spling long contours to multiple smaller segments. ...
1
vote
0answers
64 views

CentOS 7, Mapnik, and Tilestache: Seems like image assets are ignored by Mapnik's point/pattern symbolizers

[Update 6.6.2019] Ok...new detail. I checked a different Apache error log and discovered that it's littered with these errors, generically corresponding to.. failed to allocate png_ptr Actual ...
2
votes
1answer
293 views

Improving Mapnik render time

I'm adding polylines (elevation curves) to a world map. Said polylines are stored in a PostgreSQL database from gdal_contour tool. The geometry columns (LineString, 3857) has a GIST index and a ...
0
votes
1answer
246 views

Using renderd on OSM tile server?

I followed this tutorial and have some troubles. When I restart and get status of the renderd service, I get the following error : renderd[8162]: An error occurred while loading the map layer '...
1
vote
1answer
113 views

Add PNG as a layer in Mapnik

I'm playing around with Mapnik and trying to add a PNG image over a map created from an XML file. This is my XML file: <Map background-color="white" minimum-version="0.7.2" srs="+init=epsg:3395"&...
0
votes
1answer
488 views

Adding custom layer to OSM data in switch2osm?

I'm new to switch2osm and I've created an OSM Tile Server with switch2osm on Ubuntu 16.04 LTS. It uses Apache, Mod_tile, renderd and Mapnik to render tiles. It uses PostgreSQL as DBMS and osm2pgsql to ...
2
votes
1answer
121 views

Mapnik LineSymbolizer for overlaping lines

I'm creating a map with Mapnik, and I have some trouble to correctly render overlapping lines. Fot instance let's consider this piece of XML: <Style name="ferry-routes"> <Rule> ...
0
votes
0answers
48 views

Connect Mapnik to MSSQL

I want to connect Mapnik to MSSQL Spatial SDE, but I don't know how to do this. import mapnik m = mapnik.Map(256,256) mapnik.load_map(m, "test.xml") m.zoom_all() mapnik.render_to_file(m, "2.png") ...
0
votes
1answer
195 views

Map tile not rendered on node-mapnik?

const mapnik = require('mapnik'); const sphericalmercator = require('@mapbox/sphericalmercator'); mapnik.register_default_fonts(); mapnik.register_default_input_plugins(); const TILE_HEIGHT = 256; ...
1
vote
0answers
134 views

Build a tile server using MySQL as backend

I need to set up a tile server using MySQL but cannot find any documentation for it. I have done it with Postgres by following this link and it works fine. I understand that after downloading the ...
2
votes
1answer
448 views

Periodically updating OpenStreetMap tile server to keep it up to date?

I have successfully built my tile server by following this link (https://switch2osm.org/manually-building-a-tile-server-18-04-lts/) and open layers for viewing the tiles. How do I keep automate the ...
1
vote
1answer
43 views

Mapnik upsampled raster isn't smooth

I'm using Mapnik to show a map with hillshading. It works well when displaying it up to my tiff's native resolution and a little bit above, for instance at zoom 13 (dataset is SRTM30): But then if I ...
2
votes
0answers
274 views

Mapnik / OSM data not rendering correctly

I was wondering if someone could help me with a problem that I'm having rendering some maps with mapnik and OSM data. I'm imported the Australia OSM data from geofabrik into postgis, using osm2pgsql, ...
2
votes
1answer
316 views

GDAL reprojection 4326 to 3857 creates gap

I have an EPSG:4326 tif covering the world that I need to reproject to EPSG:3857 in order to use it with Mapnik to create a map. When displaying the original tif and leaving Mapnik doing the ...
2
votes
1answer
592 views

Ubuntu: Updating Mapnik from 2.2.0 to 3.x, complications?

I'm wanting to upgrade Mapnik on a production system from 2.2.0 to 3.x to take advantage of improvements to data-driven rendering. Fortunately the install instructions for Ubuntu have been updated ...
3
votes
1answer
467 views

Mapnik + PostgreSQL + Python = Segmentation fault

I would like to render subset of OpenStreetMap features over big area into one image, no sub-tiles. System: Devuan ascii 64bit (alike Debian 9), 64GB RAM, headless (SSH only) There is what I already ...
1
vote
1answer
101 views

Dynamically rendering tiles in mapnik [closed]

I am working on a mapping project on an embedded system (~1 Ghz, 512MB RAM, 2GB flash storage). It is not feasible to pre-render all of the tiles and setup a tile server. Instead, I was planning to ...
1
vote
0answers
430 views

How can I render custom google maps tiles with mapnik?

I'm currently developing my own little GIS service, that displays custom computed information on a google map. As you can see, I'm loading a custom tile overlay, where I renderd the information in a ...

1
2 3 4 5
8