Hi Hartwig,
Given the odd behavior, and the fact that the LOD implementation doesn't
have any code that is sensitive to number of children, I would suspect
something like small feature culling introducing issues.
Small feature culling doesn't require any nodes to be inserted in the scene
graph, instead it's a check done for all nodes in the scene graph,
comparing the size of the bounding volume projected into window coordinates
to a minimum size, if it's less than this the subgraph is culling.
You can control which culling the scene graph does during the cull
traversal by via the osg::CullSettings class, the osg::Camera subclasses
from this so you can do the following:
viewer.getCamera()->setCullingMode(osg::CullSettings::VIEW_FRUSTUM_SIDES_CULLING);
Which only enables view frustum culling for the left, right, top and bottom
frustum planes. The default culling mode is (copy and pasted from the
CullSettings header) :
DEFAULT_CULLING = VIEW_FRUSTUM_SIDES_CULLING|
SMALL_FEATURE_CULLING|
SHADOW_OCCLUSION_CULLING|
CLUSTER_CULLING,
As a general note, having any node with 1000 children is usually an
indication that the scene graph is poorly balanced and will likely result
in CPU and possibly GPU bottlenecks that would be avoided with a better
balanced scene graph. I don't know anything about what problem you are
actually trying to solve so can't provide any specific advice on what you
should be doing.
Robert.
On 25 February 2015 at 20:44, Hartwig Wiesmann <[email protected]>
wrote:
> Hi,
>
> I have two LOD nodes. One LOD node has one child node the other one has -
> for example - 1000 children. All children of both nodes have the same range
> settings (0 - maxValue).
> The single child of the LOD node is shown on the scene. Children in the
> vicinity of this single child - but part of the other LOD node - are not
> shown.
> If I increase the range of the second node (let's say by a factor of 10)
> the children of the second node are shown.
> If I add the 1000 children to the first LOD node none of the children are
> shown (also not the one that was shown when it was the only child of the
> first LOD node).
>
> I have no clue what is going on. Can anybody tell me what is going on?
>
> PS: I do not modify any LOD scale values in cull settings or anywhere else.
> PPS: The number of ranges is identical to the number of children.
>
> Thank you!
>
> Cheers,
> Hartwig
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=62824#62824
>
>
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org