[UMN_MAPSERVER-USERS] WMS and reprojection

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

[UMN_MAPSERVER-USERS] WMS and reprojection

vincent.dacol
Hi everybody,

I'm a student and I'm disovering the world of Mapserver and
interoperabillity.

I'm trying to use 2 WMS services in different projections, and
one client to display two layer from that server.

But the reprojection didn't work in the client. The 2 layer
obtain with the 2 WMS server aren't display in the same
projection.

The projection of my WMS server 1 is "init=epsg:27571"
The projection of my WMS server 2 is "init=epsg:27582"

This two server can serv :
"wms_srs"      "EPSG:27582 EPSG:27571"

The projection I want to display with the client is
"init=epsg:27582"

When I use the 2 layers in local, there is no supperposition
problem, the picture obtain was fine, the reprojection work.

But with the WMS client, the first layer is in it's own
projection, and the second too. So the 2 layer arn't
supperposed, it seem there is no reprojection.

Is-it a reprojection probleme?

My opignon is that a single mapfile with multiple connections
to different WMS server must only connect to server who are in
the same projection.

Maybe I'm wrong, I really new to Mapserver, but I have spend a
lot of time one this probleme, and the only solution I have
find the solve it is to use the same output projection in the
client and in the WMS server.

But this solution isn't very logical for me. I want to connect
to a server who use is own projection, and can serve data in
other predefined EPSG projection. So a WMS client use a WMS
layer has a local layer, with is own projection output, and is
abble to reproject the data obtain in the WMS layer.


Thanks for the help (I really need it).

Vincent

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)


Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

Ed McNierney-4
Vincent -

You need to be sure you are accurately describing each service; can you post the MAP file you are using for the 2 WMS servers?

        - Ed

Ed McNierney
President and Chief Mapmaker
TopoZone.com / Maps a la carte, Inc.
73 Princeton Street, Suite 305
North Chelmsford, MA  01863
Phone: +1 (978) 251-4242
Fax: +1 (978) 251-1396
[hidden email]

-----Original Message-----
From: UMN MapServer Users List [mailto:[hidden email]] On Behalf Of vincent.dacol
Sent: Wednesday, May 25, 2005 5:40 AM
To: [hidden email]
Subject: [UMN_MAPSERVER-USERS] WMS and reprojection

Hi everybody,

I'm a student and I'm disovering the world of Mapserver and interoperabillity.

I'm trying to use 2 WMS services in different projections, and one client to display two layer from that server.

But the reprojection didn't work in the client. The 2 layer obtain with the 2 WMS server aren't display in the same projection.

The projection of my WMS server 1 is "init=epsg:27571"
The projection of my WMS server 2 is "init=epsg:27582"

This two server can serv :
"wms_srs"      "EPSG:27582 EPSG:27571"

The projection I want to display with the client is "init=epsg:27582"

When I use the 2 layers in local, there is no supperposition problem, the picture obtain was fine, the reprojection work.

But with the WMS client, the first layer is in it's own projection, and the second too. So the 2 layer arn't supperposed, it seem there is no reprojection.

Is-it a reprojection probleme?

My opignon is that a single mapfile with multiple connections to different WMS server must only connect to server who are in the same projection.

Maybe I'm wrong, I really new to Mapserver, but I have spend a lot of time one this probleme, and the only solution I have find the solve it is to use the same output projection in the client and in the WMS server.

But this solution isn't very logical for me. I want to connect to a server who use is own projection, and can serve data in other predefined EPSG projection. So a WMS client use a WMS layer has a local layer, with is own projection output, and is abble to reproject the data obtain in the WMS layer.


Thanks for the help (I really need it).

Vincent

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)


Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

François-Xavier PRUNAYRE
In reply to this post by vincent.dacol
Hi (again) Vincent,

If you have a look to epsg file contained in proj 4.4.9 package :
# NTF (Paris) / Lambert zone II
<27572> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917 +k_0=0.99987742
+x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
+towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
# NTF (Paris) / France II
<27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917 +k_0=0.99987742
+x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
+towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>

Looks the same ... If you look to Lambert II Etendu (ie. France II)
parameters
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf
It seems that for Lambert II zone 27572, y_0 should be 200000 and lon_0, 0 ?
And for France II lon_0 should be 0 ! Anyone using French coordinate systems
having the same troubles ?

I'm currently using these parameters for France II.
<27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0 +k_0=0.99987742
+x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
+towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>

Any ideas ?

Francois

> -----Message d'origine-----
> De : UMN MapServer Users List
[mailto:[hidden email]] De la

> part de vincent.dacol
> Envoyé : mercredi 25 mai 2005 11:40
> À : [hidden email]
> Objet : [UMN_MAPSERVER-USERS] WMS and reprojection
>
> Hi everybody,
>
> I'm a student and I'm disovering the world of Mapserver and
> interoperabillity.
>
> I'm trying to use 2 WMS services in different projections,
and one client to
> display two layer from that server.
>
> But the reprojection didn't work in the client. The 2 layer
obtain with the
> 2 WMS server aren't display in the same projection.
>
> The projection of my WMS server 1 is "init=epsg:27571"
> The projection of my WMS server 2 is "init=epsg:27582"
>
> This two server can serv :
> "wms_srs"      "EPSG:27582 EPSG:27571"
>
> The projection I want to display with the client is
"init=epsg:27582"
>
> When I use the 2 layers in local, there is no supperposition
problem, the
> picture obtain was fine, the reprojection work.
>
> But with the WMS client, the first layer is in it's own
projection, and the
> second too. So the 2 layer arn't supperposed, it seem there
is no
> reprojection.
>
> Is-it a reprojection probleme?
>
> My opignon is that a single mapfile with multiple
connections to different
> WMS server must only connect to server who are in the same
projection.
>
> Maybe I'm wrong, I really new to Mapserver, but I have spend
a lot of time
> one this probleme, and the only solution I have find the
solve it is to use
> the same output projection in the client and in the WMS server.
>
> But this solution isn't very logical for me. I want to
connect to a server
> who use is own projection, and can serve data in other
predefined EPSG
> projection. So a WMS client use a WMS layer has a local
layer, with is own
> projection output, and is abble to reproject the data obtain
in the WMS

> layer.
>
>
> Thanks for the help (I really need it).
>
> Vincent
>
> Accédez au courrier électronique de La Poste : www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et
> rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels,
> confidentiels et prives. Toute publication, utilisation ou
diffusion, meme
> partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal,
> confidential and secret. Any total or partial publication,
use or
> distribution must be authorized.
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels, confidentiels et prives. Toute publication, utilisation ou
diffusion, meme partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal, confidential and secret. Any total or partial publication, use
or distribution must be authorized.
>
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)




--
Ce message a ete verifie par MailScanner pour des virus ou des polluriels et
rien de suspect n'a ete trouve.

Les donnees et renseignements contenus dans ce message sont personnels,
confidentiels et prives. Toute publication, utilisation ou diffusion, meme
partielle, doit etre autorisee.

Any data and information contained in this electronic mail is personal,
confidential and secret. Any total or partial publication, use or
distribution must be authorized.


--
Ce message a ete verifie par MailScanner pour des virus ou des polluriels et rien de suspect n'a ete trouve.

Les donnees et renseignements contenus dans ce message sont personnels, confidentiels et prives. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee.

Any data and information contained in this electronic mail is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized.
Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

vincent.dacol
In reply to this post by vincent.dacol
Hi Francois,

I have found what doesn't really work in my WMS server. The
reprojection really work well now. But the probleme is the
(x,y) position the differents layers who are in local French
epsg projection system. All are not at the right place.

I think it's a problem of PROJ4 epsg definition. But I don't
realy know how solve it.

Have you some tips or technique to resolve that sort of problem?

Thank for your help.

Vincent




> Hi (again) Vincent,
>
> If you have a look to epsg file contained in proj 4.4.9
package :
> # NTF (Paris) / Lambert zone II
> <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
+k_0=0.99987742
> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
> # NTF (Paris) / France II
> <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
+k_0=0.99987742
> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
>
> Looks the same ... If you look to Lambert II Etendu (ie.
France II)
> parameters
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf
> It seems that for Lambert II zone 27572, y_0 should be
200000 and lon_0, 0 ?
> And for France II lon_0 should be 0 ! Anyone using French
coordinate systems
> having the same troubles ?
>
> I'm currently using these parameters for France II.
> <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
+k_0=0.99987742

> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
>
> Any ideas ?
>
> Francois
>
> > -----Message d'origine-----
> > De : UMN MapServer Users List
> [mailto:[hidden email]] De la
> > part de vincent.dacol
> > Envoyé : mercredi 25 mai 2005 11:40
> > À : [hidden email]
> > Objet : [UMN_MAPSERVER-USERS] WMS and reprojection
> >
> > Hi everybody,
> >
> > I'm a student and I'm disovering the world of Mapserver and
> > interoperabillity.
> >
> > I'm trying to use 2 WMS services in different projections,
> and one client to
> > display two layer from that server.
> >
> > But the reprojection didn't work in the client. The 2 layer
> obtain with the
> > 2 WMS server aren't display in the same projection.
> >
> > The projection of my WMS server 1 is "init=epsg:27571"
> > The projection of my WMS server 2 is "init=epsg:27582"
> >
> > This two server can serv :
> > "wms_srs"      "EPSG:27582 EPSG:27571"
> >
> > The projection I want to display with the client is
> "init=epsg:27582"
> >
> > When I use the 2 layers in local, there is no supperposition
> problem, the
> > picture obtain was fine, the reprojection work.
> >
> > But with the WMS client, the first layer is in it's own
> projection, and the
> > second too. So the 2 layer arn't supperposed, it seem there
> is no
> > reprojection.
> >
> > Is-it a reprojection probleme?
> >
> > My opignon is that a single mapfile with multiple
> connections to different
> > WMS server must only connect to server who are in the same
> projection.
> >
> > Maybe I'm wrong, I really new to Mapserver, but I have spend
> a lot of time
> > one this probleme, and the only solution I have find the
> solve it is to use
> > the same output projection in the client and in the WMS
server.

