1. GeoConnector 使用小结
GeoConnector 可用来完成空间地理数据
的转换与同步。
1.1. 1. 支持的数据
1.1.1. 1.1 支持的数据类型
当需要同步以下数据文件时,可采用 GeoConnector :
- ShapeFile (.shp, .shx, .dbf, .prj)
- PostGIS database - through a .geodb file
- WFS (Web Feature Service) - through a .geodb file
- ArcGIS FeatureService - through a .geodb file
- ESRI File Geodatabase
- Kml
- GeoJSON
- Oracle Spatial database - through a .geodb file
1.1.2. 1.2 转换保留的内容
- 三维几何数据
- 二维几何数据
- 元素属性
1.2. 2. 转换注意事项
1.2.1. 2.1 使用配置文件
在数据进行转换同步期间,可通过配置文件实现数据的重投影或可视化等操作。
示例配置文件(SampleConfig.cfg.xml)存放的位置为: C:\Users\%USERNAME%\AppData\Local\imodelbridges\GeoBridge\Assets\SampleConfig\GeoConfig\
示例配置文件内容
<?xml version="1.0" encoding="utf-8"?>
<GeoConfig xmlns:schemaLocation="GeoConfig.xsd">
<Version>1</Version>
<Appearance>
<Color>0036a3</Color>
<FillColor>84dee8</FillColor>
<Weight>2</Weight>
</Appearance>
<GCS>
<CoordinateSystemKeyName>EPSG:3857</CoordinateSystemKeyName>
</GCS>
<Features>
<Feature Name="feature name">
<Appearance>
<Color>0036a3</Color>
<FillColor>84dee8</FillColor>
<Weight>2</Weight>
</Appearance>
<GCS>
<CoordinateSystemKeyName>EPSG:27700</CoordinateSystemKeyName>
</GCS>
</Feature>
</Features>
</GeoConfig>
1.2.2. 2.2 地理坐标
- 通过 Spatial Connector 转换同步的数据单位推荐采用
米(m)
。即元素的坐标值的单位为米,而非经纬度。 文件的地理坐标系统(GCS)表达、表达应符合 Bentley 标准,可在 Bentley coordinate systems dictionary 进行查看。如 MicroStation 中可通过坐标关键字进行搜索,下图
Key Name
列是 Connector 可识别的地理坐标定义。
1.2.3. 2.3 元素符号化
Connector 对于空间地理数据的符号化表达可通过配置实现,即通过修改 SampleConfig.cfg.xml 完成符号化配置。
- 外轮廓颜色(Color Outline):十六进制 的 RGB 值
- 颜色(Color):十六进制 的 RGB 值,元素颜色
- 填充颜色(FillColor):十六进制 的 RGB 值
- 线宽(Weight):设定值 + 1 的屏幕像素值(如设置为 4,则屏幕显示 5 像素)
Connector 默认符号化配置:
Color Outline: 000000 (black)
Color: 008be1 (blue)
FillColor: 008be1 (blue)
Weight for point type: 2
Weight for line type: 1
默认配置效果图:
1.3. 3. 使用配置文件
1.3.1. 3.1 放置位置与名称
文件应放置在待同步数据的同级目录中,且与当前同步文件名称一致,如下图文件名为 Block.cfg.xml :
1.3.2. 3.2 配置项含义
1.3.3. 3.3 使用效果
更多内容请点击访问 Bentley Communities