Coalesce rapid mouse movements in games
- Lingua principale
- Haskell
- Stelle
- 1.3k
- Fork
- 201
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Games generate a LOT of mouse movement events, which are each propagated to all clients. We should be able to reduce this. For example, suppose each client tracked when it already had a mouse movement sent within the last 50 milliseconds; and if so, coalesced all consecutive mouse events and postponed broadcasting them until 50 milliseconds had passed.
We could also look into a trick similar to the redraw-avoidance. It's less straight-forward, though, because even if the MouseMovement doesn't modify local states, it still needs to be sent because it might matter in whatever (as yet unknown) state the game will be in, in the merged canonical event stream. So that's not great. BUT, if we could introspect that MouseMovement events are _always_ the identity function for a given game, then we could save a lot of traffic.
It's not immediately clear to me how to discover this. @nomeata knows a fair bit about this: any ideas?
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.