I have two polygons in QGIS that are within the same layer and I want to merge them so they are not in two different polygons, which means that the gap between them sould not exist. How do I do that?
If you don't know Python, try OpenJump GIS. It can do things not present in QGIS
1) the polygons
2) unions in the same layer
3) Convex Hull
3) Concave Hull
4) you can adjust parameters
But is is the best result that you will get without programming (how to join the polygons, nodes, vertices ?)
(one result with Shapely)
A quick way to get an acceptable result is the Expand-Shrink method, but for vectors
In this image we have the original shapes.
- Step 1 is to create a dissolved buffer that will join the two features, with the buffer distance (x) being more or less the gap. (black line)
- Step 2 is to create another buffer with a negative (-x) of the aforementioned value (blue line)
I'm sure there are additional steps one can take to refine the results.