Board index FlightGear Support osgEarth

Regarding OSG

osgEarth renders the terrain scene by building the textured geometry at runtime from raw source imagery and elevation data. An experimental FlightGear integration is currently available.

Regarding OSG

Postby sdefvisual » Mon Apr 13, 2020 9:30 am

Can OSG be parallelized or customized in flighgear? Because we are trying to reduce the applications rendering time .If any solutions for this kindly suggest as.
sdefvisual
 
Posts: 4
Joined: Wed Mar 25, 2020 11:40 am

Re: Regarding OSG

Postby Hooray » Mon Apr 13, 2020 9:36 am

You will probably have to tell us a little more about your exact use-case, the settings (location, aircraft, startup/runtime, environment).

But yes, FG can be heavily customized - the details depend on your use-case. There are startup/runtime settings to help you, and you may need to customize scenery/aircraft, or even patch rebuild FG or any of its dependencies. And it would seem like a good idea to run a forum search:

Microsoft Flight Simulator, a small graphics study
Threadripper 1920 (12/24 threads)+Vega56 = 10fps in W10?

Low Framerate
Richard wrote:
Robertfm wrote in Thu Nov 07, 2019 3:04 pm:This sort of thing just confuses me, everything I have read of GPU's and CPU' s suggest CPU usage is maxed out will affect GPU. But my CPU is operating in region between 30/40%. But my GPU only about 30% it makes no sense. Articles I've read say it should be 99 to 100%. The suggestions in the article point to a game one is playing.


If you're interested in flying then you only need 50fps; it is what the FAA require to certify a Level-D simulator. There is little point in having a frame rate higher than your monitor's refresh frequency (often 60hz) I usually fly with my frame rate locked at 30hz because consistency is more important than performance (for me).

So really I'd suggest that you should just be pleased that you're getting the sort of performance that your hardware is capable of providing.

Try flying over one of the busy areas (e.g. Paris, LFPG, LOWI) and see what happens to your GPU utilisation

I've been investigating FG performance for a few years now and can report that currently FlightGear can only use a single core to do most of the work of rendering and simulation; and thus on a system with 4 cores the maximum CPU % will be 25% (12.5% for a hyperthreaded 4 core CPU). So if you've got two cores and you're seeing 50% (or more) then that's almost as high as it could go - and there's little that can be done to improve this because FlightGear is using OSG which in turn uses OpenGL and the underlying GPU/driver architecture simply cannot be driven effectively from multiple threads (CPU cores).

I guess what I'm getting at is that the overall CPU and GPU utilisation as a single percentage value is potentially misleading - because it depends on how all the various stages of CPU and GPU processing (particularly GPU processing) have been added together to make a single percentage number. Also all of this is irrelevant if running at vsync.

Now maybe it's great that FSX can achieve 100+FPS; but really that's of little importance unless you're on a 120hz monitor.

Tell us what your monitor vsync rate is.
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: 11836
Joined: Tue Mar 25, 2008 8:40 am

Re: Regarding OSG

Postby sdefvisual » Mon Apr 13, 2020 1:39 pm

We found the timing but using timestamps and found in osg part swaf buffer part is taking nearly 14 ms to complete one cycle .Is their any option to optimise this part ???
sdefvisual
 
Posts: 4
Joined: Wed Mar 25, 2020 11:40 am

Re: Regarding OSG

Postby Hooray » Mon Apr 13, 2020 2:56 pm

sdefvisual wrote in Mon Apr 13, 2020 1:39 pm:We found the timing but using timestamps and found in osg part swaf buffer part is taking nearly 14 ms to complete one cycle .Is their any option to optimise this part ???


Unfortunately, you are still not providing the kind of background information that would be needed to help you, which is why I suggest you spend a little more time researching FlightGear + performance:

http://wiki.flightgear.org/Howto:Use_the_system_monitor
http://wiki.flightgear.org/OSG_on_screen_stats
http://wiki.flightgear.org/Built-in_Profiler

Even without patching/rebuilding FlightGear, you can customize things pretty well.

You will probably want to look at "draw masks", which can tell you the relative overhead of rendering terrain/scenery, aircraft etc:

http://wiki.flightgear.org/Draw_masks
Image

http://wiki.flightgear.org/Minimal_Startup_Profile
Image

PS: Speaking in general, people are much more likely to respond here if you provide actionable information, and if they're getting the impression you're following up with any information requested. What you've been posting so far, isn't really helping at all. If in doubt, you can obviously check out the developers mailing lists.
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: 11836
Joined: Tue Mar 25, 2008 8:40 am

Re: Regarding OSG

Postby Thorsten » Mon Apr 13, 2020 4:59 pm

Because we are trying to reduce the applications rendering time .If any solutions for this kindly suggest as.


I'm not sure what you expect to hear. The only context in which 'How can I make this render faster?' makes any sense is one in which the FG developers for some reason deliberately made FG render slower than it would be possible.

So - don't you think if people knew how to reduce the rendering time, they'd actually done it?
Thorsten
 
Posts: 11639
Joined: Mon Nov 02, 2009 8:33 am

Re: Regarding OSG

Postby Hooray » Mon Apr 13, 2020 5:44 pm

In the context of tweaking/fine-tuning settings, the question does make sense however - but that question makes only sense in the context of providing startup/runtime settings (airport/scenery, aircraft), and the underlying hardware (CPU, RAM, GPUs, VRAM).

The links I posted can help provide the tools to come up with a "baseline" by disabling things, and toggling them on/off to see how much impact certain settings really have.

Other than that, the question is far too broad to answer at all.
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: 11836
Joined: Tue Mar 25, 2008 8:40 am

Re: Regarding OSG

Postby sdefvisual » Thu Apr 16, 2020 4:08 pm

Thanks for replying
I am working with the customized flight gear source code, where initialization will be through default.xml. Here I am using 8GB RAM and NVIDIA Quadro K400 graphics card and rendering will b on three displays. While debugging the source code, I have came to know that Osg's swap buffer is taking more time. Can OSG be parallised or any other alternative method for decreasing time in osg, kindly suggest us. It would be great full and thanks in advance.
sdefvisual
 
Posts: 4
Joined: Wed Mar 25, 2020 11:40 am

Re: Regarding OSG

Postby wkitty42 » Fri Apr 17, 2020 12:38 am

sdefvisual wrote in Thu Apr 16, 2020 4:08 pm:While debugging the source code, I have came to know that Osg's swap buffer is taking more time. Can OSG be parallised or any other alternative method for decreasing time in osg, kindly suggest us. It would be great full and thanks in advance.

OSG is another project that FG uses... you'll have to ask OSG if there's a method of speeding up its buffering... this might also depend on your version of OSG, though... you have not told anyone which version of OSG you are using with your FG...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 6491
Joined: Fri Feb 20, 2015 3:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 14.04.5

Re: Regarding OSG

Postby Hooray » Sat Apr 18, 2020 11:11 am

Your postings are missing any kind of surrounding context, while your question is indeed specific - we have no way to tell whether your question is even relevant in your context, and if your question should indeed be relevant (which I highly doubt), this would be the wrong place/forum to discuss the matter.

There is fgviewer, and there is osgviewer - these can be used to come up with a baseline for any kind of benchmarking and profiling.
You can also incrementally disable/re-enable features one by one to see if/how much of an impact they have on your stats.

But what you've provided so far contains hardly any actionable information unfortunately - also, I am not seeing the slightest indication that you're following up with the requested information by working through the resources/pointers we've shared with you. Thus, while your posting is indeed "politely phrased", it's not sufficient to yield the kind of response you're apparently hoping for.
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: 11836
Joined: Tue Mar 25, 2008 8:40 am


Return to osgEarth

Who is online

Users browsing this forum: No registered users and 1 guest