[osg-users] BUG?: mouse coordinate changes after window move

Robert Osfield robert.osfield at gmail.com
Thu Sep 20 01:57:54 PDT 2007

Hi Anders,

On 9/20/07, Anders Backman <andersb at cs.umu.se> wrote:
> Im using a recent svn version (a few weeks old) of osg under windows (both
> VISTA and XP).
> I have noticed that if I:
> 1. Start osgviewer cow.osg
> 2. press 'f' to get into windowed mode
> 3. if I now move the whole window and release it, I can see that the
> view/projection changes slightly.
> Another illustration:
> A small app that output the coordinates of a mouse click in the window
> 1. start that application and make it windowed 'f'
> 2. click on a specific point in the scene, ea.getX (), ea.getY() reports:
> (132, 171)
> 3. move the window a little bit, click in the same point in the scene
> ea.getX(), ea.getY() reports:  (139 ,121)
> 4. move the window again to any position on the screen, and now ea.getX (),
> ea.getY() reports consistent results.
> So to me it seems that the first move-window messes (or corrects) the
> view/projection.

This sounds like a GraphicsWindowWin32 bug in some form.

> Now I tried this on a ubuntu machine, but on that one the windowed mode did
> not work at all.
> Pressing 'f' results in a brief flicker of the window, and I can for a
> fraction of a second see a smaller cow, no window decoration in the lower
> left corner of the display.

I use Kubuntu and Suse here and both work fine for me.  Both are KDE though.

>From the sound of it it sounds like the window manager is screwing up
when no decoration is appearing when it goes into windowing mode.

Could you try :

  osgviewer --window 100 100 500 500 cow.osg

Does the mouse and window decoration work OK?


More information about the osg-users mailing list