Board index FlightGear Support Flying

Hang gliding simulator: Visualized thermals, multi-display

Controlling your aircraft, using the autopilot etc.

Hang gliding simulator: Visualized thermals, multi-display

Postby Sven2 » Mon Apr 22, 2013 5:49 pm

Hi folks,

I am currently building a hang gliding simulator from hang glider spare parts. I'm using FlightGear for the simulation part, which has great customizability and you guys put loads of information for modders in the wiki, so I got the software working quickly. Big props to the developers :)

Image

Anyway, the controls are still a bit shaky, display is blurry and flying is really tough even for an experienced pilot. I started from locations as described here, but can't get any uplift going without crashing into the mountains. So here's my questions:

* Can I somehow start FlightGear with predefined, big thermals? Like "I want 4m/s updrift at lat=x,lon=y,alt=0-2000m,radius 200m"? I read about "advanced weather modes" but couldn't find any of the parameters in the startup wizard
* Can I visualize thermals somehow like e.g. Nintendo did for their 3Ds game?
* Just for the presentation to observers, I'd like to attach multiple monitors and have them show different live views (in fullscreen) of the flight. Is this possible?

Any help would be greatly appreciated. I have C/C++ programming experience, so I could also add stuff to the engine if needed.

P.S.: For those who are interested: I'm using an upside-down mounted joystick attached to the main glider suspension for movement. Imagery is displayed on an eMagin Z800 Head-mounted display. I wrote a small adapter program to get the HMD working as a FlightGear input device. The HMD is kinda crappy, but I have big hopes in the Oculus Rift once it's coming out :)
Sven2
 
Posts: 12
Joined: Mon Apr 22, 2013 5:13 pm

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Philosopher » Mon Apr 22, 2013 6:15 pm

Looks cool! Regarding point 3, there is this wiki article on how to setup multiple screens/monitors: http://wiki.flightgear.org/Howto:Config ... ew_windows.
Thanks,
Philosopher
(inactive but lurking occasionally...)
Philosopher
 
Posts: 1590
Joined: Sun Aug 12, 2012 6:29 pm
Location: Stuck in my head...
Callsign: AFTI
Version: Git
OS: Mac OS X 10.7.5

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Hooray » Mon Apr 22, 2013 6:54 pm

That looks really great!
Weather-wise, you should probably not be using any of the old/legacy "AI thermals", but instead play around with "ridge lift" and the "Advanced Weather" system which has much better support for thermals.
The Advanced Weather system is actively developed/maintained (by Thorsten) and you can probably make feature requests, or implement simple changes yourself (Thorsten is usually quick to provide pointers as required).

You could probably visualize thermals by placing a 3D model, and animating it accordingly - you could also use a custom HUD and the new canvas system:

Subject: Drawing lines in the sky/environment

TheTom wrote:If you want to do something similar like a HUD, you could place a transparent canvas in front of the pilots viewpoint and draw the lines onto it. If you calculate the direction from the pilots viewpoint to the according position in the environment and intersect an imaginary line between this two points with the canvas you can draw it exactly where the point is located in the environment. You just need the two angles describing the direction to the point (up/down and left/right).



Multiple screens/monitors are supported by FG, using different approaches - through multiple instances or multiple windows by a single instance.

PS: You may want to add a section about your project to the upcoming newsletter (see my signature), let me know if you need help doing that - please feel free to also add screen shots / photos.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11329
Joined: Tue Mar 25, 2008 8:40 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Thorsten » Mon Apr 22, 2013 6:59 pm

Can I somehow start FlightGear with predefined, big thermals?


