Overview  |  API  |  Data Structures  |  Parameters  |  Example Map

TerraServer-USA .NET Web Service 2.0

Version 2.0 of the TerraService is now available! Version 2.0 supports the Urban Area data theme. Click on Version 2.0 changes to learn the specific changes required in your application to use Version 2.0.

Overview

It is too hard to say, type and probably read "TerraServer-USA .NET Web Service" all the time. To simplify all our lives, we refer to the TerraServer-USA .NET Web Service as "the TerraService". When you see the term TerraService in this document, you know we are talking about the interface to TerraServer-USA using .NET technologies. It also implies that you, a developer attempting to access TerraServer programatically, is also using Microsoft .NET technologies. If you are unfamiliar with .NET technologies, you can read all about them at http://microsoft.com/net/ . We are not going to attempt to describe what .NET is all about here. We are assuming you already have a clue about .NET are just trying to understand how call the TerraService from your application program, be it a WebForm or a WinForm. We are also going to assume that you are developing your application program in C#. You can also develop your program in VB7 or VC7. But all our examples in this document are in C#.

San Francisco's Transamerica Pyramid building, 2 meter resolution USGS DOQ image TerraServer-USA Web Service is a programmable interface to the popular TerraServer-USA on-line database of high resolution USGS aerial imagery (DOQs) and scanned USGS topographical maps (DRGs). Using Microsoft .NET technologies, developers can easily query the Microsoft TerraServer SQL Server 2000 database and access all the important functions for the system. Thus, users of the TerraServer .NET Web Service can enhance the functionality of their web site or .NET WinForm application by directly incorporating TerraServer-USA USGS imagery and tabular information. This document provides all the information you need to program the TerraServer-USA .NET Web Service.

Before we get started on programming the TerraServer .NET Web Service, lets talk a little about what TerraServer-USA is all about. You can visit the TerraServer-USA web site at http://terraserver-usa.com/ . The TerraServer-USA web site has existed since July 1998. The web site enables users to search for topographical maps and aerial imagery through a standard web browser. TerraServer-USA web application presents HTML web pages that reference JPEG or GIF "tiles" that are stored in the TerraServer-USA database. The image on the right is a single image tile stored in the TerraServer's SQL Server 2000 database. Using HTML tables, multiple image tiles are arranged to present a larger image to the end user. Buttons around the imagery allow the user to navigate in NorthWest, North, NorthEast, East, West, SouthWest, South or SouthEast direction. A zoom button allows users to "zoom in" to higher resolution image tiles or "zoom out" to lower resolution tiles. The web site application offers three methods for locating imagery — longitude & latitude, place name (city, town, and notable landmarks, e.g. Statue of Liberty), and clicking on a coverage map.

Many users of TerraServer-USA have requested permission to use imagery from TerraServer-USA. All the data stored within Microsoft Terraserver is public domain, US Geological Survey data. Thus, users are welcome to include references to TerraServer-USA imagery in their own web pages. All that is asked is that an acknowledgement be placed next to the image referencing that it is a USGS image and that it comes from TerraServer-USA. The How to link to TerraServer-USA web page describes how to form HTML <img src> and <table> tags on your web page. The task requires users to understand how TerraServer uniquely identifies each image tile within the database.

The TerraServer indexing system is fairly straight forward, however it does require familiarity with map projection systems, the notion of ground resolution, and planar coordinates. This can be daunting for those unfamiliar with these concepts. Once these concepts are mastered, it is a trivial exercise to build a script that can replicate the standard TerraServer pan and zoom functions. What is impossible to do, however, is determine if a given image tile exists in the TerraServer database. If given an address to a non-existent image tile, the TerraServer web site will return a "stock graphic" designed to look like the "matte" found around photograph frames that you might find hanging on the walls of your home. Visually, humans know immediately that the image tile is not a USGS aerial image or topographic map. But a program cannot tell. The matte has all the same properties of an aerial image tile. There is also no programmable interface to the TerraServer place name and longitude & latitude search systems. Users are required to implement their own search systems.

The TerraServer-USA .NET Web Service is designed to simplify the task of accessing TerraServer programmatically. Developers call TerraServer Web Service methods to perform standard queries against the TerraServer database. The Microsoft .NET technologies do the "heavy lifting" to connect programs to the TerraServer Web Service via Internet communication protocals and exchange data. All the programmer has to do is call the provided TerraServer Web Service API methods and iterate through the data contained in the data structures returned by TerraServer Web Service. The remainder of this document describes the TerraServer Web Service APIs and the data structures passed to and returned from the TerraServer Web Service APIs.

back buttonhome page buttonnext page button