<div>Hi Zoltan,</div>
<div> </div>
<div>using external script code snippets to create worldfiles is sure an option for this case, but I do not know how to use awk script, I hear it for the first time.</div>
<div> </div>
<div>I realize that all my GIFs may be merged into one large TIF image using gdal_merge.py command, but unfortunately I can not use it under MS4W 4.8.1, because this command only can be performed under Python support.</div>
<div> </div>
<div>I am now trying to do it in this way, but I am not sure if it works.</div>
<div> </div>
<div>thanks for your ideas</div>
<div> </div>
<div>zhonghai<br> </div>
<div><span class="gmail_quote">On 5/23/06, <b class="gmail_sendername">Siki Zoltan</b> <<a href="mailto:siki@agt.bme.hu">siki@agt.bme.hu</a>> wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Hi,<br><br>You must create world files from mapinfo tabs.<br>I could do it by an awk script, but my case was special.
<br>Nonearth coordinates and the four corners were given in the tab files and<br>no rotation.<br>^ y<br>|3 4<br>+----------+<br>| |<br>| |<br>+----------+ ------> x<br>1 2<br><br>tab file contains raster coordinates like (0,0) for point 3 and the world
<br>coordinates.<br><br>you can get the first row in the world file:<br>(x2 - x1) / (col2 - col1) called dx<br>The second and third rows are zeros if no rotation<br>fourth row<br>(y3 - y1) / (row3 - row1) called dy (it is always negative)
<br>the last two rows are the x,y coordinates of the center of the top-left<br>pixel<br>x3 + dx / 2<br>y3 + dy / 2<br><br>I hope this helps you<br><br>Zoltan<br><br>On Tue, 23 May 2006, Zhonghai Wang wrote:<br><br>> Hi guys,
<br><br>any further ideas for this topic?<br><br>l am really overwhelmed by it.<br><br>since I have a amount of small GIF+TAB files, if I really need to create<br>worldfiles for all the GIFs, it will be a huge project and seems not be
<br>possible.<br><br>thanks a lot for any idea I can try.<br><br>zhonghai<br><br>On 5/22/06, Zhonghai Wang <<a href="mailto:zhonghaiw@gmail.com">zhonghaiw@gmail.com</a>> wrote:<br>><br>> Hi,<br>><br>> I've checked using "mapserv -v" and the GIF is supported.
<br>><br>> but it's strange that I can not performed "gdalinfo --formats" or<br>> "gdal-congif --formats" to check if the GIF format is supported. I am using<br>> the precomplied MS4W on WinXP. Does this mean that my gdal utility is not
<br>> really working? but I still can use some commands such as "gdalinfo" and<br>> "gdal_translate".<br>><br>> zhongahi<br>><br>> On 5/22/06, Zhonghai Wang <<a href="mailto:zhonghaiw@gmail.com">
zhonghaiw@gmail.com</a>> wrote:<br>> ><br>> > Hi guys,<br>> ><br>> > I get some info again from the "Raster Dat Access" document, and it<br>> > indicates that:<br>> ><br>> > ****
<br>> > GIF: If GD is configured with GIF (OUTPUT=GIF) support, then MapServer<br>> > will also be able to read GIF files for raster layers. The only way to<br>> > georeference GIF files is with a world file.
<br>> ><br>> > If GD is not configured with GIF support, it may still be available in<br>> > GDAL<br>> ><br>> > ****<br>> ><br>> > Is it true that GIF raster images can only be georeferenced with a
<br>> > worldfiles? TAB files are not supported?<br>> ><br>> > zhonghai<br>> > On 5/22/06, Zhonghai Wang <<a href="mailto:zhonghaiw@gmail.com">zhonghaiw@gmail.com</a> > wrote:<br>> > >
<br>> > > Hi guys,<br>> > ><br>> > > I've found a way to do that, like this:<br>> > ><br>> > > c:\.....rasterdata>dir /b /s tem\*.gif > index.txt<br>> > > c:\.....rasterdata>gdaltindex
index.shp --optfile index.txt<br>> > ><br>> > > and this works well.<br>> > ><br>> > > but georeferencing information in the TAB file can not be found by the<br>> > > command, an error message is something like:
<br>> > ><br>> > > >>>no georeferencing info is available, gdaltindex performance will be<br>> > > skipped.<br>> > ><br>> > > actually there is georeferencing info in the TAB file, for each small
<br>> > > gif image there is a corresponding TAB, e.g.:<br>> > > ***<br>> > > !table<br>> > > !version 300<br>> > > !charset WindowsLatin1<br>> > ><br>> > > Definition Table
<br>> > > File "m_1_1_1000.gif"<br>> > > Type "RASTER"<br>> > > (5.290517,48.2308475) (1392,987) Label "Pt 1",<br>> > > (5.25001439194036,48.25) (0,0) Label "Pt 2",
<br>> > > (5.25001439194036 ,48.211695) (0,1974) Label "Pt 3",<br>> > > (5.33101960805964,48.25) (2784,0) Label "Pt 4",<br>> > > (5.33101960805964,48.211695) (2784,1974) Label "Pt 5"
<br>> > > CoordSys Earth Projection 1, 104<br>> > > Units "degree"<br>> > > ***<br>> > ><br>> > > why can it not be read by gdal?<br>> > ><br>> > > thanks a lot
<br>> > > zhonghai<br>> > ><br>> > > On 5/22/06, Mateusz Loskot <<a href="mailto:mateusz@loskot.net">mateusz@loskot.net</a> > wrote:<br>> > ><br>> > > > Rahkonen Jukka wrote:
<br>> > > > > Very first you can try giving the full path to your images, I mean<br>> > > > > c:\...\rasterdata\tem\*.gif. Let's see what happens.<br>> > > ><br>> > > > It should not be the case.
<br>> > > > I've checked gdaltindex from latest FWTools on Windows and<br>> > > > it works with relative and absolute paths.<br>> > > > Also, you can use forward or back slash:<br>> > > >
<br>> > > > gdaltindex test.shp data/*.tif<br>> > > ><br>> > > > gdaltindex test.shp data\*.tif<br>> > > ><br>> > > > Although, gdaltindex usage message suggests to use the former
<br>> > > > version<br>> > > > with Unix-like forward slash.<br>> > > ><br>> > > > Cheers<br>> > > > --<br>> > > > Mateusz Łoskot<br>> > > >
<a href="http://mateusz.loskot.net">http://mateusz.loskot.net</a><br>> > > ><br>> > ><br>> > ><br>> ><br>><br><br></blockquote></div><br>