[OpenLayers-Users] Is it possible to edit a LineString after it has been created and added to a layer?

Curtis Olson curtolson at gmail.com
Wed Apr 11 15:08:18 EDT 2012


Hi,

I've begun my plunge into openlayers and have a number of things working,
but I've run into a question that I haven't been able to answer for myself
from the docs and the mailing list archives.

I am building a map that will live track an object (for example: my
aircraft location as I fly in the FlightGear flight simulator.)

I would like to leave a trail behind myself showing my recent path (say for
the past 10 seconds or the past 10 minutes.)  I am imagining a LineString
where I can insert new points at one end and remove points from the other
end -- as my position updates.

I could create an entirely new LineString and Vector and add that to my
layer 10x a second (removing the old feature), but I was hoping I could
just build the linestring once, add it too a layer once, and from then on
just modify the linestring structure.

Is something like this possible or am I barking up the wrong tree?

I have another sort of similar situation where I may want to additionally
modify the point locations of some of the points in the linestring (based
on external data coming from the flight simulator.)  In otherwords I want
to reshape the linestring by adjusting the locations of individual points.
 Is anything like this possible?

I've been hunting through the examples and the documentation and haven't
stumbled on the appropriate magic yet.

Any tips or pointers or nudges for an openlayers newbie?

Thanks,

Curt.
-- 
Curtis Olson:
http://www.atiak.com - http://aem.umn.edu/~uav/
http://www.flightgear.org - http://gallinazo.flightgear.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120411/ad232926/attachment.html


More information about the Users mailing list