Google Map projection and EPSG codes

Cameron Shorter cameron.shorter at gmail.com
Wed Sep 27 07:04:01 EDT 2006


One of the commonly requested features for a webmapping client is to 
render WMS layers over Google Map basemaps.

Unfortunately, this is tricky to implement because the projection used 
by Google Maps doesn't have a corresponding EPSG code which means that 
the projection cannot be selected using a standard WMS query.

John Deck describes the problem, and a hack to get around it at:
http://johndeck.blogspot.com/2005/09/overlaying-mercator-projected-wms.html
John defines his own EPSG code in a mapserv config file.

Questions:
==========
1. geoserver-devel, Is there a similar hack that can be used in Geoserver?

2. webmap-discuss, has anyone worked out a "less hacky" solution?

3. What is the process for defining a new EPSG code? Is this something 
we can make happen?

Proposal:
=========
webmap-discuss, geoserver-devel, mapserver people,
If we cannot force a new EPSG code to be officially created, I suggest 
that all the Open Source projects define a de-facto EPSG code for Google 
Maps which Geoserv, Mapserv and the various webmapping clients all support.

Craig Bruce wrote:
> "Kralidis,Tom [Burlington]" <Tom.Kralidis at ec.gc.ca> wrote:
> 
> 
>>Question: has there been any definition of an EPSG code as applied to
>>the way Google Maps displays their data (I'm not exactly sure what the
>>projection params, but I did find one def from the postgis-users mailing
>>list [see:
>>http://postgis.refractions.net/pipermail/postgis-users/2005-November/009
>>920.html])?  
>>
>>I'm not sure if CubeWerx has defined one in the 42xxx series of
>>'defacto' EPSG codes, or whether it's defined already, for that matter.
> 
> 
> The closest match we have found is a simple Mercator projection.  One is
> defined in the OGC 41xxx space as:
> 
> EPSG:41001:
> 
> PROJCS["WGS84 / Simple Mercator",
>     GEOGCS["WGS 84",
>         DATUM["WGS_1984",
>             SPHEROID["WGS_1984",6378137,298.257223563]],
>         PRIMEM["Greenwich",0],
>         UNIT["Decimal_Degree",0.0174532925199433]],
>     PROJECTION["Mercator"],
>     PARAMETER["latitude_of_origin",0],
>     PARAMETER["central_meridian",0],
>     PARAMETER["false_easting",0],
>     PARAMETER["false_northing",0],
>     UNIT["Meter",1]]
> 
> This doesn't appear to be an exact match, however, as the mismatch grows
> from the equator from zero to a few kilometers.  There might be a scale
> factor/secant involved.
> 
> --------------------------+----------------------+--------------------------
> Dr. Craig S. Bruce        | Ph 819-771-8303 x205 |             CubeWerx Inc.
> Senior Software Developer |   Fax 819-771-8388   |  Gatineau, Québec, Canada
> csbruce at cubewerx.com      |  http://csbruce.com/ |  http://www.cubewerx.com/
> --------------------------+----------------------+--------------------------
>     "Q: How many of your previous romantic relationships were failures?
>      A: All of them.
>      Q: So, what are the chances for your present relationship?
>      A: Well, let's check the statistics..."
> 


-- 
Cameron Shorter
http://cameron.shorter.net




More information about the Webmap-discuss mailing list