Ok this has created a new problem. If I give focus to something other than my application, I cannot gain focus again. And I notice that there is no associated window via Alt+Tab or toolbar.
-----Original Message----- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Cary, Karl A. Sent: Friday, January 21, 2011 7:07 AM To: OpenSceneGraph Users Subject: Re: [osg-users] Screen Resolution Being Overriden in Twinview Thank you, thank you, thank you. That worked perfectly. -----Original Message----- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Robert Osfield Sent: Friday, January 21, 2011 3:58 AM To: OpenSceneGraph Users Subject: Re: [osg-users] Screen Resolution Being Overriden in Twinview Hi Karl, The issue you are seeing is mostly like the window manager redirecting the request for a full sized window to produce a window that fits one screen. To tell X11 to override the window manage redirect you'll need to set the Traits::overrideRedirect flag to true. Robert. On Thu, Jan 20, 2011 at 10:08 PM, Cary, Karl A. <karl.a.c...@saic.com> wrote: > I am having an issue with screen resolution in Twinview. If I am in clone > mode or non twinview, everything is fine. But when I am in twinview > otherwise, the screen resolution changes even though I am not telling it to. > It is essentially adding an invisible window decoration as that is the size > it is changing by. > > > > My setup: I have 2 monitors, one is 1280x1024, the other is 1920x1200. I > would like my application to show up on the 1280x1024 monitor and it does, > just not at 1280x1024. When I create my graphics context, I do the > following: > > > > osg::ref_ptr<osg::GraphicsContext::Traits> traits = new > osg::GraphicsContext::Traits; > > traits->x = 0; > > traits->y = 0; > > traits->width = 1280; > > traits->height = 1024; > > traits->windowDecoration = false; > > traits->windowName = "myApp"; > > traits->doubleBuffer = true; > > traits->sharedContext = 0; > > > > osg::DisplaySettings* ds = osg::DisplaySettings::instance(); > > traits->sampleBuffers = ds->getMultiSamples; > > traits->samples = ds->getNumMultiSamples(); > > > > osg::ref_ptr<osg::GraphicsContext> gc = > osg::GraphicsContext::createGraphicsContext(traits.get()); > > > > At this point if I pause my program, the resolution is already wrong. It is > starting at 0,0, but it is missing the far right and bottom, about the size > of the window decoration border. If I then go through and get the window out > of the osgViewer and do a window->setWindowRectangle(0,0,1280,1024), the > screen goes full screen again. However any time I do anything at all to the > viewer or wsi or window, or sets back to the other size. For example if I do > a window->useCursor(true) call it resets. > > > > What am I doing wrong? I know it is not a driver issue as this was formerly > a Performer app and it works just fine in there with the same system so it > has to either be an issue in OSG (I doubt) or an error in how I am setting > up the window. Thank you. > > > > _______________________________________________ > osg-users mailing list > osg-users@lists.openscenegraph.org > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g > > _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org