0

I have a DEM raster. I have a polygon representing a hole.

How do I combine the two, so that I have a new DEM whose elevation, in the area bounded by the polygon, has been adjusted according to whatever height value I assign the polygon?

Things I've tried:

  • Rasterizing the polygon and combining it with the existing DEM, which gets me a hole, but requires an insanely high resolution on the DEM or else I get jagged edges.
  • Giving an extrusion of the polygon a negative value, so that when rendered in 3D I get a hole. Unfortunately, the render still projects both the DEM and the polygon separately, so the "hole" is covered by the DEM. I still need to cut a hole in the DEM to reveal the polygon below.
  • After the last bullet point, I vectorized the DEM, cut a hole in it that matched my hole-polygon, and then extruded it -- and realized that in the 3D view, the extrusion is invisible if the camera angle is in the wrong plane. e.g. if my camera angle is looking at the ground from above, the extruded polygon with a negative value is invisible. If I pan the camera "under" the ground plane, so I'm looking back up at the ground from underneath, the extruded shape is visible, but everything else is invisible. I also have the problem of having the top face of my polygon, the one level with the surrounding DEM, effectively blocking the opening to my hole.

I ultimately want to be able to model a hypothetical hole and assign z-axis values to particular point data located within the ditch.

  • 1
    What size is the hole, what resolution the underlying DEM, and what resolution do you mean by "insanely high"? – Ed Rollason Dec 7 '18 at 10:01
  • The trenches/holes i want to model vary in size and depth, as they're archaeological trenches that range from small 1m square soundings to larger 10m x 5m excavations. The resolution of the underlying DEM varies, as I'm interpolating it (TIN interpolation) from vector data (contours, breaklines, and point data), and I've been varying the values in the "columns" and "rows" input to increase or decrease the resulting resolution of the DEM depending on what I need the DEM to do. For wider-view least-cost analyses, for example, i've been using a lower resolution DEM. For trenches, higher. – BogBody Dec 7 '18 at 16:57
  • 1
    If you're building the DEM from scratch using TIN interpolation, have you tried including your hole polyons into the interpolation as breaklines or structure lines? – Ed Rollason Dec 7 '18 at 17:14
  • No, but that's a really great idea, it hadn't even occurred to me! I haven't manually created contour or break lines previously -- is this as easy to do as manually drawing vector lines to match the trench? One possible problem with this method is that the depth of the trenches varies in relation to the terrain. For example, if a trench is on a slope, the maximum depth follows particular stratigraphic layers, so that on one side of the trench the maximum depth might be 0.5m, and the other side of the trench might be 1.5m. – BogBody Dec 7 '18 at 18:38
  • You might have to experiment a bit but yes theoretically. Give your lines a Z attribute and use that for the TIN calculation. I would say this is much easier in ArcGIS as TINs can be edited post hoc in a way they can't be in QGIS – Ed Rollason Dec 10 '18 at 8:59

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.