Hi Robert,

On 6/5/2014 3:29 AM, Robert Osfield wrote:
HI Judson,

The design of osgViewer provides CompositeViewer for managing
applications with multiple Views.  Why are you using multiple Viewers?
  ComposisteVIewer has the ability to coordinate between multiple
contexts that using multiple Viewers can not.

Each viewer contains a distinct model that is not related to any of the other viewers. Perhaps I misinterpreted the purpose of CompositeViewer. I intended for the viewers to be separate as if they were each opened from a separate process.


W.r.t the buffers, I suspect the problem is that the buffers used to
manage the per context data are not being allocated prior to opening
the viewers and runners the threads.  Once the buffers are allocated
to the correct size then each rendering thread should operate in it's
own copy without collision with the other contexts.

You can resize the buffers prior to opening the windows by calling
rootnode->resizeGLObjectBuffers(), but this must be done single
threaded.

If I have 3 distinct rootnodes (one assigned to each viewer, and each allocated separately), does calling resizeGLObjectBuffers() on one affect all of them? I expected the answer to be no, but in the debugger, they all appeared to be using the same data (the memory address of the GlyphTexture::_glyphsToSubload container seemed to be the same for each).


Again, I'd stress you are using the OSG multi-threaded in a way that
bypasses the route it was designed for, so you'll need to jump through
extra hoops, or just use the OSG as intended.

Robert.


Thanks,

Judson
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to