[Geoserver-users] google maps projection

Hi,

I'm not sure if the new google projection added is already using this, but I came across an explanation on google maps and microsoft live maps projection here: http://www.sharpgis.net/2007/07/27/TheMicrosoftLiveMapsAndGoogleMapsProjection.aspx

If this helps, great! If not, sorry for the spam...

Yup, that's the one we're using. GeoTools is a port of proj4, and didn't have the ability to just add a parameter, but Andrea coded up a class that accomplishes the same thing. So that is exactly the projection we're using now, and that post is why we changed things, so credit is definitely due to sharpgis, and Chris Schmidt.

Chris

Doris Lam wrote:

Hi,

I'm not sure if the new google projection added is already using this, but I came across an explanation on google maps and microsoft live maps projection here: http://www.sharpgis.net/2007/07/27/TheMicrosoftLiveMapsAndGoogleMapsProjection.aspx

If this helps, great! If not, sorry for the spam...

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

!DSPAM:4005,46be966535621431913854!

What is the status of this in the code? I have managed to get this projection (10003) running from one of the nightly builds from a few days back, with excellent results. However, for some reason, this nightly build does not handle spatial views in PostGIS correctly, and always assigns an SRID of -1. I have this documented and can log it to jira if needed, but since it is a nightly build, this might be expected. Is there a version that you would recommend for use with the Google projection?

On 8/12/07, Chris Holmes <cholmes@anonymised.com> wrote:

Yup, that’s the one we’re using. GeoTools is a port of proj4, and
didn’t have the ability to just add a parameter, but Andrea coded up a
class that accomplishes the same thing. So that is exactly the
projection we’re using now, and that post is why we changed things, so
credit is definitely due to sharpgis, and Chris Schmidt.

Chris

Doris Lam wrote:

Hi,

I’m not sure if the new google projection added is already using this,
but I came across an explanation on google maps and microsoft live maps
projection here:
http://www.sharpgis.net/2007/07/27/TheMicrosoftLiveMapsAndGoogleMapsProjection.aspx

If this helps, great! If not, sorry for the spam…


This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/


Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

!DSPAM:4005,46be966535621431913854!


This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/


Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Jason Pickering ha scritto:

What is the status of this in the code? I have managed to get this projection (10003) running from one of the nightly builds from a few days back, with excellent results. However, for some reason, this nightly build does not handle spatial views in PostGIS correctly, and always assigns an SRID of -1. I have this documented and can log it to jira if needed, but since it is a nightly build, this might be expected. Is there a version that you would recommend for use with the Google projection?

Jason,
I'm not aware of any change to the code to make views behave badly.
They are simply treaded as tables, and the code expects you to
register them in the geometry_column just as a standard table.
We have no woodoo to figure out from which tables the view
was generated and get the right crs from them.

If you have registered the views in geometry_columns, declared the
crs for each of the view geometry column in there, then yes we
are facing a bug and we need more informations to track it down,
otherwise it's expected behaviour.

Let me know
Cheers
Andrea

Regarding this new google mercator projection, I’ve made the following changes to add support for it in my Postgis database, and my Geoserver implementation:

### POSTGIS spatial_ref_sys
INSERT INTO spatial_ref_sys (srid, auth_name, auth_srid, srtext, proj4text)
VALUES (
900913,
'EPSG',
900913,
'PROJCS["WGS84 / Simple Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS_1984", 6378137.0, 298.257223563]], PRIMEM["Greenwich", 0.0], UNIT["degree", 0.017453292519943295], AXIS["Longitude", EAST], AXIS["Latitude", NORTH]], PROJECTION["Mercator_1SP_Google"], PARAMETER["latitude_of_origin", 0.0], PARAMETER["central_meridian", 0.0], PARAMETER["scale_factor", 1.0], PARAMETER["false_easting", 0.0], PARAMETER["false_northing", 0.0], UNIT["m", 1.0], AXIS["x", EAST], AXIS["y", NORTH], AUTHORITY["EPSG","900913"]]',
'+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'
);

### GEOSERVER geoserver/Data/user_projections/epsg.properties
900913=``PROJCS["WGS84 / Simple Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS_1984", 6378137.0, 298.257223563]], PRIMEM["Greenwich", 0.0], UNIT["degree", 0.017453292519943295], AXIS["Longitude", EAST], AXIS["Latitude", NORTH]], PROJECTION["Mercator_1SP_Google"], PARAMETER["latitude_of_origin", 0.0], PARAMETER["central_meridian", 0.0], PARAMETER["scale_factor", 1.0], PARAMETER["false_easting", 0.0], PARAMETER["false_northing", 0.0], UNIT["m", 1.0], AXIS["x", EAST], AXIS["y", NORTH], AUTHORITY["EPSG","54004"]]

The only thing is, my geoserver version (I want to say 1.6beta1) is using gt2-epsg-hsql-2.4-SNAPSHOT.jar. The HSQL database that is dynamically created does not contain this new projection. Does anyone know how I can incorporate the new projection here? I’m guessing a few insert statements would do, but I am unfamiliar what tables (and values for that matter) to insert records into.

Oh, and is the epsg.properties file under user_projections used by Geoserver?
Andrea Aime wrote:

