ESRI Shapefiles (SHP)
ESRI Shapefiles (SHP)
Also known as ESRI ArcView Shapefiles or ESRI Shapefiles. ESRI is the company that introduced this format. ArcView was the first product to use shapefiles.
File listing
Shapefiles are made up of a minimum of three similarly named files, with different suffixes:
Countries_area.dbf
Countries_area.shp
Countries_area.shx
Data Access / Connection Method
Shapefile access is built directly into MapServer. It is also available through OGR, but direct access without OGR is recommended and discussed here. The path to the shapefile is required. No file extension should be specified. Shapefiles only hold one layer of data, therefore no distinction needs to be made.
OGRINFO Examples
- The directory can serve as a data source.
- Each shapefile in a directory serves as a layer.
- A shapefile can also be a data source. In this case the layer has the same prefix as the shapefile.
Using ogrinfo on a directory with multiple shapefiles:
> ogrinfo /data/shapefiles/
INFO: Open of `/data/shapefiles/'
using driver `ESRI Shapefile' successful.
1: wpg_h2o (Line String)
2: wpg_roads (Line String)
3: wpg_roads_dis (Line String)
4: wpgrestaurants (Point)
Using ogrinfo on a single shapefile:
> ogrinfo /data/shapefiles/Countries_area.shp
Had to open data source read-only.
INFO: Open of `Countries_area.shp'
using driver `ESRI Shapefile' successful.
1: Countries_area (Polygon)
Using ogrinfo to examine the structure of the file/layer:
> ogrinfo -summary /data/shapefiles/Countries_area.shp Countries_area
Had to open data source read-only.
INFO: Open of `Countries_area.shp'
using driver `ESRI Shapefile' successful. Layer name: Countries_area
Geometry: Polygon
Feature Count: 27458
Extent: (-180.000000, -90.000000) - (180.000000, 83.627419)
Layer SRS WKT:
(unknown)
FAC_ID: Integer (5.0)
TILE: Integer (3.0)
ARCLIST: String (254.0)
NAM: String (77.0)
PERIMETER: Real (22.17)
POLYGONCOU: Integer (6.0)
NA2DESC: String (45.0)
Map File Example:
LAYER
NAME my_shapefile
TYPE POLYGON
DATA countries_area
STATUS OFF
CLASS
NAME "Countries"
OUTLINECOLOR 0 0 0
END
END
ESRI Shapefiles (SHP)的更多相关文章
- (数据科学学习手札59)从抓取数据到生成shp文件并展示
一.简介 shp格式的文件是地理信息领域最常见的文件格式之一,很好的结合了矢量数据与对应的标量数据,而在Python中我们可以使用pyshp来完成创建shp文件的过程,本文将从如何从高德地图获取矢量信 ...
- GDAL 生成shp文件
附件:http://pan.baidu.com/s/1i3GPwrV(C#版GDAL接口.dll) 示例程序: http://pan.baidu.com/s/1jpIKQ (程序是在vs2008 x ...
- Web直接导入导出SHP/CAD实现探讨。
1.导入SHP/CAD文件 WEB具有直接美观展现功能,功能实现到可视化最好不要超过3S,那么就要限制导入文件的大小和优化算法了. 1.1.SHP导入实现思路 SHP格式开源,Git上随便可以找到读取 ...
- [GDAL]写入shp
C#通过Wkt码构建shp,记录写不进去! static void WriteVectorFile() { string strVectorFile = "E:\\"; // 注册 ...
- OSGEARTH三维地形开源项目
第一章 OSGEarth介绍 第二章 OSGEarth编译环境配置 OSGEarth的编译环境配置随着版本的不同.运行平台的不同,也有很大的差异.本章主要以Windows XP SP3(x86 ...
- GIS开源软件大全
3 - F 3map:行星地球项目由3map驱动,这是一个自由软件,由Telstra宽带基金会创建并支持,提供客户端与服务器的能力以在线再现虚拟地球. Amein!:其界面介于ArcMap和UMN M ...
- GIS软件列表
3map:行星地球项目由3map驱动,这是一个自由软件,由Telstra宽带基金会创建并支持,提供客户端与服务器的能力以在线再现虚拟地球. Amein!:其界面介于ArcMap和UMN Mapserv ...
- MapServer Tutorial——MapServer7.2.1教程学习——第一节用例实践:Example1.3 Displaying Classes in a Layer
MapServer Tutorial——MapServer7.2.1教程学习——第一节用例实践:Example1.3 Displaying Classes in a Layer 一.前言 关于第一节的 ...
- GeoServer基础教程(三):部署发布Shapefile地图数据
转载:http://blog.csdn.net/mingzai624. 这是GeoServer官方网站提供的一份Shapefile测试数据 nyc_roads.zip ,包含了部分纽约的道路信息,我们 ...
随机推荐
- TCP粘包和半包的处理方法
先把处理的方法的代码放这里: 解析数据帧的代码: bool CSocket::findData(byte* buff, int& len) { for (int i = 0; i <= ...
- KMP算法解析
介绍一种高效的KMP算法:代码可以直接运行 #include <iostream> #include <iomanip> using namespace std; void p ...
- javascript定义函数不同方式的区别
学习javascript中遇到了这么一个问题,代码如下: var test = 'a'; function test() { alert('Hello World!'); } alert(test); ...
- Python学习之路——字符处理(一)
一.整数: 例如:1.10.30 整数可以做以下操作: bit_length函数:返回该整数占用的最少位数: >>> x=100 >>> x.bit_length( ...
- 设计模式多线程方面之Thread-Per-Message 模式
Thread-Per-Message模式是一个很简单但很常应用的模式,尤其是在GUI程式中,我们举个例子,当您设计一个文件编辑器时,您可能像这样注册一个开启档案的事件处理: menuOpenFile ...
- linux中grep的用法
http://www.9usb.net/200902/linux-grep.html http://blog.51yip.com/linux/1008.html http://blog.csdn.ne ...
- Android最新源码4.3下载-教程 2013-11
Android最新源码4.3下载-教程 有的下载会出现问题: 需要 修改manifest.xml中的fetch: "git://Android.git.linaro.org/" ...
- MFC中SDI程序创建流程的回顾
SDI程序创建流程的回顾 从CWinApp.InitialInstance()开始, 1.首先应用程序对象创建文档模板; CSingleDocTemplate* pDocTemplate; pDocT ...
- jQuery报错:Uncaught ReferenceError: $ is not defined
在使用jQuery的时候,发现有如下报错: Uncaught ReferenceError: $ is not defined (anonymous function) 出现这个报错的原因: 1.j ...
- android在ubuntu中编译为.apk资料
android在ubuntu中编译为.apk文件 今天我在ubuntu环境之下将android程序编译为.apk文件,特将其过程写下来: 1. 在windows环境下使用MyEclipse编辑好and ...