<DIV>Hi Kent,</DIV>
<DIV> </DIV>
<DIV>The Shapefile technical definition can also be found here:</DIV>
<DIV> </DIV>
<DIV><A href="http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf">http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf</A><BR></DIV>
<DIV>and </DIV>
<DIV> </DIV>
<DIV><A href="http://facweb.knowlton.ohio-state.edu/selhami/crpinfo/teaching/CRP608/Shape%20file%20structure.doc">http://facweb.knowlton.ohio-state.edu/selhami/crpinfo/teaching/CRP608/Shape%20file%20structure.doc</A></DIV>
<DIV> </DIV>
<DIV>Note that the .prj is optional and was a late addition to the Shapefile definition (not sure myself when it came along, but it was not present in the Original White paper).</DIV>
<DIV> </DIV>
<DIV>Cheers,</DIV>
<DIV>Dean</DIV>
<DIV><BR>----- Original Message -----<BR>From: Kent Eschenberg <eschenbe@psc.edu><BR>Date: Tuesday, October 9, 2007 11:08 am<BR>Subject: Re: [Gdal-dev] Shapfiles and Projections<BR>To: gdal-dev@lists.maptools.org<BR><BR>> Thank you all for your assistance. The gdal/ogr library can read <BR>> the shapefile <BR>> if the directory also contains the dbf and shx files that came <BR>> along with the <BR>> shp file. Specific responses below.<BR>> <BR>> -----Original Message-----<BR>> > gdrinfo doesn't seem to find a projection in a shapefile <BR>> describiing roads<BR>> > (from the National Atlas). I was expecting something <BR>> like what gdalinfo<BR>> > finds in a geotiff file. Could someone point me towards <BR>> the answer?<BR>> <BR>> Martin Chapman wrote:<BR>> > Make sure there is a .prj file with the same name as the <BR>> .shp file. NTAD<BR>> > data doesn't always come with these projection <BR>> files. If you read the .txt<BR>> > file with the shape file it will tell you what datum it <BR>> is using. Attached<BR>> > is a wgs84 prj file that should work if you rename it to <BR>> be the same as your<BR>> > .shp file. NTAD is generally in WGS84.<BR>> <BR>> Hmmm ... I didn't do that; there is no prj file but it now seems <BR>> to work.<BR>> <BR>> Ed McNierney wrote:<BR>> > Unfortunately, the concept of projections and coordinate <BR>> systems in general<BR>> > was late in coming to the shapefile format, and many (if <BR>> not most)<BR>> > shapefiles have no projection/coordinate information <BR>> with them.<BR>> ><BR>> > Your shapefile should have a .txt file with it <BR>> (presumably roadtrl20.txt<BR>> > if you're using the roads layer from the National Atlas) <BR>> and it will<BR>> > contain this information:<BR>> <clip><BR>> <BR>> Yes, a txt file was supplied and it has information similar to <BR>> your example. <BR>> However it doesn't seem to be used. I'm still developing my <BR>> application and so <BR>> I'll find out soon enough if it is needed by hiding or not <BR>> hiding the txt file.<BR>> <BR>> Frank Warmerdam wrote:<BR>> > I assume you were using ogrinfo?<BR>> ><BR>> > It will report coordinate system info if it finds <BR>> it. Does your shapefile<BR>> > dataset include a .prj file? If not, there <BR>> is not declared coordinate<BR>> > system for the file.<BR>> <BR>> Yes, my mistake, I am using ogrinfo. No prj file was supplied <BR>> but it seems that <BR>> information was provided in the txt file.<BR>> <BR>> Kent<BR>> Pittsburgh Supercomputing Center<BR>> _______________________________________________<BR>> Gdal-dev mailing list<BR>> Gdal-dev@lists.maptools.org<BR>> http://lists.maptools.org/mailman/listinfo/gdal-dev<BR>> </DIV><BR><BR>Dean C. Mikkelsen, B.Sc., P.Eng.
<br>Terra ETL Ltd.
<br>Victoria, B.C., Canada
<br>Phone: +1 (250) 361-6672
<br>http://www.terraetl.com
<br>
<br>Consulting in Geodesy & GIS for the Natural Resources</BR></BR>