Hi John,

I have pointed you in the right direction.  You can do what you need
to do using node masks and multiple node/buffers.

Robert.

On Fri, Jun 27, 2008 at 7:27 PM, Argentieri, John-P63223
<[EMAIL PROTECTED]> wrote:
> Robert,
>
> That will be difficult to achieve. What if each view had a unique root
> node, and each root node had an update callback?
>
> Would all of the update callbacks be triggered during the update
> traversal?
>
> This means that if I want "Selection Geometry" to be unique per view,
> that I would have to give each view a unique group to attach the
> selection geometry to. Am I understanding this?
>
> As far as the cull callbacks go, what are you saying is legal to
> perform? What is multi-buffering of internal structures? What does it
> mean to select from the multi-buffer?
>
> Thanks for your advice,
>
> John
>
>
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Robert
> Osfield
> Sent: Friday, June 27, 2008 12:53 PM
> To: OpenSceneGraph Users
> Subject: Re: [osg-users] osgViewer help needed
>
> Hi John,
>
> It's sounds like you are abusing the OSG, i.e. using in ways that it's
> not designed to be used.  Refactoring your scene graph usage slightly
> will probably fix the problems you have without having to fight the OSG
> continuously.
>
> First up some basics,  the updating of the scene graph is designed to be
> be done wholly before the cull and draw traversals, this makes it
> possible to thread the scene graph without requiring complex
> multi-buffering that you'd find in Performer/OpenSG.   You should
> consider updating the scene graph during cull and draw prohibited.
> The only exception to this is when you multi-buffer internal structures.
>
> Now given thrashing node parameters like you are doing is prohibited, so
> next you need to find an alternative, the hint of how to do it is in the
> last sentance above - you need to buffer you scene graph elements so
> that instead of one object that you change the state of, you have one
> node or one data element per view/camera.  You can do this via cull
> callbacks that's maintain local buffer of data that is selected on the
> fly, or to just use separate subgraphs with the
> topmost node unique for each view/camera.   You can set the cull masks
> individually for cameras, so you could use NodeMask's to select which
> part of the scene graph you want to use in each instance.
>
> Now if you don't want to follow this advice, we then I'm afraid I'll
> just stand back and stop giving you support on this topic, I really
> don't have time to go chasing people abusing the scene graph.
>
> Robert.
>
>
>
> On Fri, Jun 27, 2008 at 5:14 PM, Argentieri, John-P63223
> <[EMAIL PROTECTED]> wrote:
>> Robert,
>>
>> We've created our own event processing system. We need to manage a
>> common scene with different node masks, switch node settings, etc. The
>
>> problem is that the event traversal and update traversal happens for
>> all views before the cull/draw traversal. So if we follow your methods
>
>> of processing events in the event traversal or update traversal, we
>> end up with all views looking like the most recently created view,
>> instead of being unique. If I change the scene graph in the camera's
>> final draw callback, it works but OSG spits out a bunch of OpenGL
>> errors for what I'm assuming is the current frame. Thanks for your
> time.
>>
>> Sincerely,
>> John
>>
>> -----Original Message-----
>> From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED] On Behalf Of
>> Robert Osfield
>> Sent: Thursday, June 26, 2008 6:16 AM
>> To: OpenSceneGraph Users
>> Subject: Re: [osg-users] osgViewer help needed
>>
>> Hi John,
>>
>> What operation are you needing to do?
>>
>> Robert.
>>
>> On Tue, Jun 24, 2008 at 12:30 AM, Argentieri, John-P63223
>> <[EMAIL PROTECTED]> wrote:
>>> All,
>>>
>>> I need to have a callback from within osgViewer::CompositeViewer that
>
>>> happens just before each graphics context's renderer does
> cull_draw().
>>
>>> It can't be part of the cull traversal or the camera's pre-draw
>>> traversal, or the update traversal. Single threaded, and right before
>> the cull traversal.
>>> Does anyone know of a way that this can be done without gutting
>> osgViewer?
>>>
>>> Many thanks,
>>> John Argentieri
>>>
>>> _______________________________________________
>>> osg-users mailing list
>>> osg-users@lists.openscenegraph.org
>>>
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.
>>> org
>>>
>>>
>> _______________________________________________
>> osg-users mailing list
>> osg-users@lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.
>> or
>> g
>> _______________________________________________
>> osg-users mailing list
>> osg-users@lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.
>> org
>>
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or
> g
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to