Linux x86_64 implementation of libglitch : https://github.com/erlehmann/libglitch.git
x86-64
nasm
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

sdl.asm 1.2KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. EXTERN SDL_Init
  2. Extern SDL_Quit
  3. Extern SDL_SetVideoMode
  4. Extern SDL_Delay
  5. Extern SDL_OpenAudio
  6. Extern SDL_PauseAudio
  7. %define SDL_SWSURFACE 0
  8. %define AUDIO_U8 0x0008 ; Unsigned 8-bit samples
  9. %define AUDIO_S8 0x8008 ; Signed 8-bit samples
  10. %define AUDIO_U16LSB 0x0010 ; Unsigned 16-bit samples
  11. %define AUDIO_S16LSB 0x8010 ; Signed 16-bit samples
  12. %define AUDIO_U16MSB 0x1010 ; As above, but big-endian byte order
  13. %define AUDIO_S16MSB 0x9010 ; As above, but big-endian byte order
  14. %define AUDIO_U16 AUDIO_U16LSB
  15. %define AUDIO_S16 AUDIO_S16LSB
  16. STRUC SDL_AudioSpec_STRUC
  17. .freq: resw 1
  18. .format: resw 1
  19. .channels: resb 1
  20. .silence: resb 1
  21. .samples: resw 1
  22. .size: resw 1
  23. .callback: resq 1
  24. .userdata: resq 1
  25. ENDSTRUC
  26. %macro def_SDL_AudioSpec 1
  27. %define %1.freq %1+SDL_AudioSpec_STRUC.freq
  28. %define %1.format %1+SDL_AudioSpec_STRUC.format
  29. %define %1.channels %1+SDL_AudioSpec_STRUC.channels
  30. %define %1.silence %1+SDL_AudioSpec_STRUC.silence
  31. %define %1.samples %1+SDL_AudioSpec_STRUC.samples
  32. %define %1.size %1+SDL_AudioSpec_STRUC.size
  33. %define %1.callback %1+SDL_AudioSpec_STRUC.callback
  34. %define %1.userdata %1+SDL_AudioSpec_STRUC.userdata
  35. %1:
  36. ISTRUC SDL_AudioSpec_STRUC
  37. %endmacro