#17 mouse movement (not just position)

open
nobody
None
5
2003-11-22
2003-11-22
No

int glutMouseMoveFunc(int (*fnMouseMoveCallback)(int
dx, int dy));

that mouse move must be active for as long as the
window is in focus (like passive motion gets odd when
mouse leave the window area).

Discussion

  • Nigel Stewart

    Nigel Stewart - 2003-11-24

    Logged In: YES
    user_id=338692

    Sounds like a convenient thing, but...

    In what order would an application expect to receive mouse
    motion and mouse "delta" events?

    How about an alternative extended mouse motion callback that
    provided both position and deltas?

    Nigel

     
  • Misiek

    Misiek - 2003-11-25

    Logged In: YES
    user_id=917308

    >How about an alternative extended mouse motion callback
    that
    >provided both position and deltas?

    Both ways seems ok, but when you decide to add this then
    please make possibility of lock of pointer at specified
    coordinates. Delta with moving cursor still doesnt changes
    anything because its easy to count it. Most problematic thing
    is to keep cursor inside certain window. (Maybe this is
    implemented already, it isnt in old glut). Using glutWarpPointer
    is really annoying because f.e. while loading big files you can
    easily move mouse outside window (or subwindow which is my
    program case). Something like glutLockPointer(int x, int y)
    would be very handy.
    Misiek

     
  • Richard Rauch

    Richard Rauch - 2004-02-04

    Logged In: YES
    user_id=854844

    In addition to what you report about historic GLUT on MS-WINDOWS, *both* GLUT and freeglut behave that way in UNIX_X11. (Holding down a button "grabs" the focus to the current window.) This is actually an automatic feature in X.

    I wasn't aware that WIN32 did not implement this. IMHO, this is a pretty big disparity, and WIN32 freeglut is the odd man out. (UNIX_X11 in both GLUT and freeglut grabs the mouse; old GLUT in WIN32 grabbed the mouse.)

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks