[OSGeo Africa] struggling with gdalwarp

Zoltan Szecsei zoltans at geograph.co.za
Thu Sep 1 06:55:44 PDT 2016


Hi Guys,
I've been struggling to get some 3200 orthos mosaicked and tiled.
They are very old and have really bad projection definitions, pixel 
sizes and metadata funnies.
I'm down to the last 261, and have hit a brick wall, likely due to my 
not that great "projection definitions" knowledge.

I get the following error from gdalwarp:

    ERROR 6: Unable to load PROJ.4 library (libproj.so), creation of
    OGRCoordinateTransformation failed.

I have tried various different gdalwarp parameters - even leaving 
gdalwarp to sense in input projection and me only specifying the output 
projection.
If I leave out both s_srs and t_srs then gdalwarp does work but 
obliviously does not reproject to Lo19.
I have even tried feeding the output of this redundant gdalwarp into a 
gdalwarp with t_srs, but no success.

Specifying only t_srs (as above) on many other orthos on Lo17 & Lo21 
does work so it is likely that the way this projection is embedded in 
this ortho is the problem.
I have tried stripping it out with gdal_edit.py but haven't gotten that 
right yet.

Anyone with pointers or ideas on this?

My last effort before email this list is below, as is the gdalinfo output.

Thanks in advance,
Zoltan

gdalwarp -s_srs '+proj=tmerc +lat_0=0 +lon_0=21  +k=1 +x_0=0 +y_0=0 
+datum=Hartebeesthoek94 +units=m +no_defs'  \
          -t_srs '+proj=tmerc +lat_0=0 +lon_0=19  +k=1 +x_0=0 +y_0=0 
+datum=WGS84 +units=m +no_defs' \
          -r cubicspline -multi -overwrite -of GTiff -co TFW=YES -co 
COMPRESS=JPEG -co JPEG_QUALITY=75 -tr 0.75 -0.75 \
          /mnt/sdb1/used_images/dwa_2000/3220/3220CC01.tif \
/mnt/sda1/gisdata/raster/used_2016/dwa_2000/3220/3220CC01.tif
#
#
gdalinfo   /mnt/sdb1/used_images/dwa_2000/3220/3220CC01.tif
#
Driver: GTiff/GeoTIFF
Files: /mnt/sdb1/used_images/dwa_2000/3220/3220CC01.tif
Size is 6729, 7720
Coordinate System is:
LOCAL_CS[" Geocoding information not available Projection Name = WGS 
1984 Lo21 Units = meters GeoTIFF Units = meters",
     UNIT["metre",1,
         AUTHORITY["EPSG","9001"]]]
Origin = (-93872.189308887900552,-3625321.216973003931344)
Pixel Size = (0.750000000000000,-0.750000000000000)
Metadata:
   AREA_OR_POINT=Area
   TIFFTAG_DOCUMENTNAME=hetotiff
   TIFFTAG_IMAGEDESCRIPTION=ER Mapper 6.4 hetotiff
   TIFFTAG_RESOLUTIONUNIT=2 (pixels/inch)
   TIFFTAG_SOFTWARE=IMAGINE TIFF Support
Copyright 1991 - 1999 by ERDAS, Inc. All Rights Reserved
@(#)$RCSfile: etif.c $ $Revision: 1.9.1.3 $ $Date: 2002/07/29 15:39:06EDT $
   TIFFTAG_XRESOLUTION=1
   TIFFTAG_YRESOLUTION=1
Image Structure Metadata:
   INTERLEAVE=PIXEL
Corner Coordinates:
Upper Left  (  -93872.189,-3625321.217)
Lower Left  (  -93872.189,-3631111.217)
Upper Right (  -88825.439,-3625321.217)
Lower Right (  -88825.439,-3631111.217)
Center      (  -91348.814,-3628216.217)
Band 1 Block=6729x1 Type=Byte, ColorInterp=Red
Band 2 Block=6729x1 Type=Byte, ColorInterp=Green
Band 3 Block=6729x1 Type=Byte, ColorInterp=Blue
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/africa/attachments/20160901/7469c488/attachment.html>


More information about the Africa mailing list