SDL_MouseMotionEvent origin changes when switching fullscreen

Hi,
I have noticed that when I have a windowed SDL app (0, 0) for the
SDL_MouseMotionEvent structure is taken to be the bottom left of the
window, but when I fullscreen the same app it is taken to be the top
left.

Is this supposed to be the case? It isn’t documented from what I can
tell.

This is on Mac OS X btw.–
Paul Richards
pauldoo at users.sf.net

This is a known issue, I think either the latest
release or the CVS has it fixed. If you dont’ have the
latest release, get it, if not, get CVS.

— Paul Richards <p.a.richards at sms.ed.ac.uk> wrote:> Hi,

I have noticed that when I have a windowed SDL app
(0, 0) for the
SDL_MouseMotionEvent structure is taken to be the
bottom left of the
window, but when I fullscreen the same app it is
taken to be the top
left.

Is this supposed to be the case? It isn’t
documented from what I can
tell.

This is on Mac OS X btw.


Paul Richards
pauldoo at users.sf.net


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


Do you Yahoo!?
Friends. Fun. Try the all-new Yahoo! Messenger.

Ok, well I appear to have the latest release already. I’m not too
bothered about pulling CVS for now so I’ll just make do…

Which corner for (0, 0) is correct btw? Just so that I know…On Jun 13, 2004, at 12:24 AM, Donny Viszneki wrote:

This is a known issue, I think either the latest
release or the CVS has it fixed. If you dont’ have the
latest release, get it, if not, get CVS.

— Paul Richards <p.a.richards at sms.ed.ac.uk> wrote:

Hi,
I have noticed that when I have a windowed SDL app
(0, 0) for the
SDL_MouseMotionEvent structure is taken to be the
bottom left of the
window, but when I fullscreen the same app it is
taken to be the top
left.

Is this supposed to be the case? It isn’t
documented from what I can
tell.

This is on Mac OS X btw.


Paul Richards
pauldoo at users.sf.net


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


Do you Yahoo!?
Friends. Fun. Try the all-new Yahoo! Messenger.
http://messenger.yahoo.com/


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


Paul Richards
pauldoo at users.sf.net

— Paul Richards <p.a.richards at sms.ed.ac.uk> wrote:

Ok, well I appear to have the latest release
already. I’m not too
bothered about pulling CVS for now so I’ll just make
do…

Okay, but take note that this is a Mac OS X only
problem, so if you give it to someone not on OSX,
understand your solution will just recreate the
problem on another platform.

Which corner for (0, 0) is correct btw? Just so
that I know…

Upper right hand corner. But in case you ever use
OpenGL, remember that negative Y is downward for
rendering, the opposite of mouse movement.__________________________________
Do you Yahoo!?
Friends. Fun. Try the all-new Yahoo! Messenger.

Upper right? Er…

Well, anyway. In OpenGL, negative Y is towards what you make it be, in
your projection settings.On Sun, 2004-06-13 at 10:30, Donny Viszneki wrote:

Upper right hand corner. But in case you ever use
OpenGL, remember that negative Y is downward for
rendering, the opposite of mouse movement.


Petri Latvala

— Paul Richards <p.a.richards at sms.ed.ac.uk> wrote:

Ok, well I appear to have the latest release
already. I’m not too
bothered about pulling CVS for now so I’ll just make
do…

Okay, but take note that this is a Mac OS X only
problem, so if you give it to someone not on OSX,
understand your solution will just recreate the
problem on another platform.

I was going to code as if my version of SDL was fixed. It’s only a
simple flight sim style game so a flipped mouse isn’t to big an issue
while I wait on SDL 1.2.8. :slight_smile:

Which corner for (0, 0) is correct btw? Just so
that I know…

Upper right hand corner. But in case you ever use
OpenGL, remember that negative Y is downward for
rendering, the opposite of mouse movement.

Don’t you mean Upper Left? I’ve never heard of the right hand side of
the screen being used as the origin in any system…

But yes, I know about GL using Bottom Left. :)On Jun 13, 2004, at 1:30 AM, Donny Viszneki wrote:


Paul Richards
pauldoo at users.sf.net

Upper right hand corner. But in case you ever use
OpenGL, remember that negative Y is downward for
rendering, the opposite of mouse movement.

Upper right? Er…

I think he made a typo… :slight_smile:

Well, anyway. In OpenGL, negative Y is towards what you make it be, in
your projection settings.

Indeed, but certain functions that deal directly with screen
coordinates will always use the bottom left as the origin. Setting up
a viewport is an example.On Jun 13, 2004, at 5:25 AM, Petri Latvala wrote:

On Sun, 2004-06-13 at 10:30, Donny Viszneki wrote:


Paul Richards
pauldoo at users.sf.net

— Petri Latvala wrote:

Upper right hand corner. But in case you ever use
OpenGL, remember that negative Y is downward for
rendering, the opposite of mouse movement.

Upper right? Er…

WHOOPS. I don’t know why i said RIGHT, I was very
tired…

Well, anyway. In OpenGL, negative Y is towards what
you make it be, in
your projection settings.

Well by default, negative Y is down anyway…> On Sun, 2004-06-13 at 10:30, Donny Viszneki wrote:


Do you Yahoo!?
Friends. Fun. Try the all-new Yahoo! Messenger.