Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: Two mouses?

  1. #1
    Junior Member Newbie
    Join Date
    Oct 2004
    Location
    Poland
    Posts
    5

    Two mouses?

    Hi!
    I have a question: Is that possible to use two mouses in OpenGL? I'm working on 3D FPS game with SPlit-Screen, and I want to make two players uses two mouses (first mouse must be indepentend from second one). I don't want to show two cursors, I only want to check positions and states (for example LBUTTONDOWN) both of mouses...

  2. #2
    Intern Contributor
    Join Date
    Apr 2002
    Posts
    87

    Re: Two mouses?

    What kind of wanker posts a topic about using mice (yes, that's the plural of mouse) on the OpenGL Advanced forum? Just because your program has a glBegin() function?

    Please set your internet to read-only.

  3. #3
    Junior Member Newbie
    Join Date
    Oct 2004
    Location
    Poland
    Posts
    5

    Re: Two mouses?

    Sorry...
    I have been looking on other forums, but I couldn't find anything interesting. I think that people who spend many days (weeks? months?) on coding in OpenGL should know answer for my question. Lets say, there was no question. OK?
    Sorry also for mistake with mouse - mice, but I'm not native. Now I will remember that...

  4. #4
    Senior Member OpenGL Pro
    Join Date
    May 2001
    Location
    The Round Table at Camelot
    Posts
    1,537

    Re: Two mouses?

    Is it even possible to use more than one mouse at once? I have never seen or heard of any one ever doing such a thing. I'm not sure if any OS is able to handle more than one mouse at once. To me it doesn't make much sense, kind of like having two or more keyboards connected. Now having multiple monitors makes sense but anything else...I just don't know about.

    -SirKnight
    -SirKnight

  5. #5
    Member Regular Contributor
    Join Date
    May 2002
    Posts
    273

    Re: Two mouses?

    Never tried such thing, but I know DirectInput is designed to cope with such configurations.

    pszemsza, Just try plugging 2 USB mice and use this function . If DirectX does what it promises, you should get both mice enumerated. If you need help on DirectInput, you will have to look for it somewhere else - OpenGL forum is wrong place.

    As for mouses/mice, I pretty often find native English speaking people writing "vertexes" and "indexes", instead of "vertices" an "indices"

    (edit) Hmm, according to http://dictionary.reference.com/search?q=vertex, the "vertexes" is correct form too... Never mind, then.

  6. #6
    Junior Member Regular Contributor
    Join Date
    Jun 2003
    Location
    Virginia
    Posts
    215

  7. #7
    Senior Member OpenGL Pro
    Join Date
    May 2001
    Location
    The Round Table at Camelot
    Posts
    1,537

    Re: Two mouses?

    Ah...so it IS possible. And now I see some usefull uses for doing such a thing. Neat.

    -SirKnight
    -SirKnight

  8. #8
    Junior Member Newbie
    Join Date
    Oct 2004
    Location
    Poland
    Posts
    5

    Re: Two mouses?

    Thanks all of you for your help...
    Tell me if I'm wrong, but I think that in Settlers II there were option to play with two mice on one computer...
    BTW: I think "vertexes" are better
    than "mouses"
    Thanks one more time...

  9. #9
    Advanced Member Frequent Contributor arekkusu's Avatar
    Join Date
    Nov 2003
    Posts
    676

    Re: Two mouses?

    Just for some historical reference, this has been possible since at least 1986. Keyboards and mice are just input devices, like joysticks. There's no reason to expect multiple devices not to work. (How you handle them in your app is of course up to you.)

  10. #10
    Advanced Member Frequent Contributor
    Join Date
    Aug 2001
    Location
    Italy
    Posts
    628

    Re: Two mouses?

    I must say I had some troubles when I tried to use two mice togheter.
    I used DI8 and device enumeration but it didn't work as expected, sometimes the inputs were intermixed. I didn't investigate it too much however and it's likely I was doing something really wrong and easy to fix.
    I'll want to look at this in the future again so I would be glad to read something interesting.

    Fine, it's off topic. I realize it but that's interesting anyway.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •