Board index FlightGear Development

how can I change in rendring option?

FlightGear is opensource, so you can be the developer. In the need for help on anything? We are here to help you.
Forum rules
Core development is discussed on the official FlightGear-Devel development mailing list.

Bugs can be reported in the bug tracker.

how can I change in rendring option?

Postby salma abtin » Sat Aug 24, 2013 8:22 am

Hi all...
I want to change some parameters like weather in fg without resetting this software.
there are something in view/rendering options that without resetting fg reply to changes that we want...like random buildings and...
I'v studied rendering xml file.I didn't understood what is property in this file.
for example:
<property>/sim/rendering/random-objects</property>

what is it?
and how can i change this for my goal?
thanks...
salma abtin
 
Posts: 16
Joined: Sun Jul 14, 2013 12:03 pm

Re: how can I change in rendring option?

Postby Thorsten » Sat Aug 24, 2013 11:33 am

Usually all parameters of the rendering which can be adjusted runtime are accessible in the rendering, weather or environment menu. Even some parameters which require a scenery reload (textures or random building densities) can be accessed from the menu.

Other parameters (Rembrandt on/off most importantly) correspond to major architectural changes internally and can't be made runtime.

So - it'd help if you would describe in more detail what precisely you are hoping to do. Weather is pretty much completely controllable runtime from the weather menu for instance.
Thorsten
 
Posts: 12490
Joined: Mon Nov 02, 2009 9:33 am

Re: how can I change in rendring option?

Postby salma abtin » Sat Aug 24, 2013 12:02 pm

Thank you
Do you know how can i find nodes(or property) in xmls?
for example:
<property>/sim/rendering/random-objects</property>
where is random-object defined?
in nasal codes?
salma abtin
 
Posts: 16
Joined: Sun Jul 14, 2013 12:03 pm

Re: how can I change in rendring option?

Postby Hooray » Sat Aug 24, 2013 2:19 pm

salma abtin wrote in Sat Aug 24, 2013 8:22 am:Hi all...
I want to change some parameters like weather in fg without resetting this software.
there are something in view/rendering options that without resetting fg reply to changes that we want...like random buildings and...
I'v studied rendering xml file.I didn't understood what is property in this file.


In general, this is possible and worthwhile, there's an increasing trend to make more and more subsystems fully runtime-configurable - however, in practice it is usually pretty tricky, and requires familiarity with the C++ code and being able to build from source. You'll basically want to use property listeners to partially (or fully) reset subsystems - the majority of subsystems were however never developed with proper runtime reset/reinit support.
Thus, it is usually easier to fix just scripted subsystems for the time being.

So the problem is NOT just about editing some XML files, the underlying C++ code needs to be taught how to re-initialize - which is an active effort, see:

http://wiki.flightgear.org/Reset_%26_re-init
http://wiki.flightgear.org/FlightGear_Run_Levels
http://wiki.flightgear.org/FlightGear_Sessions

The first link is the most relevant once, but it is only of interest if you know C++ and know how to build FG from source, the 2nd link explains a slightly different approach - while the last link doesn't go into technical details at all, it's just a summary of why we ended up with certain shortcomings in FG, it's still valid in general, but pretty outdated.

To learn more about the C++ side of things, i.e. "SGSubsystems" and listeners, see: http://wiki.flightgear.org/Howto:Create_new_subsystems
In general, tied properties shall no longer be used, see: http://wiki.flightgear.org/Howto:Use_Pr ... ee_Objects

To get started modifying the C++ code, see: http://wiki.flightgear.org/Howto:Start_core_development
The wiki also has its own dedicated developers section: http://wiki.flightgear.org/Portal:Developer
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: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU


Return to Development

Who is online

Users browsing this forum: No registered users and 2 guests