0

I have a multiband TIFF, where each band represents a time slice of a dataset. The date of each band is stored in the Band Description. See the output from gdalinfo here:

Band 1 Block=476x1 Type=Float64, ColorInterp=Gray
  Description = 20190103
Band 2 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190108
Band 3 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190128
Band 4 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190314
Band 5 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190319
Band 6 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190423
Band 7 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190627
Band 8 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190702
Band 9 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190712
Band 10 Block=476x1 Type=Float64, ColorInterp=Undefined
  Description = 20190717

I have a custom web mapping application that needs to know the description for each band. How can this be included in the WMS?

The real dataset will have 100s of bands, this is just a test. Current GetFeatureInfo requests only give Band Names, not Descriptions:

Results for FeatureType 'test:BONHS2_chla':
--------------------------------------------
Band1 = 0.3601886935688596
Band2 = 0.35895391962365375
Band3 = 0.3633920293635388
Band4 = 0.3722105823755535
Band5 = 0.3719028533418903
Band6 = 0.3742063143146085
Band7 = 0.3719612801340882
Band8 = 0.3745988311791892
Band9 = 0.3699610274424047
Band10 = 0.37583719269755006
--------------------------------------------
1
  • Why not configure a WCS too
    – nmtoken
    Sep 12 at 9:20

1 Answer 1

0

It may not be possible to publish the layer descriptions from GeoTIFF with GeoServer but at least it is possible to edit the layer names. Open the raster layer settings in the GeoServer web interface for editing the advertised band names.

enter image description here

This name will be used in the GetFeatureInfo

enter image description here

These images are captured about the GeoServer demo layer "nurc:Arc_Sample" from the layer settings page and from the layer preview.

2
  • Yes, thats a good feature but it doesnt help us, as we will have 100+ bands and many datasets, this isnt a solution. Thanks anyway!
    – staf
    Sep 11 at 23:08
  • By the documentation docs.geoserver.org/latest/en/user/tutorials/GetFeatureInfo/… it is possible to customize the GFI output with a template but probably only that documented "label" case is supported. I suggest to contact GeoTools/GeoServer developers because you probably want something that is not implemented.
    – user30184
    Sep 12 at 5:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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