commit 37aa6660f10d03de812a8be52781024cf9fc72a8
parent e39c05aa093cdef610e327ca3b1f62db11be9d18
Author: Amin Mesbah <dev@aminmesbah.com>
Date: Tue, 19 Nov 2019 21:53:42 -0800
Add comment about GLFW input bug and its effects
The culmination of multiple hours of debuggig my software and hardware
and questioning my sanity.
Diffstat:
1 file changed, 16 insertions(+), 0 deletions(-)
diff --git a/src/platform_linux.c b/src/platform_linux.c
@@ -130,6 +130,22 @@ int main(void)
// TODO: Do something sane when vsync is disabled
glfwSwapBuffers(window);
+
+ // ಠ_ಠ: We are affected here by a GLFW bug [1]. On my Thinkpad X220, if
+ // I use the built-in keyboard, simultaneous key events sometimes get
+ // dropped. This causes, for example, a press of the jump key to often
+ // not be registered when the left or right arrow key is pressed
+ // simultaneously.
+ //
+ // If I plug in my beloved Leopold FC750R, the problem does not
+ // manifest.
+ //
+ // I have reproduced this behavior using glfw/tests/events.c
+ //
+ // TODO: Ditch GLFW on Linux, hope this gets fixed soon, or build it
+ // from source and apply the workaround discussed in [1].
+ //
+ // [1] https://github.com/glfw/glfw/issues/1112
glfwPollEvents();
}