> >
> > But this solution isn't very logical for me. I want to
> connect to a server
> > who use is own projection, and can serve data in other
> predefined EPSG
> > projection. So a WMS client use a WMS layer has a local
> layer, with is own
> > projection output, and is abble to reproject the data obtain
> in the WMS
> > layer.
> >
> >
> > Thanks for the help (I really need it).
> >
> > Vincent
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;

> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et
> > rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels,
> > confidentiels et prives. Toute publication, utilisation ou
> diffusion, meme
> > partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal,
> > confidential and secret. Any total or partial publication,
> use or
> > distribution must be authorized.
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels, confidentiels et prives. Toute publication,
utilisation ou
> diffusion, meme partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal, confidential and secret. Any total or partial
publication, use

> or distribution must be authorized.
> >
> >
>
> Accédez au courrier électronique de La Poste : www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et
> rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels,
> confidentiels et prives. Toute publication, utilisation ou
diffusion, meme
> partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal,
> confidential and secret. Any total or partial publication,
use or
> distribution must be authorized.
>
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels, confidentiels et prives. Toute publication,
utilisation ou diffusion, meme partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal, confidential and secret. Any total or partial
publication, use or distribution must be authorized.
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)


Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

Paul Hasenohr
Hello Vincent,

I would suggest that you describe the projection in your mapfile, at least for debug purposes.
If you have a prj file coming e.g. with Arcgis, it is fairly easy.
Then you avoid using +pm=paris and specify lon_0.

