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 have a number or single band raster grids that have been converted to RGBA (png). I no longer have access to the orignal single band raster data but have the png files. Is there a way to convert the png files back to the single band grid? Preferably using QGIS or other opensource GIS?

share|improve this question

It depends a bit on what you mean by single band. This could be B&W or indexed colour. If you want Indexed Colour you can use the RGB2PCT tool. Go->Raster->Convert->RGB2PCT (or use the GDAL Utility program If you want a B&W version, you could use the raster calculator to take an average of the three bands or have some other calculation if there is some emphasis in one of the bands.

Alternatively, if your PNG has a world file, simply open the image in GIMP or Photoshop. Set the mode to greyscale or Indexed Colour (depending on your needs) and save. Copy the world file and edit the name to match your B&W version (just make sure you don NOT save it in a progressive format - check the advanced save options in GIMP). This method can be very useful if you want to rearrange the pallet.

share|improve this answer

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.