Hi all,
I'm having a strange behaviour with the OSGQGLManagedWidget. I'm trying
to show up some GL Qt windows containing the same node as root. Whenever
I create a new window and set its root to be my node the precedent(s)
window(s) looses its(their) root and do not display anything anymore,
while the new one has everything...
I also tried to share the manager but then nothing gets redrawn when
there are more than one window created.
Any hint ?
Here is the code invoking the creation of a view :
void QtOSGViewer::createView(OSG::NodePtr node)
{
OSG::OSGQGLManagedWidget *osgview=0;
OSG::SimpleSceneManager* manager=0;
#ifdef OSGVIEWER_SHARE_MANAGER
if (!m_osgviews.isEmpty()) {
osgview = m_osgviews.first();
manager = &osgview->getManager();
}
#endif
LOG4CPLUS_DEBUG(logger,
"QtOSGViewer::createView : creating a view with node="<<node);
osgview = new OSG::OSGQGLManagedWidget(0, "OpenSG viewer",manager);
osgview->getManager().setRoot(node);
osgview->getManager().setStatistics( true );
osgview->getManager().showAll();
osgview->getManager().useOpenSGLogo();
connect ( osgview, SIGNAL ( closed (QWidget *) ),
this, SLOT ( removeView (QWidget *) ) );
osgview->show();
m_osgviews.append(osgview);
LOG4CPLUS_INFO(logger, "QtOSGViewer::createView : added a view");
}
Thanks in advance,
Mathieu
-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on
Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now,
one more big change to announce. We are now OSTG- Open Source Technology
Group. Come see the changes on the new OSTG site. www.ostg.com
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users