Hi,

I would like to add a wms layer with a projection that is not 4326 or 900913. It seems that the selection list for projections in /?q=admin/build/openlayers/layers/add/openlayers_layer_type_wms is limited to 4326 and 900913. Is it possible to define a wms layer for a different projection through the OpenLayers UI?

Thanks,
John

Comments

tmcw’s picture

You can manually add layers with other projections, if you export layers and modify the exports in modules or features. However, there is no support in core for the 'full range' of OpenLayers projections, because support of projections besides 4326 and 900913 requires Proj4.js support and other intricacies (mainly correct management of resolutions and zoom levels) and we haven't seen serious needs for other projections on the web.

jpulles’s picture

Thanks for your reply.
'Problem' in the Netherlands is that we have a lot of layers in the national RD projection (EPSG:28992), which are being used in maps that show e.g. mouse coordinates in RD. If all coordinates are in RD, no proj4js is necessary. Indeed, some solution is still required to manage resolutions.

tmcw’s picture

jpulles: are you sure that proj4js isn't required for EPSG:28992? It would seem that it is... not that anything needs to be reprojected from one to another, but just to get coordinates on a map in a projection system, the projection needs to be understood...

strk’s picture

No reprojection is required if all maps are in the same projection.
This is just a design issue (ie: figure out how to select a map projection and layer projection with the UI).

tmcw’s picture

Title: how to add a wms layer with a different projection » support free projection choice in wms layers
Category: support » task

Okay, then updating the title to reflect the new task. Selecting a new projection for the map based on available layer projections is already in and working, we just need to let WMS users select projections freeform without letting them shoot feet.

MichaelP’s picture

I'm not quite sure that this is related but here goes:

I need to use a wms cache which only offers an EPSG:23031 projection. All of the preset layers would be on the same projection.

I have tried hacking this in as a WMS layer using the values I could find for resolutions, bounds (extents) etc, but the bbox values generated are wrong, and I am obviously miles off, literally and conceptually!

I would like to know where would I start, and if this is major or minor surgery?

Many thanks.

BladeRider’s picture

I'd like to add my support for a free-form selection capability for projections (wanting to use EPSG:27700 myself, the GB National Grid).

quiron’s picture

+1

How can I use 23031 projection?My situation is like MichaelP.

thanks

tmcw’s picture

Version: 6.x-2.0-alpha8 » 6.x-2.x-dev
Category: task » feature

Patches accepted: this isn't a strong area of focus and development time is extremely limited. Make sure you understand what this won't do: notably, maps in 23031, 2770, etc., will only be compatible with other layers in that project; thus no Google Maps, etc.

zzolo’s picture

Component: Layers » OL API
Status: Active » Closed (duplicate)

Moving projection disucssion here: #1331410: Better Handling of Projections