Serving WCS elevation data to World Wind using GeoServer

I wrote a post earlier about how to configure GeoServer to serve elevation data to World Wind as a Web Map Service (WMS). Serving elevations over WMS is possible, but requires configuration on both the server and client. World Wind recently introduced a feature to consume elevation data from a Web Coverage Service (WCS). This is a much easier to set up, and requires only server side configuration. WCS support was adding in June 2014, is not yet in the stable World Wind release, so you’ll need a recent snapshot of World Wind.

There is one caveat: World Wind requires that the WCS server return data in a lat-lon coordinate reference system (specifically EPSG:4326). In theory, GeoServer can reproject nearly any source data into this coordinate system, but in practice I’ve had trouble getting the reprojected layer to work with World Wind. You can work around this problem by using GDAL to reproject your source data to the right projection. This will also improve performance, since the server won’t have to reproject data on-the-fly.

Use the gdalwarp command line tool to reproject a file. For example, to reproject the Spearfish elevation GeoTIFF that ships with GeoServer, run this command:

gdalwarp -t_srs EPSG:4326 sfdem.tif sfdem_geographic.tif

Now you can add the warped GeoTIFF as a GeoServer data store, publish the layer, and connect using World Wind. You shouldn’t need any further configuration on the server. See the WCSElevations example in World Wind for how to connect to the WCS server.

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *