Re: [osg-users] window position and size

2011-12-12 Thread Guy Volckaert
you caj also use the environment variable OSG_WINDOW, e.g.:

set OSG_WINDOW = 40 40 640 480

Note: space delimited.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=44341#44341





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] window position and size

2009-06-30 Thread Robert Osfield
Hi Guy,

To set the size and position of a window you use the
osgViewer::GraphicsWindow method:

/** Set the window's position and size.*/
void setWindowRectangle(int x, int y, int width, int height)

The GraphicsContext::resized() method only informs the context that
the window has been resized and that it needs to update it's cameras
aspect ratios/viewports.

Robert.

On Tue, Jun 30, 2009 at 1:14 AM, Guy Volckaertguy.volcka...@meggitt.com wrote:
 Hi,

 I've implemented the osg::GraphicsContext::ResizedCallback to get notified 
 when the user resizes the window via the mouse. That work perfectly.

 However, I also need to change the window size programatically (when the user 
 presses a button, for example). I tried calling 
 osg::GraphicsContext::resized() function, but that does not always work.

 Apart from calling ::SetWindowPos(), is there an osg call that allow the 
 windows position and size to be adjusted?

 Guy

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=14668#14668





 ___
 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] window position and size

2009-06-30 Thread Guy Volckaert
You're the man!!!

Thanks.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=14697#14697





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] window position and size

2009-06-29 Thread Guy Volckaert
Hi,

I've implemented the osg::GraphicsContext::ResizedCallback to get notified when 
the user resizes the window via the mouse. That work perfectly. 

However, I also need to change the window size programatically (when the user 
presses a button, for example). I tried calling osg::GraphicsContext::resized() 
function, but that does not always work. 
 
Apart from calling ::SetWindowPos(), is there an osg call that allow the 
windows position and size to be adjusted?

Guy

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=14668#14668





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org