Visualizing and Editing GIS data with SVG for Internet and Mobile Users

Keywords: SVG, GML, GIS, Web Mapping

Ida K.L. Cheung
Research Student
Department of Land Surveying and Geo-Informatics, The Hong Kong Polytechnic University
Hung Hom, Kowloon,
Hong Kong
China
ida.cheung@polyu.edu.hk

Biography

Ida Cheung graduated from the Department of Land Surveying and Geo-informatics of the Hong Kong Polytechnic University in 2000. She has been worked in GIS field for 3 years. Currently she is a MPhil. student in the Department of Land Surveying and Geo-informatics.

Geoffrey Y.K. Shea
Senior Lecturer
Department of Land Surveying and Geo-Informatics, The Hong Kong Polytechnic University
Hung Hom, Kowloon,
Hong Kong
China
geoffrey.shea@polyu.edu.hk
http://www.lsgi.polyu.edu.hk/staff/Geoffrey.Shea/index-IE.htm

Biography

Geoffrey Shea graduated from the Department of Civil Engineering in the National Cheng Kung University, Taiwan. He joined the Hong Kong Polytechnic in 1988, and is now a Senior Lecturer in the Department of Land Surveying and Geo-Informatics. Internet computing especially on Web Mapping and spatial database handling are the main research interests of Geoffrey. He is currently pursing a part-time Ph.D. study on adaptive mobile GIS.


Abstract


The main objective of this research is to develop efficient algorithms of editing geographic data online and in mobile devices. We are using a new GIS standard, GML incoperated with SVG. As GML is not for data display, SVG is an ideal vector graphic for displaying geographic data. GML sets at the backend to store and transport data and on the other side SVG sets on front end to render and display geographic data. They not only can visualize geographic data on the web, but also give the possibility to edit geographic data online. The research explores whether using GML and SVG is a good method to intergrate web-based mapping information in terms of data modelling, spatial data presentation represertation mechanism and spatial data editing capability. Especially in Internet and wireless environment, whether using SVG gives a significant improvement of bandwidth, speed, access and reliability.

In order to test the capability of displaying and editing geographic data, a prototype is built. It aims to investigate the capability of GML and SVG and develop a corresponding data modeling and system in order to overcome or improve the existing limitation on online graphic presentation and data editing functions. It focuses on online map editing function which is still not well developed function over existing web mapping system and examines specific problems and approaches in using SVG as a user interface for editing geographic data online.


Table of Contents


1. Introduction
2. GIS Data Visualization in SVG
3. GIS data in GML
4. Methodology for implementation
     4.1 Development of data model and design algorithms
     4.2 GML data Generation
     4.3 Application Schema Generation
     4.4 XSL stylesheet Generation
     4.5 Design algorithms for editing function
     4.6 Development and evaluation of a prototype
5. Conclusions
Acknowledgements
Bibliography

1. Introduction

The widespread availability of World Wide Web gives the opportunities for delivering maps over the Internet as well as small mobile devices. The sharing of spatial data through Internet is important to promote interoperability of spatial data. Interoperability implies that there is some common concept on which information exchange and integration is based. [Vckovski 1999]

There were over 30 different Web mapping software packages or solutions provided by different GIS vendors. Most popular Web Mapping packages are ESRI ArcIMS, Autodesk MapGuide, GeoMedia WebMap server, and MapInfo MapXtreme [Peng 2003] .They all have their own proprietary data formats and different customized programming languages. Some of them render images such as GIF and JPEG but these raster data cannot be selected, changed styling or zoomed in for more detail. In term of vector data, different data formats restrict the integration of data for applications and analyses. Moreover, different data formats support different spatial models. For instance, a particular GIS format support complex spatial model whereas another merely support simple feature model. It is difficult to share data between disparate Internet systems over a wide area network.

In application level, the proprietary Web mapping applications are limited to their own corporate networks and developing languages. The vendor-based on-line spatial services and clients means that systems are neither interoperating with systems on the data level, nor the application level.

In functional level, most Web mapping software packages can perform simple GIS functions such as zooming, querying, selecting, buffering and styling. They seldom perform more advanced GIS functions such as spatial analysis and spatial editing. In existing market, two Web mapping software packages, ArcIMS and Autodesk MapGuide, offer GIS functions which are closed to editing capability on spatial data. The ArcIMS Java Viewer using feature services has two functions called MapNotes and EditNotes. The MapNotes function enables users to add text or graphics to the map. These edits are then sent to the MapNotes folder on the ArcIMS Server. The EditNotes function enables users to edit features on the displayed map. Similar to MapNotes, once users finish editing, the changes will be submitted to the EditNotes folder on the ArcIMS Server for the server administrator to review. EditNotes must be converted to shapefiles or XML. MapNotes and EditNotes are therefore just graphics on map but not edited features on the server [Alex 2002] .

