[gdal-dev] gdal2tiles - transparent area on base image becomes
opaque in tiles
easyl
easy.lin at gmail.com
Tue Mar 30 07:38:46 EDT 2010
open base_mercator.vrt
it should looks like
<VRTDataset>
...
<VRTRasterBand dataType="Byte" band="1" subClass="VRTWarpedRasterBand"/>
<VRTRasterBand dataType="Byte" band="2" subClass="VRTWarpedRasterBand"/>
<VRTRasterBand dataType="Byte" band="3" subClass="VRTWarpedRasterBand"/>
<VRTRasterBand dataType="Byte" band="4" subClass="VRTWarpedRasterBand"/>
...
<BandList>
<BandMapping src="1" dst="1"/>
<BandMapping src="2" dst="2"/>
<BandMapping src="3" dst="3"/>
</BandList>
<SrcAlphaBand>4</SrcAlphaBand>
</GDALWarpOptions>
</VRTDataset>
Try to manually modify base_mercator.vrt
<VRTDataset>
...
<VRTRasterBand dataType="Byte" band="1" subClass="VRTWarpedRasterBand">
<Metadata/>
<ColorInterp>Red</ColorInterp>
</VRTRasterBand>
<VRTRasterBand dataType="Byte" band="2" subClass="VRTWarpedRasterBand">
<Metadata/>
<ColorInterp>Green</ColorInterp>
</VRTRasterBand>
<VRTRasterBand dataType="Byte" band="3" subClass="VRTWarpedRasterBand">
<Metadata/>
<ColorInterp>Blue</ColorInterp>
</VRTRasterBand>
<VRTRasterBand dataType="Byte" band="4" subClass="VRTWarpedRasterBand">
<Metadata/>
<ColorInterp>Alpha</ColorInterp>
</VRTRasterBand>
...
<GDALWarpOptions>
...
<BandList>
<BandMapping src="1" dst="1"/>
<BandMapping src="2" dst="2"/>
<BandMapping src="3" dst="3"/>
<BandMapping src="4" dst="4"/>
</BandList>
</GDALWarpOptions>
</VRTDataset>
and run "gdal2tiles.py --zoom=0-9 --no-kml --webviewer=openlayers
base_mercator.vrt" again
Which options should I pass into gdalwarp to generate correct band list?
btw, MapTiler generates tiles with gray boundary as well...
--
View this message in context: http://n2.nabble.com/gdal-dev-gdal2tiles-transparent-area-on-base-image-becomes-opaque-in-tiles-tp4799092p4823943.html
Sent from the GDAL - Dev mailing list archive at Nabble.com.
More information about the gdal-dev
mailing list