…rofile Note ahead, in this comment @kthakore observed issues around pump_events that i do not understand fully, and i would love if he could find the time to provide input on this: SHA-1: 4aa0251 * Need to pump before we poll to prevent skipping too many events before processing something That said, according to the documentation: http://sdl.beuc.net/sdl.wiki/SDL_PumpEvents > Often the need for calls to SDL_PumpEvents is hidden from the user > since SDL_PollEvent [...] implicitly call SDL_PumpEvents. > [...] if you are not polling or waiting for events [...] > you must call SDL_PumpEvents http://sdl.beuc.net/sdl.wiki/SDL_PollEvent > this function implicitly calls SDL_PumpEvents This means that removing it should have no deleterious effects. At the same time, its presence does seem to cause some. In the graph in this screenshot you will notice occasional red spikes at the bottom. These are caused by pump_events taking more time than ordinary, and disappear with (on Win7) no noticable side effects when pump_events is removed. Given that clear benefit, i would like to see this commit released live in a production release to see if it causes ill effects for anyone using SDL.
Previously it was easy for someone to look at the docs and assume the move handler operated in fixed steps, only discovering how wrong that is if they end up with a need to dig into the SDLx::Controller documentation. With this line it becomes obvious that the move handler takes a number of arguments and that research is necessary. And while i'm at it, also adding the arguments for the other handlers.
We built the libSDL binaries several years ago, and so it was built against an older runtime library (msvcrt.dll). Now we build SDL itself against msvcr110.dll for example, and therefore allocate on another heap than the free() is taking place, which happens in libSDL_mixer itself. See: http://stackoverflow.com/questions/23257226/sdl-mixer-mix-freechunk-crashing-on-sample-created-in-memory