Le 23 juin 06, à 17:01, Robert Osfield a écrit :

Hi Atonie,

On 6/23/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Thanks for the answer.  Actually, getting two osg::State is
what I am looking for.
One of the viewer is a true viewer displaying a scene graph
the other is running a parrallel terrain generation. The
latter should not break the first.

This is a bit not standard setup, but I can understand where you are
comming from.  You could probably do what youwant with two seperate
apps.. but what you are trying to do should be possible as is.

Thinking about it now you probably already have two seperate
osg::State one for each RenderSurface (each viewer will have one
RenderSurface in your setup), all you should need to do is modify the
second viewer so its osg::State contextID is set to 1.  To ge this
you'll need to get the OsgSceneHandler, which manages the internal
SceneView, which has the osg::State.  Do a setContextID(1) on this
State.

Here is my feed-back on this solution.
Setting the contextID solved the texture/font issue.
Last thing to know is that it is possible to create independent Producer::RenderSurface. But creating a second osgProducer::Viewer does not work fine for some LODs. Actually, all LODs generated by osgTerrain were not working: the level of detail is not updated, the crudest level is kept all the way. I have other LODs in my scene that work fine (?)

Thank you very much for the missing step,

Antoine

_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to