From Version
Status | ||||
---|---|---|---|---|
|
|
You may select a Projection for your Map Source by picking an entry from the list. There is a default Projection that is configured via the iShare Settings on the General tab under the Web heading.
In previous versions of iShare the .map file points to the Projections supplied by MapServer which contains a long list of SRID without any descriptions. With iShare v5.6.2 we have supplied Astun now supply a cut down Projection file in a projections folder that will not be overwritten if MapServer is upgraded e.g. D:\iShareData\Astun\_MapServerConfig\projections\epsg
Tip |
---|
The order in which you specify the entries in this file will be the order that they are displayed in Studio i.e. put the most used projections at the top of the list. |
Configure your .MAP file to use the new Projections file
If you wish to use this file instead of the default MapServer projection file you will need to edit your .map file to point to the new projections file by changing the CONFIG "PROJ_LIB" entry e.g.
Code Block |
---|
CONFIG "PROJ_LIB" "projections" |
Adding your own Projections
You may add your own Projections by opening the file in a Text Editor such as Notepad++. The entries must be formatted correctly to display in the list correctly e.g. for BNG
Code Block |
---|
# OSGB 1936 / British National Grid <27700> +title=British National Grid +proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996019996012717 +x_0=400000 +y_0=-100000 +ellps=airy +units=m +no_defs no_defs <> |
The first line is just a comment the next has the following formatting requirement:
Code | Descrption |
---|---|
<27700> | The SRID for the projection |
+title=British National Grid | The Title to display |
| The Projection definition. In order to find the correct definition for your required projection please see http://spatialreference.org/ref/ select the relevant entry and then click on the Proj4 link which will give you what you require. |
<> | The end of line |
Remember that your Map Sources may be set up for WMS & WFS access. If your Map Sources' associated .map files are set up to support multiple projections then make sure the epsg file referenced contains all the necessary projection definitions. Below is a typical epsg file shortened to only include projections typically used with British data.
Code Block |
---|
# WGS 84
<4326> +title=long/lat:WGS84 +proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs no_defs <>
# ETRS89
<4258> +title=long/lat:ETRS89 +proj=longlat +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +no_defs no_defs <>
# OSGB 1936 / British National Grid
<27700> +title=British National Grid +proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +ellps=airy +datum=OSGB36 +units=m +no_defs <>
# TM75 / Irish Grid
<29903> +proj=tmerc +lat_0=53.5 +lon_0=-8 +k=1.000035 +x_0=200000 +y_0=250000 +a=6377340.189 +b=6356034.447938534 +units=m +no_defs no_defs <>
# OSNI 1952 / Irish National Grid
<29901> +proj=tmerc +lat_0=53.5 +lon_0=-8 +k=1.000000 +x_0=200000 +y_0=250000 +ellps=airy +units=m +no_defs no_defs <>
# IRENET95 / Irish Transverse Mercator
<2157> +proj=tmerc +lat_0=53.5 +lon_0=-8 +k=0.999820 +x_0=600000 +y_0=750000 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs no_defs <>
# SR-ORG:6864
<3857> +proj=merc +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6378137 +b=6378137 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs <>
# EPSG:3035
<3035> +proj=laea +lat_0=52 +lon_0=10 +x_0=4321000 +y_0=3210000 +ellps=GRS80 +units=m +no_defs <> |