Yes, but you have to use Basic Weather and an AI scenario (look here for the wiki on soaring - I think you may find it useful. Advanced Weather auto-generates thermals along with the rest of the weather, you can't influence them from the commandline.

It may be that current thermals are pretty shaky for a hangglider - I would appreciate some feedback on the amount of turbulence you experience, it's tuned based on my experiences in the ASK-13, I've never flown a hangglider.

Can I visualize thermals somehow


In the AI scenario, I think you could replace the cap cloud by a semi-transparent cylinder, and then you'd get an idea where the thermal is. In Advanced Weather, there's no such possibility and you can't code it easily (I probably could if it's really needed...).
Thorsten
 
Posts: 10940
Joined: Mon Nov 02, 2009 8:33 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Hooray » Mon Apr 22, 2013 7:06 pm

If I remember correctly, LW/AW exposed tons of stuff in the property tree, including effect volumes ? How difficult would it be to expose the thermals (position, extent) ? From that point on, anybody able to use getprop/setprop from Nasal, should be able to use that data to either place static 3D models, use the data in a custom HUD or do other fancy stuff.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11329
Joined: Tue Mar 25, 2008 8:40 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Thorsten » Mon Apr 22, 2013 7:10 pm

If I remember correctly, LW/AW exposed tons of stuff in the property tree, including effect volumes ?


You do remember correctly, but I removed this a while ago to Nasal-internal space (speed...). The problem in putting them back is that thermals move with the wind, so if you have 1000 thermals in the scene, that's lots of properties to be updated, a huge garbage problem and a significant frame rate drain.
Thorsten
 
Posts: 10940
Joined: Mon Nov 02, 2009 8:33 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Hooray » Mon Apr 22, 2013 7:23 pm

right performance, so maybe we could just expose a single hook to optionally call an external Nasal function once EVs are updated, that would allow people to hook into the AW system to get certain info from it ?

Let's say weather_dynamics_loop() would be changed to accept an optional callback, so that after calling ev.move(), the optional callback would be invoked with ev being passed as parameter ?

Would that work, or do you have a better idea ?
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11329
Joined: Tue Mar 25, 2008 8:40 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Sven2 » Mon Apr 22, 2013 8:45 pm

Thanks a lot for the swift replies!

I guess the static thermals using basic weather / AI system should be fine for now. If the thermals are just vertical cylinders without wind drift, could I also just show a radar instrument to the user which contains a circle of proper size for every thermal? I figure this would be easier than meddling with the cloud drawing code, even if radar screens aren't very common on real hang gliders ;)

@P.S.: Will see if I can find something to add to the newsletter.
Sven2
 
Posts: 12
Joined: Mon Apr 22, 2013 5:13 pm

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Hooray » Mon Apr 22, 2013 9:27 pm

Sven2 wrote in Mon Apr 22, 2013 8:45 pm:could I also just show a radar instrument to the user which contains a circle of proper size for every thermal?


Yes, you can definitely do that - the simplest option (with very little coding involved on your side) would be using a canvas-driven instrument in map mode, where you would merely have to specify the position of the drawable (lat/lon), and a symbol (e.g. SVG image) and a scale transformation (for size of the thermal).
For details, see: http://wiki.flightgear.org/Canvas_Maps

Obviously, you'd still need access to all thermal positions within a range of say 20km
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 11329
Joined: Tue Mar 25, 2008 8:40 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby sim » Tue Apr 23, 2013 9:13 pm

Visual thermals Zven, in real life flying are pretty rare. Thermals often do conform to a cylindrical shape but not always. Occasionally thermals do become visible, marked for example by a number of soaring birds or by drawing smoke upward from a ground source.(or Dust Devils and the odd Tornado!) A Cumulus cloud develops at height if condensation conditions occur, so they too are good markers. Flying under cloud base or upwind edge if windy, is where to look for rising air. In clear blue skies you just have to rely on the seat of your pants and your vario instrument if you have one. Usual signal to start circling flight is the wallop up your backside, your popping ears and often buffeting unstable air. Then all you have to do is centre your turn on the best lift! (Sounds easy and sometimes it is, most times it is quite challenging)
One thing for sure in flight sims, seat of pants and popping ears are not yet built in! You will need that vario!

