Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to mosaic three images. Each image has a black back ground. The background is still there even after mosaicking the images, so it's like a gap between the image.

How can I remove this black color using ArcGIS or QGIS.

share|improve this question

use gdalwarp as following code:

gdalwarp -srcnodata 0 -dstalpha input.tif output.tif

-srcnodata value [value...]: Set nodata masking values for input bands (different values can be supplied for each band). If more than one value is supplied all values should be quoted to keep them together as a single operating system argument. Masked values will not be used in interpolation. Use a value of None to ignore intrinsic nodata settings on the source dataset.


-dstalpha: Create an output alpha band to identify nodata (unset/transparent) pixels.

i hope it helps you...

share|improve this answer

Removing the black collar is very easy using ArcMap 10:

  1. Select the "blue identify tab". Then select the black background to determine the pixel value (in my case the black background pixel value is set to 0).
  2. Right click on your raster layer in the table of contents, select Properties > Symbology.
  3. Choose the color display you want.
  4. Check the "Display Background Value" "YOUR_VALUE_HERE" as "No Color".

Alternatively, you can Reclassify your raster data and either exclude certain values or set the black collar pixel values to "NoData".

enter image description here

enter image description here

share|improve this answer
is not enough only Properties > Symbology - Display Background Value (0,0,0) as nothing. i think this is enough to get rid of black edges. – Aragon Nov 1 '12 at 12:50
@Aragon Could you please clarify your comment? – Aaron Nov 1 '12 at 14:38

If you are using QGIS, you can remove the black background/edges via properties -> transparecy, there you set the No data value to 0. In any case, my answer is almost 2,5 years late, however this answer might be useful for someone facing some problems at present time.

share|improve this answer
This also seems to remove black values within the image. – user58772 Sep 4 '15 at 23:04

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.