[gdal-dev] Re: [Fwd: Re: Warping an already georeferenced image with control points
Even Rouault
even.rouault at mines-paris.org
Wed Feb 11 17:15:57 EST 2009
Jan,
I concur with Jukka's analysis. Your need is rather uncommon, and I also
thinks it shouldn't be a default behaviour. However, adding that capability
to gdal_translate is quite easy. I've attached a patch for gdal_translate.cpp
that adds the capability of adding the 4 corners as 4 additional GCPs with
the "-add_corners_as_gcps" option. You might give it at try (it applies
cleanly on GDAL 1.6.0 and trunk). I'm not sure yet if it is valuable enough
to include it in baseline gdal_translate.cpp.
Best regards
Le Wednesday 11 February 2009 15:59:48 Jukka Rahkonen, vous avez écrit :
> Jan Hartmann <j.l.h.hartmann <at> uva.nl> writes:
> > Sorry to keep moaning about this, but I need an indication what's going
> > on here. Mind, I don't need an immediate solution: for the time being I
> > have a workaround. Just an idea whether this a real problem, a dumb
> > question, something that can be handled in the foreseeable future (or
> > not), perhaps with adequate funding. Everything is better than talking
> > to a blind wall.
> >
> > Sorry again Frank,
> >
> > Jan
>
> Hi,
>
> I think that your need to keep the original extents but add more ground
> control points inside the image frame is rather uncommon. Doesn't it mean
> that you trust that the image corners are correctly warped to a new
> projection, but there are local distortions in the middle of image which
> should be corrected with a few extra ground control points? For my mind it
> shoudn't be the default behaviour of gdal but it might be usable as an user
> selectable option sometimes.
>
> I know that missing gcp's at the image corners often leads to very odd
> result with polynomial warping because the formula shoots over. Even
> unaccurately placed gcp's could help a lot in preserving the original shape
> of the map. I guess that you are perhaps playing with scanned historical
> maps? I have a few old scanned parcel maps which are covering just the
> area of the farm, and two of the map corners are just white background. It
> is impossible to measure any real ground control points from the corners
> because there is nothing on the map to compare with, and warping with all
> gcp's on the middle area makes really funny looking curves into the hand
> drawn rectangle framing the original map.
>
> -Jukka-
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gdal_translate_add_corners_as_gcps.patch
Type: text/x-diff
Size: 4249 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/gdal-dev/attachments/20090211/cdf3c435/gdal_translate_add_corners_as_gcps.bin
More information about the gdal-dev
mailing list