SDL2 common mistakes and how to avoid them