The struct SDL_Keysym
has SDL_Scancode
and SDL_Keycode
members. What is the difference between them? The documentation does not really clear it up for me. I tried both and they seem to do the same thing.
See the SDL documentation. Scancodes represent the physical position of the keys, modeled after a standard QWERTY keyboard, while Keycodes are the character obtained by pressing the key.
On an AZERTY keyboard, pressing A will emit a 'Q'
scancode and an 'a'
keycode.