[GIS] Failing to merge rasters in QGIS

lidarmacmergeqgisraster

enter image description hereenter image description here

I am new to QGIS but have some familiarity with other GIS software (namely ArcGIS). I want to merge a number of LiDAR digital elevation model (DEM) tiles (specifically, 30 individual tiles) to create one large mosaic DEM. All the DEMs are .img files downloaded from this site.

From the QGIS home workspace, I go to Raster > Misc. > Merge. I am careful to type appropriate input and output directories, file names, and file extensions. QGIS completes the merging process, but the mosaic is pitch black and it's min/max values are both a very negative value (both the min and max are -3.40282e+35). Obviously, this mosaic isn't quite right. I am uncertain where I go wrong in my procedure.

I have experimented with writing the output file extension as .img and .tif. I have also experimented with the "No data value" option (leaving this option unselected and trying this option selected with a value of 0). These changes do nothing to the change/improve the final output file issue. I have also attempted to use the mosaic feature on just a 2-by-2 chunk of the individual DEM tiles, but this yields in the same erroneous result.

I am using QGIS 2.4-Chugiak on a Mac running OS X 10.9.4.

Best Answer

I had the same problem. To fix it, take a look at the minimum and maximum values of each raster you're merging in the Layers Panel and then input those values into the min and max of your new mosaic raster.

For example: in my LiDAR map project, the lowest minimum value of all my rasters was 1.4998 and the highest maximum value of all my rasters was 63.3014 (these values are visible under the layer name in the Layers Panel). I double-clicked my mosaic layer in the Layers Panel to reveal the Layer Properties window. Next, I input these values as the Min and Max values in the "Band rendering" section, which fixed my mosaic raster and made it look as expected.

Hope this helps, and best of luck.