20MK02 - Exercise 03
20MK02 - Exercise 03
20MK02 - Exercise 03
3.2: GEOREFERENCING:
Georeferencing means fixing a map to the earth. Georeferencing is the process of assigning
real-world coordinates to each pixel of the raster. Many times these coordinates are
obtained by doing field surveys - collecting coordinates with a GPS device for few easily
identifiable features in the image or map.
In some cases, where you are looking to digitize scanned maps, you can obtain the
coordinates from the markings on the map image itself. Using these sample coordinates or
GCPs ( Ground Control Points ), the image is warped and made to fit within the chosen
coordinate system.
STEP 1:
Open plugin > Manage and install plugin > click QuickMapServices > the plugin is added
Open web > click on the installed plugin QuickMapServices > OSM Standard
FIG 3.1: Adding OpenStreetMap into QGIS
STEP 6: Click on Project tool box > SAVE AS > save the file name Coimbatore city QGZ files
(qgz.)
Note: This image will never need to be georeferenced again. Every time you open the tif file
(not the original file, which is still just an image) in QGIS, the satellite photo will appear in
its correct location.
STEP 1: The plugin is installed in the Raster menu. Click on Raster > Georeferencer
STEP 2: Now open the JPG image which we need to georeference. Go to File>Open Raster.
Browse to the downloaded image of the scanned map and click Open.
STEP 3:In the pop-up window, enter the coordinates.where X is longitude and Y is latitude.
FIG 3.6: Enter map coordinates
GCP table now has a row with details of your first GCP, click OK.
STEP 4: Similarly, add at least 4 GCPs covering the entire image. The more points we have
the image will be also more accurate and the image is registered to the target coordinates.
choose to open the Snapping Toolbar and select the Enable Snapping tool (magnet).
From the Digitising Toolbar choose the Add Polygon (point or line) feature
Now hover your cursor in the map to snap to a feature to start digitising.
The cursor will change colour based on the snapping marker colour (e.g. magenta) which
means that you will be snapping to a feature in a chosen layer.
Now left click at the edges of the shape to snap around your chosen object.
If the object you are snapping to is complex, then you can use the TRACE tool to
automatically capture the vertices, instead of manually clicking to snap. From the Snapping
Toolbar choose the Enable Tracing button.
Start the new feature by choosing a vertex to snap to and then simply move the cursor
around your object and the TRACE tool will automatically select the vertices between
the start point and your current location. If the feature you are tracing is very complex, then
choose to snap and add a vertex manually at key points around the object.
On the Snapping Toolbar, use the Edit Advanced Configuration tool to configure which
layers you are able to snap to, the tolerance and the snapping options (vertex only, vertex
and segment) for each of those layers.
STEP 2: Navigate to and click on the menu entry Layer > Create Layer > New Shapefile
Layer. Next we will be presented with the New Shapefile Layer dialog, which will allow you
to define a new layer
STEP 3: Click … for the File name field. Select geometry type as line .A save dialog will
appear.Use the default CRS associated with this project, which is WGS84.
STEP 5: Next by using the line or point or polygon tool draw required things and save it.
STEP 6: To clean topology error for dangles (undershoot and overshoot). To clean this
error we use v.clean tool. The tool can be found in the toolbox. If the toolbox menu does not
show up. At the top menu click Processing > Toolbox.
then we can right click on the cleaned and the select attribute table it appears like this.
Now let's see the result. I captured some parts of the result and compare them before and
after the cleaning to see the difference. In fig 3.13 can be seen there is a gap between two
road segments that can be considered as undershoot error. The error was fixed as in left
picture. The two segments were joined together.
Figure 3.15 shows the overshoot error, where a segment road passes another segment with
a length 5 meter or less (because we set the threshold 5, remember :)). The result of
cleaning is shown in the right picture, which the overpass segment was cut with break
process then the remain part was removed with remove dangle.
3.5.1:TOPOLOGY ERRORS
There are different types of topological errors and they can be grouped according to
whether the vector feature types are polygons or polylines.
Topological errors with polygon features can include unclosed polygons, gaps
between polygon borders or overlapping polygon borders.
A common topological error with polyline features is that they do not meet perfectly
at a point (node). This type of error is called an undershoot if a gap exists between
the lines, and an overshoot if a line ends beyond the line it should connect to
Undershoots (1) occur when digitised vector lines that should connect to each other
don’t quite touch.
Overshoots (2) happen if a line ends beyond the line it should connect to.
Slivers (3) occur when the vertices of two polygons do not match up on their borders.
The result of overshoot and undershoot errors are so-called ‘dangling nodes’ at the end of
the lines. Dangling nodes are acceptable in special cases, for example if they are attached to
dead-end Streets.
Many GIS applications provide tools for topological editing. For example in QGIS you
can enable topological editing to improve editing and maintaining common boundaries in
polygon layers. A GIS such as QGIS ‘detects’ a shared boundary in a polygon map so you
only have to move the edge vertex of one polygon boundary and QGIS will ensure the
updating of the other polygon boundaries as shown in Fig 3.16 (1).
Another topological option allows you to prevent polygon overlaps during digitising
(see Fig 3.16 (2)). If you already have one polygon, it is possible with this option to digitise
a second adjacent polygon so that both polygons overlap and QGIS then clips the second
polygon to the common boundary.
FIG:3.16 (1):-Topological editing to detect shared boundaries, when moving vertices. When
moving a vertex, all features that share that vertex are updated.
FIG:3.16 (2):- To avoid polygon overlaps, when a new polygon is digitised (shown in red)
it is clipped to avoid overlapping neighbouring areas.