SDL_mixer: mixer.c: updated after the latest SDL3 audio api changes

From 9222a1e16f5ba38585c4ca3e83b934a5f3470105 Mon Sep 17 00:00:00 2001
From: Ozkan Sezer <[EMAIL REDACTED]>
Date: Mon, 28 Aug 2023 12:28:00 +0300
Subject: [PATCH] mixer.c: updated after the latest SDL3 audio api changes

---
 src/mixer.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/mixer.c b/src/mixer.c
index 748c4100..8ae898c4 100644
--- a/src/mixer.c
+++ b/src/mixer.c
@@ -340,7 +340,7 @@ static void *Mix_DoEffects(int chan, void *snd, int len)
 
 /* Mixing function */
 static void SDLCALL
-mix_channels(SDL_AudioStream *astream, int len, void *udata)
+mix_channels(void *udata, SDL_AudioStream *astream, int len)
 {
     Uint8 *stream;
     Uint8 *mix_input;
@@ -515,14 +515,14 @@ int Mix_OpenAudio(SDL_AudioDeviceID devid, const SDL_AudioSpec *spec)
     }
 
     SDL_GetAudioDeviceFormat(audio_device, &mixer);
-
-    audio_stream = SDL_CreateAndBindAudioStream(audio_device, &mixer);
+    audio_stream = SDL_CreateAudioStream(&mixer, &mixer);
     if (!audio_stream) {
         SDL_CloseAudioDevice(audio_device);
         audio_device = 0;
         return -1;
     }
 
+    SDL_BindAudioStream(audio_device, audio_stream);
     SDL_SetAudioStreamGetCallback(audio_stream, mix_channels, NULL);
 
 #if 0