Scenery LOD ideas for FlightGear: Difference between revisions

Jump to navigation Jump to search
m
clarify
mNo edit summary
m (clarify)
Line 104: Line 104:
We could then use it for 1) terrain, 2) main aircraft models (cockpit!) and 3) AI objects to expose a property-driven interface to customize LOD at runtime.
We could then use it for 1) terrain, 2) main aircraft models (cockpit!) and 3) AI objects to expose a property-driven interface to customize LOD at runtime.


The first thing that we could change is using SGPropertyChangeListener or property objects so that properties can be changed at runtime, without requiring a  scenery-reload.
The first thing that we could change is using SGPropertyChangeListener or property objects so that properties can be changed at runtime, without requiring a  manual scenery-reload.


I think we would only need to subclass osgUtil::Simplifier and make it derive from SGPropertyChangeListener, too - would that work ?
I think we would only need to subclass osgUtil::Simplifier and make it derive from SGPropertyChangeListener, too - would that work ?
Line 132: Line 132:
-Stuart
-Stuart


'''Hooray:''' Right as is, it's definitely destructive and it ''will'' require a tile reload obviously (supported by Robert Osfield's comments on the osg list) - I was referring to doing the reload automatically, instead of having to run a corresponding fgcommand (we're currently using your rendering dialog and its "reload scenery" button for this. For instance, see the OSG demo code using the simplifier - i.e. see [http://www.rozengain.com/blog/2011/02/16/openscenegraph-level-of-detail-management/] - there are several LOD nodes created which can be selected. Obviously, at the cost of increased memory consumption (so this may be a no-go for scenery) - but it may still be a useful feature for developers/power users (especially to come up with good numbers/heuristics), but also help with Aircraft/Cockpit/AI related LOD management. So, I'm all for coming up with a wrapper in SimGear that we can add to the terrain/tile manager, but also use in the main aircraft/cockpit and for AI models. Using a different type of visitor pattern may not be feasible for scenery I guess, until we have some way to tell how much RAM is actually being consumed --[[User:Hooray|Hooray]] ([[User talk:Hooray|talk]]) 11:35, 19 February 2014 (UTC)   
'''Hooray:''' Right as is, it's definitely destructive and it ''will'' require a tile reload obviously (supported by Robert Osfield's comments on the osg list) - I was referring to doing the reload automatically, instead of having to run a corresponding fgcommand (we're currently using your rendering dialog and its "reload scenery" button for this. For instance, see the OSG demo code using the simplifier - i.e. see [http://www.rozengain.com/blog/2011/02/16/openscenegraph-level-of-detail-management/] - there are several LOD nodes created which can be selected. Obviously, at the cost of increased memory consumption (so this may be a no-go for scenery) - but it may still be a useful feature for developers/power users (especially to come up with good numbers/heuristics), but also help with Aircraft/Cockpit/AI related LOD management. So, I'm all for coming up with a wrapper in SimGear that we can add to the terrain/tile manager, but also use in the main aircraft/cockpit and for AI models. Using a different type of visitor pattern may not be feasible for scenery I guess, until we have some way to tell how much RAM is actually being consumed. That being said, some folks on the osg list mentioned that CGAL could be used inside an OSG Simplifier, as CGAL has extensive mesh simplification support which can also be run in a background thread (I guess psadro_gm & papillon81 know more about that?) --[[User:Hooray|Hooray]] ([[User talk:Hooray|talk]]) 11:35, 19 February 2014 (UTC)   




Navigation menu