[Gdal-dev] transparent Geotiff?

Luis W. Sevilla sevilla_lui at gva.es
Mon May 30 06:58:39 EDT 2005


We've tryed to configure a mapserver serving WCS layers, but is seems to 
ignore that OFFSITE parameter
it's there anything more to do ?

    thanks in advance

Ken Boss wrote:

>Bart--
>
>If your goal is simply to set background to transparent in mapserver apps, you should be able to use the OFFSITE parameter in your layer definition to accomplish that - no conversion necessary.  Eg:,
>
>  LAYER
>    NAME shr30im3
>    STATUS OFF
>    DATA "data/gen/state/mn/shdr_clrim3.tif"
>    TYPE RASTER
>    OFFSITE 255 255 255
>  END # shaded relief
>
>HTH,
>
>--Ken
>
>  
>
>>>>"Bart van den Eijnden" <BEN at Syncera-ITSolutions.NL> 05/27/05 9:21 AM >>>
>>>>        
>>>>
>Worked like a charm! Opens up transparent in OpenEV now so I am sure Mapserver will do the same. Thanks a lot!
>
>D:\wormerland\new>gdalwarp -dstalpha -srcnodata 255 -dstnodata 0 de_poel.tif de_poel2.tif
>Creating output file that is 9384P x 6340L.
>ERROR 6: SetColorInterpretation() not supported for this dataset.
>:0...10...20...30...40...50...60...70...80...90...100 - done.
>
>Best regards,
>Bart
>
>Bart van den Eijnden
>Syncera-ITSolutions
>Postbus 270
>2600 AG  DELFT
>
>tel.nr.: 015-7512436
>email: BEN at Syncera-ITSolutions.nl 
>
>  
>
>>>>Eric Sokolowsky <eric.sokolowsky at gsfc.nasa.gov> 05/27/05 04:12pm >>>
>>>>        
>>>>
>On Fri, 27 May 2005, Bart van den Eijnden wrote:
>
>  
>
>>Hi list,
>>
>>I have a lot of geotiff files which have a white background. Because many of the tiffs overlap, I need a way to create transparent tiffs (set white as the transparency color). Does anybody know how to do this?
>>    
>>
>
>You can try using the gdalwarp tool to convert from your source image to
>a new image with transparency with the -dstalpha switch.  You probably also
>need -srcnodata 255 and -dstnodata 0.  The the help for gdalwarp for more info.
>
>  
>


-- 
  Luis W. Sevilla
  Equipo de desarrollo gvSIG
  Conselleria de Infraestructuras y Transporte
  Generalitat Valenciana
  Valencia - Spain
  http://www.gvsig.gva.es





More information about the Gdal-dev mailing list