···
__________________________________
Jeremy Nix
Senior Application Developer
Southwest Financial Services, Ltd.
(513) 621-6699

Jason Pickering ha scritto:
  
What is the status of this in the code? I have managed to get this 
projection (10003) running from one of the nightly builds from a few 
days back, with excellent results. However, for some reason, this 
nightly build does not handle spatial views in PostGIS correctly, and 
always assigns an SRID of -1. I have this documented and can log it to 
jira if needed, but since it is a nightly build, this might be expected. 
Is there a version that you would recommend for use with the Google 
projection?
    

Jason,
I'm not aware of any change to the code to make views behave badly.
They are simply treaded as tables, and the code expects you to
register them in the geometry_column just as a standard table.
We have no woodoo to figure out from which tables the view
was generated and get the right crs from them.

If you have registered the views in geometry_columns, declared the
crs for each of the view geometry column in there, then yes we
are facing a bug and we need more informations to track it down,
otherwise it's expected behaviour.

Let me know
Cheers
Andrea

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  [http://get.splunk.com/](http://get.splunk.com/)
_______________________________________________
Geoserver-users mailing list
[Geoserver-users@lists.sourceforge.net](mailto:Geoserver-users@lists.sourceforge.net)
[https://lists.sourceforge.net/lists/listinfo/geoserver-users](https://lists.sourceforge.net/lists/listinfo/geoserver-users)
  

Hey, you're going to have to upgrade your version of GeoServer to take advantage of the new projection, as it involved some new code to make it work right. You can grab a 1.6.x from: http://geo.openplans.org/nightly/trunk/

It should have the projection in epsg.properties file under user_projections. It is definitely used by GeoServer. I think inserting in to PostGIS as well may work, but you need the upgraded classes for it to work properly. But the easiest is to just do things in the user projection file.

best regards,

Chris

Jeremy Nix wrote:

Regarding this new google mercator projection, I've made the following changes to add support for it in my Postgis database, and my Geoserver implementation:

### POSTGIS spatial_ref_sys
INSERT INTO spatial_ref_sys (srid, auth_name, auth_srid, srtext, proj4text)
VALUES (
    900913,
    'EPSG',
    900913,
    'PROJCS["WGS84 / Simple Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS_1984", 6378137.0, 298.257223563]], PRIMEM["Greenwich", 0.0], UNIT["degree", 0.017453292519943295], AXIS["Longitude", EAST], AXIS["Latitude", NORTH]], PROJECTION["Mercator_1SP_Google"], PARAMETER["latitude_of_origin", 0.0], PARAMETER["central_meridian", 0.0], PARAMETER["scale_factor", 1.0], PARAMETER["false_easting", 0.0], PARAMETER["false_northing", 0.0], UNIT["m", 1.0], AXIS["x", EAST], AXIS["y", NORTH], AUTHORITY["EPSG","900913"]]',
    '+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'
);

### GEOSERVER geoserver/Data/user_projections/epsg.properties
900913=PROJCS["WGS84 / Simple Mercator", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS_1984", 6378137.0, 298.257223563]], PRIMEM["Greenwich", 0.0], UNIT["degree", 0.017453292519943295], AXIS["Longitude", EAST], AXIS["Latitude", NORTH]], PROJECTION["Mercator_1SP_Google"], PARAMETER["latitude_of_origin", 0.0], PARAMETER["central_meridian", 0.0], PARAMETER["scale_factor", 1.0], PARAMETER["false_easting", 0.0], PARAMETER["false_northing", 0.0], UNIT["m", 1.0], AXIS["x", EAST], AXIS["y", NORTH], AUTHORITY["EPSG","54004"]]

The only thing is, my geoserver version (I want to say 1.6beta1) is using gt2-epsg-hsql-2.4-SNAPSHOT.jar. The HSQL database that is dynamically created does not contain this new projection. Does anyone know how I can incorporate the new projection here? I'm guessing a few insert statements would do, but I am unfamiliar what tables (and values for that matter) to insert records into.

Oh, and is the epsg.properties file under user_projections used by Geoserver?
__________________________________
Jeremy Nix
Senior Application Developer
Southwest Financial Services, Ltd.
(513) 621-6699
  
Andrea Aime wrote:

Jason Pickering ha scritto:
  

What is the status of this in the code? I have managed to get this projection (10003) running from one of the nightly builds from a few days back, with excellent results. However, for some reason, this nightly build does not handle spatial views in PostGIS correctly, and always assigns an SRID of -1. I have this documented and can log it to jira if needed, but since it is a nightly build, this might be expected. Is there a version that you would recommend for use with the Google projection?
    
Jason,
I'm not aware of any change to the code to make views behave badly.
They are simply treaded as tables, and the code expects you to
register them in the geometry_column just as a standard table.
We have no woodoo to figure out from which tables the view
was generated and get the right crs from them.

If you have registered the views in geometry_columns, declared the
crs for each of the view geometry column in there, then yes we
are facing a bug and we need more informations to track it down,
otherwise it's expected behaviour.

Let me know
Cheers
Andrea

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users
  

!DSPAM:4005,46c1f8b9255252090977483!
------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/

!DSPAM:4005,46c1f8b9255252090977483!
  ------------------------------------------------------------------------

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

!DSPAM:4005,46c1f8b9255252090977483!