[OpenLayers-Users] change projection layer dynamically

toni hernández tonidelacalle at gmail.com
Sat Apr 25 19:55:15 EDT 2009


Hi,
I'am no sure I understand the question.

The WMS server renders just one layer for a very close scale. From 5000 and
lower. Depending on the zone you want to be drawn you have to send the
correct epsg. Otherwise no image is drawn.
is that where you where asking?

2009/4/26 Roald de Wit <roald.dewit at lisasoft.com>

> Hi Toni,
>
> Can you tell me how this WMS server works (the one that expects different
> projections based on the area of Spain that you're looking at)?
> Is it one layer for the whole country or 3 different layers that you would
> request (1 layer for every projection/region)? I'd be surprised if it was 1
> layer.
>
> Regards, Roald
>
> toni hernández wrote:
>
>> Hi,
>>
>> thanks for the advise.
>> Now at least I have two different possibilities.
>>
>> The other one I was thinking about is reloading the html page with a new
>> parameter. This new parameter should be used to define the new projection
>> when setting the map. The only problem is that I have to be comparing the
>> coordinates with every new zoom or pan.
>>
>>
>>
>>
>> 2009/4/25 Roald de Wit <roald.dewit at lisasoft.com <mailto:
>> roald.dewit at lisasoft.com>>
>>
>>    Hi Toni,
>>
>>    OpenLayers cannot combine WMS layers with different projections
>>    nor can it easily switch projections, certainly not on the fly
>>    based on the region you are viewing!
>>    What I advise you to do is the following if you have no control
>>    over these WMS servers and cannot have them serve all images in
>>    one projection: have MapServer act as a reprojecting proxy for
>>    you. MapServer can act as a WMS client and reproject the imagery
>>    into the projection you want. This page describes how to do this: [1].
>>
>>    If you need more assistance with setting up or configuring
>>    MapServer I advise you to ask their mailing list.
>>
>>    I hope this helps.
>>
>>    Regards, Roald
>>
>>    [1] http://mapserver.org/ogc/wms_client.html
>>
>>
>>    toni hernández wrote:
>>
>>        hi,
>>
>>        I have a map that gets some WMS layers from two different
>>        servers all over spain.
>>
>>        There is one wms server that needs a concrete epsg parameter
>>        (23029, 23030 or 23031) depending on the zone of spain. This
>>        server does not accept epsg:4326.
>>
>>        So dependig on the zone of the map that is being displaid I
>>        need to change the WMS layer projection.
>>        is this possible?
>>
>>
>>
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20090426/aa809052/attachment.html


More information about the Users mailing list