1 (edited by jon 2020-03-11 15:54:20)

Topic: Huge Route Lines

Hi I have KML file for a coastal path route in the UK, the dataset is quite large but split into 30 parts.
I parse the coordinates and generate  a series of Vector2 Arrays for each part then:-

OnlineMapsDrawingLine NewRoute = new OnlineMapsDrawingLine(RouteVector2Array, RouteColor, lineWidth);
OnlineMapsDrawingElementManager.AddItem(NewRoute); 

This works ok on a pc/mac but slightly slower, on mobile the whole app crawls very slowly.

Any suggestions? It's interesting that traffic seems to work fine, which can't be less data that i'm trying to overlay? Although I  understand that traffic is raster tile data so handles better. My problem is although I could generate an overlay tileset in a similar fashion to traffic, I need to plot/show part of the routes that have been used/walked/travelled on, thus will need to draw copious amounts of lines or routes.

Re: Huge Route Lines

Hello.

Rasterize your line, split it into tiles, and use as overlay.
Traffic works the same way.

To automate generation of overlay tiles, you can use Online Maps API.
http://infinity-code.com/doxygen/online … 46da6a6a42

Kind Regards,
Infinity Code Team.

Do not know the best way to thank the developer? Rate the asset in Asset Store!

Re: Huge Route Lines

Thanks Alex, I'll take a look at the tile solution. I will still need something longer term that will fill in the routes completed, so I'll contact back if I come up with anything useful.

Re: Huge Route Lines

Hello,

Sorry to hijack the thread.
Are there any examples to show how to rasterize, split into tiles then use as a overlay?

Re: Huge Route Lines

Hello.

Within 24 hours I will make and publish an example of how to rasterize drawing elements.
Follow the news on the site.

Kind Regards,
Infinity Code Team.

Do not know the best way to thank the developer? Rate the asset in Asset Store!

Re: Huge Route Lines

Example:
https://forum.infinity-code.com/viewtopic.php?id=1478

Kind Regards,
Infinity Code Team.

Do not know the best way to thank the developer? Rate the asset in Asset Store!