@@ -244,7 +244,7 @@ function Mix_GetMusicType(music: TMix_Music): TMix_MusicType cdecl; external MIX
244244 or add a custom mixer filter for the stream data.
245245 *}
246246type
247- TMix_Func = procedure(udata: Pointer; stream: PUInt8; len: Integer);
247+ TMix_Func = procedure(udata: Pointer; stream: PUInt8; len: Integer) cdecl ;
248248
249249procedure Mix_SetPostMix (func: TMix_Func; arg: Pointer) cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_SetPostMix' { $ENDIF} { $ENDIF} ;
250250
@@ -253,12 +253,13 @@ procedure Mix_SetPostMix(func: TMix_Func; arg: Pointer) cdecl; external MIX_LibN
253253 *}
254254procedure Mix_HookMusic (func: TMix_Func; arg: Pointer) cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_HookMusic' { $ENDIF} { $ENDIF} ;
255255
256- { * Add your own callback when the music has finished playing.
257- This callback is only called if the music finishes naturally .
256+ { * Add your own callback when the music has finished playing
257+ * or when it is stopped from a call to Mix_HaltMusic .
258258 *}
259259type
260260 PMix_Music_Finished = ^TMix_Music_Finished;
261- TMix_Music_Finished = procedure();
261+ TMix_Music_Finished = procedure() cdecl;
262+
262263procedure Mix_HookMusicFinished (music_finished: PMix_Music_Finished) cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_HookMusicFinished' { $ENDIF} { $ENDIF} ;
263264
264265 { * Get a pointer to the user data for the current music hook *}
@@ -273,7 +274,8 @@ function Mix_GetMusicHookData: Pointer cdecl; external MIX_LibName {$IFDEF DELPH
273274 * before calling your callback.
274275 *}
275276type
276- TMix_Channel_Finished = procedure(channel: Integer);
277+ TMix_Channel_Finished = procedure(channel: Integer) cdecl;
278+
277279procedure Mix_ChannelFinished (channel_finished: TMix_Channel_Finished) cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_ChannelFinished' { $ENDIF} { $ENDIF} ;
278280
279281 { * Special Effects API by ryan c. gordon. (icculus@icculus.org) *}
@@ -298,7 +300,7 @@ procedure Mix_ChannelFinished(channel_finished: TMix_Channel_Finished) cdecl; ex
298300 * DO NOT EVER call SDL_LockAudio() from your callback function!
299301 *}
300302type
301- TMix_EffectFunc_t = procedure(chan: Integer; stream: Pointer; len: Integer; udata: Pointer);
303+ TMix_EffectFunc_t = procedure(chan: Integer; stream: Pointer; len: Integer; udata: Pointer) cdecl ;
302304
303305 { *
304306 * This is a callback that signifies that a channel has finished all its
@@ -310,7 +312,7 @@ procedure Mix_ChannelFinished(channel_finished: TMix_Channel_Finished) cdecl; ex
310312 * DO NOT EVER call SDL_LockAudio() from your callback function!
311313 *}
312314type
313- TMix_EffectDone_t = procedure(chan: Integer; udata: Pointer);
315+ TMix_EffectDone_t = procedure(chan: Integer; udata: Pointer) cdecl ;
314316
315317 { * Register a special effect function. At mixing time, the channel data is
316318 * copied into a buffer and passed through each registered effect function.
@@ -654,7 +656,7 @@ function Mix_SetSoundFonts(paths: PAnsiChar): Integer cdecl; external MIX_LibNam
654656function Mix_GetSoundFonts : PAnsiChar cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_GetSoundFonts' { $ENDIF} { $ENDIF} ;
655657
656658type
657- TMix_SoundFunc = function(c: PAnsiChar; p: Pointer): Integer;
659+ TMix_SoundFunc = function(c: PAnsiChar; p: Pointer): Integer cdecl ;
658660
659661function Mix_EachSoundFont (func: TMix_SoundFunc; data: Pointer): Integer cdecl; external MIX_LibName { $IFDEF DELPHI} { $IFDEF MACOS} name ' _MIX_EachSoundFont' { $ENDIF} { $ENDIF} ;
660662
0 commit comments