For Autodesk MapGuide, functions are extended to include edit capability by the SDF COM Toolkit to enable users to create, edit, or delete actual SDF files. From the client end, the use of a MapGuide server requires downloading and installing a proprietary plug-in. Data are in proprietary format not readily accessible to or useable by other applications.

In short, over the Internet, it is essential to have a method of storing and representing data in an open, extendable and flexible way, but also in a way that is vendor-independent. Therefore Geography Markup Language (GML) was designed to help solve above problems and promote interoperability of spatial data. GML is an XML grammar written in XML Schema for the modelling, transport, and storage of geographic information including both spatial and non-spatial properties of geographic features [OGC 2003] . It is developed by Open GIS Consortium. On the other side, the Scalable Vector Graphics (SVG) is an emerging two-dimensional vector graphics standard, which is developed by W3C organization. GML is used as the standard of data exchange and then can be transformed into SVG for graphic visualization so that downloads can be considerably shortened and even more important for bandwidth is the scalability inherent to vector lines. Once on the client browser, vectors are scalable without return trips to the server [Randy 2002] . The performance hence can be improved. It is essential for Web mapping which requires fast delivery time and high performance. It seems that GML and SVG are ideal for transporting and storing geographic information over Internet using advanced XML technology and provide potential capability to integrate different geographic information together.

The aim of this paper is to investigate and develop methods for generalizing map online and editing vector-formatted geospatial data to Internet and mobile user using emerging standards – GML and SVG. The main purposes are:

2. GIS Data Visualization in SVG

SVG is an ideal candidate for displaying GIS information in a Web browser. All typical GIS features can be readily displayed and manipulated, and data are transferred in a compact vector format rather than raster format. SVG knows shape types for 2D graphics including rectangles, circles, ellipses, lines, polylines, polygons, symbols and path elements. These graphical objects can be grouped, styled and transformed using stylesheets such as XSLT and CSS. SVG is already supported by several browsers, but it still requires a plug-in for current versions of Microsoft Internet Explorer and Netscape. Adobe offers a free SVG plug-in called Adobe SVG viewer 3.0.

SVG drawings can be dynamic and interactive. The Document Object Model (DOM) for SVG, which includes the full XML DOM, allows for straightforward and efficient vector graphics animation via scripting. This makes SVG useful for dynamic websites with graphical content, especially for web mapping which has rich content on graphical representation. Data can be selected, queried and processed according to the clients’ settings on the server side. On the other hand, clients can create, delete and update the elements graphically as well as manipulate their attributes.

3. GIS data in GML

GML is an XML based encoding standard for geographic information developed by the OpenGIS Consortium (OGC). GML 1.0 was released as a Recommendation Paper in February, 2001 and GML 2.0 was approved in April 2000 as an OpenGIS Implementation Specification. GML 2.0 provides for XML Schema, complex features and feature relations, extending GML’s scope beyond the basic 2-dimensional vector-based descriptions in Simple Features. Currently, the latest version of GML is GML 3.0 which has been approved in January 2003. New additions in GML 3.0 support complex geometries, spatial and temporal reference systems, topology, units of measure, metadata, gridded data, and default styles for feature and coverage visualization [OGC 2003] . GML is intended to enable the transport and storage of geographical information in XML, to provide greater interoperability between GIS applications, and to enable linked geographical datasets. Figure 1 shows that relationship between GML and SVG.

gmlsvg.jpg

Figure 1: Relationship between GML and SVG

4. Methodology for implementation

In order to test the editing capability of GML and SVG, we propose a framework. The major target of the framework is to design algorithms, mechanism and workflow of distributing geographic information online with more advanced editing functions. It focuses on examine specific problems and approaches in using SVG as a user interface for editing geographic data online.

4.1 Development of data model and design algorithms

