Scenery LOD ideas for FlightGear: Difference between revisions

m (clarify)
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. 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)
'''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)


'''poweroftwo''':
I have used osgUtil::Simplifier on models with some success.  It is used in the osgEarth implementation when importing KML files to improve performance, particularly helpful with models from the Sketchup 3D warehouse where there is a lack of consistency and a lot of over building with excessive number of vertices.    If indeed the bottleneck with the terrain is vert/poly pipeline limited, then yes, I think the Simplifier is a fine way to try and yes the node visitor changes the drawable in-place.


-poweroftwo


= Ideas (2012) =
= Ideas (2012) =