1GDAL_PROXIMITY(1)                    GDAL                    GDAL_PROXIMITY(1)
2
3
4

NAME

6       gdal_proximity - Produces a raster proximity map.
7

SYNOPSIS

9          gdal_proximity.py <srcfile> <dstfile> [-srcband n] [-dstband n]
10                            [-of format] [-co name=value]*
11                            [-ot Byte/UInt16/UInt32/Float32/etc]
12                            [-values n,n,n] [-distunits PIXEL/GEO]
13                            [-maxdist n] [-nodata n] [-use_input_nodata YES/NO]
14                            [-fixed-buf-val n]
15

DESCRIPTION

17       The  gdal_proximity.py script generates a raster proximity map indicat‐
18       ing the distance from the center of each pixel to  the  center  of  the
19       nearest pixel identified as a target pixel.  Target pixels are those in
20       the source raster for which the raster pixel value is  in  the  set  of
21       target pixel values.
22
23       <srcfile>
24              The source raster file used to identify target pixels.
25
26       <dstfile>
27              The  destination  raster file to which the proximity map will be
28              written.  It may be a pre-existing file of the same size as src‐
29              file.  If it does not exist it will be created.
30
31       -srcband <n>
32              Identifies the band in the source file to use (default is 1).
33
34       -dstband <n>
35              Identifies  the  band in the destination file to use (default is
36              1).
37
38       -of <format>
39              Select the output format. Starting with GDAL 2.3, if not  speci‐
40              fied,  the  format is guessed from the extension (previously was
41              GTiff). Use the short format name.
42
43       -co <NAME=VALUE>
44              Many formats have one or more optional creation options that can
45              be  used  to control particulars about the file created. For in‐
46              stance, the GeoTIFF driver supports creation options to  control
47              compression, and whether the file should be tiled.
48
49              The  creation  options available vary by format driver, and some
50              simple formats have no creation options at all. A  list  of  op‐
51              tions  supported  for  a format can be listed with the --formats
52              command line option but the documentation for the format is  the
53              definitive  source  of  information  on driver creation options.
54              See Raster drivers format specific documentation for legal  cre‐
55              ation options for each format.
56
57       -ot <type>
58              Specify a data type supported by the driver, which may be one of
59              the following: Byte, UInt16, Int16, UInt32, Int32, Float32  (de‐
60              fault), or Float64.
61
62       -values <n>,<n>,<n>
63              A  list of target pixel values in the source image to be consid‐
64              ered target pixels. If not specified, all non-zero  pixels  will
65              be considered target pixels.
66
67       -distunits PIXEL|GEO
68              Indicate  whether distances generated should be in pixel or geo‐
69              referenced coordinates (default PIXEL).
70
71       -maxdist <n>
72              The maximum distance to be generated. The nodata value  will  be
73              used  for  pixels beyond this distance. If a nodata value is not
74              provided, the output band will be queried for its nodata  value.
75              If  the output band does not have a nodata value, then the value
76              65535 will be used. Distance is  interpreted  in  pixels  unless
77              -distunits GEO is specified.
78
79       -nodata <n>
80              Specify  a  nodata  value  to  use for the destination proximity
81              raster.
82
83       -use_input_nodata YES/NO
84              Indicate whether nodata pixels in the input raster should be no‐
85              data in the output raster (default NO).
86
87       -fixed-buf-val <n>
88              Specify  a value to be applied to all pixels that are within the
89              -maxdist of target pixels (including the target pixels)  instead
90              of a distance value.
91

AUTHOR

93       Frank Warmerdam <warmerdam@pobox.com>
94
96       1998-2023
97
98
99
100
101                                 Oct 30, 2023                GDAL_PROXIMITY(1)
Impressum