<div dir="ltr"><div><br></div>Hi Simen,<div><br></div><div>Ok, here is how to implement the suggestion I gave, which was to create a new worldfile and shift the image so that it fit the footprint vector better.  </div><div><br></div><div>1. Use gdal_edit.py with the "-unsetgt" option to remove the georeferencing from the .tif</div><div>2. Then copy the attached .tfw file into the same dir as the .tif and view it in relation to the KML footprint.</div><div>3.  You can tweak the alignment further by modifiying the bottom 2 coordinate values in the .tfw file.</div><div><br></div><div>Why do I advocate this method over warping the image using GCP's or QGis?  Because those are "lossy" processes.  In other words, the warping will force a re-write of the pixel values using some sort of interpolation.  You might still want to do that at the very end, like if you need  perfect point-to-point matching against the footprint corners, but I still would shift the image first.</div><div><br></div><div>Hope this helps,</div><div><br></div><div>Roger</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 19, 2014 at 1:16 AM, Simen Langseth <span dir="ltr"><<a href="mailto:simlangen@gmail.com" target="_blank">simlangen@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"> I wanted to georeference the raster image in UTM coordinates into the boundry of red polygon with geographic coordinate system.<br><br><a href="https://drive.google.com/file/d/0B2RqG9tSAAIUc3J5ZDN6V01IcG8/view?usp=sharing" target="_blank">https://drive.google.com/file/d/0B2RqG9tSAAIUc3J5ZDN6V01IcG8/view?usp=sharing</a><br><br>I tried as follows:<br><br>gdalwarp,-t_srs wgs84 -srcnodata 0 -dstnodata 0 -r near -te -96.75234 54.93479 -92.90071 56.91041 i<div><br></div><div><span style="color:rgb(51,51,51);font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:14px;line-height:18px;background-color:rgba(248,248,248,0.6)">What parameters should I provide for that?</span><br></div></div>
<br>_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br></blockquote></div><br></div></div>