[osg-users] 2 viewers vs. 1 viewer with 2 cameras
Hello I'm writing an application which needs multiple cameras. Some will look at the same scenedata, some won't. Some will move together, and some will need their own seperate position update. I have 2 options I'm considering: 1: composite viewer with multiple viewers 2: 1 simple viewer with slave cameras I don't know for sure which option to choose. If I choose #2, can I set a different camera manipulator for each slave cameras? On the other hand, if I choose #1 will it run slower? (I could have as many as 100 cameras/viewers) Any tips will be appreciated ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Farewell 2007, It's 2008, Happy New Year!!!
I would like to pass on my thanks to all those who contributed to the OpenSceneGraph project through 2007. Thank you!! A thoroughly packed year 2007 was too: . new build system . new viewer library . new version control system . new Tracs based website . new servers/admins/mailing list hosting . 2.0 and 2.2 stable releases . New weekly developer release system in the run up to major releases. . The publication of the Quick Start Guide . The publication of the 1.2, 2.0 and 2.2 Reference manuals And that's just a selection, lots more has happened besides, within the software, as well as out in the community. At a personal level I've struggled with Repetitive Strain Injury in my wrists that struck me down last spring and still dogs me today - I pushed too hard, working 60hrs weeks for too many months on a trot, and finally my body broke. In hindsight this was an entirely predictable consequence and was avoidable, and if I had worked less hard through the winter of 2006/2007 I would have achieved more over the whole year and under much less physically and mentally stressful conditions. A lesson to learn certainly for myself, but I write here in hope that others can learn from my errors, and avoid the trap over trying to work yourself out of a hole by working all hours, but in the end only digging a deeper hole for oneself. I guess this is a lesson to learn for individuals, teams and whole communities both as groups and looking out for those within teams/communities that could be in danger of overdoing it and burning out in the process. 2007 was the first full year that we've had to cope without the Don Burn's hearty presence, contributions and support. The beginning of 2007 was very bleak, both physicals systems that once were in place had to be rebuilt, re-hosted and re-manned, and also hole in character of the project - you can find new servers and admins, but you can't find another Don. This major loss was a real challenge for the OpenSceneGraph community, and thankfully many individuals within the community stood up and helped provide the initial safe passage and then bedrock on which the project could find its footing and move forward. One year on from the bleak start to 2007, I am relieved to be able to reflect on how things turned out, sure have plenty of regrets but I really do marvel at the generosity and effort that people have put in over the past year, its this is what has achieved the above headline items, and perhaps more importantly restored the overall project health so that we can confidently look forward to 2008 and beyond. Looking forward to 2008, what will it bring? Ooo lots of goodies :-) May all your code compile and run perfectly first time through 2008 and beyond! Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] 2 viewers vs. 1 viewer with 2 cameras
Hi Roni, The CompositeViewer is written specifically to address your usage model. In 2.2 there is no performance and feature penalty in use CompositeViewer instead of Viewer as they both now use the same ViewerBase class that provides all the threading and rendering setup. The key difference between the two class is conceptual and functional associated with high level view management - CompositeViewer has one or more Views, Viewer is a View. While a single View can have multiple slaves these slaves aren't meant to support the rendering of a single view - for instance a single view out of car through multiple windows uses multiple slave cameras that all relative to the master camera's projection and view matrix - what they aren't intended to do are have provide multiple views from multiple cars. As soon as you start mixing multiple views within a single View you are in really tangled mess both conceptually and functionally, and with such a mess will come confusion and bugs. Robert. On Jan 1, 2008 8:21 AM, Roni Rosenzweig [EMAIL PROTECTED] wrote: Hello I'm writing an application which needs multiple cameras. Some will look at the same scenedata, some won't. Some will move together, and some will need their own seperate position update. I have 2 options I'm considering: 1: composite viewer with multiple viewers 2: 1 simple viewer with slave cameras I don't know for sure which option to choose. If I choose #2, can I set a different camera manipulator for each slave cameras? On the other hand, if I choose #1 will it run slower? (I could have as many as 100 cameras/viewers) Any tips will be appreciated ___ 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
Re: [osg-users] osgViewer
Thanks for the info Rafa. I appear to have something working. I my KMapView class is derived from QGLWidget and osgViewer::Viewer. The application compiled successfully. To test it I tried to open cube.osg that came with my osg source. It appeared to open the file. It was a yellow cube with a symbol that looked like a lamda. However, when the file was opened it was showing full screen. My question is how do you keep this from happening? Was it the file or is there something wrong in my code? Thanks, Michael On Thu, 2007-12-27 at 08:18 +0100, Rafa Gaitan wrote: Hi Michael, I'm not an expert in QT, but probably you can take a look to osgviewerQT example inside OSG source tree. Rafa. On Dec 27, 2007 4:35 AM, Michael W. Hall [EMAIL PROTECTED] wrote: I have created a KDevelop project using the Application framework template. I have made my kmapview.cpp class derive from QGLWidget. I created a member variable, m_Viewer in the KMapView class. I have in my constructor for KMapView the following: m_Viewer.getCamera()-setProjectionMatrixAsPerspective( 40., 1., 1., 100. ); m_Viewer.getCamera()-setClearColor( osg::Vec4( 0., 0., 0., 1. ) ); However, it doesn't appear that anything is changing. I ran the application after creating the project to see how it looked. With the above changes, it appears that nothing is being effected. The window still looks the same as when I first ran it. I have still have a window with a white background. I have attached a picture of the application running. I was hoping the big white field would have changed to an osgViewer as the window where the white field is. Any ideas as how to replace the white field with an osgViewer? I am a beginner with OSG. I am playing to learn. I have read the OpenSceneGraph Quick Start Quide. Thanks for any help. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- Rafael Gaitán Linares Instituto de Automática e Informática Industrial http://www.ai2.upv.es Ciudad Politécnica de la Innovación Universidad Politécnica de Valencia ___ 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
[osg-users] unable to create opengl rendering context
Hi, all: First of all, Happy New Year and Good Luck in 2008. Then there's my problem: I was immigrating from osg 2.0 to osg 2.3 with the new QOSGWidget which is derived directly from Qwidget but QGLWidget, and my programming environment is Windows 2003 server, visual studio 2005, during the initialization of the programming, it crashed. Windows Error #2000: [Screen #0] GraphicsWindowWin32::setWindow() - Unable to create OpenGL rendering context. Reason: The pixel format is invalid. I tracked down, and I found that the creation of graphics context failed, and the stack is like following: if (s_WindowingSystemInterface.valid()) return s_WindowingSystemInterface-createGraphicsContext(traits); in osg::ref_ptrosg::GraphicsContext gc = osg::GraphicsContext::createGraphicsContext(traits.get()); and I checked that my s_WindowingSystemInterface is surely Win32WindowingSystem , but the GraphicsWindowWin32::setWindow( HWND handle ) and the osg::GraphicsContext* createGraphicsContext( osg::GraphicsContext::Traits* traits ) is never called(the breakpoints didn't caught them). I don't know why this happens, hope someone can give me some hint. I want gain some performance by immigrating to the new QOSGWidget, but this problem stuck me for really a long time. Shuxing Xiao 2008-1-1 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osgViewer
Hi Michael, mmh I don't know, I successfully created a Viewer in Java, so, probably you are missingsomething...Have you called to setUpViewerAsEmbedded method?.. .You should have all you need in the viewer examples of the OSG source tree. Rafa. On Jan 1, 2008 11:45 PM, Michael W. Hall [EMAIL PROTECTED] wrote: Thanks for the info Rafa. I appear to have something working. I my KMapView class is derived from QGLWidget and osgViewer::Viewer. The application compiled successfully. To test it I tried to open cube.osg that came with my osg source. It appeared to open the file. It was a yellow cube with a symbol that looked like a lamda. However, when the file was opened it was showing full screen. My question is how do you keep this from happening? Was it the file or is there something wrong in my code? Thanks, Michael On Thu, 2007-12-27 at 08:18 +0100, Rafa Gaitan wrote: Hi Michael, I'm not an expert in QT, but probably you can take a look to osgviewerQT example inside OSG source tree. Rafa. On Dec 27, 2007 4:35 AM, Michael W. Hall [EMAIL PROTECTED] wrote: I have created a KDevelop project using the Application framework template. I have made my kmapview.cpp class derive from QGLWidget. I created a member variable, m_Viewer in the KMapView class. I have in my constructor for KMapView the following: m_Viewer.getCamera()-setProjectionMatrixAsPerspective( 40., 1., 1., 100. ); m_Viewer.getCamera()-setClearColor( osg::Vec4( 0., 0., 0., 1. ) ); However, it doesn't appear that anything is changing. I ran the application after creating the project to see how it looked. With the above changes, it appears that nothing is being effected. The window still looks the same as when I first ran it. I have still have a window with a white background. I have attached a picture of the application running. I was hoping the big white field would have changed to an osgViewer as the window where the white field is. Any ideas as how to replace the white field with an osgViewer? I am a beginner with OSG. I am playing to learn. I have read the OpenSceneGraph Quick Start Quide. Thanks for any help. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- Rafael Gaitán Linares Instituto de Automática e Informática Industrial http://www.ai2.upv.es Ciudad Politécnica de la Innovación Universidad Politécnica de Valencia ___ 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 -- Rafael Gaitán Linares Instituto de Automática e Informática Industrial http://www.ai2.upv.es Ciudad Politécnica de la Innovación Universidad Politécnica de Valencia ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org