[OpenLayers-Users] Projection over the north pole (EPSG:3573)

John Bennett john.bennett at noetix.on.ca
Tue Mar 11 14:24:06 EDT 2008


Hi,

I am trying to get the mouse position to display in lat/lon when using EPSG:
3573 (http://nsidc.org/data/atlas/epsg_3573.html ).  I'm using the trunk in
hope of openlayers having proj4js support.

 

In the following example if I use option1 with layer 'gsat' and
sphericalMercator projection everything works great, the mouse position is
displayed in lat/lon. If I use option2 with layer 'sat_north' and EPSG:3573
the mouse position is displayed in meters, but I want it displayed in
lat/lon. Is this possible?

 

function init(){

            var options1 = {

                projection: new OpenLayers.Projection("EPSG:900913"),

                displayProjection: new OpenLayers.Projection("EPSG:4326"),

                units: "m",

                maxResolution: 156543.0339,

                maxExtent: new OpenLayers.Bounds(-20037508,
-20037508,20037508, 20037508.34)

            };

            var options2 = {

                projection: new OpenLayers.Projection("EPSG:3573"),

                displayProjection: new OpenLayers.Projection("EPSG:4326"),

                units: "m",

                maxResolution: "auto",

                maxExtent: new
OpenLayers.Bounds(-9036842.762,-9036842.762,9036842.762,9036842.762)

            };

            map = new OpenLayers.Map('map', options2);

 

            var gsat = new OpenLayers.Layer.Google(

                "Google Satellite",

                {type: G_SATELLITE_MAP, 'sphericalMercator': true}

            );

            sat_north = new OpenLayers.Layer.WMS( "Satellite imagery MODIS",


                    "http://nsidc.org/cgi-bin/atlas_north?", {layers:
'blue_marble_01', projection: new OpenLayers.Projection("EPSG:3573")});

 

            map.addLayer(sat_north);

            map.addControl(new OpenLayers.Control.Permalink());

            map.addControl(new OpenLayers.Control.MousePosition());

            map.zoomToMaxExtent()

        }

Regards,

John Bennett

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20080311/69d3eb5c/attachment.html


More information about the Users mailing list