Re: [Flightgear-devel] Display existing path?
Hi Adam, It took me a while, but I finally got a chance to take a look at this, thanks! I can see that I probably want to do it totally different, but I like quite a bit about your approach and how you track the points you draw so you can remove them cleanly. For myself, I'd like to draw the route manager route, rather than data from an external csv file. I'm also playing around with circle holds about a fixed point so it would be interesting to draw the center reference point surrounded by the desired path. But I have a starting point now I can fiddle with. Thanks again! Curt. On Sat, Sep 24, 2011 at 11:10 AM, Adam Dershowitz, Ph.D., P.E. wrote: On Sep 11, 2011, at 10:30 AM, Adam Dershowitz, Ph.D., P.E. wrote: Is there any easy way to show a prior route in Flightgear? In other words, if I have a set of recorded GPS points (lat,long, alt) in a text file can I display them in 3-D space, as I am flying in flightgear? Ideally I would like points (some box or sphere icon?) connected with line segments. There are three different approaches that occur to me, so I figured I would check if anyone has done anything like this, and see if anyone can offer any guidance. 1) It is probably possible to generate some custom scenery that has my desired path as custom made objects. But this seems like it is likely the most difficult approach? 2) It seems likely that it could be done with nasal, but I have really not done any nasal coding. One approach might be to hard code a bunch of objects, representing points, in the right locations into a nasal file. This is not very flexible, as each nasal script would be for a given single path. 3) Finally, what seems most general would be to write some code in nasal that can read in a csv file, and then to display objects in those locations. Is this feasible? Can nasal import a csv file or other general file format that could contain points? If any of you have any existing code, or suggestions, I would love to hear it. Thanks, --Adam I wrote some NASAL to accomplish this, and I thought that I would pass it back to the group, as there was some interest (Curt), and I don't have commit access. To use this, put show_points.nas into data/Nasal. The 4 geometry files go into data/Models/geometry and finally data is read from a csv file put in fg-aircraft. I included a little sample file to show a few points. To turn this on do: --prop:/sim/rendering/LLpoints=1 (or change this in flight to turn it on an off) You can change the interpolated points, between the actual points, by doing: --prop:/sim/rendering/LLpointsInterp=50. By default there is effectively no interpolation, only the actual points are displayed. A value of 50 will put a point every 50 meters, in a straight line between the existing points. Finally, you can change the data file name (although not the path) with --prop:/sim/rendering/LLfile=latlong.csv (although this is the default value). The sample lat/long file will put a few points around SFO, just for demo purposes. I hope that this is helpful. -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2dcopy2 ___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel -- Curtis Olson: http://www.atiak.com - http://aem.umn.edu/~uav/ http://www.flightgear.org - http://gallinazo.flightgear.org -- All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense. http://p.sf.net/sfu/splunk-d2d-oct___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel
Re: [Flightgear-devel] Display existing path?
On Sep 11, 2011, at 10:30 AM, Adam Dershowitz, Ph.D., P.E. wrote: Is there any easy way to show a prior route in Flightgear? In other words, if I have a set of recorded GPS points (lat,long, alt) in a text file can I display them in 3-D space, as I am flying in flightgear? Ideally I would like points (some box or sphere icon?) connected with line segments. There are three different approaches that occur to me, so I figured I would check if anyone has done anything like this, and see if anyone can offer any guidance. 1) It is probably possible to generate some custom scenery that has my desired path as custom made objects. But this seems like it is likely the most difficult approach? 2) It seems likely that it could be done with nasal, but I have really not done any nasal coding. One approach might be to hard code a bunch of objects, representing points, in the right locations into a nasal file. This is not very flexible, as each nasal script would be for a given single path. 3) Finally, what seems most general would be to write some code in nasal that can read in a csv file, and then to display objects in those locations. Is this feasible? Can nasal import a csv file or other general file format that could contain points? If any of you have any existing code, or suggestions, I would love to hear it. Thanks, --Adam I wrote some NASAL to accomplish this, and I thought that I would pass it back to the group, as there was some interest (Curt), and I don't have commit access. To use this, put show_points.nas into data/Nasal. The 4 geometry files go into data/Models/geometry and finally data is read from a csv file put in fg-aircraft. I included a little sample file to show a few points. To turn this on do: --prop:/sim/rendering/LLpoints=1 (or change this in flight to turn it on an off) You can change the interpolated points, between the actual points, by doing: --prop:/sim/rendering/LLpointsInterp=50. By default there is effectively no interpolation, only the actual points are displayed. A value of 50 will put a point every 50 meters, in a straight line between the existing points. Finally, you can change the data file name (although not the path) with --prop:/sim/rendering/LLfile=latlong.csv (although this is the default value). The sample lat/long file will put a few points around SFO, just for demo purposes. I hope that this is helpful. show_points.nas Description: Binary data 37.6139,-122.3586,50 37.6140,-122.3670,75 37.6137,-122.3650,100 37.6175,-122.3678,200 37.6204,-122.3739,100 trackpoint.ac Description: Binary data trackpoint.xml Description: XML document volume.ac Description: Binary data volume.xml Description: XML document -- All of the data generated in your IT infrastructure is seriously valuable. Why? It contains a definitive record of application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-d2dcopy2___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel
Re: [Flightgear-devel] Display existing path?
Nasal can handle pretty general problems (you can run a whole weather system in it...). 3) Finally, what seems most general would be to write some code in nasal that can read in a csv file, and then to display objects in those locations. Is this feasible? Can nasal import a csv file or other general file format that could contain points? I don't know about reading general file formats, but what is certainly possible is to have a file of your waypoints in xml format, such that it appears in the property tree. Nasal can then read out the waypoints from the tree, place object markers at the given positions, compute the connecting lines and compute regularly spaced positions to indicate the lines. All this is rather straightforward. To see how xml creates property nodes, see preferences.xml. To see how to read properties into Nasal, read the FgWiki on Nasal. To see how to make Nasal display objects at given (lat, lon, alt), study the tanker.nas script. To see how to do the trigonometry calculating your course lines, see the documentation of geo.nas. Cheers, * Thorsten -- Doing More with Less: The Next Generation Virtual Desktop What are the key obstacles that have prevented many mid-market businesses from deploying virtual desktops? How do next-generation virtual desktops provide companies an easier-to-deploy, easier-to-manage and more affordable virtual desktop model.http://www.accelacomm.com/jaw/sfnl/114/51426474/ ___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel
[Flightgear-devel] Display existing path?
Is there any easy way to show a prior route in Flightgear? In other words, if I have a set of recorded GPS points (lat,long, alt) in a text file can I display them in 3-D space, as I am flying in flightgear? Ideally I would like points (some box or sphere icon?) connected with line segments. There are three different approaches that occur to me, so I figured I would check if anyone has done anything like this, and see if anyone can offer any guidance. 1) It is probably possible to generate some custom scenery that has my desired path as custom made objects. But this seems like it is likely the most difficult approach? 2) It seems likely that it could be done with nasal, but I have really not done any nasal coding. One approach might be to hard code a bunch of objects, representing points, in the right locations into a nasal file. This is not very flexible, as each nasal script would be for a given single path. 3) Finally, what seems most general would be to write some code in nasal that can read in a csv file, and then to display objects in those locations. Is this feasible? Can nasal import a csv file or other general file format that could contain points? If any of you have any existing code, or suggestions, I would love to hear it. Thanks, --Adam -- Using storage to extend the benefits of virtualization and iSCSI Virtualization increases hardware utilization and delivers a new level of agility. Learn what those decisions are and how to modernize your storage and backup environments for virtualization. http://www.accelacomm.com/jaw/sfnl/114/51434361/ ___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel
Re: [Flightgear-devel] Display existing path?
Hi Adam, This has been something I thought would be a nice feature too. It should be possible. I've placed other models using nasal to create interesting scenes. It would be kind of cool for simulated UAV work to see your exact waypoint target in 3d space. Curt. On Sun, Sep 11, 2011 at 12:30 PM, Adam Dershowitz, Ph.D., P.E. wrote: Is there any easy way to show a prior route in Flightgear? In other words, if I have a set of recorded GPS points (lat,long, alt) in a text file can I display them in 3-D space, as I am flying in flightgear? Ideally I would like points (some box or sphere icon?) connected with line segments. There are three different approaches that occur to me, so I figured I would check if anyone has done anything like this, and see if anyone can offer any guidance. 1) It is probably possible to generate some custom scenery that has my desired path as custom made objects. But this seems like it is likely the most difficult approach? 2) It seems likely that it could be done with nasal, but I have really not done any nasal coding. One approach might be to hard code a bunch of objects, representing points, in the right locations into a nasal file. This is not very flexible, as each nasal script would be for a given single path. 3) Finally, what seems most general would be to write some code in nasal that can read in a csv file, and then to display objects in those locations. Is this feasible? Can nasal import a csv file or other general file format that could contain points? If any of you have any existing code, or suggestions, I would love to hear it. Thanks, --Adam -- Using storage to extend the benefits of virtualization and iSCSI Virtualization increases hardware utilization and delivers a new level of agility. Learn what those decisions are and how to modernize your storage and backup environments for virtualization. http://www.accelacomm.com/jaw/sfnl/114/51434361/ ___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel -- Curtis Olson: http://www.atiak.com - http://aem.umn.edu/~uav/ http://www.flightgear.org - http://gallinazo.flightgear.org -- Using storage to extend the benefits of virtualization and iSCSI Virtualization increases hardware utilization and delivers a new level of agility. Learn what those decisions are and how to modernize your storage and backup environments for virtualization. http://www.accelacomm.com/jaw/sfnl/114/51434361/___ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel