[gdal-dev] using gcp's without giving coordinates

erik whatevar89 at gmail.com
Thu Apr 2 13:19:35 EDT 2009


Thanks, Klokan. I'll check this out.

On Wed, Apr 1, 2009 at 2:52 PM, Klokan Petr Přidal <klokan at klokan.cz> wrote:

> Hi,
>
> I am not familiar with OziExplorer Map files, but I have seen a
> project trying to implement what you need, maybe you can reuse it (and
> probably improve it and add support of different projections):
>
>
> http://ozi2geotiff.svn.sourceforge.net/viewvc/ozi2geotiff/trunk/ozi2geotiff.py?view=markup
>
> I guess you would like to have affine transformation georeference from
> your GCPs points in your example with gdal_translate.
> Then you should either warp your raster with gdalwarp utility or use a
> tool like gcps2wld.py to calculate a best fitting World file and keep
> raster as it is.
>
> Klokan
>
> P.S.
> A standalone application for World file generation then you can use
> independently on GDAL is:
>
> http://blog.oldmapsonline.org/2008/06/georeferencing-images-by-control-points.html
> or very simple python script doing the calculation as well:
>
> http://code.google.com/p/oldmapsonline/source/browse/trunk/gcps2wld/python-no-dep/gcps2wld.py
>
> 2009/3/30 erik <whatevar89 at gmail.com>:
> > Hello,
> >
> > I'm trying to convert a map from OziExplorer Map file fromat to Geotiff.
> > FOr this i'm using the calibration points in the Map file as Ground
> Control
> > Points.
> >
> > I do the following:
> >
> > gdal_translate \
> > -gcp 203 52 529000 4191000 \
> > -gcp 5174 3096 544000 4182000 \
> > -gcp 5201 99 544000 4191000 \
> > -gcp 176 3051 529000 4182000 \
> > -gcp 1861 1067 534000 4188000 \
> > -gcp 3517 2081 539000 4185000 \
> > -gcp 3526 1083 539000 4188000 \
> > -gcp 1851 2066 534000 4185000 \
> > -gcp 2844 2742 537000 4183000 \
> > -a_srs "+proj=utm  +ellps=intl  +k=0.999600  +x_0=500000.0  +y_0=0.0
> > +zone=30  +units=m
> > +towgs84=-125.098545,-76.000054,-156.198703,0.0,0.0,-1.129,8.30463103
> > +no_defs" \
> > map.bmp \
> > map.tif
> >
> > However doing this still gives the maps upper left corner start at 0-0.
> > I was wondering if there was a way to make gdal infer the correct corners
> of
> > the map from the gcp's without specifying them directly.
> > Or is there another way to achieve this without specifying the coord
> > corners? (The calibration points are not corner-based)
> > One solution would be to calculate the corners myself programmatically
> (from
> > the pixels), but this would be the least good solution.
> >
> > Many thanks,
> > Erik
> >
> > _______________________________________________
> > gdal-dev mailing list
> > gdal-dev at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/gdal-dev
> >
>
>
>
> --
> http://blog.klokan.cz/
> http://www.maptiler.org/
> http://www.oldmapsonline.org/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20090402/bde3ab68/attachment.html


More information about the gdal-dev mailing list