Jump to content

 
Photo

How to merge two DEMs without steps between them?

- - - - -

  • Please log in to reply
14 replies to this topic

#1
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

Hi!

I spend the whole last week in trying to find a way to merge two DEM files without steps between then.
When using the feathering option in GlobalMapper, both DEMs merge just perfect until I export them to GeoTIFF or whatever other format. When I re-open that saved new DEM, the merger/feather areas are full of steps.

See attached screenshots from GlobalMapper. The first one shows how it looks like after the feathering has been done along selected polys, the second ones shows the result of the same after it has been saved.

What I did so far:
  • Brought both DEMs up to exactly the same resolution.
  • Tried all kinds of resample options GlobalMapper offers
  • Saved the whole thing in a higher resolution. After that the steps are smaller but still there.
  • Tried almost all other export formats GlobalMapper offers

Any help would be highly appreciated.

Bests,
Simmer

Attached Files



#2
Charles Syrett

Charles Syrett

    Ultimate Contributor

  • Validated Member
  • PipPipPipPipPipPip
  • 537 posts
  • Canada

Do you have the two DEMs as separate entries in Global Mapper? If so, it may be best simply to export each one separately, and then import them into an image editor (such as Photoshop) as separate layers, then merge the layers and save as a flat image.

Global wants to interpolate between the two images -- hence the steps. Photoshop will just look at these as images, and won't mess with them unless you tell it exactly what to do. The drawback is that you'll lose the georeferencing, but you can re-import into Global and add it back in.

Charles Syrett
Map Graphics
http://www.mapgraphics.com

#3
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

Right, but if I do that I loose the smooth feathering between both DEMs. Making a smooth selection in Photoshop is not an option because the mesh consists of about 200+ tiles and Photoshop would also smooth the corners of every single one causing the tiles not to match anymore on the corners.

Bests,
Simmer

#4
Charles Syrett

Charles Syrett

    Ultimate Contributor

  • Validated Member
  • PipPipPipPipPipPip
  • 537 posts
  • Canada

Have you tried Global Mapper Forum? I've found I can get answers on all kinds of issues there, very quickly.

Charles Syrett
Map Graphics
http://www.mapgraphics.com

Right, but if I do that I loose the smooth feathering between both DEMs. Making a smooth selection in Photoshop is not an option because the mesh consists of about 200+ tiles and Photoshop would also smooth the corners of every single one causing the tiles not to match anymore on the corners.

Bests,
Simmer



#5
canvas101

canvas101

    Contributor

  • Validated Member
  • PipPip
  • 37 posts
  • United States

Hello Simmer,

Any chance you can post two of your DEM example tiles to see if somebody can assist.

Regards

#6
Sv_BG

Sv_BG

    Contributor

  • Validated Member
  • PipPip
  • 33 posts
  • Gender:Male
  • Location:Sofia
  • Bulgaria

You can try with ArcGIS' raster calculator. Check this out - http://www.brocku.ca...d/mergeGRID.htm
It looks pretty easy :)

Cheers,
Svetoslav

#7
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

Any chance you can post two of your DEM example tiles to see if somebody can assist.


Ok, here's the 1st of 2 parts.

Attached Files



#8
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

And here part 2.

The data comes from ASTER DEM for Antarctica. I'm trying to get rid of the peaks and holes that are scattered over the whole snow-covered areas there. Therefore I have created a low resolution DEM of the same area for the snow covered areas so that the peaks and holes are not so obvious anymore.
Next step was to draw polygons around all the snow-covered areas, mainly glaciers. My plan was to cut out the DEM along the polylines to get the result shown in the screens above. Which works pretty well and even looks great in Global Mapper's 3D preview until I export everything. How I do it:

- Load all 3 files including the SHP
- Select the polygons
- Go to Control Panel and move "TestBlur" below "TestNormal"
- Click o "TestBlur", Options, Feathering, Feather within currently selected polygons, border size=10px, Feather Outside, OK

The result looks exactly as I need it until it has been exported.

I tried the same with Manifold and ArcGIS but couldn't find a way to merge two DEMs and feather them along the selection corners.

Bests,
Simmer

Attached Files



#9
canvas101

canvas101

    Contributor

  • Validated Member
  • PipPip
  • 37 posts
  • United States

Hello Simmer,

The attached image is a DEM from the data you provided. I was able to achieve the results by adding a buffer of 500m to the polygons and then adding the feather at a value of 40 inside(less slope). By doing this I have reduced the transition from one DTM to the other. Let me know your thoughts.

Regards

Attached Files



#10
canvas101

canvas101

    Contributor

  • Validated Member
  • PipPip
  • 37 posts
  • United States

Hello Simmer,

If you would like the test DEM to review let me know. The file is 1.37mb zipped.

Regards

#11
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

Thanks. Doesn't look too bad but if I'm not mistaken there are still some obvious steps in there.
Problem is that this is intended to be used in a flight simulator and the sun is always rather low in those latitudes causing every single step in the terrain to be visible due to the shadows they cause.

Bests,
Simmer

#12
canvas101

canvas101

    Contributor

  • Validated Member
  • PipPip
  • 37 posts
  • United States

Thanks. Doesn't look too bad but if I'm not mistaken there are still some obvious steps in there.
Problem is that this is intended to be used in a flight simulator and the sun is always rather low in those latitudes causing every single step in the terrain to be visible due to the shadows they cause.

Bests,
Simmer


Hello Simmer,

Have a look at a 3d (sun altitude 25) image of the DEM. Just change your sampling and you will get your desired results. Let me know if this solution will work.

Regards

Attached Files

  • Attached File  3d_2.jpg   252.89KB   39 downloads


#13
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

Have a look at a 3d (sun altitude 25) image of the DEM. Just change your sampling and you will get your desired results. Let me know if this solution will work.


Thank you for your efforts. It looks tempting although not completely satisfying yet. Using your approach things look a lot smoother but "smaller" details like a mountain peaking out of the ice with 1-2km in diameter get lost completely (see attached screen).

If I remember right I once saw it somewhere being discussed that filling holes in SRTM v1 would be possible with 3rd party data. This would require a similar approach as for this problem I assume but I can't find anything about it anymore.

Jonathan de Ferranti did it by converting everything to contour lines first. Not a bad approach and it also works for this case. But only if you don't mind having flat mountaintops in the resulting DEM. I guess Jonathan fixed that manually for every mountain by adding contours up to the top:
http://www.viewfinde...g/voidfill.html

Bests,
Simmer

Attached Files



#14
canvas101

canvas101

    Contributor

  • Validated Member
  • PipPip
  • 37 posts
  • United States

Hello Simmer,

Please follow-up with the method you settle on. On a side note building a TIN model in AutoCAD and using a TIN merge option would certainly give you the most editing power but it seems a bit excessive consider the nature of your project. I have merged low resolution and high resolution models without fail using this method. Good luck.

Regards

#15
Simmer

Simmer

    Contributor

  • Validated Member
  • PipPip
  • 31 posts
  • Trinidad and Tobago

I've just seen that ArcGis does a pretty nice job in converting contours to DEM, therefore I give that option another try: Converting the DEM to contours, 200 steps in the snow covered areas, 25m in all the others. First experiments were rather successful in this, let's hope it also works for a larger area.
I'll let you know how it works out.

Simmer




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

-->