navit-project.org
http://forum.navit-project.org/

Snail mode
http://forum.navit-project.org/viewtopic.php?f=16&t=457
Page 1 of 1

Author:  MrEd [ 29 Oct 2013, 08:47 ]
Post subject:  Snail mode

Hello,

I'm totally new in Navit and I'd like to add a feature. My purpose is to add a trace, following cursor position when moving, with an external (possibly changing) color. Of course, map scaling will affect the draw. There are a lot of application for this feature, mine is the availability of phone network.

Hope someone will be able to let me know the best way to realize the task.
A plugin seems good way, but I didn't seen how to be called when moving or rescale.

Regards,
Ed

Author:  Mapmapper [ 29 Oct 2013, 11:25 ]
Post subject:  Re: Snail mode

Only to show the way (not a snail with constant length):
For Android: This you need to change in config-file navit.xml of Navit (track is the Keyword):

Code:
<layer name="Internal">
<itemgra item_types="track" order="7-">
   <polyline color="#3f3f3f" width="3"/>
</itemgra>


Its there, you only need to change color. Perhaps track_tracked after this has to do with it, too.
Then to store your way in navit.xml:

Code:
<log enabled="yes" type="textfile" attr_types="position_time_iso8601,position_direction,position_speed,profilename,position_radius" data="/sdcard/navit/logs/track_%Y%m%d-%%i_nav.txt" flush_size="1000" flush_time="30"/>


The line before on this position:


Code:
<vehicle name="Local GPS" profilename="bike" enabled="yes" active="1" source="android:" follow="1">
(here in between)
</vehicle>


Perhaps profilename is car, not bike. Its the standard-vehicle for routing.
To show the stored way (save and show simultaneous)

Code:
<mapset enabled="yes">
   <maps type="binfile" enabled="yes" data="/sdcard/navit/*.bin"/>
   <maps type="textfile" enabled="yes" data="/sdcard/navit/logs/*.txt"/>
</mapset>

Author:  Developerx [ 10 Mar 2017, 20:42 ]
Post subject:  Re: Snail mode

Hello,

I use all these recomendations, but tracks displayed after restart Navit only.
I need that tracks draws in realtime, if it possible. Maybe via plugin or navit.xml?

Regards, Yuriy.

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/