Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Slow Event Polling (Linux x64)  (Read 12408 times)

0 Members and 1 Guest are viewing this topic.

Senzaki

  • Newbie
  • *
  • Posts: 48
    • View Profile
Re: Slow Event Polling (Linux x64)
« Reply #15 on: August 26, 2013, 04:02:21 pm »
Actually, it is not detected as a joystick in the end, because the open call fails. But if SFML tries to open it, it is because it is detected as a joystick at first. I've added printf when open is called, and it is called once per pollEvent call.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Slow Event Polling (Linux x64)
« Reply #16 on: August 26, 2013, 04:16:10 pm »
Ah, I see. I should add a flag so that joysticks that failed to open don't retry every time pollEvent is called. Sounds like a lot more sane :))
Laurent Gomila - SFML developer

Senzaki

  • Newbie
  • *
  • Posts: 48
    • View Profile
Re: Slow Event Polling (Linux x64)
« Reply #17 on: August 26, 2013, 05:48:09 pm »
In this case, would it be possible to add a function that would unset this flag ? It may be useful in some cases.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Slow Event Polling (Linux x64)
« Reply #18 on: August 26, 2013, 06:00:10 pm »
In which cases? If I fail to open an input node, I think it's safe to assume that I'll fail to open it during the lifetime of the application.
Laurent Gomila - SFML developer

Senzaki

  • Newbie
  • *
  • Posts: 48
    • View Profile
Re: Slow Event Polling (Linux x64)
« Reply #19 on: August 26, 2013, 07:41:11 pm »
You're right, if anything changes users can just restart the application.
But about the high-res mouse problem, I must admit I don't really understand why it would be inconveniant to offer the option of having mouse motion synced with the display() call, since it's an option offered by several famous commercial games (like Starcraft II).

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Slow Event Polling (Linux x64)
« Reply #20 on: August 26, 2013, 07:57:38 pm »
It might be the only solution, but I will investigate more before implementing it this way, because :

- it's ugly (as I said, it's a workaround, not a feature)
- it's very inconvenient to implement -- but I don't expect you to understand that, unless you've read the corresponding source code
Laurent Gomila - SFML developer

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Slow Event Polling (Linux x64)
« Reply #21 on: August 26, 2013, 08:54:46 pm »
The accelerometer problem should be solved with the latest commit.
Laurent Gomila - SFML developer