Hi Gaby,

> I am retooling an application that is using a home grown “map” interface,
> replacing the latter with geotools.
> Some of the data comes as georeferenced images. These are created by helper
> tools from CSV files, ESRI bin files or NETCDF files.
>
> All good so far. I can read these files no problem using the
> GridCoverageReader.
>
> All the images produced this way are RGB PNG’s which come with an additional
> file with the extension “range" which gives
> the range of the physical values represented by each pixel.  Without this
> information I cannot get pack the physical value at
> each pixel (wind velocity, flood depth, that sort of thing)

Actually apart of being quite a hack, I don't think that you can get
the real value back in every case, don't you?
From the png you get rgb values in 0-255 ranges. What should happen
next? A mapping to a physical value?

This sounds very strange to me.
Not sure what the range file really contains, though.

Andrea




> Correct me if I am wrong, but I think this is part of the “home grown”
> solution. I have never seen anything like this before and
> google has no idea either.
> I thought that I could get the range of values from getting
> GridSampleDimension from GridCoverage2D, but they are not there.
>
> Am I right to assume that the way the images  are being created basically
> omits this information from the PNG?
>
> Going forward, I would like to correct this in our helper tools if possible.
> Additionally, I want to create grayscale rasters rather than
> RGB  rasters, since want to leave the “styling” separate and user
> modifiable.
>
> Tweaking the code to create grayscale raster is a piece of cake, but I still
> have to use the extra range file.
>
> What am I missing?
> Thanx
> Gaby
>
>
>
> ------------------------------------------------------------------------------
> Want fast and easy access to all the code in your enterprise? Index and
> search up to 200,000 lines of code with a free copy of Black Duck
> Code Sight - the same software that powers the world's largest code
> search on Ohloh, the Black Duck Open Hub! Try it now.
> http://p.sf.net/sfu/bds
> _______________________________________________
> GeoTools-GT2-Users mailing list
> GeoTools-GT2-Users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users
>

------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to