GML has ability to provide a framework for modelling application relationships. This allows application to be designed independently yet still able to interoperate when using the same base object model [Toon 2001] . Application framework can depend upon one or more GML schemas by importing them shown in Figure 2 . For example, schema 1 in the application framework imports the GML feature schema. Since this research focuses on mobile application, mobile GIS data model is used. Based on existing GIS data model, further enhancements are performed for the model, for example, modelling the spatial relationship and spatial entities according to the topographic features in Hong Kong digital map data. Besides, the presented rules of mapping can be generalized easily to translate oriented objects models, in UML or another formalism, for files in XML Schema [Miguel 2002] . The relationships between features and attributes in an application are modelled by UML.

For graphic presentation, Scalable Vector Graphics (SVG) is applied. SVG is an XML grammar for describing 2D graphics. GML is used as a spatial data interchange format, and SVG provides a format for viewing spatial data. As Figure 2 shows that style engine is used to transform GML data into SVG graphics. The figure summarizes the work flow of data structure and transformation.

model.jpg

Figure 2: Overview of making vector maps on Web with GML

4.2 GML data Generation

To test the model, Hong Kong digital base map was collected from Land Information Centre (LIC) of Survey and Mapping Office, Lands Department for the framework. Scale 1:1000 digital topographic map (B1000) are used. Since the native format of the digital base map is in ArcInfo coverage format, data conversion from coverage format to GML data is required. The procedure of generating GML data is shown in Figure 3 .

conversion.jpg

Figure 3: Overview of making vector maps on Web with GML

