EXTERN SDL_Init Extern SDL_Quit Extern SDL_Delay Extern SDL_OpenAudio Extern SDL_PauseAudio Extern SDL_WaitEvent Extern SDL_GetError %ifdef SDL1 %define SDL_QUIT 0x0C Extern SDL_SetVideoMode %endif %ifdef SDL2 ; events %define SDL_QUIT 0x100 %define SDL_AUDIODEVICEADDED 0x1100 ; values %define SDL_WINDOWPOS_UNDEFINED_MASK 0x1FFF0000 %define SDL_WINDOWPOS_UNDEFINED SDL_WINDOWPOS_UNDEFINED_MASK | 0 ; display 0 ; function Extern SDL_CreateWindow %endif %ifdef MIX_AUDIO Extern SDL_MixAudio %define SDL_MAX_VOLUME 128 %endif %define SDL_SWSURFACE 0 %define AUDIO_U8 0x0008 ; Unsigned 8-bit samples %define AUDIO_S8 0x8008 ; Signed 8-bit samples %define AUDIO_U16LSB 0x0010 ; Unsigned 16-bit samples %define AUDIO_S16LSB 0x8010 ; Signed 16-bit samples %define AUDIO_U16MSB 0x1010 ; As above, but big-endian byte order %define AUDIO_S16MSB 0x9010 ; As above, but big-endian byte order %define AUDIO_U16 AUDIO_U16LSB %define AUDIO_S16 AUDIO_S16LSB STRUC SDL_AudioSpec_STRUC .freq: resw 1 .format: resw 1 .channels: resb 1 .silence: resb 1 .samples: resw 1 .size: resw 1 .callback: resq 1 .userdata: resq 1 ENDSTRUC %macro def_SDL_AudioSpec 1 %define %1.freq %1+SDL_AudioSpec_STRUC.freq %define %1.format %1+SDL_AudioSpec_STRUC.format %define %1.channels %1+SDL_AudioSpec_STRUC.channels %define %1.silence %1+SDL_AudioSpec_STRUC.silence %define %1.samples %1+SDL_AudioSpec_STRUC.samples %define %1.size %1+SDL_AudioSpec_STRUC.size %define %1.callback %1+SDL_AudioSpec_STRUC.callback %define %1.userdata %1+SDL_AudioSpec_STRUC.userdata %1: ISTRUC SDL_AudioSpec_STRUC %endmacro