20,741
edits
Line 42: | Line 42: | ||
=== Flightplan access via Scripting === | === Flightplan access via Scripting === | ||
James has improved the "flightplan()" extension function of the [[Nasal]] scripting interpreter | In advance of converting the Map and NavDisplay to use the [[Canvas]], James has improved the "flightplan()" extension function of the [[Nasal]] scripting interpreter to expose the full route-path vector for each flight plan leg, as a vector on the leg . | ||
<syntaxhighlight lang="php"> | |||
var fp = flightplan(); | |||
for (var i=0; i<fp.getPlanSize(); i += 1) | |||
{ | |||
var leg = fp.getWP(i); | |||
debug.dump(leg.path()); | |||
} | |||
</syntaxhighlight> | |||
With these changes in place, it is already possible to directly show a SVG image for each waypoint and connect them using OpenVG paths, even without separate "icon" support. | With these changes in place, it is already possible to directly show a SVG image for each waypoint and connect them using OpenVG paths, even without separate "icon" support. |