On 1/2/21 9:13 AM, mega saputra wrote:
Dear all,

I try to create color table in 16 bit. That is in attachment. But, when I set color table interactively, then I input that file (in attachment), then I click Load. There is a message : "Invalid color table format". Do I missing something?


I think you have the categories and colors backwards. RGB color tables are (throughout all GIS and image software) always three 8 bit numbers, with optionally a fourth alpha band, also 8 bit. In your rules file you attach raster values (16 bit numbers in your case) to certain RGB values.  So, To define a color table for your raster you put the raster values in the left column and R:G:B (0-255) combinations in the right column.


Here's an example of the srtm (elevation) builtin color table. Maybe you can use it as a template.


-11000 0:0:0
-500 0:0:10
-300 0:0:20
-200 0:0:70
-100 0:0:130
-50 0:0:205
0 100:128:255
0.1 57:151:105
100 117:194:93
200 230:230:128
500 202:158:75
1000 214:187:98
2000 185:154:100
3000 220:220:220
5000 250:250:250
8850 255:255:255
nv 255:255:255
default 255:255:255


It spans the range of elevations from sea bottom (-11000 m) to the peak of the Himalaya Mts. (8850 m)


HTH


Thank you.

Regards,
mega

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

--
Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab
cell: +972-523-665918

_______________________________________________
grass-user mailing list
grass-user@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/grass-user

Reply via email to