Raster JPEG Input using OFFSITE
Randy How
rhow at I3.COM
Tue Jan 31 14:20:11 PST 2006
Thanks Armin,
That's interesting, and after looking at the documentation
(http://mapserver.gis.umn.edu/docs/howto/raster_data/#special-processing-dir
ectives) I have a fuller understanding of the capabilities.
My still outstanding question is in regards to the layer processing tags and
the images in a TILEINDEX. Do each of the images get preprocessed before
the composite is made? Or is the composite made then the processing
applied?
Anyone have any thoughts on this? If not I'll let you know.
Randy
-----Original Message-----
From: Armin Burger [mailto:armin.burger at gmx.net]
Sent: Monday, January 30, 2006 1:07 PM
To: Randy How
Cc: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: Re: [UMN_MAPSERVER-USERS] Raster JPEG Input using OFFSITE
Randy,
with JPEG (and mainly also ECW) you will not completely get rid of the black
borders because, as you mention, their 'black' is not fully black.
But you can get get most parts of the black transparent by applying a
PROCESSING "SCALE..." tag, eg.
PROCESSING "SCALE_1=3,255"
PROCESSING "SCALE_2=3,255"
PROCESSING "SCALE_3=3,255"
OFFSITE 0 0 0
All pixel values from 0 to 3 will be mapped to 0 and then set transparent by
the OFFSITE tag. It has the slight drawback that some very dark parts inside
the image will also be touched by this and become transparent. It works
quite well though for multispectral images, a bit less nicely on
panchromatic.
Armin
Randy How wrote:
> My question is in regards to using the OFFSITE setting for a JPEG data
> source to remove the "black/NoData" areas. Does it work at all? I've
> attempted this but it made no difference (mapserver 4.7).
>
> It will work with Tiff's (that have internal JPEG compression) and
> poorly with ECW's due to the variability in "black".
>
> Randy
More information about the MapServer-users
mailing list