Donut Polygons in QGIS, ArcMap, ArcGIS Pro and geoJSON

Donut Polygons were the nightmare in first GIS courses. At the very moment I can’t remember why but the concept of an inner and an outer part makes total sense in the real world (house with a patio, lakes with islands, Rome with the Vatican City) yet the creation of those was never the covered in the basic “how to edit”-classes. So how can we create them with QGIS, ArcMap as well as ArcGIS Pro and geoJSON? In this tutorial I will cover this basic task.

Donut Polygons in QGIS

The process of creating Donut Polygons in QGIS is a two step process:
  1. Create the outer ring first.
  2. Digitize the inner ring in the end.


Inner vs. outer rings of Donut Polygons
Inner vs. outer ring of a Donut Polygon


Make sure you are in an editing session by pressing the “Toggle Editing” tool . Then create the exterior ring of your polygon using the “Add Feature” tool. Once the exterior ring is finished, end the creation by pressing right mouse button and fill the attributes of choice. In the next step we will use the “Add Ring” tool. If you can’t find it: It is part of the “Advanced Digitizing Toolbar”. This can be enabled via View->Toolbar->Advanced Ditizing Toolbar. Simply digitize the interior ring of your Donut Polygon, save your edits and you’re done. Follow the whole process with this video:

Donut Polygons in ArcMap

Creating a Donut Polygon in ArcMap is somewhat hidden in the concept of multipart geometries. The great plus with ArcMap: When you add a second part (the inner ring) to an existing part it automatically enhance or subtracts the area from the exterior ring if you digitize outside the exterior ring:

Donut Polygons in ArcMap
Donut Polygons in ArcMap


In the end it is quite straight forward:
  1. Digitize the outer ring but don’t double click at the end of this but right-click the mouse and select “Finish Part”
  2. Digitize the interior ring and end it either with a double-click or with right-click and select “Finish Sketch”
You can also use the “Continue Feature Tool” in the Edit Vertices Toolbar to add a new ring to the exterior ring. Check the example in this short video:

Donut Polygons in ArcGIS Pro

The same situation can be found in arcGIS Pro. Start editing the exterior ring and use the right click to add a new part or use the “Modify” tool to “Continue Feature”. In the end, the creation of Donut Polygons is easier in ArcGIS/ArcMap compared to qgis. But check also the video for ArcGIS Pro:

Donut Polygons in geoJSON

This is somewhat a different view on the problem. But it might be of importance if you work with geoJSON on a more computational level. The overall architecture of a geoJSON polygon looks like this:

{
  "type": "Feature",
  "properties": {
	"name": "Donut Polygon"
  },
  "geometry": {
	"type": "Polygon",
	"coordinates": [
	  [
		[-1.876101718749999,12.48788989632766],
		[-1.3175217187499988,12.043710725966251],
		[-1.3695917187499989,12.448594238033987],
		[-1.876101718749999,12.48788989632766]
	  ]
	]
  }
}
We see a simple polygon with three edges. This defines the exterior part of our Donut. The normal geometry type “Polygon” allows nested geometries. We enhance the geometry by adding a new ring:
    "coordinates": [
      [
        [
          exterior ring ccordinate pairs
        ],
        [
          interior ring coordinate pairs
        ]
      ]
    ]
The result will look like this:


{
  "type": "Feature",
  "properties": {
	"name": "Donut Polygon"
  },
  "geometry": {
	"type": "Polygon",
	"coordinates": [
	  [
		[-1.876101718749999,12.48788989632766],
		[-1.3175217187499988,12.043710725966251],
		[-1.3695917187499989,12.448594238033987],
		[-1.876101718749999,12.48788989632766]
	  ],
	  [
		[-1.7324066162109375,12.443281785521078],
		[-1.395263671875,12.18232089399501],
		[-1.4447021484374998,12.418471506919504],
		[-1.7324066162109375,12.443281785521078]
	  ]
	]
  }
}
5 2 votes
Article Rating
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

4 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Pablo Angulo
Pablo Angulo
6 years ago

nice share dude,

digital-geography
digital-geography
6 years ago
Reply to  Pablo Angulo

we’ve just added two more videos for ArcGIS Pro and ArcMap.

Andrew Zolnai
6 years ago

A little history: Oracle Spatial was started as a spatial extension to Oracle 4 in 1983 by CDN Hydrographic Service http://bit.ly/2w4Rapv
Problem is when they tested it (Sylvain then @ CHS now @ Bentley Projectwise by way of Oracle) R-Tree indexing went well with points and lines (fish and shorelines), slow w time-aware points and polygons (schools of fish and islands) but crawled to a halt on donut polygons (lakes in islands) LOL

Yohann
Yohann
2 years ago

Nice article, thank you for sharing