itinero / routing

The routing core of itinero.
Apache License 2.0
222 stars 71 forks source link

What is the common PCL profile version for Itinero + Mapsui + OsmSharp? #83

Closed alexshikov closed 7 years ago

alexshikov commented 7 years ago

I'm trying to install Itinero + Mapsui + OsmSharp NuGet packages into Xamarin's PCL project.

After unsuccessful try of using Profile49, I've switched to Profile111 to be able to install Mapsui. But now I can install neither Itinero nor OsmSharp with error:

Could not install package 'Itinero 0.39.2-rc1'. You are trying to install this package into a project that targets '.NETPortable,Version=v4.5,Profile=Profile111', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.

What is PCL profile version should be used?

Not sure if it has any influence but I'm using Visual Studio for Mac.

xivk commented 7 years ago

Hmm, not sure, I think OsmSharp & Itinero both support 147. I haven't talked to the author of Mapsui yet about this (ping @pauldendulk )

alexshikov commented 7 years ago

@xivk it would be really useful to see any example of how it works together. Right now I'm trying to update one old project that based on OsmSharp.UI, OsmSharp.Routing and RoutingInterpreter with latest commits at May of 2016. And it looks like a decent piece of work to make a transition for a new stack.

xivk commented 7 years ago

I have been talking to @pauldendulk about making a sample project putting Itinero and Mapsui together but we haven't gotten around to it yet.

Any more information about what you are doing? Because there has been some functionality that was removed since OsmSharp.UI. For example offline vector rendering is not yet possible with Mapsui if I'm not mistaken.

pauldendulk commented 7 years ago

Mapsui is Profile 111. It should be possible to add profile 147 package to Mapsui.

Mapsui does not implement vector tile rendering yet but it would not be very hard to implement (but does not have the highest priority).

alexshikov commented 7 years ago

Profile147 is based on .NET 4.0 which going to be a problem when adding other libraries. Are there any problems to support Profile111 for OsmSharp and Itinero? Profile111 seems default when creating PCL from Xamarin Studio.

As for vector tile rendering, I'm not sure we are using it.

The project I'm trying to refresh is the one @JoeCooper worked for are few years, he has made some contribution to OsmSharp and OsmSharp.UI : )

pauldendulk commented 7 years ago

Profile147 is based on .NET 4.0 which going to be a problem when adding other libraries.

Why is this a problem for your project. You could create a 4.6 project and add a Profile147 PCL to it. It is compatible for .NET 4.0 and up.

xivk commented 7 years ago

Yes, as far as I know, @pauldendulk is correct. If even think it should be possible to remove the custom builds for PCL's because of:

https://blog.xamarin.com/net-standard-library-support-for-xamarin/

alexshikov commented 7 years ago

@pauldendulk first of all, I'll go and read about PCL and .NETStandard a bit more...

Secondary, Profile44 perfectly matched all required libraries: Itinero, OsmSharp, Mapsui, MvvmCross, sqlite-net-pcl, and more.

Thanks, guys! It's time to make an actual migration now : )

alexshikov commented 7 years ago

Any chance you can give a few hints where I can start to look for types/libraries migration?

For example, once there were the next types:

OsmSharp.Math.Geo.GeoCoordinate // Show we use now GeoAPI.Geometries.Coordinate or Itinero.LocalGeo.Coordinate ?
OsmSharp.Math.Geo.GeoCoordinateBox
OsmSharp.Math.Geo.GeoCoordinateWithHeading
OsmSharp.Routing.RouteTracker // Should we just learn more about Itinero router?

@xivk please, let me know where is the best place to ask these questions? Skype, email, github issues?

xivk commented 7 years ago

Use the form below to get in touch, I can email, is faster:

http://www.itinero.tech/

alexshikov commented 7 years ago

Awesome, thank you guys!