Hi, I make an OSG activex used in IE brower , IE crashes when I push the refresh button for about 12 times
I need help. I meet the same problem shown in http://forum.openscenegraph.org/viewtopic.php?t=4527 But the IE crash even if I load a simple osg file,such as cow.osg. And the brower doesn't crash when I push the refresh buttton for the first time. It will crash when I push the refresh button for about 12 times. Because the osgActivex was embeded in the html with <object></object> , it is not easy to debug. So I guess it crashes when the activex deals with the OnCreate Message or the OnDestroy Message. Luckily , I decreased the scope of the code. and found that the program could not create the GraphicsContext successfully: int CTestActiveXCtrl::OnCreate(LPCREATESTRUCT lpCreateStruct) { .... MessageBox(L"before createGraphicsContext"); osg::ref_ptr<osg::GraphicsContext> gc; gc = osg::GraphicsContext::createGraphicsContext(traits.get()); MessageBox(L"after createGraphicsContext"); .... } MessageBox(L"before createGraphicsContext"); can display, but MessageBox(L"after createGraphicsContext") can not display when crash occured. What should I do? I tried : /* m_Viewer->getSceneData()->releaseGLObjects(0); m_Viewer->releaseGLObjects(0); gc->releaseGLObjects(0); gc->releaseContext(); gc->close(); osg::discardAllDeletedGLObjects(0); */ in Ondestoy Message. But it still crashes. And I don't know how to get the parameter of the discardAllDeletedGLObjects, it needs a context Id. Thank you very much. Thank you! Cheers, Licheng ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=31744#31744 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org