Just use SDL_GetScancodeFromKey.