Change to EPSG:3857 from 900913

434 views
Skip to first unread message

Jukka Rahkonen

unread,
Nov 27, 2013, 12:32:26 PM11/27/13
to mapstor...@googlegroups.com
Hi,

The config files of Mapstore define the Web Mercator projection as "projection": "EPSG:900913".  However, many WMS servers do not support out-of-the box that code any more but only the official EPSG:3857. Mapserver belongs to those servers. Could you consider changing the projection code or do you think that the change would break something?

-Jukka Rahkonen-

Tobia Di Pisa

unread,
Nov 27, 2013, 12:54:49 PM11/27/13
to mapstor...@googlegroups.com
Hi Jukka,

in MapStore you have to:

1) Enable the proj4js script tag in your template. For example inside the composer.html you have just to uncomment the line below:

<!--script type="text/javascript" src="script/proj4js.js"></script-->

2) Add the EPSG:3857 proj4js definition to the mapstore configuration file (the default one is inside  the mapStoreConfig.js file):

"proj4jsDefs": {
     "EPSG:3857": "+title= Google Mercator EPSG:3857 +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"
 },

3) Use directly the EPSG:3857 in the map projection definition (inside the configuration file):

"map": {
    "projection": "EPSG:3857",

This should be all, if you need to use the EPSG:3857 for your map.

Best Regards,
     Tobia Di Pisa



==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for
more information.
==

Dott. Ing. Tobia Di Pisa
Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------


2013/11/27 Jukka Rahkonen <jukka.r...@latuviitta.fi>
Hi,

The config files of Mapstore define the Web Mercator projection as "projection": "EPSG:900913".  However, many WMS servers do not support out-of-the box that code any more but only the official EPSG:3857. Mapserver belongs to those servers. Could you consider changing the projection code or do you think that the change would break something?

-Jukka Rahkonen-

--
You received this message because you are subscribed to the Google Groups "mapstore-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mapstore-user...@googlegroups.com.
To post to this group, send email to mapstor...@googlegroups.com.
Visit this group at http://groups.google.com/group/mapstore-users.
For more options, visit https://groups.google.com/groups/opt_out.

Jukka Rahkonen

unread,
Nov 27, 2013, 1:11:53 PM11/27/13
to mapstor...@googlegroups.com, tobia....@geo-solutions.it
Hi,

I am not so much thinking about myself as a MapStore user. I am thinking about all the people running MapStore with the default settings and myself as WMS server admin. We do not support EPSG:900913 in our WMS which means that those poor MapStore users cannot read the good data we might have for them. But if there is no way to discard 900913 we all must just learn how to handle it.

-Jukka-

Andrea Aime

unread,
Nov 28, 2013, 3:31:30 AM11/28/13
to mapstor...@googlegroups.com, Tobia Di Pisa
On Wed, Nov 27, 2013 at 7:11 PM, Jukka Rahkonen <jukka.r...@latuviitta.fi> wrote:
Hi,

I am not so much thinking about myself as a MapStore user. I am thinking about all the people running MapStore with the default settings and myself as WMS server admin. We do not support EPSG:900913 in our WMS which means that those poor MapStore users cannot read the good data we might have for them. But if there is no way to discard 900913 we all must just learn how to handle it.

As an aside, I believe that while GeoWebCache advertises by default only support for 900913, it has an internal
alias so that if you hit it with 3857, it will work anyways:


Cheers
Andrea

--
==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.
==

Ing. Andrea Aime 
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
Reply all
Reply to author
Forward
0 new messages