nik4(1)

Tile-aware Mapnik image renderer

Section 1 nik4 bookworm source

Description

nik4

NAME

nik4 - Tile-aware Mapnik image renderer

SYNOPSIS

nik4 [-h] [--version] [-z ZOOM] [-p PPI] [--factor FACTOR] [-s SCALE] [-b Xmin Ymin Xmax Ymax] [-a PAPER] [-d W H] [-x W H] [--norotate] [-m MARGIN] [-c X Y] [--fit FIT] [--padding PADDING] [--layers LAYERS] [--add-layers ADD_LAYERS] [--hide-layers HIDE_LAYERS] [--url URL] [--ozi OZI] [--wld WLD] [-t {1,2,3,4,5,6,7,8,9,10,11,12}] [--just-tiles] [-v] [-f FMT] [--base BASE] [--vars [VARS [VARS ...]]] [--fonts [FONTS [FONTS ...]]] style output

DESCRIPTION

nik4 is a Python script to generate images with Mapnik.

OPTIONS

Positional arguments:

style

Style file for Mapnik

output

Resulting image file

Optional arguments:
-h
, --help

Show usage information and exit

--version

Show program’s version number and exit

-z ZOOM, --zoom ZOOM

Target zoom level

-p PPI, --ppi PPI, --dpi PPI

Pixels per inch (alternative to scale)

--factor FACTOR

Scale factor (affects ppi, default=1)

-s SCALE, --scale SCALE

Scale as in 1:100000 (specifying ppi is recommended)

-b Xmin Ymin Xmax Ymax, --bbox Xmin Ymin Xmax Ymax

Bounding box

-a PAPER, --paper PAPER

Paper format: -a +4 for landscape A4, -a -4 for portrait A4, -a letter for autorotated US Letter

-d W H, --size W H

Target dimensions in mm (one 0 allowed)

-x W H, --size-px W H

Target dimensions in pixels (one 0 allowed)

--norotate

Do not swap width and height for bbox

-m MARGIN, --margin MARGIN

Amount in mm to reduce paper size

-c X Y, --center X Y

Center of an image

--fit FIT

Fit layers in the map, comma-separated

--padding PADDING

Margin for layers in --fit (default=5), mm

--layers LAYERS

Map layers to render, comma-separated

--add-layers ADD_LAYERS

Map layers to include, comma-separated

--hide-layers HIDE_LAYERS

Map layers to hide, comma-separated

--url URL

URL of a map to center on

--ozi OZI

Generate ozi map file

--wld WLD

Generate world file

-t {1,2,3,4,5,6,7,8,9,10,11,12}, --tiles {1,2,3,4,5,6,7,8,9,10,11,12}

Write N×N tiles, then join using ImageMagick

--just-tiles

Do not join tiles, instead write ozi/wld file for each

-v, --debug

Display calculated values

-f FMT, --format FMT

Target file format (by default looks at extension)

--base BASE

Base path for style file, in case it’s piped to STDIN

--vars [VARS [VARS ...]]

List of variables (name=value) to substitute in style file (use ${name:default})

--fonts [FONTS [FONTS ...]]

List of full path to directories containing fonts