To conclude the creation of our own source of elevation , started in
previous articles( Starting with ArcGis
Pro: create your own
source of elevations ( 1) and (2)
) we are
going discuss the use of the raster calculator with ArCGis Pro.
We have two different areas in our work surface:
- a terrestrial area
- a marine area
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/51.png?resize=630%2C339&ssl=1)
We
have finished calculating the marine area with the command Topo to raster:
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/52.png?resize=630%2C339&ssl=1)
We will create a continuous DEM by following the following steps :
1-cutting the marine DEM with the ” sea ” polygon
2-cutting of the terrestrial DTM with the ” earth ” polygons
3-filling of the empty cells eventually created in the boundary of both areas (
land-sea )
Cutting the marine DEM with the “sea “ polygon
We will select the polygon “sea” of
the polygon terrestrial-sea layer ( in Map tab of the ribbon “Select”
button)
In the Geoprocessing window , click on Toolboxes and go to Data Management
Tools -> Raster -> Raster Processing -> Clip
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/53.png?resize=630%2C337&ssl=1)
You
must indicate that you want to cut the raster with the layer terrestrial_sea AND
check Use Input Features for geometry Clipping. This makes ArcGIS Pro to use,
only, the entities selected for cutting , in this specific case, the ” sea
” polygon.
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/54.png?resize=630%2C338&ssl=1)
Cutting
of the
terrestrial
DTM
with the
“earth” polygons
We
start by loading the whole terrestrial area DTM in the view window
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/55.png?resize=630%2C341&ssl=1)
We will perform the
same operation as before, but by using the “terrestrial” polygons.
Since the ” sea ” polygon is always selected, just click on the terrestrial_sea layer in the legend window -> Select -> select switch to invert
the selection and get all “earth” polygons
selected.
The
Raster Clip command is executed again , but this time on the srtm raster . It just
replaces the name of the input raster.
The result is loaded
into the view :
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/56.png?resize=630%2C339&ssl=1)
Now that we have both sections of the desired DTM, we need to join them in an unique raster. To that end we will use the ArcGis Pro Raster Calculator .
In
the Geoprocessing window, return to the Toolboxes and click Spatial Analyst
Tools -> Map Algebra -> Raster Calculator
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/57.png?resize=264%2C630&ssl=1)
The formula is the
following :
Con ( IsNull (“ MntMer
“), “srtm_36_031_Clip”, “MntMer”)
In French , this
means that, depending on the following condition (Con):
if the pixel of the MntMer raster is empty ( IsNull (” MntMer “)), we will retain the
value of the terrestrial raster , if not we will retain the value of the sea
raster.
The
only problem with this formula
is that some pixels on the terrestrial-sea boundary
are empty on both input
raster (the pixels that appear in white):
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/58.png?resize=630%2C343&ssl=1)
It is enough to replace these null values by 0, which corresponds to the height of the coastline.
To this end , in the raster calculator you must type the formula
Con ( IsNull (“Mntcommun1”),
0, “Mntcommun1”)
The
result is the following :
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/59.png?resize=630%2C419&ssl=1)
Now we can click on
the Scene tab and edit the dtm used for the 3D
view .
By
default the Aerial image appears in
the dtm provided with ArcGis Pro:
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/510.png?resize=630%2C365&ssl=1)
By clicking the ribbon, MAP tab, Add Preset button-> Ground and
pointing to dtm that we have just created, we get:
![](https://i0.wp.com/www.sigterritoires.fr/wp-content/uploads/2019/03/511.png?resize=630%2C280&ssl=1)
Even if it is subtle enough , we can see that the absolute
flat surface of the marine part of the first picture is replaced by the actual seabed elevation.