For this WKT definition (probably equivalent to a LambertIIE):
PROJCS["France_IMAGE2000",GEOGCS["GCS_NTF",DATUM["D_NTF",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenw
ich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",600000.0],P
ARAMETER["False_Northing",2200000.0],PARAMETER["Central_Meridian",2.337229166666667],PARAMETER["Standard_Parallel_1",45.
898919],PARAMETER["Standard_Parallel_2",47.696014],PARAMETER["Latitude_Of_Origin",46.8],UNIT["Meter",1.0]]

I am using this projection section in my mapfile:
  PROJECTION
    "proj=lcc"
    "ellps=clrk80"
    "lat_1=45.898919"
    "lat_2=47.696014"
    "lat_0=46.8"
    "lon_0=2.337229166666667"
    "x_0=600000.0"
    "y_0=2200000.0"
    "units=m"
    "no_defs"
  END

Also check whether or not you need to use the +towgs84 parameter...

HTH
Paul

-----Original Message-----
From: UMN MapServer Users List [mailto:[hidden email]] On Behalf Of vincent.dacol
Sent: Thursday, May 26, 2005 9:17 AM
To: [hidden email]
Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection

Hi Francois,

I have found what doesn't really work in my WMS server. The reprojection really work well now. But the probleme is the
(x,y) position the differents layers who are in local French epsg projection system. All are not at the right place.

I think it's a problem of PROJ4 epsg definition. But I don't realy know how solve it.

Have you some tips or technique to resolve that sort of problem?

Thank for your help.

Vincent




> Hi (again) Vincent,
>
> If you have a look to epsg file contained in proj 4.4.9
package :
> # NTF (Paris) / Lambert zone II
> <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
+k_0=0.99987742
> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
> # NTF (Paris) / France II
> <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
+k_0=0.99987742
> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
>
> Looks the same ... If you look to Lambert II Etendu (ie.
France II)
> parameters
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf
> It seems that for Lambert II zone 27572, y_0 should be
200000 and lon_0, 0 ?
> And for France II lon_0 should be 0 ! Anyone using French
coordinate systems
> having the same troubles ?
>
> I'm currently using these parameters for France II.
> <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
+k_0=0.99987742

> +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
>
> Any ideas ?
>
> Francois
>
> > -----Message d'origine-----
> > De : UMN MapServer Users List
> [mailto:[hidden email]] De la
> > part de vincent.dacol
> > Envoyé : mercredi 25 mai 2005 11:40
> > À : [hidden email]
> > Objet : [UMN_MAPSERVER-USERS] WMS and reprojection
> >
> > Hi everybody,
> >
> > I'm a student and I'm disovering the world of Mapserver and
> > interoperabillity.
> >
> > I'm trying to use 2 WMS services in different projections,
> and one client to
> > display two layer from that server.
> >
> > But the reprojection didn't work in the client. The 2 layer
> obtain with the
> > 2 WMS server aren't display in the same projection.
> >
> > The projection of my WMS server 1 is "init=epsg:27571"
> > The projection of my WMS server 2 is "init=epsg:27582"
> >
> > This two server can serv :
> > "wms_srs"      "EPSG:27582 EPSG:27571"
> >
> > The projection I want to display with the client is
> "init=epsg:27582"
> >
> > When I use the 2 layers in local, there is no supperposition
> problem, the
> > picture obtain was fine, the reprojection work.
> >
> > But with the WMS client, the first layer is in it's own
> projection, and the
> > second too. So the 2 layer arn't supperposed, it seem there
> is no
> > reprojection.
> >
> > Is-it a reprojection probleme?
> >
> > My opignon is that a single mapfile with multiple
> connections to different
> > WMS server must only connect to server who are in the same
> projection.
> >
> > Maybe I'm wrong, I really new to Mapserver, but I have spend
> a lot of time
> > one this probleme, and the only solution I have find the
> solve it is to use
> > the same output projection in the client and in the WMS
server.

> >
> > But this solution isn't very logical for me. I want to
> connect to a server
> > who use is own projection, and can serve data in other
> predefined EPSG
> > projection. So a WMS client use a WMS layer has a local
> layer, with is own
> > projection output, and is abble to reproject the data obtain
> in the WMS
> > layer.
> >
> >
> > Thanks for the help (I really need it).
> >
> > Vincent
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;

> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et
> > rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels,
> > confidentiels et prives. Toute publication, utilisation ou
> diffusion, meme
> > partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal,
> > confidential and secret. Any total or partial publication,
> use or
> > distribution must be authorized.
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels, confidentiels et prives. Toute publication,
utilisation ou
> diffusion, meme partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal, confidential and secret. Any total or partial
publication, use

> or distribution must be authorized.
> >
> >
>
> Accédez au courrier électronique de La Poste : www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et
> rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels,
> confidentiels et prives. Toute publication, utilisation ou
diffusion, meme
> partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal,
> confidential and secret. Any total or partial publication,
use or
> distribution must be authorized.
>
>
> --
> Ce message a ete verifie par MailScanner pour des virus ou
des polluriels et rien de suspect n'a ete trouve.
>
> Les donnees et renseignements contenus dans ce message sont
personnels, confidentiels et prives. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee.
>
> Any data and information contained in this electronic mail
is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized.
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

vincent.dacol
In reply to this post by vincent.dacol
Thanks for the help and the idea.

I don't know if it is abble to solve my problem, I have try to
decribe the projection like you said, but T don't have any
change one screen :(

I give you a "impscreen" with a visualisation of my probleme.
But it seem it's a PROJ4 pb.

A strange think, all work great when I use WFS server with the
same projection as my WMS server. All layer display at the
right place (except the europe layer who is not display
because he use an other projection unit). Strange isn't it???

have a nice day,

Vincent



> Hello Vincent,
>
> I would suggest that you describe the projection in your
mapfile, at least for debug purposes.
> If you have a prj file coming e.g. with Arcgis, it is fairly
easy.
> Then you avoid using +pm=paris and specify lon_0.
>
> For this WKT definition (probably equivalent to a LambertIIE):
>
PROJCS["France_IMAGE2000",GEOGCS["GCS_NTF",DATUM["D_NTF",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenw
>
ich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",600000.0],P
>
ARAMETER["False_Northing",2200000.0],PARAMETER["Central_Meridian",2.337229166666667],PARAMETER["Standard_Parallel_1",45.
>
898919],PARAMETER["Standard_Parallel_2",47.696014],PARAMETER["Latitude_Of_Origin",46.8],UNIT["Meter",1.0]]

>
> I am using this projection section in my mapfile:
>   PROJECTION
>     "proj=lcc"
>     "ellps=clrk80"
>     "lat_1=45.898919"
>     "lat_2=47.696014"
>     "lat_0=46.8"
>     "lon_0=2.337229166666667"
>     "x_0=600000.0"
>     "y_0=2200000.0"
>     "units=m"
>     "no_defs"
>   END
>
> Also check whether or not you need to use the +towgs84
parameter...
>
> HTH
> Paul
>
> -----Original Message-----
> From: UMN MapServer Users List
[mailto:[hidden email]] On Behalf Of vincent.dacol
> Sent: Thursday, May 26, 2005 9:17 AM
> To: [hidden email]
> Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
>
> Hi Francois,
>
> I have found what doesn't really work in my WMS server. The
reprojection really work well now. But the probleme is the
> (x,y) position the differents layers who are in local French
epsg projection system. All are not at the right place.
>
> I think it's a problem of PROJ4 epsg definition. But I don't
realy know how solve it.

>
> Have you some tips or technique to resolve that sort of problem?
>
> Thank for your help.
>
> Vincent
>
>
>
>
> > Hi (again) Vincent,
> >
> > If you have a look to epsg file contained in proj 4.4.9
> package :
> > # NTF (Paris) / Lambert zone II
> > <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
> +k_0=0.99987742
> > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
> > # NTF (Paris) / France II
> > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
> +k_0=0.99987742
> > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
> >
> > Looks the same ... If you look to Lambert II Etendu (ie.
> France II)
> > parameters
> >
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf

> > It seems that for Lambert II zone 27572, y_0 should be
> 200000 and lon_0, 0 ?
> > And for France II lon_0 should be 0 ! Anyone using French
> coordinate systems
> > having the same troubles ?
> >
> > I'm currently using these parameters for France II.
> > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
> +k_0=0.99987742
> > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m +no_defs  <>
> >
> > Any ideas ?
> >
> > Francois
> >
> > > -----Message d'origine-----
> > > De : UMN MapServer Users List
> > [mailto:[hidden email]] De la
> > > part de vincent.dacol
> > > Envoyé : mercredi 25 mai 2005 11:40
> > > À : [hidden email]
> > > Objet : [UMN_MAPSERVER-USERS] WMS and reprojection
> > >
> > > Hi everybody,
> > >
> > > I'm a student and I'm disovering the world of Mapserver and
> > > interoperabillity.
> > >
> > > I'm trying to use 2 WMS services in different projections,
> > and one client to
> > > display two layer from that server.
> > >
> > > But the reprojection didn't work in the client. The 2 layer
> > obtain with the
> > > 2 WMS server aren't display in the same projection.
> > >
> > > The projection of my WMS server 1 is "init=epsg:27571"
> > > The projection of my WMS server 2 is "init=epsg:27582"
> > >
> > > This two server can serv :
> > > "wms_srs"      "EPSG:27582 EPSG:27571"
> > >
> > > The projection I want to display with the client is
> > "init=epsg:27582"
> > >
> > > When I use the 2 layers in local, there is no supperposition
> > problem, the
> > > picture obtain was fine, the reprojection work.
> > >
> > > But with the WMS client, the first layer is in it's own
> > projection, and the
> > > second too. So the 2 layer arn't supperposed, it seem there
> > is no
> > > reprojection.
> > >
> > > Is-it a reprojection probleme?
> > >
> > > My opignon is that a single mapfile with multiple
> > connections to different
> > > WMS server must only connect to server who are in the same
> > projection.
> > >
> > > Maybe I'm wrong, I really new to Mapserver, but I have spend
> > a lot of time
> > > one this probleme, and the only solution I have find the
> > solve it is to use
> > > the same output projection in the client and in the WMS
> server.
> > >
> > > But this solution isn't very logical for me. I want to
> > connect to a server
> > > who use is own projection, and can serve data in other
> > predefined EPSG
> > > projection. So a WMS client use a WMS layer has a local
> > layer, with is own
> > > projection output, and is abble to reproject the data obtain
> > in the WMS
> > > layer.
> > >
> > >
> > > Thanks for the help (I really need it).
> > >
> > > Vincent
> > >
> > > Accédez au courrier électronique de La Poste :
> www.laposte.net ;
> > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> > >
> > >
> > >
> > > --
> > > Ce message a ete verifie par MailScanner pour des virus ou
> > des polluriels et
> > > rien de suspect n'a ete trouve.
> > >
> > > Les donnees et renseignements contenus dans ce message sont
> > personnels,
> > > confidentiels et prives. Toute publication, utilisation ou
> > diffusion, meme
> > > partielle, doit etre autorisee.
> > >
> > > Any data and information contained in this electronic mail
> > is personal,
> > > confidential and secret. Any total or partial publication,
> > use or
> > > distribution must be authorized.
> > >
> > > --
> > > Ce message a ete verifie par MailScanner pour des virus ou
> > des polluriels et rien de suspect n'a ete trouve.
> > >
> > > Les donnees et renseignements contenus dans ce message sont
> > personnels, confidentiels et prives. Toute publication,
> utilisation ou
> > diffusion, meme partielle, doit etre autorisee.
> > >
> > > Any data and information contained in this electronic mail
> > is personal, confidential and secret. Any total or partial
> publication, use
> > or distribution must be authorized.
> > >
> > >
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;

> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et
> > rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels,
> > confidentiels et prives. Toute publication, utilisation ou
> diffusion, meme
> > partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal,
> > confidential and secret. Any total or partial publication,
> use or
> > distribution must be authorized.
> >
> >
> > --
> > Ce message a ete verifie par MailScanner pour des virus ou
> des polluriels et rien de suspect n'a ete trouve.
> >
> > Les donnees et renseignements contenus dans ce message sont
> personnels, confidentiels et prives. Toute publication,
utilisation ou diffusion, meme partielle, doit etre autorisee.
> >
> > Any data and information contained in this electronic mail
> is personal, confidential and secret. Any total or partial
publication, use or distribution must be authorized.
> >
>
> Accédez au courrier électronique de La Poste : www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)



=?iso-8859-1?Q?MapServ.jpg?= (24K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

vincent.dacol
In reply to this post by vincent.dacol
Hi Paul,

I think you're right, and my data have good projection coord
with WFS server.


Here is my WMS server's Mapfile :

Server 1 (epsg 27582) :


#############################################################################################################################################################################################################################################################
##MAP########################################################################################################################################################################################################################################################
#############################################################################################################################################################################################################################################################



MAP

NAME France_WFS_L2
EXTENT 47700 1620400 1197900 2677200
IMAGETYPE gif
SIZE 800 600
SHAPEPATH "data"

DEBUG ON

OUTPUTFORMAT
NAME gif
MIMETYPE "image/gif"
DRIVER "GD/GIF"
EXTENSION "gif"
IMAGEMODE PC256
TRANSPARENT TRUE
END

PROJECTION
"init=epsg:27582"
END

#######
##WEB##
#######


WEB
log "./tmp/France_Lambert2.log"
IMAGEPATH
"C:/ms4w/Apache/htdocs/projection/Serveur_France/tmp/"
TEMPLATE 'Donnees_test_WMS_WFS_template.html'
IMAGEURL "http://10.133.110.29/projection/Serveur_France/tmp/"
METADATA
"wfs_title" "France_WFS_test"
"wfs_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_France/France_L2_WFS.map&"
"wfs_schemas_location" "http://ogc.dmsolutions.ca"
"wfs_srs" "epsg:27582"
END

END


#############
##France_L2##
#############


LAYER
NAME "France_L2_WFS"
DATA "France_L2"
STATUS ON
TYPE POLYGON
DUMP TRUE
TEMPLATE "query.html"
TOLERANCE 3
TOLERANCEUNITS PIXELS

METADATA
"wfs_title" "France_L2_WFS"
END

CLASS
COLOR 200 231 193
OUTLINECOLOR 32 32 32
END

END


END



Server 2 (epsg 4326) :


#############################################################################################################################################################################################################################################################
##MAP########################################################################################################################################################################################################################################################
#############################################################################################################################################################################################################################################################



MAP

NAME Europe_WFS_Name
EXTENT -34.5523788 26.2114230 72.2516881 83.340374
#EXTENT -4760555 -1058700 4505870 8245049
IMAGETYPE gif
SIZE 800 600
SHAPEPATH "data"

PROJECTION
"init=epsg:4326"
#"init=epsg:27582" #PROJ L2
END

DEBUG ON

OUTPUTFORMAT
NAME gif
MIMETYPE "image/gif"
DRIVER "GD/GIF"
EXTENSION "gif"
IMAGEMODE PC256
TRANSPARENT TRUE
END




#######
##WEB##
#######


WEB
log "/tmp/Europe_WGS84.log"
IMAGEPATH
"C:/ms4w/Apache/htdocs/projection/Serveur_Europe/tmp/"
TEMPLATE 'Donnees_test_WMS_WFS_template.html'
IMAGEURL "http://10.133.110.29/projection/Serveur_Europe/tmp/"
METADATA
"wfs_title" "Europe_WFS_WEB"
"wfs_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_Europe/Europe_WFS.map&"
"wfs_srs" "epsg:27582"
"wfs_schemas_location" "http://ogc.dmsolutions.ca"
END

END




##########
##Europe##
##########


LAYER
NAME "Europe_WFS"
DATA "Europe_region"
STATUS ON
TYPE POLYGON
DUMP TRUE
TEMPLATE "query.html"
TOLERANCE 3
TOLERANCEUNITS PIXELS

METADATA
"wfs_title" "Europe_WFS"
END

CLASS
COLOR 0 231 193
OUTLINECOLOR 32 32 32
END

END

END



This is my 2 Mapfiles. If I give the same output projection to
my 2 WMS server and my WMS client, all data superimpose with
the right coordinates.

But if it's not the fact, all data are like in the jpeg join
with the mail.

If you see somethink strange, thank you a lot for the help

Vincent





> Hello Vincent,
>
> I did not have a look at the whole thread when I first replied.
> In fact, as Ed suggested, it would be very usefull if you
could post the mapfiles you are using to the list.
> I don't think there is any PROJ.4 related problem (as long
as your projection definitions are correct) but more likely a
> misconfiguration in one of your mapfiles as you wrote that
you can properly display all layers if they are accessed
> locally and referenced in a single mapfile. Am I right?
>
> Paul
>
> -----Original Message-----
> From: UMN MapServer Users List
[mailto:[hidden email]] On Behalf Of vincent.dacol
> Sent: Thursday, May 26, 2005 10:52 AM
> To: [hidden email]
> Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
>
> Thanks for the help and the idea.
>
> I don't know if it is abble to solve my problem, I have try
to decribe the projection like you said, but T don't have
> any change one screen :(
>
> I give you a "impscreen" with a visualisation of my probleme.
> But it seem it's a PROJ4 pb.
>
> A strange think, all work great when I use WFS server with
the same projection as my WMS server. All layer display at
> the right place (except the europe layer who is not display
because he use an other projection unit). Strange isn't

> it???
>
> have a nice day,
>
> Vincent
>
>
>
> > Hello Vincent,
> >
> > I would suggest that you describe the projection in your
> mapfile, at least for debug purposes.
> > If you have a prj file coming e.g. with Arcgis, it is fairly
> easy.
> > Then you avoid using +pm=paris and specify lon_0.
> >
> > For this WKT definition (probably equivalent to a LambertIIE):
> >
>
PROJCS["France_IMAGE2000",GEOGCS["GCS_NTF",DATUM["D_NTF",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenw
> >
>
ich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",600000.0],P
> >
>
ARAMETER["False_Northing",2200000.0],PARAMETER["Central_Meridian",2.337229166666667],PARAMETER["Standard_Parallel_1",45.
> >
>
898919],PARAMETER["Standard_Parallel_2",47.696014],PARAMETER["Latitude_Of_Origin",46.8],UNIT["Meter",1.0]]

> >
> > I am using this projection section in my mapfile:
> >   PROJECTION
> >     "proj=lcc"
> >     "ellps=clrk80"
> >     "lat_1=45.898919"
> >     "lat_2=47.696014"
> >     "lat_0=46.8"
> >     "lon_0=2.337229166666667"
> >     "x_0=600000.0"
> >     "y_0=2200000.0"
> >     "units=m"
> >     "no_defs"
> >   END
> >
> > Also check whether or not you need to use the +towgs84
> parameter...
> >
> > HTH
> > Paul
> >
> > -----Original Message-----
> > From: UMN MapServer Users List
> [mailto:[hidden email]] On Behalf Of
vincent.dacol

> > Sent: Thursday, May 26, 2005 9:17 AM
> > To: [hidden email]
> > Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
> >
> > Hi Francois,
> >
> > I have found what doesn't really work in my WMS server. The
> reprojection really work well now. But the probleme is the
> > (x,y) position the differents layers who are in local French
> epsg projection system. All are not at the right place.
> >
> > I think it's a problem of PROJ4 epsg definition. But I don't
> realy know how solve it.
> >
> > Have you some tips or technique to resolve that sort of
problem?

> >
> > Thank for your help.
> >
> > Vincent
> >
> >
> >
> >
> > > Hi (again) Vincent,
> > >
> > > If you have a look to epsg file contained in proj 4.4.9
> > package :
> > > # NTF (Paris) / Lambert zone II
> > > <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
> > +k_0=0.99987742
> > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
+no_defs  <>
> > > # NTF (Paris) / France II
> > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=-2.33722917
> > +k_0=0.99987742
> > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
+no_defs  <>
> > >
> > > Looks the same ... If you look to Lambert II Etendu (ie.
> > France II)
> > > parameters
> > >
> >
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf

> > > It seems that for Lambert II zone 27572, y_0 should be
> > 200000 and lon_0, 0 ?
> > > And for France II lon_0 should be 0 ! Anyone using French
> > coordinate systems
> > > having the same troubles ?
> > >
> > > I'm currently using these parameters for France II.
> > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
> > +k_0=0.99987742
> > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
+no_defs  <>

> > >
> > > Any ideas ?
> > >
> > > Francois
> > >
> > > > -----Message d'origine-----
> > > > De : UMN MapServer Users List
> > > [mailto:[hidden email]] De la
> > > > part de vincent.dacol
> > > > Envoyé : mercredi 25 mai 2005 11:40 À :
> > > > [hidden email] Objet :
[UMN_MAPSERVER-USERS] WMS
> > > > and reprojection
> > > >
> > > > Hi everybody,
> > > >
> > > > I'm a student and I'm disovering the world of
Mapserver and
> > > > interoperabillity.
> > > >
> > > > I'm trying to use 2 WMS services in different projections,
> > > and one client to
> > > > display two layer from that server.
> > > >
> > > > But the reprojection didn't work in the client. The 2
layer

> > > obtain with the
> > > > 2 WMS server aren't display in the same projection.
> > > >
> > > > The projection of my WMS server 1 is "init=epsg:27571"
> > > > The projection of my WMS server 2 is "init=epsg:27582"
> > > >
> > > > This two server can serv :
> > > > "wms_srs"      "EPSG:27582 EPSG:27571"
> > > >
> > > > The projection I want to display with the client is
> > > "init=epsg:27582"
> > > >
> > > > When I use the 2 layers in local, there is no
supperposition
> > > problem, the
> > > > picture obtain was fine, the reprojection work.
> > > >
> > > > But with the WMS client, the first layer is in it's own
> > > projection, and the
> > > > second too. So the 2 layer arn't supperposed, it seem
there

> > > is no
> > > > reprojection.
> > > >
> > > > Is-it a reprojection probleme?
> > > >
> > > > My opignon is that a single mapfile with multiple
> > > connections to different
> > > > WMS server must only connect to server who are in the same
> > > projection.
> > > >
> > > > Maybe I'm wrong, I really new to Mapserver, but I have
spend

> > > a lot of time
> > > > one this probleme, and the only solution I have find the
> > > solve it is to use
> > > > the same output projection in the client and in the WMS
> > server.
> > > >
> > > > But this solution isn't very logical for me. I want to
> > > connect to a server
> > > > who use is own projection, and can serve data in other
> > > predefined EPSG
> > > > projection. So a WMS client use a WMS layer has a local
> > > layer, with is own
> > > > projection output, and is abble to reproject the data
obtain

> > > in the WMS
> > > > layer.
> > > >
> > > >
> > > > Thanks for the help (I really need it).
> > > >
> > > > Vincent
> > > >
> > > > Accédez au courrier électronique de La Poste :
> > www.laposte.net ;
> > > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50
(0,34€/mn)
> > > >
> > > >
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et
> > > > rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels,
> > > > confidentiels et prives. Toute publication, utilisation ou
> > > diffusion, meme
> > > > partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal,
> > > > confidential and secret. Any total or partial publication,
> > > use or
> > > > distribution must be authorized.
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels, confidentiels et prives. Toute publication,
> > utilisation ou
> > > diffusion, meme partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal, confidential and secret. Any total or partial
> > publication, use
> > > or distribution must be authorized.
> > > >
> > > >
> > >
> > > Accédez au courrier électronique de La Poste :
> www.laposte.net ;
> > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> > >
> > >
> > >
> > >
> > > --
> > > Ce message a ete verifie par MailScanner pour des virus ou
> > des polluriels et
> > > rien de suspect n'a ete trouve.
> > >
> > > Les donnees et renseignements contenus dans ce message sont
> > personnels,
> > > confidentiels et prives. Toute publication, utilisation ou
> > diffusion, meme
> > > partielle, doit etre autorisee.
> > >
> > > Any data and information contained in this electronic mail
> > is personal,
> > > confidential and secret. Any total or partial publication,
> > use or
> > > distribution must be authorized.
> > >
> > >
> > > --
> > > Ce message a ete verifie par MailScanner pour des virus ou
> > des polluriels et rien de suspect n'a ete trouve.
> > >
> > > Les donnees et renseignements contenus dans ce message sont
> > personnels, confidentiels et prives. Toute publication,
> utilisation ou diffusion, meme partielle, doit etre autorisee.
> > >
> > > Any data and information contained in this electronic mail
> > is personal, confidential and secret. Any total or partial
> publication, use or distribution must be authorized.
> > >
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;

> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
>
> Accédez au courrier électronique de La Poste : www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>
>
Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)



=?iso-8859-1?Q?MapServ.jpg?= (24K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

vincent.dacol
In reply to this post by vincent.dacol
OUPS

I work to mutch, and I send you my WFS server file lol. Sorry.
This mapfile work great and all project overlay very well.



Here is my WMS server file, realy that's the good one ;)

server 1:


#############################################################################################################################################################################################################################################################
##MAP########################################################################################################################################################################################################################################################
#############################################################################################################################################################################################################################################################



MAP

  NAME              Europe_WGS84
  EXTENT            -34.5523788 26.2114230 72.2516881 83.340374
  IMAGETYPE         gif
  SIZE              800 600
  SHAPEPATH         "data"

  PROJECTION
    "init=epsg:4326"
  END

  DEBUG ON

  OUTPUTFORMAT
    NAME gif
    MIMETYPE "image/gif"
    DRIVER "GD/GIF"
    EXTENSION "gif"
    IMAGEMODE PC256
    TRANSPARENT TRUE
  END




#######
##WEB##
#######


  WEB
    log "/tmp/Europe_WGS84.log"
    IMAGEPATH "./tmp/"
    TEMPLATE  'Donnees_test_WMS_WFS_template.html'
    IMAGEURL "http://10.133.110.29/projection/Serveur_Europe/tmp/"
    METADATA
        "wms_title"                 "Europe_France_WGS84"
        "wms_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_Europe/Europe.map&"
        "wms_srs"                   "epsg:4326 epsg:27582
epsg:2154 epsg:27571 epsg:27572 epsg:27573 "
    END

  END




##########
##Europe##
##########


  LAYER
    NAME "Europe_WGS84"
    DATA "Europe_region"
    STATUS ON
    TYPE POLYGON
    DUMP TRUE
    TEMPLATE "query.html"
        TOLERANCE 3
        TOLERANCEUNITS PIXELS

    METADATA
        "wms_title"                 "Europe_WGS84"
        #"wms_srs"                   "epsg:27582 epsg:2154
epsg:27571 epsg:27572 epsg:27573 epsg:4326"
    END

    CLASS
        COLOR 0 231 193
        OUTLINECOLOR 32 32 32
    END

    PROJECTION
        #"epsg:4326"
        END

  END

END




Server 2:


#############################################################################################################################################################################################################################################################
##MAP########################################################################################################################################################################################################################################################
#############################################################################################################################################################################################################################################################



MAP

  NAME              Proj_France_L2
  EXTENT            47700 1620400 1197900 2677200
  IMAGETYPE         gif
  SIZE              800 600
  SHAPEPATH         "data"

  DEBUG ON

  OUTPUTFORMAT
    NAME gif
    MIMETYPE "image/gif"
    DRIVER "GD/GIF"
    EXTENSION "gif"
    IMAGEMODE PC256
    TRANSPARENT TRUE
  END


  PROJECTION
        "proj=lcc"
        "ellps=clrk80"
        "lat_1=45.898919"
        "lat_2=47.696014"
        "lat_0=46.8"
        "lon_0=2.337229166666667"
        "x_0=600000.0"
        "y_0=2200000.0"
        "units=m"
        "no_defs"
    #"init=epsg:43
    #"init=epsg:4326"   #PROJ EUROPE
    #"init=epsg:27582"       #PROJ L2
    #"init=epsg:2154"        #PROJ L93
    #"EPSG:27571"       #PROJ LZ1
    #"EPSG:27572"       #PROJ LZ2
    #"EPSG:27573"       #PROJ LZ3
  END

#######
##WEB##
#######


  WEB
    log "/tmp/France_Lambert2.log"
    IMAGEPATH "./tmp/"
    TEMPLATE  'Donnees_test_WMS_WFS_template.html'
    IMAGEURL "http://10.133.110.29/projection/Serveur_France/tmp/"
    METADATA
        "wms_title"                 "Test_France"
        "wms_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Server_France/France_L2.map&"
        "wms_srs"                   "epsg:27582 epsg:4326
epsg:2154 epsg:27571 epsg:27572 epsg:27573"
    END

  END


#############
##France_L2##
#############


  LAYER
    NAME "France_L2"
    DATA "France_L2"
    STATUS ON
    TYPE POLYGON
    DUMP TRUE
    TEMPLATE "query.html"
        TOLERANCE 3
        TOLERANCEUNITS PIXELS

    CLASS
        COLOR 200 231 193
        OUTLINECOLOR 32 32 32
    END

        PROJECTION
                #"init=epsg:4326"   #PROJ EUROPE
                "init=epsg:27582"       #PROJ L2
                #"init=epsg:2154"        #PROJ L93
                #"EPSG:27571"       #PROJ LZ1
                #"EPSG:27572"       #PROJ LZ2
                #"EPSG:27573"       #PROJ LZ3
        END


    METADATA
        "wms_title"                 "France_L2"
        "wms_srs"                   "epsg:27582 epsg:4326
epsg:2154 epsg:27571 epsg:27572 epsg:27573"
    END

  END

END



Sorry for the mistake, and thanks for the help, I'm going
crazy with all that ;)

Vincent


























> Hi Paul,
>
> I think you're right, and my data have good projection coord
> with WFS server.
>
>
> Here is my WMS server's Mapfile :
>
> Server 1 (epsg 27582) :
>
>
>
#############################################################################################################################################################################################################################################################
>
##MAP########################################################################################################################################################################################################################################################
>
#############################################################################################################################################################################################################################################################

>
>
>
> MAP
>
> NAME France_WFS_L2
> EXTENT 47700 1620400 1197900 2677200
> IMAGETYPE gif
> SIZE 800 600
> SHAPEPATH "data"
>
> DEBUG ON
>
> OUTPUTFORMAT
> NAME gif
> MIMETYPE "image/gif"
> DRIVER "GD/GIF"
> EXTENSION "gif"
> IMAGEMODE PC256
> TRANSPARENT TRUE
> END
>
> PROJECTION
> "init=epsg:27582"
> END
>
> #######
> ##WEB##
> #######
>
>
> WEB
> log "./tmp/France_Lambert2.log"
> IMAGEPATH
> "C:/ms4w/Apache/htdocs/projection/Serveur_France/tmp/"
> TEMPLATE 'Donnees_test_WMS_WFS_template.html'
> IMAGEURL "http://10.133.110.29/projection/Serveur_France/tmp/"
> METADATA
> "wfs_title" "France_WFS_test"
> "wfs_onlineresource"
>
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_France/France_L2_WFS.map&"

> "wfs_schemas_location" "http://ogc.dmsolutions.ca"
> "wfs_srs" "epsg:27582"
> END
>
> END
>
>
> #############
> ##France_L2##
> #############
>
>
> LAYER
> NAME "France_L2_WFS"
> DATA "France_L2"
> STATUS ON
> TYPE POLYGON
> DUMP TRUE
> TEMPLATE "query.html"
> TOLERANCE 3
> TOLERANCEUNITS PIXELS
>
> METADATA
> "wfs_title" "France_L2_WFS"
> END
>
> CLASS
> COLOR 200 231 193
> OUTLINECOLOR 32 32 32
> END
>
> END
>
>
> END
>
>
>
> Server 2 (epsg 4326) :
>
>
>
#############################################################################################################################################################################################################################################################
>
##MAP########################################################################################################################################################################################################################################################
>
#############################################################################################################################################################################################################################################################

>
>
>
> MAP
>
> NAME Europe_WFS_Name
> EXTENT -34.5523788 26.2114230 72.2516881 83.340374
> #EXTENT -4760555 -1058700 4505870 8245049
> IMAGETYPE gif
> SIZE 800 600
> SHAPEPATH "data"
>
> PROJECTION
> "init=epsg:4326"
> #"init=epsg:27582" #PROJ L2
> END
>
> DEBUG ON
>
> OUTPUTFORMAT
> NAME gif
> MIMETYPE "image/gif"
> DRIVER "GD/GIF"
> EXTENSION "gif"
> IMAGEMODE PC256
> TRANSPARENT TRUE
> END
>
>
>
>
> #######
> ##WEB##
> #######
>
>
> WEB
> log "/tmp/Europe_WGS84.log"
> IMAGEPATH
> "C:/ms4w/Apache/htdocs/projection/Serveur_Europe/tmp/"
> TEMPLATE 'Donnees_test_WMS_WFS_template.html'
> IMAGEURL "http://10.133.110.29/projection/Serveur_Europe/tmp/"
> METADATA
> "wfs_title" "Europe_WFS_WEB"
> "wfs_onlineresource"
>
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_Europe/Europe_WFS.map&"

> "wfs_srs" "epsg:27582"
> "wfs_schemas_location" "http://ogc.dmsolutions.ca"
> END
>
> END
>
>
>
>
> ##########
> ##Europe##
> ##########
>
>
> LAYER
> NAME "Europe_WFS"
> DATA "Europe_region"
> STATUS ON
> TYPE POLYGON
> DUMP TRUE
> TEMPLATE "query.html"
> TOLERANCE 3
> TOLERANCEUNITS PIXELS
>
> METADATA
> "wfs_title" "Europe_WFS"
> END
>
> CLASS
> COLOR 0 231 193
> OUTLINECOLOR 32 32 32
> END
>
> END
>
> END
>
>
>
> This is my 2 Mapfiles. If I give the same output projection to
> my 2 WMS server and my WMS client, all data superimpose with
> the right coordinates.
>
> But if it's not the fact, all data are like in the jpeg join
> with the mail.
>
> If you see somethink strange, thank you a lot for the help
>
> Vincent
>
>
>
>
>
> > Hello Vincent,
> >
> > I did not have a look at the whole thread when I first
replied.

> > In fact, as Ed suggested, it would be very usefull if you
> could post the mapfiles you are using to the list.
> > I don't think there is any PROJ.4 related problem (as long
> as your projection definitions are correct) but more likely a
> > misconfiguration in one of your mapfiles as you wrote that
> you can properly display all layers if they are accessed
> > locally and referenced in a single mapfile. Am I right?
> >
> > Paul
> >
> > -----Original Message-----
> > From: UMN MapServer Users List
> [mailto:[hidden email]] On Behalf Of
vincent.dacol

> > Sent: Thursday, May 26, 2005 10:52 AM
> > To: [hidden email]
> > Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
> >
> > Thanks for the help and the idea.
> >
> > I don't know if it is abble to solve my problem, I have try
> to decribe the projection like you said, but T don't have
> > any change one screen :(
> >
> > I give you a "impscreen" with a visualisation of my probleme.
> > But it seem it's a PROJ4 pb.
> >
> > A strange think, all work great when I use WFS server with
> the same projection as my WMS server. All layer display at
> > the right place (except the europe layer who is not display
> because he use an other projection unit). Strange isn't
> > it???
> >
> > have a nice day,
> >
> > Vincent
> >
> >
> >
> > > Hello Vincent,
> > >
> > > I would suggest that you describe the projection in your
> > mapfile, at least for debug purposes.
> > > If you have a prj file coming e.g. with Arcgis, it is fairly
> > easy.
> > > Then you avoid using +pm=paris and specify lon_0.
> > >
> > > For this WKT definition (probably equivalent to a
LambertIIE):
> > >
> >
>
PROJCS["France_IMAGE2000",GEOGCS["GCS_NTF",DATUM["D_NTF",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenw
> > >
> >
>
ich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",600000.0],P
> > >
> >
>
ARAMETER["False_Northing",2200000.0],PARAMETER["Central_Meridian",2.337229166666667],PARAMETER["Standard_Parallel_1",45.
> > >
> >
>
898919],PARAMETER["Standard_Parallel_2",47.696014],PARAMETER["Latitude_Of_Origin",46.8],UNIT["Meter",1.0]]

> > >
> > > I am using this projection section in my mapfile:
> > >   PROJECTION
> > >     "proj=lcc"
> > >     "ellps=clrk80"
> > >     "lat_1=45.898919"
> > >     "lat_2=47.696014"
> > >     "lat_0=46.8"
> > >     "lon_0=2.337229166666667"
> > >     "x_0=600000.0"
> > >     "y_0=2200000.0"
> > >     "units=m"
> > >     "no_defs"
> > >   END
> > >
> > > Also check whether or not you need to use the +towgs84
> > parameter...
> > >
> > > HTH
> > > Paul
> > >
> > > -----Original Message-----
> > > From: UMN MapServer Users List
> > [mailto:[hidden email]] On Behalf Of
> vincent.dacol
> > > Sent: Thursday, May 26, 2005 9:17 AM
> > > To: [hidden email]
> > > Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
> > >
> > > Hi Francois,
> > >
> > > I have found what doesn't really work in my WMS server. The
> > reprojection really work well now. But the probleme is the
> > > (x,y) position the differents layers who are in local French
> > epsg projection system. All are not at the right place.
> > >
> > > I think it's a problem of PROJ4 epsg definition. But I don't
> > realy know how solve it.
> > >
> > > Have you some tips or technique to resolve that sort of
> problem?
> > >
> > > Thank for your help.
> > >
> > > Vincent
> > >
> > >
> > >
> > >
> > > > Hi (again) Vincent,
> > > >
> > > > If you have a look to epsg file contained in proj 4.4.9
> > > package :
> > > > # NTF (Paris) / Lambert zone II
> > > > <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8
+lon_0=-2.33722917
> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > > # NTF (Paris) / France II
> > > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8
+lon_0=-2.33722917

> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > >
> > > > Looks the same ... If you look to Lambert II Etendu (ie.
> > > France II)
> > > > parameters
> > > >
> > >
> >
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf

> > > > It seems that for Lambert II zone 27572, y_0 should be
> > > 200000 and lon_0, 0 ?
> > > > And for France II lon_0 should be 0 ! Anyone using French
> > > coordinate systems
> > > > having the same troubles ?
> > > >
> > > > I'm currently using these parameters for France II.
> > > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > >
> > > > Any ideas ?
> > > >
> > > > Francois
> > > >
> > > > > -----Message d'origine-----
> > > > > De : UMN MapServer Users List
> > > > [mailto:[hidden email]] De la
> > > > > part de vincent.dacol
> > > > > Envoyé : mercredi 25 mai 2005 11:40 À :
> > > > > [hidden email] Objet :
> [UMN_MAPSERVER-USERS] WMS
> > > > > and reprojection
> > > > >
> > > > > Hi everybody,
> > > > >
> > > > > I'm a student and I'm disovering the world of
> Mapserver and
> > > > > interoperabillity.
> > > > >
> > > > > I'm trying to use 2 WMS services in different
projections,

> > > > and one client to
> > > > > display two layer from that server.
> > > > >
> > > > > But the reprojection didn't work in the client. The 2
> layer
> > > > obtain with the
> > > > > 2 WMS server aren't display in the same projection.
> > > > >
> > > > > The projection of my WMS server 1 is "init=epsg:27571"
> > > > > The projection of my WMS server 2 is "init=epsg:27582"
> > > > >
> > > > > This two server can serv :
> > > > > "wms_srs"      "EPSG:27582 EPSG:27571"
> > > > >
> > > > > The projection I want to display with the client is
> > > > "init=epsg:27582"
> > > > >
> > > > > When I use the 2 layers in local, there is no
> supperposition
> > > > problem, the
> > > > > picture obtain was fine, the reprojection work.
> > > > >
> > > > > But with the WMS client, the first layer is in it's own
> > > > projection, and the
> > > > > second too. So the 2 layer arn't supperposed, it seem
> there
> > > > is no
> > > > > reprojection.
> > > > >
> > > > > Is-it a reprojection probleme?
> > > > >
> > > > > My opignon is that a single mapfile with multiple
> > > > connections to different
> > > > > WMS server must only connect to server who are in
the same

> > > > projection.
> > > > >
> > > > > Maybe I'm wrong, I really new to Mapserver, but I have
> spend
> > > > a lot of time
> > > > > one this probleme, and the only solution I have find the
> > > > solve it is to use
> > > > > the same output projection in the client and in the WMS
> > > server.
> > > > >
> > > > > But this solution isn't very logical for me. I want to
> > > > connect to a server
> > > > > who use is own projection, and can serve data in other
> > > > predefined EPSG
> > > > > projection. So a WMS client use a WMS layer has a local
> > > > layer, with is own
> > > > > projection output, and is abble to reproject the data
> obtain
> > > > in the WMS
> > > > > layer.
> > > > >
> > > > >
> > > > > Thanks for the help (I really need it).
> > > > >
> > > > > Vincent
> > > > >
> > > > > Accédez au courrier électronique de La Poste :
> > > www.laposte.net ;
> > > > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50
> (0,34€/mn)
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Ce message a ete verifie par MailScanner pour des
virus ou
> > > > des polluriels et
> > > > > rien de suspect n'a ete trouve.
> > > > >
> > > > > Les donnees et renseignements contenus dans ce message
> sont
> > > > personnels,
> > > > > confidentiels et prives. Toute publication,
utilisation ou
> > > > diffusion, meme
> > > > > partielle, doit etre autorisee.
> > > > >
> > > > > Any data and information contained in this
electronic mail
> > > > is personal,
> > > > > confidential and secret. Any total or partial
publication,
> > > > use or
> > > > > distribution must be authorized.
> > > > >
> > > > > --
> > > > > Ce message a ete verifie par MailScanner pour des
virus ou
> > > > des polluriels et rien de suspect n'a ete trouve.
> > > > >
> > > > > Les donnees et renseignements contenus dans ce message
> sont
> > > > personnels, confidentiels et prives. Toute publication,
> > > utilisation ou
> > > > diffusion, meme partielle, doit etre autorisee.
> > > > >
> > > > > Any data and information contained in this
electronic mail
> > > > is personal, confidential and secret. Any total or partial
> > > publication, use
> > > > or distribution must be authorized.
> > > > >
> > > > >
> > > >
> > > > Accédez au courrier électronique de La Poste :
> > www.laposte.net ;
> > > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50
(0,34€/mn)

> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et
> > > > rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels,
> > > > confidentiels et prives. Toute publication, utilisation ou
> > > diffusion, meme
> > > > partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal,
> > > > confidential and secret. Any total or partial publication,
> > > use or
> > > > distribution must be authorized.
> > > >
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels, confidentiels et prives. Toute publication,
> > utilisation ou diffusion, meme partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal, confidential and secret. Any total or partial
> > publication, use or distribution must be authorized.
> > > >
> > >
> > > Accédez au courrier électronique de La Poste :
> www.laposte.net ;
> > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> > >
> > >
> > >
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;
> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
> >
>
> Accédez au courrier électronique de La Poste :
www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)


Reply | Threaded
Open this post in threaded view
|

Re: [UMN_MAPSERVER-USERS] WMS and reprojection

Paul Hasenohr
Hi Vincent,

Some notes and suggestions(?) to solve your problem,

Server1:
Layer Europe:

wms_title is the same as for the map, maybe it is not a good idea (I never tried so maybe I am wrong).
projection of the layer is not defined (should be "init=epsg:xxxx" and not "epsg:xxxx"). Mapserver is then using the one
defined in the PROJECTION section below MAP, is it the correct one?.

Server2:
Note: The projection section directly below MAP does not matter for the wms as it is not an epsg code.
Layer France_L2:
You do not need to specify a wms_srs for a specific layer. It is defined in the projection section of the layer.

If it is not enough, try putting the epsg codes under WEB/wms_srs in the same order or specify only one (obviously the
same epsg code for both mapfiles!). In your WMS client, did you specify in which projection you want the data to be
sent?

As you wrote your WFS mapfiles are working, if what I wrote before is not working, just replace wfs_ with wms_ in your
wfs mapfiles and check if it is working better. (you will need to comment  the wfs_schemas_location lines).


Paul

-----Original Message-----
From: UMN MapServer Users List [mailto:[hidden email]] On Behalf Of vincent.dacol
Sent: Thursday, May 26, 2005 12:08 PM
To: [hidden email]
Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection

OUPS

I work to mutch, and I send you my WFS server file lol. Sorry.
This mapfile work great and all project overlay very well.



Here is my WMS server file, realy that's the good one ;)

server 1:


########################################################################################################################
########################################################################################################################
#############
##MAP###################################################################################################################
########################################################################################################################
#############
########################################################################################################################
########################################################################################################################
#############



MAP

  NAME              Europe_WGS84
  EXTENT            -34.5523788 26.2114230 72.2516881 83.340374
  IMAGETYPE         gif
  SIZE              800 600
  SHAPEPATH         "data"

  PROJECTION
    "init=epsg:4326"
  END

  DEBUG ON

  OUTPUTFORMAT
    NAME gif
    MIMETYPE "image/gif"
    DRIVER "GD/GIF"
    EXTENSION "gif"
    IMAGEMODE PC256
    TRANSPARENT TRUE
  END




#######
##WEB##
#######


  WEB
    log "/tmp/Europe_WGS84.log"
    IMAGEPATH "./tmp/"
    TEMPLATE  'Donnees_test_WMS_WFS_template.html'
    IMAGEURL "http://10.133.110.29/projection/Serveur_Europe/tmp/"
    METADATA
        "wms_title"                 "Europe_France_WGS84"
        "wms_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_Europe/Europe.map&"
        "wms_srs"                   "epsg:4326 epsg:27582
epsg:2154 epsg:27571 epsg:27572 epsg:27573 "
    END

  END




##########
##Europe##
##########


  LAYER
    NAME "Europe_WGS84"
    DATA "Europe_region"
    STATUS ON
    TYPE POLYGON
    DUMP TRUE
    TEMPLATE "query.html"
        TOLERANCE 3
        TOLERANCEUNITS PIXELS

    METADATA
        "wms_title"                 "Europe_WGS84"
        #"wms_srs"                   "epsg:27582 epsg:2154
epsg:27571 epsg:27572 epsg:27573 epsg:4326"
    END

    CLASS
        COLOR 0 231 193
        OUTLINECOLOR 32 32 32
    END

    PROJECTION
        #"epsg:4326"
        END

  END

END




Server 2:


########################################################################################################################
########################################################################################################################
#############
##MAP###################################################################################################################
########################################################################################################################
#############
########################################################################################################################
########################################################################################################################
#############



MAP

  NAME              Proj_France_L2
  EXTENT            47700 1620400 1197900 2677200
  IMAGETYPE         gif
  SIZE              800 600
  SHAPEPATH         "data"

  DEBUG ON

  OUTPUTFORMAT
    NAME gif
    MIMETYPE "image/gif"
    DRIVER "GD/GIF"
    EXTENSION "gif"
    IMAGEMODE PC256
    TRANSPARENT TRUE
  END


  PROJECTION
        "proj=lcc"
        "ellps=clrk80"
        "lat_1=45.898919"
        "lat_2=47.696014"
        "lat_0=46.8"
        "lon_0=2.337229166666667"
        "x_0=600000.0"
        "y_0=2200000.0"
        "units=m"
        "no_defs"
    #"init=epsg:43
    #"init=epsg:4326"   #PROJ EUROPE
    #"init=epsg:27582"       #PROJ L2
    #"init=epsg:2154"        #PROJ L93
    #"EPSG:27571"       #PROJ LZ1
    #"EPSG:27572"       #PROJ LZ2
    #"EPSG:27573"       #PROJ LZ3
  END

#######
##WEB##
#######


  WEB
    log "/tmp/France_Lambert2.log"
    IMAGEPATH "./tmp/"
    TEMPLATE  'Donnees_test_WMS_WFS_template.html'
    IMAGEURL "http://10.133.110.29/projection/Serveur_France/tmp/"
    METADATA
        "wms_title"                 "Test_France"
        "wms_onlineresource"
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Server_France/France_L2.map&"
        "wms_srs"                   "epsg:27582 epsg:4326
epsg:2154 epsg:27571 epsg:27572 epsg:27573"
    END

  END


#############
##France_L2##
#############


  LAYER
    NAME "France_L2"
    DATA "France_L2"
    STATUS ON
    TYPE POLYGON
    DUMP TRUE
    TEMPLATE "query.html"
        TOLERANCE 3
        TOLERANCEUNITS PIXELS

    CLASS
        COLOR 200 231 193
        OUTLINECOLOR 32 32 32
    END

        PROJECTION
                #"init=epsg:4326"   #PROJ EUROPE
                "init=epsg:27582"       #PROJ L2
                #"init=epsg:2154"        #PROJ L93
                #"EPSG:27571"       #PROJ LZ1
                #"EPSG:27572"       #PROJ LZ2
                #"EPSG:27573"       #PROJ LZ3
        END


    METADATA
        "wms_title"                 "France_L2"
        "wms_srs"                   "epsg:27582 epsg:4326
epsg:2154 epsg:27571 epsg:27572 epsg:27573"
    END

  END

END



Sorry for the mistake, and thanks for the help, I'm going crazy with all that ;)

Vincent


























> Hi Paul,
>
> I think you're right, and my data have good projection coord with WFS
> server.
>
>
> Here is my WMS server's Mapfile :
>
> Server 1 (epsg 27582) :
>
>
>
########################################################################################################################
########################################################################################################################
#############
>
##MAP###################################################################################################################
########################################################################################################################
#############
>
########################################################################################################################
########################################################################################################################
#############

>
>
>
> MAP
>
> NAME France_WFS_L2
> EXTENT 47700 1620400 1197900 2677200
> IMAGETYPE gif
> SIZE 800 600
> SHAPEPATH "data"
>
> DEBUG ON
>
> OUTPUTFORMAT
> NAME gif
> MIMETYPE "image/gif"
> DRIVER "GD/GIF"
> EXTENSION "gif"
> IMAGEMODE PC256
> TRANSPARENT TRUE
> END
>
> PROJECTION
> "init=epsg:27582"
> END
>
> #######
> ##WEB##
> #######
>
>
> WEB
> log "./tmp/France_Lambert2.log"
> IMAGEPATH
> "C:/ms4w/Apache/htdocs/projection/Serveur_France/tmp/"
> TEMPLATE 'Donnees_test_WMS_WFS_template.html'
> IMAGEURL "http://10.133.110.29/projection/Serveur_France/tmp/"
> METADATA
> "wfs_title" "France_WFS_test"
> "wfs_onlineresource"
>
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_France/France_L2_WFS.map&"

> "wfs_schemas_location" "http://ogc.dmsolutions.ca"
> "wfs_srs" "epsg:27582"
> END
>
> END
>
>
> #############
> ##France_L2##
> #############
>
>
> LAYER
> NAME "France_L2_WFS"
> DATA "France_L2"
> STATUS ON
> TYPE POLYGON
> DUMP TRUE
> TEMPLATE "query.html"
> TOLERANCE 3
> TOLERANCEUNITS PIXELS
>
> METADATA
> "wfs_title" "France_L2_WFS"
> END
>
> CLASS
> COLOR 200 231 193
> OUTLINECOLOR 32 32 32
> END
>
> END
>
>
> END
>
>
>
> Server 2 (epsg 4326) :
>
>
>
########################################################################################################################
########################################################################################################################
#############
>
##MAP###################################################################################################################
########################################################################################################################
#############
>
########################################################################################################################
########################################################################################################################
#############

>
>
>
> MAP
>
> NAME Europe_WFS_Name
> EXTENT -34.5523788 26.2114230 72.2516881 83.340374 #EXTENT -4760555
> -1058700 4505870 8245049 IMAGETYPE gif SIZE 800 600 SHAPEPATH "data"
>
> PROJECTION
> "init=epsg:4326"
> #"init=epsg:27582" #PROJ L2
> END
>
> DEBUG ON
>
> OUTPUTFORMAT
> NAME gif
> MIMETYPE "image/gif"
> DRIVER "GD/GIF"
> EXTENSION "gif"
> IMAGEMODE PC256
> TRANSPARENT TRUE
> END
>
>
>
>
> #######
> ##WEB##
> #######
>
>
> WEB
> log "/tmp/Europe_WGS84.log"
> IMAGEPATH
> "C:/ms4w/Apache/htdocs/projection/Serveur_Europe/tmp/"
> TEMPLATE 'Donnees_test_WMS_WFS_template.html'
> IMAGEURL "http://10.133.110.29/projection/Serveur_Europe/tmp/"
> METADATA
> "wfs_title" "Europe_WFS_WEB"
> "wfs_onlineresource"
>
"http://10.133.110.29/cgi-bin/mapserv.exe?map=C:/ms4w/Apache/htdocs/projection/Serveur_Europe/Europe_WFS.map&"

> "wfs_srs" "epsg:27582"
> "wfs_schemas_location" "http://ogc.dmsolutions.ca"
> END
>
> END
>
>
>
>
> ##########
> ##Europe##
> ##########
>
>
> LAYER
> NAME "Europe_WFS"
> DATA "Europe_region"
> STATUS ON
> TYPE POLYGON
> DUMP TRUE
> TEMPLATE "query.html"
> TOLERANCE 3
> TOLERANCEUNITS PIXELS
>
> METADATA
> "wfs_title" "Europe_WFS"
> END
>
> CLASS
> COLOR 0 231 193
> OUTLINECOLOR 32 32 32
> END
>
> END
>
> END
>
>
>
> This is my 2 Mapfiles. If I give the same output projection to my 2
> WMS server and my WMS client, all data superimpose with the right
> coordinates.
>
> But if it's not the fact, all data are like in the jpeg join with the
> mail.
>
> If you see somethink strange, thank you a lot for the help
>
> Vincent
>
>
>
>
>
> > Hello Vincent,
> >
> > I did not have a look at the whole thread when I first
replied.

> > In fact, as Ed suggested, it would be very usefull if you
> could post the mapfiles you are using to the list.
> > I don't think there is any PROJ.4 related problem (as long
> as your projection definitions are correct) but more likely a
> > misconfiguration in one of your mapfiles as you wrote that
> you can properly display all layers if they are accessed
> > locally and referenced in a single mapfile. Am I right?
> >
> > Paul
> >
> > -----Original Message-----
> > From: UMN MapServer Users List
> [mailto:[hidden email]] On Behalf Of
vincent.dacol

> > Sent: Thursday, May 26, 2005 10:52 AM
> > To: [hidden email]
> > Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
> >
> > Thanks for the help and the idea.
> >
> > I don't know if it is abble to solve my problem, I have try
> to decribe the projection like you said, but T don't have
> > any change one screen :(
> >
> > I give you a "impscreen" with a visualisation of my probleme.
> > But it seem it's a PROJ4 pb.
> >
> > A strange think, all work great when I use WFS server with
> the same projection as my WMS server. All layer display at
> > the right place (except the europe layer who is not display
> because he use an other projection unit). Strange isn't
> > it???
> >
> > have a nice day,
> >
> > Vincent
> >
> >
> >
> > > Hello Vincent,
> > >
> > > I would suggest that you describe the projection in your
> > mapfile, at least for debug purposes.
> > > If you have a prj file coming e.g. with Arcgis, it is fairly
> > easy.
> > > Then you avoid using +pm=paris and specify lon_0.
> > >
> > > For this WKT definition (probably equivalent to a
LambertIIE):
> > >
> >
>
PROJCS["France_IMAGE2000",GEOGCS["GCS_NTF",DATUM["D_NTF",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenw
> > >
> >
>
ich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",600000.0],P
> > >
> >
>
ARAMETER["False_Northing",2200000.0],PARAMETER["Central_Meridian",2.337229166666667],PARAMETER["Standard_Parallel_1",45.
> > >
> >
>
898919],PARAMETER["Standard_Parallel_2",47.696014],PARAMETER["Latitude_Of_Origin",46.8],UNIT["Meter",1.0]]

> > >
> > > I am using this projection section in my mapfile:
> > >   PROJECTION
> > >     "proj=lcc"
> > >     "ellps=clrk80"
> > >     "lat_1=45.898919"
> > >     "lat_2=47.696014"
> > >     "lat_0=46.8"
> > >     "lon_0=2.337229166666667"
> > >     "x_0=600000.0"
> > >     "y_0=2200000.0"
> > >     "units=m"
> > >     "no_defs"
> > >   END
> > >
> > > Also check whether or not you need to use the +towgs84
> > parameter...
> > >
> > > HTH
> > > Paul
> > >
> > > -----Original Message-----
> > > From: UMN MapServer Users List
> > [mailto:[hidden email]] On Behalf Of
> vincent.dacol
> > > Sent: Thursday, May 26, 2005 9:17 AM
> > > To: [hidden email]
> > > Subject: Re: [UMN_MAPSERVER-USERS] WMS and reprojection
> > >
> > > Hi Francois,
> > >
> > > I have found what doesn't really work in my WMS server. The
> > reprojection really work well now. But the probleme is the
> > > (x,y) position the differents layers who are in local French
> > epsg projection system. All are not at the right place.
> > >
> > > I think it's a problem of PROJ4 epsg definition. But I don't
> > realy know how solve it.
> > >
> > > Have you some tips or technique to resolve that sort of
> problem?
> > >
> > > Thank for your help.
> > >
> > > Vincent
> > >
> > >
> > >
> > >
> > > > Hi (again) Vincent,
> > > >
> > > > If you have a look to epsg file contained in proj 4.4.9
> > > package :
> > > > # NTF (Paris) / Lambert zone II
> > > > <27572> +proj=lcc +lat_1=46.8 +lat_0=46.8
+lon_0=-2.33722917
> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > > # NTF (Paris) / France II
> > > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8
+lon_0=-2.33722917

> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > >
> > > > Looks the same ... If you look to Lambert II Etendu (ie.
> > > France II)
> > > > parameters
> > > >
> > >
> >
>
http://www.ign.fr/telechargement/education/fiches/geodesie/projections.pdf

> > > > It seems that for Lambert II zone 27572, y_0 should be
> > > 200000 and lon_0, 0 ?
> > > > And for France II lon_0 should be 0 ! Anyone using French
> > > coordinate systems
> > > > having the same troubles ?
> > > >
> > > > I'm currently using these parameters for France II.
> > > > <27582> +proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=0
> > > +k_0=0.99987742
> > > > +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356515
> > > > +towgs84=-168,-60,320,0,0,0,0 +pm=paris +units=m
> +no_defs  <>
> > > >
> > > > Any ideas ?
> > > >
> > > > Francois
> > > >
> > > > > -----Message d'origine-----
> > > > > De : UMN MapServer Users List
> > > > [mailto:[hidden email]] De la
> > > > > part de vincent.dacol
> > > > > Envoyé : mercredi 25 mai 2005 11:40 À :
> > > > > [hidden email] Objet :
> [UMN_MAPSERVER-USERS] WMS
> > > > > and reprojection
> > > > >
> > > > > Hi everybody,
> > > > >
> > > > > I'm a student and I'm disovering the world of
> Mapserver and
> > > > > interoperabillity.
> > > > >
> > > > > I'm trying to use 2 WMS services in different
projections,

> > > > and one client to
> > > > > display two layer from that server.
> > > > >
> > > > > But the reprojection didn't work in the client. The 2
> layer
> > > > obtain with the
> > > > > 2 WMS server aren't display in the same projection.
> > > > >
> > > > > The projection of my WMS server 1 is "init=epsg:27571"
> > > > > The projection of my WMS server 2 is "init=epsg:27582"
> > > > >
> > > > > This two server can serv :
> > > > > "wms_srs"      "EPSG:27582 EPSG:27571"
> > > > >
> > > > > The projection I want to display with the client is
> > > > "init=epsg:27582"
> > > > >
> > > > > When I use the 2 layers in local, there is no
> supperposition
> > > > problem, the
> > > > > picture obtain was fine, the reprojection work.
> > > > >
> > > > > But with the WMS client, the first layer is in it's own
> > > > projection, and the
> > > > > second too. So the 2 layer arn't supperposed, it seem
> there
> > > > is no
> > > > > reprojection.
> > > > >
> > > > > Is-it a reprojection probleme?
> > > > >
> > > > > My opignon is that a single mapfile with multiple
> > > > connections to different
> > > > > WMS server must only connect to server who are in
the same

> > > > projection.
> > > > >
> > > > > Maybe I'm wrong, I really new to Mapserver, but I have
> spend
> > > > a lot of time
> > > > > one this probleme, and the only solution I have find the
> > > > solve it is to use
> > > > > the same output projection in the client and in the WMS
> > > server.
> > > > >
> > > > > But this solution isn't very logical for me. I want to
> > > > connect to a server
> > > > > who use is own projection, and can serve data in other
> > > > predefined EPSG
> > > > > projection. So a WMS client use a WMS layer has a local
> > > > layer, with is own
> > > > > projection output, and is abble to reproject the data
> obtain
> > > > in the WMS
> > > > > layer.
> > > > >
> > > > >
> > > > > Thanks for the help (I really need it).
> > > > >
> > > > > Vincent
> > > > >
> > > > > Accédez au courrier électronique de La Poste :
> > > www.laposte.net ;
> > > > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50
> (0,34€/mn)
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Ce message a ete verifie par MailScanner pour des
virus ou
> > > > des polluriels et
> > > > > rien de suspect n'a ete trouve.
> > > > >
> > > > > Les donnees et renseignements contenus dans ce message
> sont
> > > > personnels,
> > > > > confidentiels et prives. Toute publication,
utilisation ou
> > > > diffusion, meme
> > > > > partielle, doit etre autorisee.
> > > > >
> > > > > Any data and information contained in this
electronic mail
> > > > is personal,
> > > > > confidential and secret. Any total or partial
publication,
> > > > use or
> > > > > distribution must be authorized.
> > > > >
> > > > > --
> > > > > Ce message a ete verifie par MailScanner pour des
virus ou
> > > > des polluriels et rien de suspect n'a ete trouve.
> > > > >
> > > > > Les donnees et renseignements contenus dans ce message
> sont
> > > > personnels, confidentiels et prives. Toute publication,
> > > utilisation ou
> > > > diffusion, meme partielle, doit etre autorisee.
> > > > >
> > > > > Any data and information contained in this
electronic mail
> > > > is personal, confidential and secret. Any total or partial
> > > publication, use
> > > > or distribution must be authorized.
> > > > >
> > > > >
> > > >
> > > > Accédez au courrier électronique de La Poste :
> > www.laposte.net ;
> > > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50
(0,34€/mn)

> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et
> > > > rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels,
> > > > confidentiels et prives. Toute publication, utilisation ou
> > > diffusion, meme
> > > > partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal,
> > > > confidential and secret. Any total or partial publication,
> > > use or
> > > > distribution must be authorized.
> > > >
> > > >
> > > > --
> > > > Ce message a ete verifie par MailScanner pour des virus ou
> > > des polluriels et rien de suspect n'a ete trouve.
> > > >
> > > > Les donnees et renseignements contenus dans ce message
sont

> > > personnels, confidentiels et prives. Toute publication,
> > utilisation ou diffusion, meme partielle, doit etre autorisee.
> > > >
> > > > Any data and information contained in this electronic mail
> > > is personal, confidential and secret. Any total or partial
> > publication, use or distribution must be authorized.
> > > >
> > >
> > > Accédez au courrier électronique de La Poste :
> www.laposte.net ;
> > > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> > >
> > >
> > >
> >
> > Accédez au courrier électronique de La Poste :
www.laposte.net ;
> > 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
> >
> >
> >
> >
>
> Accédez au courrier électronique de La Poste :
www.laposte.net ;
> 3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)
>
>
>

Accédez au courrier électronique de La Poste : www.laposte.net ;
3615 LAPOSTENET (0,34€/mn) ; tél : 08 92 68 13 50 (0,34€/mn)