[gdal-dev] Reprojecting rasters

Rob gis at vanbooth.com
Tue Jun 8 13:04:22 EDT 2010


Panic over.  I have just proven that an idiot can panic and cast suspicion
on everyone but himself!

The tiles seem to be reprojected OK, but Geoserver was laying the tiles on
top of each other without using any transparency, hence each tile leaving a
white blob on top of the last one.

A quick modification to the Input Transparent Color setting and Bob is your
fathers brother!

Thanks again

Rob


On 8 June 2010 17:34, <christian.mueller at nvoe.at> wrote:

> I am not sure here, but this looks like  each tile is projected for itself.
>
> My procedure always is
>
> 1) Build a large image without tiles
> 2) Reproject
> 3) Create Tiles/pyramids
>
> Try to avoid TILED=YES and reproject  within the same gdalwarp call.
>
>
>
> Quoting Rob <gis at vanbooth.com>:
>
>  Hi
>>
>> [Apols for the X-post]
>>
>> I'm trying to reproject a set of rasters in order to improve performance
>> on
>> my application.
>>
>> I have a set of rasters in OSGB (EPSG:27700) that I want to pre-process so
>> that they are in WGS84 (EPSG:4326) within GeoServer, rather than relying
>> on
>> GeoServer to do the reprojection on the fly.
>>
>> I have been reprojecting the rasters using the following command
>>
>>
>> gdalwarp -of GTiff -s_srs "EPSG:27700" -t_srs "EPSG:4326" -co "TILED=YES"
>> -co "COMPRESS=LZW" -co "TFW=YES" OLDNAME.TIF NEWNAME.TIF
>>
>>
>> I have used the ImageMosaic datastore to load these into GeoServer and can
>> view them.  So far, so good.
>>
>> However, there seems to be large gaps between the 'tiles' so that roads no
>> longer join up and forests have big white gaps within them.
>>
>>  From checking the rasters and the resultant world files, I've noticed a
>>> few
>>>
>> things.
>>
>> 1) The image sizes are not constant.  All of my original tiles are the
>> same
>> size.  It has raised an interesting question of whether the meridian line
>> runs parallel to an OSGB Y-axis.
>> 2) The worldfiles also contain some curious values.  I understand that the
>> 1st and 4th parameters in a worldfile are the real world distance of a
>> single pixel, but they seem to have the same value in despite the fact
>> that
>> the image size changes from being square to being rectangular.
>>
>> Whether those things mean anything, or are perfectly legitimate when
>> reprojecting, I don't know, I just thought I should mention them.
>>
>> Has anybody got any advice on how to reproject a full set of rasters, or
>> what I have done wrong?
>>
>> Thanks
>>
>> Rob
>>
>>
>
>
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100608/4e211f18/attachment.html


More information about the gdal-dev mailing list