Differences between revisions 1 and 2
Revision 1 as of 2010-04-10 07:06:10
Size: 442
Editor: SamatJain
Comment: Add NPS data
Revision 2 as of 2010-08-26 03:34:24
Size: 2303
Editor: SamatJain
Comment: Serving NAIP imagery through tilecache/TMS
Deletions are marked like this. Additions are marked like this.
Line 5: Line 5:
The National Park Service has a [[http://www.nps.gov/gis/data_info/park_gisdata/nm.htm|data clearing house for New Mexico national park GIS information]], including [[http://nrdata.nps.gov/All_NPS/basedata/imagery/doq/doq_series/html/newmexico.html|DOQs for various national park-containing areas of New Mexico]] (including White Sands National Monument). The DOQs are in MrSID format.
Line 6: Line 7:
== NAIP imagery with Mapserver, tilecache, and JOSM ==
Line 7: Line 9:
The National Park Service has a [[http://www.nps.gov/gis/data_info/park_gisdata/nm.htm|data clearing house for New Mexico national park GIS information]], including [[http://nrdata.nps.gov/All_NPS/basedata/imagery/doq/doq_series/html/newmexico.html|DOQs for various national park-containing areas of New Mexico]] (including White Sands National Monument). The DOQs are in MrSID format. === MapServer ===

UNM !MapServer is needed to reproject from EPSG:4326 to EPSG:900913 (Google Mercator) projection.

{{{
MAP
    SIZE 256 256
    TRANSPARENT TRUE
    OUTPUTFORMAT
      NAME PNG
      DRIVER 'GD/PNG'
      MIMETYPE 'image/png'
      IMAGEMODE RGBA
      EXTENSION "png"
      TRANSPARENT ON
      FORMATOPTION "INTERLACE=OFF"
    END
    WEB
      IMAGEPATH "/var/run/mapserv"
      METADATA
        wms_srs "epsg:4326 epsg:900913"
      END
      TEMPLATE "/path/to/web_template.html"
    END
    STATUS ON

    PROJECTION
        "init=epsg:900913"
    END

    LAYER
        NAME 'naip1m'
        TYPE RASTER
        STATUS DEFAULT
        CONNECTION "http://isse.cr.usgs.gov/ArcGIS/services/Combined/USGS_EDC_Ortho_NAIP/MapServer/WMSServer?"
        CONNECTIONTYPE WMS
        PROJECTION
            "init=epsg:4326"
        END
        METADATA
            "wms_name" "0"
            "wms_server_version" "1.1.1"
            "wms_format" "image/jpeg"
        END
    END
END
}}}

=== tilecache ===

tilecache takes converts TMS requests (made by Mercartor, JOSM, Potlatch) and turns them into WMS requests, serviced by the custom Mapserver instance we setup above.

{{{
[naip]
type=WMS
url=http://hypercube.telascience.org/cgi-bin/mapserv?map=/home/iandees/mapserver/naip.map&
extension=png
layers=naip1m
bbox=-20037508.3427892,-20037508.3427892,20037508.3427892,20037508.3427892
srs=EPSG:900913
metatile=yes
levels=20
tms_type=google
}}}

=== JOSM ===
[22:33:24] <iandees_> so if you open up ~/.josm/preferences and add the following two lines:

{{{
slippymap.custom_tile_source_1.name=NAIP
slippymap.custom_tile_source_1.url=http://hypercube.telascience.org/tiles/1.0.0/naip/
}}}

Aerial photography

The National Park Service has a data clearing house for New Mexico national park GIS information, including DOQs for various national park-containing areas of New Mexico (including White Sands National Monument). The DOQs are in MrSID format.

NAIP imagery with Mapserver, tilecache, and JOSM

MapServer

UNM MapServer is needed to reproject from EPSG:4326 to EPSG:900913 (Google Mercator) projection.

MAP
    SIZE 256 256
    TRANSPARENT TRUE
    OUTPUTFORMAT
      NAME PNG
      DRIVER 'GD/PNG'
      MIMETYPE 'image/png'
      IMAGEMODE RGBA
      EXTENSION "png"
      TRANSPARENT ON
      FORMATOPTION "INTERLACE=OFF"
    END
    WEB
      IMAGEPATH "/var/run/mapserv"
      METADATA
        wms_srs "epsg:4326 epsg:900913"
      END
      TEMPLATE "/path/to/web_template.html"
    END
    STATUS ON

    PROJECTION
        "init=epsg:900913"
    END

    LAYER
        NAME 'naip1m'
        TYPE RASTER
        STATUS DEFAULT
        CONNECTION "http://isse.cr.usgs.gov/ArcGIS/services/Combined/USGS_EDC_Ortho_NAIP/MapServer/WMSServer?"
        CONNECTIONTYPE WMS
        PROJECTION
            "init=epsg:4326"
        END
        METADATA
            "wms_name"              "0"
            "wms_server_version"    "1.1.1"
            "wms_format"            "image/jpeg"
        END
    END
END

tilecache

tilecache takes converts TMS requests (made by Mercartor, JOSM, Potlatch) and turns them into WMS requests, serviced by the custom Mapserver instance we setup above.

[naip]
type=WMS
url=http://hypercube.telascience.org/cgi-bin/mapserv?map=/home/iandees/mapserver/naip.map&
extension=png 
layers=naip1m
bbox=-20037508.3427892,-20037508.3427892,20037508.3427892,20037508.3427892
srs=EPSG:900913
metatile=yes
levels=20
tms_type=google

JOSM

[22:33:24] <iandees_> so if you open up ~/.josm/preferences and add the following two lines:

slippymap.custom_tile_source_1.name=NAIP
slippymap.custom_tile_source_1.url=http://hypercube.telascience.org/tiles/1.0.0/naip/

SamatsWiki: OpenStreetMap (last edited 2012-08-07 09:20:09 by SamatJain)