1GDAL_VIEWSHED(1)                     GDAL                     GDAL_VIEWSHED(1)
2
3
4

NAME

6       gdal_viewshed  -  Calculates a viewshed raster from an input raster DEM
7       for a user defined point
8

SYNOPSIS

10          gdal_viewshed [-b <band>]
11                        [-a_nodata <value>] [-f <formatname>]
12                        [-oz <observer_height>] [-tz <target_height>] [-md <max_distance>]
13                        -ox <observer_x> -oy <observer_y>
14                        [-vv <visibility>] [-iv <invisibility>]
15                        [-ov <out_of_range>] [-cc <curvature_coef>]
16                        [[-co NAME=VALUE] ...]
17                        [-q] [-om <output mode>]
18                        <src_filename> <dst_filename>
19

DESCRIPTION

21       By default the gdal_viewshed generates a binary visibility raster  from
22       one  band  of the input raster elevation model (DEM). The output raster
23       will be of type Byte. With the -mode flag can  also  return  a  minimum
24       visible height raster of type Float64.
25
26       NOTE:
27          The  algorithm  as implemented currently will only output meaningful
28          results if the georeferencing is in a projected coordinate reference
29          system.
30
31       -co <NAME=VALUE>
32              Many formats have one or more optional creation options that can
33              be used to control  particulars  about  the  file  created.  For
34              instance,  the  GeoTIFF driver supports creation options to con‐
35              trol compression, and whether the file should be tiled.
36
37              The creation options available vary by format driver,  and  some
38              simple  formats  have  no  creation  options  at  all. A list of
39              options supported for a format can be listed with the  --formats
40              command  line option but the documentation for the format is the
41              definitive source of information  on  driver  creation  options.
42              See  raster_drivers format specific documentation for legal cre‐
43              ation options for each format.
44
45       -b <band>
46              Select an input band band containing the  DEM  data.  Bands  are
47              numbered  from 1.  Only a single band can be used. Only the part
48              of the raster within the specified maximum distance  around  the
49              observer point is processed.
50
51       -a_nodata <value>
52              The value to be set for the cells in the output raster that have
53              no data.
54
55              NOTE:
56                 Currently, no special processing of input cells at  a  nodata
57                 value is done (which may result in erroneous results).
58
59       -ox <value>
60              The X position of the observer (in SRS units).
61
62       -oy <value>
63              The Y position of the observer (in SRS units).
64
65       -oz <value>
66              The  height  of the observer above the DEM surface in the height
67              unit of the DEM. Default: 2
68
69       -tz <value>
70              The height of the target above the DEM  surface  in  the  height
71              unit of the DEM. Default: 0
72
73       -md <value>
74              Maximum distance from observer to compute visibiliy.  It is also
75              used to clamp the extent of the output raster.
76
77       -cc <value>
78              Coefficient to consider the effect of the curvature and  refrac‐
79              tion.   The height of the DEM is corrected according to the fol‐
80              lowing formula:
81
82              Height_{Corrected}=Height_{DEM}-{CurvCoeff}\frac{{TargetDistance}^2}{SphereDiameter}
83
84              For atmospheric refraction we can use 0.85714
85
86       -iv <value>
87              Pixel value to set for invisible areas. Default: 0
88
89       -ov <value>
90              Pixel value to set for the cells that fall outside of the  range
91              specified  by  the  observer  location and the maximum distance.
92              Default: 0
93
94       -vv <value>
95              Pixel value to set for visible areas. Default: 255
96
97       -om <output mode>
98              Sets what information the output contains.
99
100              Possible values: VISIBLE, DEM, GROUND
101
102              VISIBLE returns a raster of type Byte containing  visible  loca‐
103              tions.
104
105              DEM  and  GROUND will return a raster of type Float64 containing
106              the minimum target height for target to be visible from the  DEM
107              surface  or  ground  level respectively.  Flags -tz, -iv and -vv
108              will be ignored.
109
110              Default VISIBLE
111

C API

113       Functionality of this utility can be done from C with  GDALViewshedGen‐
114       erate().
115

EXAMPLE

117       Compute the visibility of an elevation raster data source with defaults
118         [image]  A computed visibility for two separate -ox and -oy points on
119         a DEM..UNINDENT
120
121          gdal_viewshed -md 500 -ox -10147017 -oy 5108065 source.tif destination.tif
122
123       [Wang2000]
124            Generating Viewsheds  without  Using  Sightlines.  Wang,  Jianjun,
125            Robinson,  Gary  J., and White, Kevin. Photogrammetric Engineering
126            and               Remote               Sensing.               p81.
127            https://www.asprs.org/wp-content/uploads/pers/2000journal/january/2000_jan_87-90.pdf
128

AUTHOR

130       Tamas Szekeres <szekerest@gmail.com>
131
133       1998-2021
134
135
136
137
138                                 Jan 05, 2021                 GDAL_VIEWSHED(1)
Impressum