i was wondering what is the correct workflow of api calls to create/destroy sdl mixer?
currently this is the logic:
SDL_Init(SDL_INIT_TIMER | SDL_INIT_AUDIO | SDL_INIT_VIDEO | SDL_INIT_EVENTS) Mix_OpenAudio(44100, MIX_DEFAULT_FORMAT, 2, 512)
should i also call
After a lot of testing and experimentation, this is the order I do it:
And to shut down:
(stop all playing channels and music)
(free all sound and music chunks)
Other combinations result in crashes.
Pretty sure Mix_Init should be called before Mix_OpenAudio. Why would it crash?