pkdumpimg(1)

NAME
pkdumpimg - program to dump image content to ASCII or STDOUT

SYNOPSIS
\FCpkdumpimg\F[]
\FC-i\F[] input [\FC-o\F[] output] [options] [advanced options]

DESCRIPTION
pkdumpimg dumps the content of a raster dataset to (standard) output (screen or filename). The default is to dump the output in matrix format. Use \FC-of\F[] line to dump each pixel value on a separate line, preceded by its position (x and y value). You can specify a bounding box to dump with either the extent of an OGR vector dataset or via the options \FC-ulx\F[] \FC-uly\F[] \FC-lrx\F[] and \FC-lry\F[].

OPTIONS

\FC-i\F[] filename, \FC--input\F[] filename
    input image file

\FC-o\F[] filename, \FC--output\F[] filename
    Output ASCII file (Default is empty: use STDOUT)

\FC-of\F[] matrix|line, \FC--oformat\F[] matrix|line
    Output format (matrix form or list (x,y,z) form). Default is matrix form

\FC-b\F[] band, \FC--band\F[] band
    band index to crop

\FC-e\F[] vector, \FC--extent\F[] vector
    get boundary from extent from polygons in vector file

\FC-ulx\F[] value, \FC--ulx\F[] value
    Upper left x value bounding box (in geocoordinates if georef is true)

\FC-uly\F[] value, \FC--uly\F[] value
    Upper left y value bounding box (in geocoordinates if georef is true)

\FC-lrx\F[] value, \FC--lrx\F[] value
    Lower left x value bounding box (in geocoordinates if georef is true)

\FC-lry\F[] value, \FC--lry\F[] value
    Lower left y value bounding box (in geocoordinates if georef is true)

\FC-v\F[] level, \FC--verbose\F[] level
    verbose (Default: 0)

Advanced options

\FC-dx\F[] value, \FC--dx\F[] value
    Output resolution in x (in meter) (0.0: keep original resolution)

\FC-dy\F[] value, \FC--dy\F[] value
    Output resolution in y (in meter) (0.0: keep original resolution)

\FC-r\F[] resampling, \FC--resampling-method\F[] resampling
    Resampling method (near: nearest neighbour, bilinear: bi-linear interpolation).

\FC-srcnodata\F[] value, \FC--srcnodata\F[] value
    set no data value(s) for input image

\FC-dstnodata\F[] value, \FC--dstnodata\F[] value
    nodata value for output if out of bounds.

EXAMPLE
We create a 5x5 raster dataset containing all 0 values except for its center (value=1)

\FC
cat input.txt

0 0 0 0 0
0 0 0 0 0
0 0 1 0 0
0 0 0 0 0
0 0 0 0 0
      \F[]

Use pkascii2img(1) to create an raster dataset from input.txt

\FC
pkascii2img -i input.txt -o output.tif -of GTiff -a_srs epsg:3035 -dx 25 -dy 25 -ulx 1000000 -uly 1000000
      \F[]

Dump the image content of output.tif to screen

\FC
pkdumpimg -i output.tif
      \F[]

SEE ALSO
pkascii2img(1)