logo separator

[mkgmap-dev] Don't let action rule execute its actions if its type isn't going to be used

From Felix Hartmann extremecarver at googlemail.com on Sun Nov 29 22:24:07 GMT 2009

2009/11/29 Mark Burton <markb at ordern.com>

>
> Felix,
>
> Please try this new patch to trunk. Don't use any other of my recent
> style patches as it contains all the current stuff.
>
> This now suppresses action execution when looking for further matches.
> If you want the actions to be executed anyway, add 'with_actions' (or
> 'withactions', both are recognised).
>
> Also, there is a subtle change in the logic in that now if an action
> rule matches but otherwise would be ignored because it's not the first
> time through, resolveType() will return null so that if the action rule
> is part of a sequence (which it almost certainly is) then the rule
> munging engine will go on to look at the next rule in the sequence.
>
> Without that change, I think it would always choose the first rule in
> cases like this:
>
> foo=bah { tag=val1 } [0x01 continue]
>
> foo=bah { tag=val2 } [0x02 stop]
>
Yeah , this allways took a lot of smart thought to be circumvented! Now I
will have to look through my lists to remove the workarounds that I have
done to accomodate.

>
> Anyway, see what happens.
>
> Mark
>
Overall: Great it's the first time the patch actually seems to work as
expected (as expected when looking at the result with gpsmapedit).
Inside Mapsource it works 100% when not starting or ending on the street
that is oneway. So if you have to route over such a stretch - it will work
as expected - with different speeds depending on the dircection of travel.
This is the greatest feature we have since routing was
introduced!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Only if you start or end the route against the oneway of the way on the top,
it might end up to route to one end of the street, and then run the opposite
direction back. This is no major concern to me at all and probably simply
caused by the fact that if you click somewhere it always chooses the top
road, and there are no interchanging nodes so it has to route to the end of
the street to change to the street that lies below.

-- I did not notice any drawbacks using this patch, and it makes the
"continue" command much more useful. Now we really have a unique feature.
(and I have a lot of work thinking about all the great stuff I can use this
for to improve routing)

 I think you can safely commit this!

(for anyone wanting to use this like me for different speed depending of
direction, now having the slower way with oneway=no also works great, I'll
play around a bit to see whether two opposing oneways, or one fast oneway
and slow way "without direction" works better).

>
> _______________________________________________
> mkgmap-dev mailing list
> mkgmap-dev at lists.mkgmap.org.uk
> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20091129/f797b8c4/attachment.html 


More information about the mkgmap-dev mailing list