The e00 files are the export format of ArcInfo coverage. They are first decompressed to ArcInfo coverage and then converted to shapefiles format. The reason of converting shapefiles is that many free tools are available to convert shapefiles to GML such as deegree command line shape to GML converter 1.5 (http://deegree.sourceforge.net/) By using free converter, shapefiles format data can be converted to GML data.

4.3 Application Schema Generation

Since Hong Kong base map has own specification of data content, an application schema specified for Hong Kong base map data is needed to validate the GML documents. Referring to the data dictionary of Hong Kong digital base map, an application schema declares actual feature types and property types. It defines data types of textual data. For example, it defines whether id should be in numeric and name should be string. It is further developed to include schemas for different features such as building, road and contour etc.

4.4 XSL stylesheet Generation

In order to visualize GML data, stylesheets are required. As mentioned in previous section, stylesheets are used to convert and format GML into SVG and different style and symbols can be applied. For example, a set of recommended styles and symbols for the portrayal of OS MasterMap data are specified. Since the Hong Kong digital map has own style and symbols in representing geographic features, a XSL stylesheet is need to be specially designed.

4.5 Design algorithms for editing function

SVG offers more than vector display. SVG document can be added, moved, modified, copied and deleted using client triggered graphical user interface (GUI) events [Randy 2002] . By developing some common scripting language like Javascript, the program can track the mouse and transform the user coordinate on client machine to the user-defined coordinate system. This makes onscreen digitizing online possible and then allows adding and updating data. The functions include move, add and delete feature and vertex and modify textual information. In order to design and implement on-line editing capability using GML and SVG, a system is set up.

The basic algorithms and workflow of enabling data editing is shown in Figure 4 . On the server side, the system takes care of storing GIS data and also translates GML documents into SVG on the fly by using stylesheets. And then the SVG files can be rendered and showed on web browser such as Internet Explorer. By using Javascript and DOM supporting plug-in, SVG can be modified graphically with attributes and the changes are transferred back to the server, which apples the modifications to the original GML file.

editflow.jpg

Figure 4: The basic workflow of data editing using GML and SVG

4.6 Development and evaluation of a prototype

After all, a prototype is developed for testing the proposed data model and algorithms and applied for real application. The implementation applies Java script and SVG DOM to make XML application and Web service. Since applications on Window CE platform become popular and increasingly gain market share [Legard 2002] , Window CE platform is chosen for evaluation. There are several components in the system including Web and data server, networking devices and mobile devices such as tablet and pocket PC.

In order to produce the application which can be applied in Hong Kong, Hong Kong base map data and networking data are used and stored in database. The following Figure 5 is the overview of the proposed system.

system.jpg

Figure 5: The overview of the proposed system for the prototype.

The prototype is used to demonstrate and test the effectiveness of the proposed data model and algorithms using existing GIS data. The data are stored in database and served through Internet or wireless terminals. As both SVG and GML are XML-based, and conversion from one to the other is simple, GML could be used to handle GIS data and SVG to view and deliver it to mobile users, making one the perfect complement to the other.

Several functions including map rendering, spatial query, and map editing are performed. GML and SVG are served as vector format across the Internet. Data are transferred as vector on the client browser. The browsers allow users to control their view with zoom and pan the same way they do so in GIS software. For example, when the user wants to zoom or pan to a different area of the map, that request is then sent back to the GML data store, where the Web feature server extracts new GML features and send them the style engine for styling. The styled SVG sends to the Web for display again. SVG links can also trigger server events to query database.

For implementation, many free tools are available now. One of advanced tools for distributing GML and SVG data is the GeoServer project which is the open Internet gateway for geographic data (http://geoserver.sourceforge.net). GeoClient, which is a part of the GeoServer project, is graphical software for online mapping. GeoClient is designed to work as a client to a server operating on the Open GIS Consortium's Web Feature Server standard. It is written in Scalable Vector Graphics (SVG) and ECMAscript/JavaScript. Some basic functions of map interface are available such as zooming, panning, querying and identifying attributes. The prototype is based on the tool of GeoServer and GeoClient to be further developed and customized. Figure 6 shows the SVG Web map using Hong Kong base map data.

interface.jpg

Figure 6: The interface of SVG Web map using Hong Kong base map data.

The possibility of editing data through Internet is tested. For example, people can digitize the route of their truck by mobile devices. With this function, people can edit and get real time information anytime, anywhere.

5. Conclusions

The paper describes an ongoing project and addresses the new idea of deploying GIS data by SVG through Internet with open and standard application and design algorithms for online data editing capability. The framework is based on open and non-proprietary standard, which provide ideas of distributing GIS data and application in Hong Kong by using open and standard way.

We have proposed a framework for integrating distributed Web-based GISs by using GML and SVG technologies. The study of generating GML, GML schema, XSL stylesheets and SVG, the methodology of the framework has been examined and developed.

Acknowledgements

This study was supported by the funds from The Hong Kong Polytechnic University.

Bibliography

[Alex 2002]
Alex, F., 2002. Technical Comparison: Autodesk MapGuide 6 and ESRI’s ArcIMS 4, http://usa.autodesk.com/
[Lake 2000]
Lake, R., 2000. Making Maps for the Web with Geography Markup Language (GML). http://spatialnews.geocomm.com/whitepapers/gml.html
[Legard 2002]
Legard, D., 2002. Pocket PCs Gain Ground in PDA Market. http://www.pcworld.com/news/article/0,aid,106463,00.asp
[Miguel 2002]
Miguel, R.F. and Cirano, I., 2002. Mapping of Conceptual Object Oriented Models to Geography Markup Language (GML).Universidade Federal do Rio Grande do Sul, www.ulbra.tche.br/ugc-comp/pdf/at-2002-iadis-fornari_iochpe.pdf
[OGC 2001]
OGC, 2001. OpenGIS® Geography Markup Language (GML 2.0) Implementation Specification., Open GIS Consortium http://www.opengis.org/, Open GIS Consortium
[OGC 2003]
OGC, 2003. OpenGIS® Geography Markup Language (GML 3.0) Implementation Specification., Open GIS Consortium http://www.opengis.org/, Open GIS Consortium
[Peng 1999]
Peng, Z. R., 1999. An Assessment Framework of the Development Strategies of Internet GIS. ,Environment and Planning B: Planning and Design, 26(1), pp 117-132.
[Peng 2003]
Peng, Z. R. and Tsou, M. H., 2003. Geography Markup Language. ,Internet GIS, John Wiley and Sons, Inc.,Canada.
[Plewe 1994]
Plewe, B., 1994. GIS Online: Information Retrieval, Mapping, and the Internet. ,Santa Fe, New Mexico: OnWord Press.
[Randy 2002]
Randy, G., 2002. Maximize Online Mapping with SVG/XML. ,GIS World, Dec 2002
[Seff 2002]
Seff, G., 2002. SVG and GIS., Direction Magazine http://www.directionsmag.com/article.php?article_id=198
[Shan 1998]
Shan, Y.-P., and Earle, R.H., 1998. Enterprise Computing with Objects: From Client/Serve Environments to the Internet.,Reading, Addison-Wesley, Massachusetts.
[Toon 2001]
Toon, M., 2001. What the hell is GML?, ESRIUK http://www.esriuk.com/OurCompany/pdf/Toon_GML.pdf
[Vckovski 1999]
Vckovski, A., 1999. Interoperability and Spatial Information Theory.Interoperating Geographic Information Systems, pp.31-37

XHTML rendition created by gcapaper Web Publisher v2.0, © 2001-3 Schema Software Inc.