[Oskari-user] Lat/long between Oskari Demo and RPC Examples

Mäkinen Sami (MML) sami.makinen at maanmittauslaitos.fi
Tue Dec 10 05:23:17 PST 2019


Hi,

The RPC example in https://oskari.org/examples/rpc-api/rpc_example.html uses a map published from paikkatietoikkuna.fi. That map uses the EPSG:3067 projection. If you publish a map from demo.oskari.org with the world view you will get a map using EPSG:3857 projection. That is why you see different kind of coordinates in these two instances. You can check the map projection in an RPC app by calling:

channel.getInfo(function (info) {
    console.log(info);
});

You should see something like this in the developer console: {version: "1.54.0", clientSupported: true, srs: "EPSG:3067"}. If you want to push features to the map you should transform the coordinates to the projection referenced in srs.

Best regards,
     Sami

-----Alkuperäinen viesti-----
Lähettäjä: Oskari-user <oskari-user-bounces at lists.osgeo.org> Puolesta Lasse Kulmala
Lähetetty: tiistai 10. joulukuuta 2019 13.50
Vastaanottaja: Oskari-user at lists.osgeo.org
Aihe: [Oskari-user] Lat/long between Oskari Demo and RPC Examples

Hello

I was going through Oskari RPC events and Oskari Demo and noticed that the lat/long returned by MapClickEvent does not match correct coordinates in Oskari Demo, e.g. RPC example returns nonsensical lat/long coordinates. Demo Oskari returns correct search results so is the problem with the RPC Example dataset or is there some other reason. 
I have a excisting set of lat/long points that need to be used if the project I'm consulting changes to Oskari from Google Maps but I need to know it the points are usable as is or does the RPC API require some sort of conversion.

_______________________________________________
Oskari-user mailing list
Oskari-user at lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/oskari-user


More information about the Oskari-user mailing list