Hi Chris, I don't know why I just got a copy of this message several months late. However it reminds me that I solved the problem and never reported it. It is not a problem of Spherical Mercator or of OpenLayers.
The problem is with the definition of the "Gauss Boaga" projection (that ESRI call Monte Mario ITaly). I did specify that the ellipsoid is the Hayford 1909 (+ellps=intl) but I did not specify that the datum is Rome 1940, i.e. that the ellipsoid is rotated towards Monte Mario (a mountain near Rome). In fact I never worked out how to do it, so I used a workaround in my project. Regards -- George Mu'ammar Quoting "Christopher Schmidt-2 (via Nabble)" <[email protected]>: > > > > On Fri, Aug 08, 2008 at 01:02:31PM -0700, George.Muammar wrote: >> The road layer (Teleatlas / Navteq) comes in UTM - WGS84 and I also combine >> it with my cadastral data. I play with these projections every day and are >> very confident with them - but not so with the so called "spherical >> mercator" > > Using Google Maps in EPSG:4326 *must* lead to offsets within OpenLayers. > There is no possible way to avoid this, as Google Maps data is > *projected* data, and EPSG:4326 is a 'flat' projection, using lat/lon as > planar units. The end result is that there is no way that you can > correctly overlay data on top of Google Maps, Virtual Earth, or any > other commercial baselayer. > > However, reading the following, I realize you are using spherical > mercator? At least, I Think? In which case, the answer is "yes, I have > used this with 'very accurate maps', and had no problems getting pixel > perfect overlays on top of Google Maps. However, I have also seen > significant offsets, *especially* in VirtualEarth (in the 100M range) > even in areas where I would typicaly expect better results. > (Specifically, New Orleans in VE at some zoom levels is *bad*.) > > I don't see anything wrong with your configuration here; Have you tried > laying over Google instead? > > Another comment is that it is possible that your proj.4 version may > affect things: I've heard people reporting problems with older proj.4 > libraries not respecting the +nadgri...@null hack. > > Just a few thoughts. > >> >> Does anybody have any opinion in the matter ? has anyone tried to overlay >> Google / VE / Yahoo with very accurate maps ? >> >> For the record I am doing the following: (maybe something wrong) >> >> projections in Proj.4 epsg file: >> >> # Spherical Mercator for Google etc. >> <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 +nadgri...@null +no_defs >> # GAUSS BOAGA EST >> <3004> +proj=tmerc +lat_0=0 +lon_0=15.0 +k=0.999600 +x_0=2520000 +y_0=0 >> +ellps=intl +pm=0 +units=m no_defs <> >> >> >> I define my map thus: >> var smproj = new OpenLayers.Projection("EPSG:900913"); >> >> mapOptions = { >> projection: smproj, >> units: "m", >> displayProjection: geoproj >> }; >> >> >> my layers thus: >> var hyblayer = new OpenLayers.Layer.VirtualEarth( .... >> 'sphericalMercator': true}); >> >> var pmwms = new OpenLayers.Layer.WMS( ..... >> {'projection': smproj}); >> >> >> >> -- >> View this message in context: >> http://www.nabble.com/Conversion-to-Spherical-Mercator---100m-error-tp18898188p18898188.html >> Sent from the OpenLayers Users mailing list archive at Nabble.com. >> >> _______________________________________________ >> Users mailing list >> [email protected] >> http://openlayers.org/mailman/listinfo/users > > -- > Christopher Schmidt > MetaCarta > _______________________________________________ > Users mailing list > [email protected] > http://openlayers.org/mailman/listinfo/users > > > ______________________________________ > > This email is a reply to your post @ > http://n2.nabble.com/Conversion-to-Spherical-Mercator---100m-error-tp1829789p1829790.html > You can reply by email or by visting the link above. > > -- View this message in context: http://n2.nabble.com/Conversion-to-Spherical-Mercator---100m-error-tp1829789p1877997.html Sent from the OpenLayers Users mailing list archive at Nabble.com.
_______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
