Feature request #805

Templates or saveability/loadability in the color stretches (custom color maps)?

Added by yury_t - almost 13 years ago. Updated about 11 years ago.

Status:Closed
Priority:Low
Assignee:ersts -
Category:Rasters
Pull Request or Patch supplied: Resolution:fixed
Easy fix?:No Copied to github as #:10864

Description

Is there any way to make color stretches saveable/loadable? Possibly,
the "Classify" parameters (palette?) saveable/loadable, too? Or would
the Classify templates be feasible?

Right now doing the customized stretch is lots of work, the result
isn't transferrable, and occasional hit of "Claassify" button resets
everything in the stretch.

slope.tar.bz2 - example ArcInfo ASCII raster with an XML colortable file (20.8 KB) Maciej Sieczka -, 2008-08-26 01:01 AM

History

#1 Updated by ersts - about 12 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

You can now save your color maps as a textfile. It is a very simple format and could be edited or created by hand if a user wants

The structure of the file is:
  1. {COMMENTS}
    INTERPOLATION: {Method = INTERPOLATED, DISCRETE, EXACT} {PixelValue},{RedValue 0-255},{GreenValue 0-255},{Blue 0-255},{Alpha 0-255}, {Label} {PixelValue},{RedValue 0-255},{GreenValue 0-255},{Blue 0-255},{Alpha 0-255}, {Label} {PixelValue},{RedValue 0-255},{GreenValue 0-255},{Blue 0-255},{Alpha 0-255}, {Label}
    ...

Where values inside {} are numbers or strings.

#2 Updated by Maciej Sieczka - about 12 years ago

GDAL is able to create and interpret a colortable in an XML file, for any raster. Would it be possible to use this format instead of introducing QGIS's own one?

See the attached ArcInfo ASCII raster with an external colortable. QGIS renders the raster all nice in colors.

#3 Updated by ersts - about 12 years ago

I would prefer to not look at this as one format or another. I would rather see an enhancement request for QGIS being able import and export several different types of color maps/gradient formats - as there are some nice features in each but not all are 100% compatible - for example, class label support.

Currently QGIS will read/load any initial color map provided by GDAL for a band.

#4 Updated by Anonymous about 11 years ago

Milestone Version 1.0.0 deleted

Also available in: Atom PDF