[mapserver-users] processing scale=auto with float multibands rasters
Andrea Peri
aperi2007 at gmail.com
Tue Aug 4 10:07:04 PDT 2015
Hi Even,
thx for response.
Please can you help me to better understand the question ?
My raster is effectively a 18000 x 24000 px image with tiles.
it have a tile size of 1024 x 1024 produced from gdalwarp:
gdalwarp -s_srs EPSG:32632 -t_srs EPSG:32632 -overwrite --config
GDAL_CACHEMAX 1000 -wm 1000 -co TILED=YES -co COMPRESS=NONE -co
BLOCKXSIZE=1024 -co BLOCKYSIZE=1024 -co BIGTIFF=YES -co SPARSE_OK=TRUE
.......
and also have overviews from
gdaladdo --config GDAL_CACHEMAX 1500 -ro -r average ..... 2 4 8 16 32
64 128 256 512 1024
If I understand correctly your info.
The mapserver could search the min/max using only the first tile ?
This mean that it more probably found always only 0 values or near 0
values beacuse these could be the values in the first tile.
And so it return a white image because the min/max is always min=0/
max=0 (or something quite like this)
I understand correct ?
thx,
A.
2015-08-04 16:01 GMT+02:00 Even Rouault <even.rouault at spatialys.com>:
> On Monday 03 August 2015 11:02:43 Andrea Peri wrote:
>> Hi,
>> I have a geotiff multibands with float64 values to serve with a wms
>> mapserver service.
>>
>> With this kind of rasters,
>> is affordable the directive
>>
>> PROCESSING "BANDS=4,3,2"
>> PROCESSING "SCALE=AUTO"
>>
>> (the 4,3,2 are the red,green,blue channels)
>>
>> Infact it seem do nothing.
>>
>> Instead all work well if I set:
>>
>> PROCESSING "BANDS=4,3,2"
>> PROCESSING "SCALE_1=0.01,0.2"
>> PROCESSING "SCALE_2=0.01,0.2"
>> PROCESSING "SCALE_3=0.01,0.2"
>>
>> where ii use the min=0.01 and max=0.2
>> But I like to have the exact values of min/max for every raster.
>
> Andrea,
>
> SCALE=AUTO should work but looking at the actual implementation I can see it
> computes the min/max on the pixel values intersecting the requested area, and
> not on the whole raster as I'd have expected. So in a tiling context, it will
> likely not produce the expected result.
>
> Even
>
> --
> Spatialys - Geospatial professional services
> http://www.spatialys.com
--
-----------------
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-----------------
More information about the MapServer-users
mailing list