PS. Hang glider pilots lying in prone position will feel the oomph in their guts!
User avatar
sim
 
Posts: 1441
Joined: Tue Jun 30, 2009 2:13 pm
Location: Shropshire England
Callsign: Fly4Fun
Version: 0.9.10 up
OS: 64 Win 10 HD6450

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Johan G » Wed Apr 24, 2013 9:12 am

sim wrote in Tue Apr 23, 2013 9:13 pm:...and the odd Tornado!...

One probably would should not be hang gliding on such a day. :lol:
Low-level flying — It's all fun and games till someone looses an engine. (Paraphrased from a YouTube video)
Improving the Dassault Mirage F1 (Wiki, Forum, GitLab. Work in slow progress)
Johan G
Moderator
 
Posts: 5509
Joined: Fri Aug 06, 2010 5:33 pm
Location: Sweden
Callsign: SE-JG
IRC name: Johan_G
Version: 3.0.0
OS: Windows 7, 32 bit

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Sven2 » Wed Apr 24, 2013 2:37 pm

sim wrote in Tue Apr 23, 2013 9:13 pm:Visual thermals Zven, in real life flying are pretty rare. Thermals often do conform to a cylindrical shape but not always. Occasionally thermals do become visible, marked for example by a number of soaring birds or by drawing smoke upward from a ground source.(or Dust Devils and the odd Tornado!) A Cumulus cloud develops at height if condensation conditions occur, so they too are good markers. Flying under cloud base or upwind edge if windy, is where to look for rising air. In clear blue skies you just have to rely on the seat of your pants and your vario instrument if you have one. Usual signal to start circling flight is the wallop up your backside, your popping ears and often buffeting unstable air. Then all you have to do is centre your turn on the best lift! (Sounds easy and sometimes it is, most times it is quite challenging)
One thing for sure in flight sims, seat of pants and popping ears are not yet built in! You will need that vario!

PS. Hang glider pilots lying in prone position will feel the oomph in their guts!


Yeah, I know I'm simplifying here. I'm a hang glider pilot myself and I've lost the thermals and was forced to land countless times :)

The purpose of this device, however, is mostly for non-pilots (like the guy in the picture, who is just about to crash his glider ;)) to show them some gliding experience. So I want to have it as easy and simplified as possible. For beginners, even the fact that you need to shift your body weight to initiate a turn is often enough of a challenge.
Sven2
 
Posts: 12
Joined: Mon Apr 22, 2013 5:13 pm

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Thorsten » Wed Apr 24, 2013 2:40 pm

I think it's a fair enough request for training purposes to have a pre-defined thermal somewhere which is visually clearly marked, and I think an AI scenario with a changed cap cloud would fit the requirement best.
Thorsten
 
Posts: 10940
Joined: Mon Nov 02, 2009 8:33 am

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby sim » Fri Apr 26, 2013 2:08 pm

Magnificent hill soaring in westerly wind at Long Myndd Shropshire. Who needs thermals? :lol: !







Air Traffic Control. Wha'ssat ?
User avatar
sim
 
Posts: 1441
Joined: Tue Jun 30, 2009 2:13 pm
Location: Shropshire England
Callsign: Fly4Fun
Version: 0.9.10 up
OS: 64 Win 10 HD6450

Re: Hang gliding simulator: Visualized thermals, multi-displ

Postby Thorsten » Fri Apr 26, 2013 3:04 pm

Who needs thermals?


Me - I want to fly places, not scrub a single ridge forever!

(Admittedly, if the terrain is right, it also works with ridge lift - I've done pretty much all of the Alaska custom scenery around Juneau with the Hangglider just with ridge hopping, but it is tricky, and the terrain is very rough).
Thorsten
 
Posts: 10940
Joined: Mon Nov 02, 2009 8:33 am

Next

Return to Flying

Who is online

Users browsing this forum: No registered users and 0 guests