Wednesday, 19 August 2015

coordinate system - QGIS Merge rasters without projection edges


I have been trying with no luck to merge forest canopy rasters available through the NLCD (e.g. Grids 102 and 105) using QGIS in Mac (as well as R, and SAGA in Windows).


The GeoTIFF grids import and display fine. However, when I try to merge the two, triangular black spaces appear around the edges of each, and where they overlap the zero/null values of one are superimposed on the actual values of the other. It looks like this:



projection edge overlap error in merge


I suspect this is a projection problem, as the grids do not align with their mutual boundary. The files import with a "user defined" projection that is similar to NAD83/Conus Albers (EPSG:5070).


I have tried straight merging, and re-projecting before merging to various projections, but nothing seems to work. Strangely enough, however, the "land cover" (as opposed to "forest canopy") GeoTIFF rasters provided by the NLCD corresponding to the same areas - and with the same projection - merge without issue.


How can I perform a proper merge with these rasters?



Answer



Try to check No data value = Zero, and see if that succeed, as shown below


If it is not zero, then replace the zero pixel value with value of pixel. enter image description here


Another option, would be to go to the Transparency tab, and add 0 as an Additional no data value or the pixel value of it is not Zero.


enter image description here


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...