Lurker Posted July 28, 2010 Report Share Posted July 28, 2010 A Shapefile is a commonly used binary format that stores geometric data such as lines, points and polygons along with attribute information that describes what that geometric data represents. Despite the term “shapefile,” a shapefile is actually a set of several files, three of which are mandatory to store the data comprising a “shapefile”. The first of these files is the .shp file, which stores the actual geometric data. Another file, the .shx file, is an index file that allows seeking forwards and backwards very quickly. The last mandatory file in a “shapefile” is the .dbf file, which stores the attribute information for the geometric data. Tom Carden has written a shapefile renderer in JavaScript using the HTML5 Canvas element. It loads the binary data using an AJAX request, parses it, and renders it in the canvas element. And it does it pretty quickly as well, as you can see in this demo, which renders an interactive map similar to Google Maps. You can drag the map around, and zoom using your scroll wheel. Since the files are binary, they are fairly small. An equivalent file in a text format such as SVG would probably be much larger. see the demo here : [hide] http://s3.amazonaws.com/shapefile-js/simple.html [/hide] you can download the script for free here : [hide] http://github.com/RandomEtc/shapefile-js [/hide] Quote Link to comment Share on other sites More sharing options...
un_sorry Posted September 3, 2010 Report Share Posted September 3, 2010 :blank: Quote Link to comment Share on other sites More sharing options...
pdogz Posted September 24, 2010 Report Share Posted September 24, 2010 :cool: :cool: Thanks Quote Link to comment Share on other sites More sharing options...
intertronic Posted October 8, 2010 Report Share Posted October 8, 2010 :shocked: Quote Link to comment Share on other sites More sharing options...
hal1999it Posted October 31, 2010 Report Share Posted October 31, 2010 ok :smiley: Quote Link to comment Share on other sites More sharing options...
wankbass Posted January 17, 2012 Report Share Posted January 17, 2012 :sad: Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.