开发者

Creating custom Google (or OpenLayers?) maps

开发者 https://www.devze.com 2022-12-08 10:18 出处:网络
I\'m currently wo开发者_运维知识库rking on a project which maps items to a physical location within a building. We have a map created in our GIS system (ArcGIS), and are able to resolve items to the a

I'm currently wo开发者_运维知识库rking on a project which maps items to a physical location within a building. We have a map created in our GIS system (ArcGIS), and are able to resolve items to the appropriate shape ID on this map.

We want to create a web map using one of the APIs such as Google maps or Open Layers in order to display this info, directing the user to the correct location on the map, and ideally highlighting the particular location (for example using a shaded polygon), or at least identifying it with some sort of marker.

However we're very new to all of the online mapping APIs, and are finding it pretty overwhelming at the moment. All we really want is a flat map with our own custom imagery - we dont really care about geo-referencing, or projections etc.

Does anyone have any tips or info about how we might go about this? Even just general pointers would be helpful - it's hard to know where to look when there's so much info out there!

Cheers


If you are using ArcGIS Server, use ArcCatalog to expose your data as a WMS.

If you do not have an ArcGIS Server license, you can use MapServer or GeoServer to do the same (i.e expose as a WMS).

OpenLayers has support for adding WMS layers. See their examples section for sample code.

Cheers


OpenLayers can handle your own custom imagery maps without any problems.

You can check out this example:

http://openlayers.org/dev/examples/image-layer.html

And of course you need to read the API documentation


If you are using ArcGIS to creat eyour map, then use ArcGIS Server to serve up the maps online. Then use ArcGIS JavaScript API to build your web application. There are several out-of-the-box templates as well as easy-to-use examples for performing basic actions such as pan, zoom, select, highlight, redlining, etc.

Create your map service, then add your custom Map as a Dynamic Map Service or a Tiled Map Service (if you've cached it). Perform a Find (or Query if you have more than one feature you want to highlight). Add the Graphic from the FindResult to your GraphicsLayer.

Here's a more complete example.


You could also look at MapGuide OS and (if you don't have studio) Maestro. It is a server side application that will take in SHP files from Arc easily. The only downside IMO is that the built in search and reporting functionality is rather limited but can be extended via the API (C#, PHP and Java) that and it is rather centralized with a persistent process on the server (which can make debugging exceedingly fun).

The fusion/flexible (or whatever they heck they call it) layouts are based on the OpenLayers API but is still relatively new. And you can publish as a WMS or WFS I believe (I haven't done it personally).


If using ArcGIS Server, you can also expose your imagery and feature layers via a REST endpoint that can be consumed by OpenLayers. Check out James Fee's blog post on the topic.

0

精彩评论

暂无评论...
验证码 换一张
取 消