[osg-users] Switch call to viewer::frame() between threads

Steven Powers StevenAPowers at gmail.com
Mon Sep 10 23:48:15 PDT 2018

I am attempting to switch which thread I call viewer::frame in. 

I realize my viewer in thread A, call viewer::frame() several times, do some loading, then switch the call to viewer::frame() to thread B. When I do so the items within the window still update but I am unable to move/resize/select the window.

It seems to be dependent on which thread I call viewer::realize from. If I call it from thread B then the opposite is true. Or perhaps it is dependent on what thread I call createGraphicsContext on???

What is the elegant or appropriate way to accomplish such a feat. Is the realize operation thread specific or is it the keyboard handlers?

Thanks in advance for any advice/ help that can be provided.

Read this topic online here:

More information about the osg-users mailing list