[MAPSERVER-USERS] cs2cs problems

CARLA FERNANDEZ carla.fernandezb at gmail.com
Tue Mar 18 05:14:37 PDT 2008


Hi Jukka,

Thanks very much for your interest!! and sorry for the conflicting
information...

I explain you, I have all my layers in epsg:23030, and I don't want to
reproject them. However, I want to set my WMS in WGS84-epsg:4326 (not
ETRS89-epsg:4230, sorry), so that I can load my WMS in Google-Earth without
the difference that it has (almost 130 meters) because of the differents
reference systems...It seems like MapServer ignores the projection settings
in the map section!! (because I set WGS84, like GoogleEarth)

And googleing I've read that I can use the cs2cs in the projection object
(map section), but I get this error:
msProcessProjection(): Projection library error. projection not named

I've tried several combinations, but nothing works...

PROJECTION
 #"cs2cs +from +proj=utm +zone=30 +ellps=intl +units=m +no_defs no_defs +to
+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs no_defs"
 "cs2cs +from +init=epsg:23030 +to +init=epsg:4326"
 #"init=epsg:4326"
END



Thanks!!

2008/3/18, Rahkonen Jukka <Jukka.Rahkonen at mmmtike.fi>:
>
>  Hi Carla,
>
> Please remember to use "reply to all" in order to send your message for
> the mailing list as well.
>
>  I hope I understand this  correctly. So your original data (the
> shapefile) is in epsg:23030? Then you should have in mapfile, in
> corresponding LAYER section
> PROJECTION
> "init=epsg:23030"
> END
>
> Next, because you are willing to deliver that layer through WMS in
> epsg:4230, it is good to add this to layer METADATA as
> "wms_srs"    "EPSG:4230"
>
> By looking at my old mapfiles wms_srs metadata seems not to be compulsory
> if WMS service will only be used in one output projection which is the same
> as the main MAP projection.  Anyway I believe it would be good habbit to
> have it.
>
> Third, you should give the default output projection in MAP section as
> PROJECTION
>     "init=epsg:4230"
> END
>
> And last calculate the bounding box containing your data in the mapfile
> projection (epsg:4230) and feel in the values as EXTENT of the map object.
>
> I try to read your messages once again faithfully and I feel you are
> giving a bit conflicting information. In one place you say you are willing
> to publish your data in ETRS89, wich I believe to mean epsg:4258.  If this
> is the case then insert that value to "wms_srs" and mapfile projection
> instead of 4230.  Why do you play at all with epsg:4230 if your data are not
> using it, and you don't want to any output in that projection either?
> Perhaps I have just not understood what you are aiming at, but I hope you
> will have luck with it.
>
> -Jukka Rahkonen-
>
>
>
>  ------------------------------
> *Lähettäjä:* CARLA FERNANDEZ [mailto:carla.fernandezb at gmail.com]
> *Lähetetty:* 18. maaliskuuta 2008 11:50
> *Vastaanottaja:* Rahkonen Jukka
> *Aihe:* Re: [MAPSERVER-USERS] cs2cs problems
>
> Thanks four your answer,
>
> I've defined projections in my WMS before without problems. In this case I
> want to change the projection of my WMS (to ETRS89) with the layers in ED50,
> but if I just set the projection of the header's mapfile like ETRS89, and I
> leave the  layers' projections like ED50, it doesn't work :(
>
>
> Do you have any idea of how can I use the cs2cs??
>
> Thanks!!
>
>
>
>
>
> 2008/3/17, Rahkonen Jukka <Jukka.Rahkonen at mmmtike.fi>:
> >
> > Hi,
> >
> > I you want to define projections in mapfile then there are two
> > alternatives:
> > either give the espg code:
> >
> > PROJECTION
> >           "init=epsg:2393"
> > END
> >
> > or proj4 strings:
> >
> > PROJECTION
> > "+proj=tmerc +lat_0=0 +lon_0=27 +k=1.000000 +x_0=3500000
> > +y_0=0 +ellps=intl +towgs84=-90.7,-106.1,-119.2,4.09,0.218,-1.05,1.37
> > +units=m +no_defs"
> > END
> >
> > But perhaps you are aiming at something else by using cs2cs?
> >
> > -Jukka Rahkonen-
> >
> > -----Alkuperäinen viesti-----
> > Lähettäjä: mapserver-users-bounces at lists.osgeo.org puolesta: cfb
> > Lähetetty: ma 17.3.2008 15:49
> > Vastaanottaja: mapserver-users at lists.osgeo.org
> > Aihe: [MAPSERVER-USERS] cs2cs problems
> >
> >
> >
> > Hi,
> >
> > I'm having problems with the projection again. I've got a shape in
> > epsg:23030 (ED50 UTM 30N), but I want to set my service in epsg:4230
> > (ETRS89). I've changed the extent, the "wms_boundingbox" and the
> > "wms_latlonboundingbox" of my header's mapfile to geographic coordinates
> > (epsg:4230 for ED50), and in the projection object (always in the
> > header, in
> > the layer object I leave epsg:23030) I put:
> >
> > PROJECTION
> >    'cs2cs +from +init=epsg:4230 +to +proj=4258 +no_defs +no_defs
> > +no_defs
> > +no_defs +ellps=GRS80 +datum=ETRS89 +no_defs +units=m'
> > END http://www.nabble.com/file/p16092875/epsg epsg
> >
> > For the second reference system, I've also tried with "+proj=longlat"
> > and
> > with "+init=epsg:4258", but I get always the same error:
> >
> > msProcessProjection(): Projection library error. projection not named
> >
> > The epsg file of my proj4 is attached (ms4w v. 2.2.7, MapServer 5.0.2)
> >
> > Thanks in advance!!
> >
> >
> > --
> > View this message in context:
> > http://www.nabble.com/cs2cs-problems-tp16092875p16092875.html
> > Sent from the Mapserver - User mailing list archive at Nabble.com<http://nabble.com/>
> > .
> >
> > _______________________________________________
> > mapserver-users mailing list
> > mapserver-users at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
> >
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20080318/5f87ecca/attachment.htm>


More information about the MapServer-users mailing list