From d8239786b306ffda6d5d73753d01f0ad3358e1a0 Mon Sep 17 00:00:00 2001 From: Jesse Hall Date: Tue, 17 Jul 2012 16:58:55 -0700 Subject: Delete sdl-1.2.12 Change-Id: Ia96f80df04035ae84be3af468c945f2cec14f99c --- distrib/sdl-1.2.12/BUGS | 18 - distrib/sdl-1.2.12/COPYING | 458 -- distrib/sdl-1.2.12/CREDITS | 92 - distrib/sdl-1.2.12/Makefile | 71 - distrib/sdl-1.2.12/Makefile.android | 93 - distrib/sdl-1.2.12/README | 49 - distrib/sdl-1.2.12/README.ANDROID | 9 - distrib/sdl-1.2.12/android-configure.sh | 553 -- distrib/sdl-1.2.12/include/SDL.h | 94 - distrib/sdl-1.2.12/include/SDL_active.h | 58 - distrib/sdl-1.2.12/include/SDL_audio.h | 253 - distrib/sdl-1.2.12/include/SDL_byteorder.h | 24 - distrib/sdl-1.2.12/include/SDL_cdrom.h | 171 - distrib/sdl-1.2.12/include/SDL_config.h.default | 45 - distrib/sdl-1.2.12/include/SDL_config.h.in | 305 - distrib/sdl-1.2.12/include/SDL_config_amiga.h | 80 - distrib/sdl-1.2.12/include/SDL_config_dreamcast.h | 106 - distrib/sdl-1.2.12/include/SDL_config_macos.h | 112 - distrib/sdl-1.2.12/include/SDL_config_macosx.h | 135 - distrib/sdl-1.2.12/include/SDL_config_minimal.h | 62 - distrib/sdl-1.2.12/include/SDL_config_os2.h | 141 - distrib/sdl-1.2.12/include/SDL_config_win32.h | 180 - distrib/sdl-1.2.12/include/SDL_copying.h | 22 - distrib/sdl-1.2.12/include/SDL_cpuinfo.h | 75 - distrib/sdl-1.2.12/include/SDL_endian.h | 194 - distrib/sdl-1.2.12/include/SDL_error.h | 61 - distrib/sdl-1.2.12/include/SDL_events.h | 337 - distrib/sdl-1.2.12/include/SDL_getenv.h | 24 - distrib/sdl-1.2.12/include/SDL_joystick.h | 167 - distrib/sdl-1.2.12/include/SDL_keyboard.h | 121 - distrib/sdl-1.2.12/include/SDL_keysym.h | 311 - distrib/sdl-1.2.12/include/SDL_loadso.h | 74 - distrib/sdl-1.2.12/include/SDL_main.h | 98 - distrib/sdl-1.2.12/include/SDL_mouse.h | 136 - distrib/sdl-1.2.12/include/SDL_mutex.h | 162 - distrib/sdl-1.2.12/include/SDL_name.h | 11 - distrib/sdl-1.2.12/include/SDL_opengl.h | 6551 -------------------- distrib/sdl-1.2.12/include/SDL_platform.h | 100 - distrib/sdl-1.2.12/include/SDL_quit.h | 50 - distrib/sdl-1.2.12/include/SDL_rwops.h | 144 - distrib/sdl-1.2.12/include/SDL_stdinc.h | 594 -- distrib/sdl-1.2.12/include/SDL_syswm.h | 226 - distrib/sdl-1.2.12/include/SDL_thread.h | 119 - distrib/sdl-1.2.12/include/SDL_timer.h | 115 - distrib/sdl-1.2.12/include/SDL_types.h | 24 - distrib/sdl-1.2.12/include/SDL_version.h | 85 - distrib/sdl-1.2.12/include/SDL_video.h | 922 --- distrib/sdl-1.2.12/include/begin_code.h | 156 - distrib/sdl-1.2.12/include/close_code.h | 41 - distrib/sdl-1.2.12/sdl-config.in | 61 - distrib/sdl-1.2.12/sources.make | 244 - distrib/sdl-1.2.12/src/SDL.c | 350 -- distrib/sdl-1.2.12/src/SDL_error.c | 238 - distrib/sdl-1.2.12/src/SDL_error_c.h | 58 - distrib/sdl-1.2.12/src/SDL_fatal.c | 134 - distrib/sdl-1.2.12/src/SDL_fatal.h | 28 - distrib/sdl-1.2.12/src/audio/SDL_audio.c | 695 --- distrib/sdl-1.2.12/src/audio/SDL_audio_c.h | 34 - distrib/sdl-1.2.12/src/audio/SDL_audiocvt.c | 1510 ----- distrib/sdl-1.2.12/src/audio/SDL_audiodev.c | 179 - distrib/sdl-1.2.12/src/audio/SDL_audiodev_c.h | 26 - distrib/sdl-1.2.12/src/audio/SDL_audiomem.h | 25 - distrib/sdl-1.2.12/src/audio/SDL_mixer.c | 258 - distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.c | 206 - distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.h | 15 - distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.c | 181 - distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.h | 36 - distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.c | 211 - distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.h | 36 - distrib/sdl-1.2.12/src/audio/SDL_sysaudio.h | 184 - distrib/sdl-1.2.12/src/audio/SDL_wave.c | 597 -- distrib/sdl-1.2.12/src/audio/SDL_wave.h | 62 - distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.c | 538 -- distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.h | 54 - .../sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.c | 337 - .../sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.h | 60 - distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.c | 348 -- distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.h | 60 - distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.cc | 225 - distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.h | 39 - distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.c | 404 -- distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.h | 58 - distrib/sdl-1.2.12/src/audio/dart/SDL_dart.c | 441 -- distrib/sdl-1.2.12/src/audio/dart/SDL_dart.h | 63 - distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.c | 246 - distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.h | 41 - distrib/sdl-1.2.12/src/audio/dc/aica.c | 271 - distrib/sdl-1.2.12/src/audio/dc/aica.h | 40 - distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.c | 186 - distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.h | 41 - distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.c | 455 -- distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.h | 59 - .../sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.c | 242 - .../sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.h | 45 - distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.c | 340 - distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.h | 53 - .../sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.c | 156 - .../sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.h | 40 - distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.c | 323 - distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.h | 57 - .../sdl-1.2.12/src/audio/macosx/SDL_coreaudio.c | 277 - .../sdl-1.2.12/src/audio/macosx/SDL_coreaudio.h | 46 - distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.c | 496 -- distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.h | 50 - distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.c | 215 - distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.h | 153 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.c | 361 -- .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.h | 85 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.c | 436 -- .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.h | 108 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_it.S | 281 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.c | 404 -- .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.h | 59 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.c | 323 - .../sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.h | 100 - .../src/audio/mint/SDL_mintaudio_xbios.c | 495 -- distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.c | 264 - distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.h | 51 - distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.c | 299 - distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.h | 62 - distrib/sdl-1.2.12/src/audio/nto/SDL_nto_audio.c | 507 -- distrib/sdl-1.2.12/src/audio/nto/SDL_nto_audio.h | 68 - distrib/sdl-1.2.12/src/audio/paudio/SDL_paudio.c | 511 -- distrib/sdl-1.2.12/src/audio/paudio/SDL_paudio.h | 57 - distrib/sdl-1.2.12/src/audio/sun/SDL_sunaudio.c | 432 -- distrib/sdl-1.2.12/src/audio/sun/SDL_sunaudio.h | 55 - distrib/sdl-1.2.12/src/audio/ums/SDL_umsaudio.c | 547 -- distrib/sdl-1.2.12/src/audio/ums/SDL_umsaudio.h | 50 - distrib/sdl-1.2.12/src/audio/windib/SDL_dibaudio.c | 343 - distrib/sdl-1.2.12/src/audio/windib/SDL_dibaudio.h | 53 - distrib/sdl-1.2.12/src/audio/windx5/SDL_dx5audio.c | 705 --- distrib/sdl-1.2.12/src/audio/windx5/SDL_dx5audio.h | 55 - distrib/sdl-1.2.12/src/audio/windx5/directx.h | 84 - distrib/sdl-1.2.12/src/cdrom/SDL_cdrom.c | 341 - distrib/sdl-1.2.12/src/cdrom/SDL_syscdrom.h | 76 - distrib/sdl-1.2.12/src/cdrom/aix/SDL_syscdrom.c | 660 -- distrib/sdl-1.2.12/src/cdrom/beos/SDL_syscdrom.cc | 412 -- distrib/sdl-1.2.12/src/cdrom/bsdi/SDL_syscdrom.c | 542 -- distrib/sdl-1.2.12/src/cdrom/dc/SDL_syscdrom.c | 167 - distrib/sdl-1.2.12/src/cdrom/dummy/SDL_syscdrom.c | 41 - .../sdl-1.2.12/src/cdrom/freebsd/SDL_syscdrom.c | 406 -- distrib/sdl-1.2.12/src/cdrom/linux/SDL_syscdrom.c | 564 -- distrib/sdl-1.2.12/src/cdrom/macos/SDL_syscdrom.c | 525 -- .../sdl-1.2.12/src/cdrom/macos/SDL_syscdrom_c.h | 140 - .../sdl-1.2.12/src/cdrom/macosx/AudioFilePlayer.c | 354 -- .../sdl-1.2.12/src/cdrom/macosx/AudioFilePlayer.h | 170 - .../src/cdrom/macosx/AudioFileReaderThread.c | 605 -- distrib/sdl-1.2.12/src/cdrom/macosx/CDPlayer.c | 628 -- distrib/sdl-1.2.12/src/cdrom/macosx/CDPlayer.h | 69 - .../sdl-1.2.12/src/cdrom/macosx/SDLOSXCAGuard.c | 199 - .../sdl-1.2.12/src/cdrom/macosx/SDLOSXCAGuard.h | 116 - distrib/sdl-1.2.12/src/cdrom/macosx/SDL_syscdrom.c | 505 -- .../sdl-1.2.12/src/cdrom/macosx/SDL_syscdrom_c.h | 136 - distrib/sdl-1.2.12/src/cdrom/mint/SDL_syscdrom.c | 317 - .../sdl-1.2.12/src/cdrom/openbsd/SDL_syscdrom.c | 415 -- distrib/sdl-1.2.12/src/cdrom/os2/SDL_syscdrom.c | 393 -- distrib/sdl-1.2.12/src/cdrom/osf/SDL_syscdrom.c | 444 -- distrib/sdl-1.2.12/src/cdrom/qnx/SDL_syscdrom.c | 551 -- distrib/sdl-1.2.12/src/cdrom/win32/SDL_syscdrom.c | 385 -- distrib/sdl-1.2.12/src/cpuinfo/SDL_cpuinfo.c | 446 -- distrib/sdl-1.2.12/src/events/SDL_active.c | 91 - distrib/sdl-1.2.12/src/events/SDL_events.c | 500 -- distrib/sdl-1.2.12/src/events/SDL_events_c.h | 80 - distrib/sdl-1.2.12/src/events/SDL_expose.c | 51 - distrib/sdl-1.2.12/src/events/SDL_keyboard.c | 578 -- distrib/sdl-1.2.12/src/events/SDL_mouse.c | 263 - distrib/sdl-1.2.12/src/events/SDL_quit.c | 92 - distrib/sdl-1.2.12/src/events/SDL_resize.c | 75 - distrib/sdl-1.2.12/src/events/SDL_sysevents.h | 46 - distrib/sdl-1.2.12/src/file/SDL_rwops.c | 612 -- distrib/sdl-1.2.12/src/hermes/COPYING.LIB | 438 -- distrib/sdl-1.2.12/src/hermes/HeadMMX.h | 100 - distrib/sdl-1.2.12/src/hermes/HeadX86.h | 186 - distrib/sdl-1.2.12/src/hermes/README | 13 - distrib/sdl-1.2.12/src/hermes/common.inc | 9 - distrib/sdl-1.2.12/src/hermes/mmx_main.asm | 74 - distrib/sdl-1.2.12/src/hermes/mmxp2_32.asm | 405 -- distrib/sdl-1.2.12/src/hermes/x86_main.asm | 75 - distrib/sdl-1.2.12/src/hermes/x86p_16.asm | 490 -- distrib/sdl-1.2.12/src/hermes/x86p_32.asm | 1045 ---- distrib/sdl-1.2.12/src/joystick/SDL_joystick.c | 573 -- distrib/sdl-1.2.12/src/joystick/SDL_joystick_c.h | 38 - distrib/sdl-1.2.12/src/joystick/SDL_sysjoystick.h | 82 - .../src/joystick/amigaos/SDL_sysjoystick.c | 233 - .../sdl-1.2.12/src/joystick/beos/SDL_bejoystick.cc | 237 - .../sdl-1.2.12/src/joystick/bsd/SDL_sysjoystick.c | 591 -- .../src/joystick/darwin/SDL_sysjoystick.c | 841 --- .../sdl-1.2.12/src/joystick/dc/SDL_sysjoystick.c | 193 - .../src/joystick/dummy/SDL_sysjoystick.c | 83 - .../src/joystick/linux/SDL_sysjoystick.c | 1199 ---- .../src/joystick/macos/SDL_sysjoystick.c | 320 - .../sdl-1.2.12/src/joystick/mint/SDL_sysjoystick.c | 683 -- .../sdl-1.2.12/src/joystick/os2/SDL_sysjoystick.c | 668 -- distrib/sdl-1.2.12/src/joystick/os2/joyos2.h | 177 - .../src/joystick/riscos/SDL_sysjoystick.c | 176 - .../sdl-1.2.12/src/joystick/win32/SDL_mmjoystick.c | 405 -- distrib/sdl-1.2.12/src/loadso/beos/SDL_sysloadso.c | 72 - .../sdl-1.2.12/src/loadso/dlopen/SDL_sysloadso.c | 69 - .../sdl-1.2.12/src/loadso/dummy/SDL_sysloadso.c | 50 - .../sdl-1.2.12/src/loadso/macos/SDL_sysloadso.c | 106 - .../sdl-1.2.12/src/loadso/macosx/SDL_dlcompat.c | 1407 ----- distrib/sdl-1.2.12/src/loadso/mint/SDL_sysloadso.c | 62 - distrib/sdl-1.2.12/src/loadso/os2/SDL_sysloadso.c | 71 - .../sdl-1.2.12/src/loadso/win32/SDL_sysloadso.c | 139 - distrib/sdl-1.2.12/src/main/beos/SDL_BeApp.cc | 109 - distrib/sdl-1.2.12/src/main/beos/SDL_BeApp.h | 33 - distrib/sdl-1.2.12/src/main/dummy/SDL_dummy_main.c | 13 - distrib/sdl-1.2.12/src/main/epoc/SDL_main.cpp | 129 - distrib/sdl-1.2.12/src/main/macos/SDL.r | 58 - distrib/sdl-1.2.12/src/main/macos/SDL_main.c | 610 -- distrib/sdl-1.2.12/src/main/macos/SIZE.r | 24 - distrib/sdl-1.2.12/src/main/macos/exports/Makefile | 34 - distrib/sdl-1.2.12/src/main/macos/exports/SDL.x | 209 - .../sdl-1.2.12/src/main/macos/exports/gendef.pl | 43 - distrib/sdl-1.2.12/src/main/macosx/Info.plist.in | 24 - distrib/sdl-1.2.12/src/main/macosx/SDLMain.h | 11 - distrib/sdl-1.2.12/src/main/macosx/SDLMain.m | 398 -- .../src/main/macosx/SDLMain.nib/classes.nib | 12 - .../src/main/macosx/SDLMain.nib/info.nib | 12 - .../src/main/macosx/SDLMain.nib/objects.nib | Bin 1701 -> 0 bytes distrib/sdl-1.2.12/src/main/macosx/info.nib | 1 - .../sdl-1.2.12/src/main/qtopia/SDL_qtopia_main.cc | 47 - distrib/sdl-1.2.12/src/main/win32/SDL_win32_main.c | 357 -- distrib/sdl-1.2.12/src/main/win32/version.rc | 39 - distrib/sdl-1.2.12/src/stdlib/SDL_getenv.c | 247 - distrib/sdl-1.2.12/src/stdlib/SDL_iconv.c | 881 --- distrib/sdl-1.2.12/src/stdlib/SDL_malloc.c | 5111 --------------- distrib/sdl-1.2.12/src/stdlib/SDL_qsort.c | 425 -- distrib/sdl-1.2.12/src/stdlib/SDL_stdlib.c | 620 -- distrib/sdl-1.2.12/src/stdlib/SDL_string.c | 1248 ---- distrib/sdl-1.2.12/src/thread/SDL_systhread.h | 52 - distrib/sdl-1.2.12/src/thread/SDL_thread.c | 298 - distrib/sdl-1.2.12/src/thread/SDL_thread_c.h | 64 - distrib/sdl-1.2.12/src/thread/amigaos/SDL_syssem.c | 148 - .../sdl-1.2.12/src/thread/amigaos/SDL_systhread.c | 151 - .../src/thread/amigaos/SDL_systhread_c.h | 61 - distrib/sdl-1.2.12/src/thread/amigaos/SDL_thread.c | 278 - distrib/sdl-1.2.12/src/thread/beos/SDL_syssem.c | 142 - distrib/sdl-1.2.12/src/thread/beos/SDL_systhread.c | 96 - .../sdl-1.2.12/src/thread/beos/SDL_systhread_c.h | 31 - distrib/sdl-1.2.12/src/thread/dc/SDL_syscond.c | 215 - distrib/sdl-1.2.12/src/thread/dc/SDL_syscond_c.h | 23 - distrib/sdl-1.2.12/src/thread/dc/SDL_sysmutex.c | 122 - distrib/sdl-1.2.12/src/thread/dc/SDL_sysmutex_c.h | 23 - distrib/sdl-1.2.12/src/thread/dc/SDL_syssem.c | 173 - distrib/sdl-1.2.12/src/thread/dc/SDL_syssem_c.h | 23 - distrib/sdl-1.2.12/src/thread/dc/SDL_systhread.c | 60 - distrib/sdl-1.2.12/src/thread/dc/SDL_systhread_c.h | 24 - .../sdl-1.2.12/src/thread/epoc/SDL_sysmutex.cpp | 105 - distrib/sdl-1.2.12/src/thread/epoc/SDL_syssem.cpp | 193 - .../sdl-1.2.12/src/thread/epoc/SDL_systhread.cpp | 124 - .../sdl-1.2.12/src/thread/epoc/SDL_systhread_c.h | 31 - .../sdl-1.2.12/src/thread/generic/SDL_syscond.c | 215 - .../sdl-1.2.12/src/thread/generic/SDL_sysmutex.c | 129 - .../sdl-1.2.12/src/thread/generic/SDL_sysmutex_c.h | 23 - distrib/sdl-1.2.12/src/thread/generic/SDL_syssem.c | 209 - .../sdl-1.2.12/src/thread/generic/SDL_systhread.c | 54 - .../src/thread/generic/SDL_systhread_c.h | 25 - distrib/sdl-1.2.12/src/thread/irix/SDL_syssem.c | 219 - distrib/sdl-1.2.12/src/thread/irix/SDL_systhread.c | 85 - .../sdl-1.2.12/src/thread/irix/SDL_systhread_c.h | 27 - distrib/sdl-1.2.12/src/thread/os2/SDL_syscond.c | 215 - distrib/sdl-1.2.12/src/thread/os2/SDL_syscond_c.h | 23 - distrib/sdl-1.2.12/src/thread/os2/SDL_sysmutex.c | 108 - distrib/sdl-1.2.12/src/thread/os2/SDL_syssem.c | 192 - distrib/sdl-1.2.12/src/thread/os2/SDL_systhread.c | 108 - .../sdl-1.2.12/src/thread/os2/SDL_systhread_c.h | 28 - distrib/sdl-1.2.12/src/thread/pth/SDL_syscond.c | 164 - distrib/sdl-1.2.12/src/thread/pth/SDL_sysmutex.c | 87 - distrib/sdl-1.2.12/src/thread/pth/SDL_sysmutex_c.h | 31 - distrib/sdl-1.2.12/src/thread/pth/SDL_systhread.c | 103 - .../sdl-1.2.12/src/thread/pth/SDL_systhread_c.h | 31 - .../sdl-1.2.12/src/thread/pthread/SDL_syscond.c | 155 - .../sdl-1.2.12/src/thread/pthread/SDL_sysmutex.c | 153 - .../sdl-1.2.12/src/thread/pthread/SDL_sysmutex_c.h | 31 - distrib/sdl-1.2.12/src/thread/pthread/SDL_syssem.c | 156 - .../sdl-1.2.12/src/thread/pthread/SDL_systhread.c | 120 - .../src/thread/pthread/SDL_systhread_c.h | 26 - distrib/sdl-1.2.12/src/thread/riscos/SDL_syscond.c | 160 - .../sdl-1.2.12/src/thread/riscos/SDL_sysmutex.c | 153 - .../sdl-1.2.12/src/thread/riscos/SDL_sysmutex_c.h | 34 - distrib/sdl-1.2.12/src/thread/riscos/SDL_syssem.c | 203 - .../sdl-1.2.12/src/thread/riscos/SDL_systhread.c | 144 - .../sdl-1.2.12/src/thread/riscos/SDL_systhread_c.h | 34 - distrib/sdl-1.2.12/src/thread/win32/SDL_sysmutex.c | 95 - distrib/sdl-1.2.12/src/thread/win32/SDL_syssem.c | 164 - .../sdl-1.2.12/src/thread/win32/SDL_systhread.c | 150 - .../sdl-1.2.12/src/thread/win32/SDL_systhread_c.h | 28 - .../sdl-1.2.12/src/thread/win32/win_ce_semaphore.c | 216 - .../sdl-1.2.12/src/thread/win32/win_ce_semaphore.h | 22 - distrib/sdl-1.2.12/src/timer/SDL_systimer.h | 40 - distrib/sdl-1.2.12/src/timer/SDL_timer.c | 285 - distrib/sdl-1.2.12/src/timer/SDL_timer_c.h | 46 - .../sdl-1.2.12/src/timer/amigaos/SDL_systimer.c | 267 - distrib/sdl-1.2.12/src/timer/beos/SDL_systimer.c | 95 - distrib/sdl-1.2.12/src/timer/dc/SDL_systimer.c | 100 - distrib/sdl-1.2.12/src/timer/dummy/SDL_systimer.c | 91 - distrib/sdl-1.2.12/src/timer/epoc/SDL_systimer.cpp | 116 - distrib/sdl-1.2.12/src/timer/macos/FastTimes.c | 352 -- distrib/sdl-1.2.12/src/timer/macos/FastTimes.h | 27 - distrib/sdl-1.2.12/src/timer/macos/SDL_MPWtimer.c | 152 - distrib/sdl-1.2.12/src/timer/macos/SDL_systimer.c | 186 - distrib/sdl-1.2.12/src/timer/mint/SDL_systimer.c | 147 - distrib/sdl-1.2.12/src/timer/mint/SDL_vbltimer.S | 159 - distrib/sdl-1.2.12/src/timer/mint/SDL_vbltimer_s.h | 35 - distrib/sdl-1.2.12/src/timer/os2/SDL_systimer.c | 227 - distrib/sdl-1.2.12/src/timer/riscos/SDL_systimer.c | 233 - distrib/sdl-1.2.12/src/timer/unix/SDL_systimer.c | 240 - distrib/sdl-1.2.12/src/timer/win32/SDL_systimer.c | 160 - distrib/sdl-1.2.12/src/timer/wince/SDL_systimer.c | 198 - distrib/sdl-1.2.12/src/video/SDL_RLEaccel.c | 1943 ------ distrib/sdl-1.2.12/src/video/SDL_RLEaccel_c.h | 31 - distrib/sdl-1.2.12/src/video/SDL_blit.c | 360 -- distrib/sdl-1.2.12/src/video/SDL_blit.h | 541 -- distrib/sdl-1.2.12/src/video/SDL_blit_0.c | 471 -- distrib/sdl-1.2.12/src/video/SDL_blit_1.c | 523 -- distrib/sdl-1.2.12/src/video/SDL_blit_A.c | 2872 --------- distrib/sdl-1.2.12/src/video/SDL_blit_N.c | 2490 -------- distrib/sdl-1.2.12/src/video/SDL_bmp.c | 520 -- distrib/sdl-1.2.12/src/video/SDL_cursor.c | 758 --- distrib/sdl-1.2.12/src/video/SDL_cursor_c.h | 73 - distrib/sdl-1.2.12/src/video/SDL_gamma.c | 233 - distrib/sdl-1.2.12/src/video/SDL_glfuncs.h | 341 - distrib/sdl-1.2.12/src/video/SDL_leaks.h | 31 - distrib/sdl-1.2.12/src/video/SDL_pixels.c | 625 -- distrib/sdl-1.2.12/src/video/SDL_pixels_c.h | 46 - distrib/sdl-1.2.12/src/video/SDL_stretch.c | 334 - distrib/sdl-1.2.12/src/video/SDL_stretch_c.h | 29 - distrib/sdl-1.2.12/src/video/SDL_surface.c | 941 --- distrib/sdl-1.2.12/src/video/SDL_sysvideo.h | 433 -- distrib/sdl-1.2.12/src/video/SDL_video.c | 2009 ------ distrib/sdl-1.2.12/src/video/SDL_yuv.c | 150 - distrib/sdl-1.2.12/src/video/SDL_yuv_mmx.c | 428 -- distrib/sdl-1.2.12/src/video/SDL_yuv_sw.c | 1298 ---- distrib/sdl-1.2.12/src/video/SDL_yuv_sw_c.h | 37 - distrib/sdl-1.2.12/src/video/SDL_yuvfuncs.h | 37 - distrib/sdl-1.2.12/src/video/Xext/README | 10 - distrib/sdl-1.2.12/src/video/Xext/XME/xme.c | 405 -- .../sdl-1.2.12/src/video/Xext/Xinerama/Xinerama.c | 319 - distrib/sdl-1.2.12/src/video/Xext/Xv/Xv.c | 1151 ---- distrib/sdl-1.2.12/src/video/Xext/Xv/Xvlibint.h | 76 - .../sdl-1.2.12/src/video/Xext/Xxf86dga/XF86DGA.c | 716 --- .../sdl-1.2.12/src/video/Xext/Xxf86dga/XF86DGA2.c | 988 --- .../sdl-1.2.12/src/video/Xext/Xxf86vm/XF86VMode.c | 1223 ---- .../sdl-1.2.12/src/video/Xext/extensions/Xext.h | 50 - .../src/video/Xext/extensions/Xinerama.h | 46 - distrib/sdl-1.2.12/src/video/Xext/extensions/Xv.h | 129 - .../sdl-1.2.12/src/video/Xext/extensions/Xvlib.h | 433 -- .../sdl-1.2.12/src/video/Xext/extensions/Xvproto.h | 604 -- .../sdl-1.2.12/src/video/Xext/extensions/extutil.h | 226 - .../src/video/Xext/extensions/panoramiXext.h | 52 - .../src/video/Xext/extensions/panoramiXproto.h | 192 - .../sdl-1.2.12/src/video/Xext/extensions/xf86dga.h | 265 - .../src/video/Xext/extensions/xf86dga1.h | 169 - .../src/video/Xext/extensions/xf86dga1str.h | 194 - .../src/video/Xext/extensions/xf86dgastr.h | 344 - .../src/video/Xext/extensions/xf86vmode.h | 314 - .../src/video/Xext/extensions/xf86vmstr.h | 546 -- distrib/sdl-1.2.12/src/video/Xext/extensions/xme.h | 45 - distrib/sdl-1.2.12/src/video/aalib/SDL_aaevents.c | 202 - .../sdl-1.2.12/src/video/aalib/SDL_aaevents_c.h | 35 - distrib/sdl-1.2.12/src/video/aalib/SDL_aamouse.c | 35 - distrib/sdl-1.2.12/src/video/aalib/SDL_aamouse_c.h | 26 - distrib/sdl-1.2.12/src/video/aalib/SDL_aavideo.c | 388 -- distrib/sdl-1.2.12/src/video/aalib/SDL_aavideo.h | 66 - .../src/video/ataricommon/SDL_ataric2p.S | 447 -- .../src/video/ataricommon/SDL_ataric2p_s.h | 75 - .../src/video/ataricommon/SDL_ataridevmouse.c | 159 - .../src/video/ataricommon/SDL_ataridevmouse_c.h | 42 - .../src/video/ataricommon/SDL_atarieddi.S | 42 - .../src/video/ataricommon/SDL_atarieddi_s.h | 54 - .../src/video/ataricommon/SDL_atarievents.c | 239 - .../src/video/ataricommon/SDL_atarievents_c.h | 65 - .../sdl-1.2.12/src/video/ataricommon/SDL_atarigl.c | 1088 ---- .../src/video/ataricommon/SDL_atarigl_c.h | 109 - .../src/video/ataricommon/SDL_atarikeys.h | 140 - .../src/video/ataricommon/SDL_atarimxalloc.c | 52 - .../src/video/ataricommon/SDL_atarimxalloc_c.h | 45 - .../src/video/ataricommon/SDL_biosevents.c | 131 - .../src/video/ataricommon/SDL_biosevents_c.h | 42 - .../src/video/ataricommon/SDL_gemdosevents.c | 137 - .../src/video/ataricommon/SDL_gemdosevents_c.h | 42 - .../src/video/ataricommon/SDL_ikbdevents.c | 126 - .../src/video/ataricommon/SDL_ikbdevents_c.h | 42 - .../src/video/ataricommon/SDL_ikbdinterrupt.S | 260 - .../src/video/ataricommon/SDL_ikbdinterrupt_s.h | 61 - .../src/video/ataricommon/SDL_xbiosevents.c | 154 - .../src/video/ataricommon/SDL_xbiosevents_c.h | 48 - .../src/video/ataricommon/SDL_xbiosinterrupt.S | 172 - .../src/video/ataricommon/SDL_xbiosinterrupt_s.h | 52 - distrib/sdl-1.2.12/src/video/blank_cursor.h | 33 - distrib/sdl-1.2.12/src/video/bwindow/SDL_BView.h | 116 - distrib/sdl-1.2.12/src/video/bwindow/SDL_BWin.h | 282 - .../sdl-1.2.12/src/video/bwindow/SDL_lowvideo.h | 58 - .../sdl-1.2.12/src/video/bwindow/SDL_sysevents.cc | 381 -- .../sdl-1.2.12/src/video/bwindow/SDL_sysevents_c.h | 31 - .../sdl-1.2.12/src/video/bwindow/SDL_sysmouse.cc | 153 - .../sdl-1.2.12/src/video/bwindow/SDL_sysmouse_c.h | 33 - .../sdl-1.2.12/src/video/bwindow/SDL_sysvideo.cc | 829 --- distrib/sdl-1.2.12/src/video/bwindow/SDL_syswm.cc | 91 - distrib/sdl-1.2.12/src/video/bwindow/SDL_syswm_c.h | 32 - distrib/sdl-1.2.12/src/video/bwindow/SDL_sysyuv.cc | 314 - distrib/sdl-1.2.12/src/video/bwindow/SDL_sysyuv.h | 73 - .../src/video/cybergfx/SDL_amigaevents.c | 535 -- .../src/video/cybergfx/SDL_amigaevents_c.h | 29 - .../sdl-1.2.12/src/video/cybergfx/SDL_amigamouse.c | 77 - .../src/video/cybergfx/SDL_amigamouse_c.h | 32 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxaccel.c | 262 - distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxgl.c | 212 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxgl_c.h | 51 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgximage.c | 906 --- .../sdl-1.2.12/src/video/cybergfx/SDL_cgximage_c.h | 36 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxmodes.c | 316 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxmodes_c.h | 45 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxvideo.c | 1375 ---- .../sdl-1.2.12/src/video/cybergfx/SDL_cgxvideo.h | 172 - distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxwm.c | 63 - .../sdl-1.2.12/src/video/cybergfx/SDL_cgxwm_c.h | 33 - distrib/sdl-1.2.12/src/video/dc/SDL_dcevents.c | 152 - distrib/sdl-1.2.12/src/video/dc/SDL_dcevents_c.h | 33 - distrib/sdl-1.2.12/src/video/dc/SDL_dcmouse.c | 35 - distrib/sdl-1.2.12/src/video/dc/SDL_dcmouse_c.h | 26 - distrib/sdl-1.2.12/src/video/dc/SDL_dcvideo.c | 445 -- distrib/sdl-1.2.12/src/video/dc/SDL_dcvideo.h | 42 - distrib/sdl-1.2.12/src/video/default_cursor.h | 116 - distrib/sdl-1.2.12/src/video/dga/SDL_dgaevents.c | 150 - distrib/sdl-1.2.12/src/video/dga/SDL_dgaevents_c.h | 28 - distrib/sdl-1.2.12/src/video/dga/SDL_dgamouse.c | 35 - distrib/sdl-1.2.12/src/video/dga/SDL_dgamouse_c.h | 26 - distrib/sdl-1.2.12/src/video/dga/SDL_dgavideo.c | 1100 ---- distrib/sdl-1.2.12/src/video/dga/SDL_dgavideo.h | 123 - .../src/video/directfb/SDL_DirectFB_events.c | 210 - .../src/video/directfb/SDL_DirectFB_events.h | 29 - .../src/video/directfb/SDL_DirectFB_keys.h | 135 - .../src/video/directfb/SDL_DirectFB_video.c | 1171 ---- .../src/video/directfb/SDL_DirectFB_video.h | 62 - .../src/video/directfb/SDL_DirectFB_yuv.c | 290 - .../src/video/directfb/SDL_DirectFB_yuv.h | 38 - .../sdl-1.2.12/src/video/dummy/SDL_nullevents.c | 45 - .../sdl-1.2.12/src/video/dummy/SDL_nullevents_c.h | 33 - distrib/sdl-1.2.12/src/video/dummy/SDL_nullmouse.c | 33 - .../sdl-1.2.12/src/video/dummy/SDL_nullmouse_c.h | 26 - distrib/sdl-1.2.12/src/video/dummy/SDL_nullvideo.c | 239 - distrib/sdl-1.2.12/src/video/dummy/SDL_nullvideo.h | 40 - distrib/sdl-1.2.12/src/video/e_log.h | 140 - distrib/sdl-1.2.12/src/video/e_pow.h | 302 - distrib/sdl-1.2.12/src/video/e_sqrt.h | 493 -- .../sdl-1.2.12/src/video/epoc/SDL_epocevents.cpp | 419 -- .../sdl-1.2.12/src/video/epoc/SDL_epocevents_c.h | 46 - .../sdl-1.2.12/src/video/epoc/SDL_epocvideo.cpp | 697 --- distrib/sdl-1.2.12/src/video/epoc/SDL_epocvideo.h | 90 - distrib/sdl-1.2.12/src/video/fbcon/3dfx_mmio.h | 56 - distrib/sdl-1.2.12/src/video/fbcon/3dfx_regs.h | 83 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fb3dfx.c | 217 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fb3dfx.h | 29 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbelo.c | 442 -- distrib/sdl-1.2.12/src/video/fbcon/SDL_fbelo.h | 55 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbevents.c | 1245 ---- .../sdl-1.2.12/src/video/fbcon/SDL_fbevents_c.h | 38 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbkeys.h | 139 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmatrox.c | 280 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmatrox.h | 29 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmouse.c | 33 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmouse_c.h | 26 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbriva.c | 222 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbriva.h | 36 - distrib/sdl-1.2.12/src/video/fbcon/SDL_fbvideo.c | 1701 ----- distrib/sdl-1.2.12/src/video/fbcon/SDL_fbvideo.h | 182 - distrib/sdl-1.2.12/src/video/fbcon/matrox_mmio.h | 51 - distrib/sdl-1.2.12/src/video/fbcon/matrox_regs.h | 376 -- distrib/sdl-1.2.12/src/video/fbcon/out | 29 - distrib/sdl-1.2.12/src/video/fbcon/riva_mmio.h | 449 -- distrib/sdl-1.2.12/src/video/fbcon/riva_regs.h | 43 - distrib/sdl-1.2.12/src/video/gapi/SDL_gapivideo.c | 1232 ---- distrib/sdl-1.2.12/src/video/gapi/SDL_gapivideo.h | 162 - distrib/sdl-1.2.12/src/video/gem/SDL_gemevents.c | 370 -- distrib/sdl-1.2.12/src/video/gem/SDL_gemevents_c.h | 33 - distrib/sdl-1.2.12/src/video/gem/SDL_gemmouse.c | 204 - distrib/sdl-1.2.12/src/video/gem/SDL_gemmouse_c.h | 34 - distrib/sdl-1.2.12/src/video/gem/SDL_gemvideo.c | 1340 ---- distrib/sdl-1.2.12/src/video/gem/SDL_gemvideo.h | 191 - distrib/sdl-1.2.12/src/video/gem/SDL_gemwm.c | 116 - distrib/sdl-1.2.12/src/video/gem/SDL_gemwm_c.h | 37 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggievents.c | 264 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggievents_c.h | 29 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggikeys.h | 135 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggimouse.c | 32 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggimouse_c.h | 26 - distrib/sdl-1.2.12/src/video/ggi/SDL_ggivideo.c | 378 -- distrib/sdl-1.2.12/src/video/ggi/SDL_ggivideo.h | 48 - distrib/sdl-1.2.12/src/video/ipod/SDL_ipodvideo.c | 733 --- distrib/sdl-1.2.12/src/video/ipod/SDL_ipodvideo.h | 38 - .../sdl-1.2.12/src/video/maccommon/SDL_lowvideo.h | 102 - .../sdl-1.2.12/src/video/maccommon/SDL_macevents.c | 746 --- .../src/video/maccommon/SDL_macevents_c.h | 32 - distrib/sdl-1.2.12/src/video/maccommon/SDL_macgl.c | 197 - .../sdl-1.2.12/src/video/maccommon/SDL_macgl_c.h | 47 - .../sdl-1.2.12/src/video/maccommon/SDL_mackeys.h | 140 - .../sdl-1.2.12/src/video/maccommon/SDL_macmouse.c | 129 - .../src/video/maccommon/SDL_macmouse_c.h | 34 - distrib/sdl-1.2.12/src/video/maccommon/SDL_macwm.c | 442 -- .../sdl-1.2.12/src/video/maccommon/SDL_macwm_c.h | 41 - distrib/sdl-1.2.12/src/video/macdsp/SDL_dspvideo.c | 1422 ----- distrib/sdl-1.2.12/src/video/macdsp/SDL_dspvideo.h | 54 - distrib/sdl-1.2.12/src/video/macrom/SDL_romvideo.c | 745 --- distrib/sdl-1.2.12/src/video/macrom/SDL_romvideo.h | 29 - distrib/sdl-1.2.12/src/video/math_private.h | 173 - distrib/sdl-1.2.12/src/video/mmx.h | 704 --- distrib/sdl-1.2.12/src/video/nanox/SDL_nxevents.c | 382 -- .../sdl-1.2.12/src/video/nanox/SDL_nxevents_c.h | 32 - distrib/sdl-1.2.12/src/video/nanox/SDL_nximage.c | 230 - distrib/sdl-1.2.12/src/video/nanox/SDL_nximage_c.h | 35 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxmodes.c | 84 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxmodes_c.h | 34 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxmouse.c | 79 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxmouse_c.h | 29 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxvideo.c | 544 -- distrib/sdl-1.2.12/src/video/nanox/SDL_nxvideo.h | 96 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxwm.c | 61 - distrib/sdl-1.2.12/src/video/nanox/SDL_nxwm_c.h | 32 - .../sdl-1.2.12/src/video/os2fslib/SDL_os2fslib.c | 3018 --------- .../sdl-1.2.12/src/video/os2fslib/SDL_os2fslib.h | 71 - distrib/sdl-1.2.12/src/video/os2fslib/SDL_vkeys.h | 74 - .../sdl-1.2.12/src/video/photon/SDL_ph_events.c | 624 -- .../sdl-1.2.12/src/video/photon/SDL_ph_events_c.h | 37 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_gl.c | 406 -- distrib/sdl-1.2.12/src/video/photon/SDL_ph_gl.h | 41 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_image.c | 1059 ---- .../sdl-1.2.12/src/video/photon/SDL_ph_image_c.h | 59 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_modes.c | 390 -- .../sdl-1.2.12/src/video/photon/SDL_ph_modes_c.h | 43 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_mouse.c | 220 - .../sdl-1.2.12/src/video/photon/SDL_ph_mouse_c.h | 39 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_video.c | 648 -- distrib/sdl-1.2.12/src/video/photon/SDL_ph_video.h | 157 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_wm.c | 118 - distrib/sdl-1.2.12/src/video/photon/SDL_ph_wm_c.h | 37 - distrib/sdl-1.2.12/src/video/photon/SDL_phyuv.c | 504 -- distrib/sdl-1.2.12/src/video/photon/SDL_phyuv_c.h | 62 - .../sdl-1.2.12/src/video/picogui/SDL_pgevents.c | 117 - .../sdl-1.2.12/src/video/picogui/SDL_pgevents_c.h | 37 - distrib/sdl-1.2.12/src/video/picogui/SDL_pgvideo.c | 364 -- distrib/sdl-1.2.12/src/video/picogui/SDL_pgvideo.h | 50 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsevents.c | 977 --- .../sdl-1.2.12/src/video/ps2gs/SDL_gsevents_c.h | 38 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gskeys.h | 139 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsmouse.c | 146 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsmouse_c.h | 37 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsvideo.c | 689 -- distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsvideo.h | 95 - distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsyuv.c | 461 -- distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsyuv_c.h | 37 - distrib/sdl-1.2.12/src/video/qtopia/SDL_QPEApp.cc | 63 - distrib/sdl-1.2.12/src/video/qtopia/SDL_QPEApp.h | 33 - distrib/sdl-1.2.12/src/video/qtopia/SDL_QWin.cc | 527 -- distrib/sdl-1.2.12/src/video/qtopia/SDL_QWin.h | 110 - distrib/sdl-1.2.12/src/video/qtopia/SDL_lowvideo.h | 65 - .../sdl-1.2.12/src/video/qtopia/SDL_sysevents.cc | 269 - .../sdl-1.2.12/src/video/qtopia/SDL_sysevents_c.h | 31 - .../sdl-1.2.12/src/video/qtopia/SDL_sysmouse.cc | 56 - .../sdl-1.2.12/src/video/qtopia/SDL_sysmouse_c.h | 32 - .../sdl-1.2.12/src/video/qtopia/SDL_sysvideo.cc | 403 -- distrib/sdl-1.2.12/src/video/qtopia/SDL_syswm.cc | 35 - distrib/sdl-1.2.12/src/video/qtopia/SDL_syswm_c.h | 28 - distrib/sdl-1.2.12/src/video/quartz/CGS.h | 84 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzEvents.m | 984 --- distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzGL.m | 281 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzKeys.h | 146 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzVideo.h | 237 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzVideo.m | 1691 ----- distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWM.h | 28 - distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWM.m | 574 -- .../sdl-1.2.12/src/video/quartz/SDL_QuartzWindow.h | 43 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzWindow.m | 232 - .../sdl-1.2.12/src/video/quartz/SDL_QuartzYUV.m | 330 - .../sdl-1.2.12/src/video/riscos/SDL_riscosASM.S | 116 - .../src/video/riscos/SDL_riscosFullScreenVideo.c | 777 --- .../sdl-1.2.12/src/video/riscos/SDL_riscosevents.c | 549 -- .../src/video/riscos/SDL_riscosevents_c.h | 34 - .../sdl-1.2.12/src/video/riscos/SDL_riscosmouse.c | 371 -- .../src/video/riscos/SDL_riscosmouse_c.h | 44 - .../sdl-1.2.12/src/video/riscos/SDL_riscossprite.c | 265 - .../sdl-1.2.12/src/video/riscos/SDL_riscostask.c | 350 -- .../sdl-1.2.12/src/video/riscos/SDL_riscostask.h | 39 - .../sdl-1.2.12/src/video/riscos/SDL_riscosvideo.c | 316 - .../sdl-1.2.12/src/video/riscos/SDL_riscosvideo.h | 62 - distrib/sdl-1.2.12/src/video/riscos/SDL_wimppoll.c | 330 - .../sdl-1.2.12/src/video/riscos/SDL_wimpvideo.c | 501 -- distrib/sdl-1.2.12/src/video/svga/SDL_svgaevents.c | 412 -- .../sdl-1.2.12/src/video/svga/SDL_svgaevents_c.h | 35 - distrib/sdl-1.2.12/src/video/svga/SDL_svgamouse.c | 33 - .../sdl-1.2.12/src/video/svga/SDL_svgamouse_c.h | 26 - distrib/sdl-1.2.12/src/video/svga/SDL_svgavideo.c | 584 -- distrib/sdl-1.2.12/src/video/svga/SDL_svgavideo.h | 58 - distrib/sdl-1.2.12/src/video/vgl/SDL_vglevents.c | 299 - distrib/sdl-1.2.12/src/video/vgl/SDL_vglevents_c.h | 155 - distrib/sdl-1.2.12/src/video/vgl/SDL_vglmouse.c | 56 - distrib/sdl-1.2.12/src/video/vgl/SDL_vglmouse_c.h | 32 - distrib/sdl-1.2.12/src/video/vgl/SDL_vglvideo.c | 640 -- distrib/sdl-1.2.12/src/video/vgl/SDL_vglvideo.h | 65 - .../sdl-1.2.12/src/video/wincommon/SDL_lowvideo.h | 139 - .../sdl-1.2.12/src/video/wincommon/SDL_sysevents.c | 924 --- .../sdl-1.2.12/src/video/wincommon/SDL_sysmouse.c | 260 - .../src/video/wincommon/SDL_sysmouse_c.h | 33 - distrib/sdl-1.2.12/src/video/wincommon/SDL_syswm.c | 321 - .../sdl-1.2.12/src/video/wincommon/SDL_syswm_c.h | 35 - distrib/sdl-1.2.12/src/video/wincommon/SDL_wingl.c | 647 -- .../sdl-1.2.12/src/video/wincommon/SDL_wingl_c.h | 135 - distrib/sdl-1.2.12/src/video/wincommon/wmmsg.h | 1030 --- .../sdl-1.2.12/src/video/windib/SDL_dibevents.c | 591 -- .../sdl-1.2.12/src/video/windib/SDL_dibevents_c.h | 35 - distrib/sdl-1.2.12/src/video/windib/SDL_dibvideo.c | 1422 ----- distrib/sdl-1.2.12/src/video/windib/SDL_dibvideo.h | 68 - distrib/sdl-1.2.12/src/video/windib/SDL_vkeys.h | 75 - .../sdl-1.2.12/src/video/windx5/SDL_dx5events.c | 923 --- .../sdl-1.2.12/src/video/windx5/SDL_dx5events_c.h | 37 - distrib/sdl-1.2.12/src/video/windx5/SDL_dx5video.c | 2518 -------- distrib/sdl-1.2.12/src/video/windx5/SDL_dx5video.h | 61 - distrib/sdl-1.2.12/src/video/windx5/SDL_dx5yuv.c | 295 - distrib/sdl-1.2.12/src/video/windx5/SDL_dx5yuv_c.h | 38 - distrib/sdl-1.2.12/src/video/windx5/directx.h | 84 - .../sdl-1.2.12/src/video/wscons/SDL_wsconsevents.c | 233 - .../src/video/wscons/SDL_wsconsevents_c.h | 36 - .../sdl-1.2.12/src/video/wscons/SDL_wsconsmouse.c | 33 - .../src/video/wscons/SDL_wsconsmouse_c.h | 26 - .../sdl-1.2.12/src/video/wscons/SDL_wsconsvideo.c | 609 -- .../sdl-1.2.12/src/video/wscons/SDL_wsconsvideo.h | 76 - distrib/sdl-1.2.12/src/video/x11/SDL_x11dga.c | 90 - distrib/sdl-1.2.12/src/video/x11/SDL_x11dga_c.h | 33 - distrib/sdl-1.2.12/src/video/x11/SDL_x11dyn.c | 217 - distrib/sdl-1.2.12/src/video/x11/SDL_x11dyn.h | 87 - distrib/sdl-1.2.12/src/video/x11/SDL_x11events.c | 1453 ----- distrib/sdl-1.2.12/src/video/x11/SDL_x11events_c.h | 33 - distrib/sdl-1.2.12/src/video/x11/SDL_x11gamma.c | 142 - distrib/sdl-1.2.12/src/video/x11/SDL_x11gamma_c.h | 32 - distrib/sdl-1.2.12/src/video/x11/SDL_x11gl.c | 552 -- distrib/sdl-1.2.12/src/video/x11/SDL_x11gl_c.h | 99 - distrib/sdl-1.2.12/src/video/x11/SDL_x11image.c | 318 - distrib/sdl-1.2.12/src/video/x11/SDL_x11image_c.h | 38 - distrib/sdl-1.2.12/src/video/x11/SDL_x11modes.c | 1110 ---- distrib/sdl-1.2.12/src/video/x11/SDL_x11modes_c.h | 43 - distrib/sdl-1.2.12/src/video/x11/SDL_x11mouse.c | 284 - distrib/sdl-1.2.12/src/video/x11/SDL_x11mouse_c.h | 33 - distrib/sdl-1.2.12/src/video/x11/SDL_x11sym.h | 221 - distrib/sdl-1.2.12/src/video/x11/SDL_x11video.c | 1558 ----- distrib/sdl-1.2.12/src/video/x11/SDL_x11video.h | 223 - distrib/sdl-1.2.12/src/video/x11/SDL_x11wm.c | 619 -- distrib/sdl-1.2.12/src/video/x11/SDL_x11wm_c.h | 38 - distrib/sdl-1.2.12/src/video/x11/SDL_x11yuv.c | 413 -- distrib/sdl-1.2.12/src/video/x11/SDL_x11yuv_c.h | 41 - distrib/sdl-1.2.12/src/video/xbios/SDL_xbios.c | 953 --- distrib/sdl-1.2.12/src/video/xbios/SDL_xbios.h | 131 - .../sdl-1.2.12/src/video/xbios/SDL_xbios_blowup.c | 70 - .../sdl-1.2.12/src/video/xbios/SDL_xbios_blowup.h | 86 - .../src/video/xbios/SDL_xbios_centscreen.c | 103 - .../src/video/xbios/SDL_xbios_centscreen.h | 118 - distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_sb3.c | 86 - distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_sb3.h | 82 - 658 files changed, 181463 deletions(-) delete mode 100644 distrib/sdl-1.2.12/BUGS delete mode 100644 distrib/sdl-1.2.12/COPYING delete mode 100644 distrib/sdl-1.2.12/CREDITS delete mode 100644 distrib/sdl-1.2.12/Makefile delete mode 100644 distrib/sdl-1.2.12/Makefile.android delete mode 100644 distrib/sdl-1.2.12/README delete mode 100644 distrib/sdl-1.2.12/README.ANDROID delete mode 100755 distrib/sdl-1.2.12/android-configure.sh delete mode 100644 distrib/sdl-1.2.12/include/SDL.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_active.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_audio.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_byteorder.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_cdrom.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config.h.default delete mode 100644 distrib/sdl-1.2.12/include/SDL_config.h.in delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_amiga.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_dreamcast.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_macos.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_macosx.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_minimal.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_os2.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_config_win32.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_copying.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_cpuinfo.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_endian.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_error.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_events.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_getenv.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_joystick.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_keyboard.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_keysym.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_loadso.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_main.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_mouse.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_mutex.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_name.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_opengl.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_platform.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_quit.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_rwops.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_stdinc.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_syswm.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_thread.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_timer.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_types.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_version.h delete mode 100644 distrib/sdl-1.2.12/include/SDL_video.h delete mode 100644 distrib/sdl-1.2.12/include/begin_code.h delete mode 100644 distrib/sdl-1.2.12/include/close_code.h delete mode 100644 distrib/sdl-1.2.12/sdl-config.in delete mode 100644 distrib/sdl-1.2.12/sources.make delete mode 100644 distrib/sdl-1.2.12/src/SDL.c delete mode 100644 distrib/sdl-1.2.12/src/SDL_error.c delete mode 100644 distrib/sdl-1.2.12/src/SDL_error_c.h delete mode 100644 distrib/sdl-1.2.12/src/SDL_fatal.c delete mode 100644 distrib/sdl-1.2.12/src/SDL_fatal.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audio_c.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audiocvt.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audiodev.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audiodev_c.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_audiomem.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_sysaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_wave.c delete mode 100644 distrib/sdl-1.2.12/src/audio/SDL_wave.h delete mode 100644 distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.cc delete mode 100644 distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dart/SDL_dart.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dart/SDL_dart.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dc/aica.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dc/aica.h delete mode 100644 distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_it.S delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.h delete mode 100644 distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_xbios.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/nto/SDL_nto_audio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/nto/SDL_nto_audio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/paudio/SDL_paudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/paudio/SDL_paudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/sun/SDL_sunaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/sun/SDL_sunaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/ums/SDL_umsaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/ums/SDL_umsaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/windib/SDL_dibaudio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/windib/SDL_dibaudio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/windx5/SDL_dx5audio.c delete mode 100644 distrib/sdl-1.2.12/src/audio/windx5/SDL_dx5audio.h delete mode 100644 distrib/sdl-1.2.12/src/audio/windx5/directx.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/SDL_cdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/SDL_syscdrom.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/aix/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/beos/SDL_syscdrom.cc delete mode 100644 distrib/sdl-1.2.12/src/cdrom/bsdi/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/dc/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/dummy/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/freebsd/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/linux/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macos/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macos/SDL_syscdrom_c.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/AudioFilePlayer.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/AudioFilePlayer.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/AudioFileReaderThread.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/CDPlayer.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/CDPlayer.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/SDLOSXCAGuard.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/SDLOSXCAGuard.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/macosx/SDL_syscdrom_c.h delete mode 100644 distrib/sdl-1.2.12/src/cdrom/mint/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/openbsd/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/os2/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/osf/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/qnx/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cdrom/win32/SDL_syscdrom.c delete mode 100644 distrib/sdl-1.2.12/src/cpuinfo/SDL_cpuinfo.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_active.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_events.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_events_c.h delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_expose.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_keyboard.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_mouse.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_quit.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_resize.c delete mode 100644 distrib/sdl-1.2.12/src/events/SDL_sysevents.h delete mode 100644 distrib/sdl-1.2.12/src/file/SDL_rwops.c delete mode 100644 distrib/sdl-1.2.12/src/hermes/COPYING.LIB delete mode 100644 distrib/sdl-1.2.12/src/hermes/HeadMMX.h delete mode 100644 distrib/sdl-1.2.12/src/hermes/HeadX86.h delete mode 100644 distrib/sdl-1.2.12/src/hermes/README delete mode 100644 distrib/sdl-1.2.12/src/hermes/common.inc delete mode 100644 distrib/sdl-1.2.12/src/hermes/mmx_main.asm delete mode 100644 distrib/sdl-1.2.12/src/hermes/mmxp2_32.asm delete mode 100644 distrib/sdl-1.2.12/src/hermes/x86_main.asm delete mode 100644 distrib/sdl-1.2.12/src/hermes/x86p_16.asm delete mode 100644 distrib/sdl-1.2.12/src/hermes/x86p_32.asm delete mode 100644 distrib/sdl-1.2.12/src/joystick/SDL_joystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/SDL_joystick_c.h delete mode 100644 distrib/sdl-1.2.12/src/joystick/SDL_sysjoystick.h delete mode 100644 distrib/sdl-1.2.12/src/joystick/amigaos/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/beos/SDL_bejoystick.cc delete mode 100644 distrib/sdl-1.2.12/src/joystick/bsd/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/darwin/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/dc/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/dummy/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/linux/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/macos/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/mint/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/os2/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/os2/joyos2.h delete mode 100644 distrib/sdl-1.2.12/src/joystick/riscos/SDL_sysjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/joystick/win32/SDL_mmjoystick.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/beos/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/dlopen/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/dummy/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/macos/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/macosx/SDL_dlcompat.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/mint/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/os2/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/loadso/win32/SDL_sysloadso.c delete mode 100644 distrib/sdl-1.2.12/src/main/beos/SDL_BeApp.cc delete mode 100644 distrib/sdl-1.2.12/src/main/beos/SDL_BeApp.h delete mode 100644 distrib/sdl-1.2.12/src/main/dummy/SDL_dummy_main.c delete mode 100644 distrib/sdl-1.2.12/src/main/epoc/SDL_main.cpp delete mode 100644 distrib/sdl-1.2.12/src/main/macos/SDL.r delete mode 100644 distrib/sdl-1.2.12/src/main/macos/SDL_main.c delete mode 100644 distrib/sdl-1.2.12/src/main/macos/SIZE.r delete mode 100644 distrib/sdl-1.2.12/src/main/macos/exports/Makefile delete mode 100644 distrib/sdl-1.2.12/src/main/macos/exports/SDL.x delete mode 100644 distrib/sdl-1.2.12/src/main/macos/exports/gendef.pl delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/Info.plist.in delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/SDLMain.h delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/SDLMain.m delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/SDLMain.nib/classes.nib delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/SDLMain.nib/info.nib delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/SDLMain.nib/objects.nib delete mode 100644 distrib/sdl-1.2.12/src/main/macosx/info.nib delete mode 100644 distrib/sdl-1.2.12/src/main/qtopia/SDL_qtopia_main.cc delete mode 100644 distrib/sdl-1.2.12/src/main/win32/SDL_win32_main.c delete mode 100644 distrib/sdl-1.2.12/src/main/win32/version.rc delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_getenv.c delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_iconv.c delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_malloc.c delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_qsort.c delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_stdlib.c delete mode 100644 distrib/sdl-1.2.12/src/stdlib/SDL_string.c delete mode 100644 distrib/sdl-1.2.12/src/thread/SDL_systhread.h delete mode 100644 distrib/sdl-1.2.12/src/thread/SDL_thread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/SDL_thread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/amigaos/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/amigaos/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/amigaos/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/amigaos/SDL_thread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/beos/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/beos/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/beos/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_syscond_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_sysmutex_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_syssem_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/dc/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/epoc/SDL_sysmutex.cpp delete mode 100644 distrib/sdl-1.2.12/src/thread/epoc/SDL_syssem.cpp delete mode 100644 distrib/sdl-1.2.12/src/thread/epoc/SDL_systhread.cpp delete mode 100644 distrib/sdl-1.2.12/src/thread/epoc/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_sysmutex_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/generic/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/irix/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/irix/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/irix/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_syscond_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/os2/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/pth/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pth/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pth/SDL_sysmutex_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/pth/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pth/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_sysmutex_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/pthread/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_syscond.c delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_sysmutex_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/riscos/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/SDL_sysmutex.c delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/SDL_syssem.c delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/SDL_systhread.c delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/SDL_systhread_c.h delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/win_ce_semaphore.c delete mode 100644 distrib/sdl-1.2.12/src/thread/win32/win_ce_semaphore.h delete mode 100644 distrib/sdl-1.2.12/src/timer/SDL_systimer.h delete mode 100644 distrib/sdl-1.2.12/src/timer/SDL_timer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/SDL_timer_c.h delete mode 100644 distrib/sdl-1.2.12/src/timer/amigaos/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/beos/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/dc/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/dummy/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/epoc/SDL_systimer.cpp delete mode 100644 distrib/sdl-1.2.12/src/timer/macos/FastTimes.c delete mode 100644 distrib/sdl-1.2.12/src/timer/macos/FastTimes.h delete mode 100644 distrib/sdl-1.2.12/src/timer/macos/SDL_MPWtimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/macos/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/mint/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/mint/SDL_vbltimer.S delete mode 100644 distrib/sdl-1.2.12/src/timer/mint/SDL_vbltimer_s.h delete mode 100644 distrib/sdl-1.2.12/src/timer/os2/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/riscos/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/unix/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/win32/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/timer/wince/SDL_systimer.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_RLEaccel.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_RLEaccel_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit_0.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit_1.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit_A.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_blit_N.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_bmp.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_cursor.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_cursor_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_gamma.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_glfuncs.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_leaks.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_pixels.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_pixels_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_stretch.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_stretch_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_surface.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_sysvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_video.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_yuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_yuv_mmx.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_yuv_sw.c delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_yuv_sw_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/SDL_yuvfuncs.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/README delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/XME/xme.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xinerama/Xinerama.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xv/Xv.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xv/Xvlibint.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xxf86dga/XF86DGA.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xxf86dga/XF86DGA2.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/Xxf86vm/XF86VMode.c delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/Xext.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/Xinerama.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/Xv.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/Xvlib.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/Xvproto.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/extutil.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/panoramiXext.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/panoramiXproto.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86dga.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86dga1.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86dga1str.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86dgastr.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86vmode.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xf86vmstr.h delete mode 100644 distrib/sdl-1.2.12/src/video/Xext/extensions/xme.h delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aaevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aaevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aamouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aamouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aavideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/aalib/SDL_aavideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ataric2p.S delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ataric2p_s.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ataridevmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ataridevmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarieddi.S delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarieddi_s.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarievents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarievents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarigl.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarigl_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarikeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarimxalloc.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_atarimxalloc_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_biosevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_biosevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_gemdosevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_gemdosevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ikbdevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ikbdevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ikbdinterrupt.S delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_ikbdinterrupt_s.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_xbiosevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_xbiosevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_xbiosinterrupt.S delete mode 100644 distrib/sdl-1.2.12/src/video/ataricommon/SDL_xbiosinterrupt_s.h delete mode 100644 distrib/sdl-1.2.12/src/video/blank_cursor.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_BView.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_BWin.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_lowvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysevents.cc delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysmouse.cc delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysvideo.cc delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_syswm.cc delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_syswm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysyuv.cc delete mode 100644 distrib/sdl-1.2.12/src/video/bwindow/SDL_sysyuv.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_amigaevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_amigaevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_amigamouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_amigamouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxaccel.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxgl.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxgl_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgximage.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgximage_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxmodes.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxmodes_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxwm.c delete mode 100644 distrib/sdl-1.2.12/src/video/cybergfx/SDL_cgxwm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/dc/SDL_dcvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/default_cursor.h delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgaevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgaevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgamouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgamouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgavideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/dga/SDL_dgavideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_events.c delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_events.h delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_keys.h delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_video.c delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_video.h delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_yuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/directfb/SDL_DirectFB_yuv.h delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/dummy/SDL_nullvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/e_log.h delete mode 100644 distrib/sdl-1.2.12/src/video/e_pow.h delete mode 100644 distrib/sdl-1.2.12/src/video/e_sqrt.h delete mode 100644 distrib/sdl-1.2.12/src/video/epoc/SDL_epocevents.cpp delete mode 100644 distrib/sdl-1.2.12/src/video/epoc/SDL_epocevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/epoc/SDL_epocvideo.cpp delete mode 100644 distrib/sdl-1.2.12/src/video/epoc/SDL_epocvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/3dfx_mmio.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/3dfx_regs.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fb3dfx.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fb3dfx.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbelo.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbelo.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbkeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmatrox.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmatrox.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbriva.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbriva.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/SDL_fbvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/matrox_mmio.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/matrox_regs.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/out delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/riva_mmio.h delete mode 100644 distrib/sdl-1.2.12/src/video/fbcon/riva_regs.h delete mode 100644 distrib/sdl-1.2.12/src/video/gapi/SDL_gapivideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/gapi/SDL_gapivideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemwm.c delete mode 100644 distrib/sdl-1.2.12/src/video/gem/SDL_gemwm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ggi/SDL_ggievents.c delete mode 100755 distrib/sdl-1.2.12/src/video/ggi/SDL_ggievents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ggi/SDL_ggikeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/ggi/SDL_ggimouse.c delete mode 100755 distrib/sdl-1.2.12/src/video/ggi/SDL_ggimouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ggi/SDL_ggivideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/ggi/SDL_ggivideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/ipod/SDL_ipodvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/ipod/SDL_ipodvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_lowvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macgl.c delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macgl_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_mackeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macwm.c delete mode 100644 distrib/sdl-1.2.12/src/video/maccommon/SDL_macwm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/macdsp/SDL_dspvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/macdsp/SDL_dspvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/macrom/SDL_romvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/macrom/SDL_romvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/math_private.h delete mode 100644 distrib/sdl-1.2.12/src/video/mmx.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nximage.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nximage_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxmodes.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxmodes_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxwm.c delete mode 100644 distrib/sdl-1.2.12/src/video/nanox/SDL_nxwm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/os2fslib/SDL_os2fslib.c delete mode 100644 distrib/sdl-1.2.12/src/video/os2fslib/SDL_os2fslib.h delete mode 100644 distrib/sdl-1.2.12/src/video/os2fslib/SDL_vkeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_events.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_events_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_gl.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_gl.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_image.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_image_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_modes.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_modes_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_mouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_mouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_video.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_video.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_wm.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_ph_wm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_phyuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/photon/SDL_phyuv_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/picogui/SDL_pgevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/picogui/SDL_pgevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/picogui/SDL_pgvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/picogui/SDL_pgvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gskeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsyuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/ps2gs/SDL_gsyuv_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_QPEApp.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_QPEApp.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_QWin.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_QWin.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_lowvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_sysevents.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_sysevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_sysmouse.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_sysmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_sysvideo.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_syswm.cc delete mode 100644 distrib/sdl-1.2.12/src/video/qtopia/SDL_syswm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/CGS.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzEvents.m delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzGL.m delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzKeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzVideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzVideo.m delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWM.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWM.m delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWindow.h delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzWindow.m delete mode 100644 distrib/sdl-1.2.12/src/video/quartz/SDL_QuartzYUV.m delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosASM.S delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosFullScreenVideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscossprite.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscostask.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscostask.h delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_riscosvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_wimppoll.c delete mode 100644 distrib/sdl-1.2.12/src/video/riscos/SDL_wimpvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgaevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgaevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgamouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgamouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgavideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/svga/SDL_svgavideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/vgl/SDL_vglvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_lowvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_sysevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_sysmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_sysmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_syswm.c delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_syswm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_wingl.c delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/SDL_wingl_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/wincommon/wmmsg.h delete mode 100644 distrib/sdl-1.2.12/src/video/windib/SDL_dibevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/windib/SDL_dibevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/windib/SDL_dibvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/windib/SDL_dibvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/windib/SDL_vkeys.h delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5events.c delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5events_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5video.c delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5video.h delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5yuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/SDL_dx5yuv_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/windx5/directx.h delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsevents.c delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsevents_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsmouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsmouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsvideo.c delete mode 100644 distrib/sdl-1.2.12/src/video/wscons/SDL_wsconsvideo.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11dga.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11dga_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11dyn.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11dyn.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11events.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11events_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11gamma.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11gamma_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11gl.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11gl_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11image.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11image_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11modes.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11modes_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11mouse.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11mouse_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11sym.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11video.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11video.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11wm.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11wm_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11yuv.c delete mode 100644 distrib/sdl-1.2.12/src/video/x11/SDL_x11yuv_c.h delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios.c delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios.h delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_blowup.c delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_blowup.h delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_centscreen.c delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_centscreen.h delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_sb3.c delete mode 100644 distrib/sdl-1.2.12/src/video/xbios/SDL_xbios_sb3.h diff --git a/distrib/sdl-1.2.12/BUGS b/distrib/sdl-1.2.12/BUGS deleted file mode 100644 index 218bf3d..0000000 --- a/distrib/sdl-1.2.12/BUGS +++ /dev/null @@ -1,18 +0,0 @@ - -Bugs are now managed in the SDL bug tracker, here: - - http://bugzilla.libsdl.org/ - -You may report bugs there, and search to see if a given issue has already - been reported, discussed, and maybe even fixed. - - - -You may also find help at the SDL mailing list. Subscription information: - - http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org - -Bug reports are welcome here, but we really appreciate if you use Bugzilla, as - bugs discussed on the mailing list may be forgotten or missed. - - diff --git a/distrib/sdl-1.2.12/COPYING b/distrib/sdl-1.2.12/COPYING deleted file mode 100644 index 2cba2ac..0000000 --- a/distrib/sdl-1.2.12/COPYING +++ /dev/null @@ -1,458 +0,0 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 - - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS diff --git a/distrib/sdl-1.2.12/CREDITS b/distrib/sdl-1.2.12/CREDITS deleted file mode 100644 index 7a21c12..0000000 --- a/distrib/sdl-1.2.12/CREDITS +++ /dev/null @@ -1,92 +0,0 @@ - -Simple DirectMedia Layer CREDITS -Thanks to everyone who made this possible, including: - -* Cliff Matthews, for giving me a reason to start this project. :) - -- Executor rocks! *grin* - -* Scott Call, for making a home for SDL on the 'Net... Thanks! :) - -* The Linux Fund, C Magazine, Educational Technology Resources Inc., - Gareth Noyce, Jesse Pavel, Keith Kitchin, Jeremy Horvath, Thomas Nicholson, - Hans-Peter Gygax, the Eternal Lands Development Team, Lars Brubaker, - and Phoenix Kokido for financial contributions - -* Gaëtan de Menten for writing the PHP and SQL behind the SDL website - -* Tim Jones for the new look of the SDL website - -* Marco Kraus for setting up SDL merchandise - -* Martin Donlon for his work on the SDL Documentation Project - -* Ryan Gordon for helping everybody out and keeping the dream alive. :) - -* Mattias Engdegård, for help with the Solaris port and lots of other help - -* Max Watson, Matt Slot, and Kyle for help with the MacOS Classic port - -* Stan Shebs, for the initial Mac OS X port - -* Eric Wing, Max Horn, and Darrell Walisser for unflagging work on the Mac OS X port - -* Patrick Trainor, Jim Boucher, and Mike Gorchak for the QNX Neutrino port - -* Carsten Griwodz for the AIX port - -* Gabriele Greco, for the Amiga port - -* Patrice Mandin, for the Atari port - -* Hannu Viitala for the EPOC port - -* Marcus Mertama for the S60 port. - -* Peter Valchev for nagging me about the OpenBSD port until I got it right. :) - -* Kent B Mein, for a place to do the IRIX port - -* Ash, for a place to do the OSF/1 Alpha port - -* David Sowsy, for help with the BeOS port - -* Eugenia Loli, for endless work on porting SDL games to BeOS - -* Jon Taylor for the GGI front-end - -* Paulus Esterhazy, for the Visual C++ testing and libraries - -* Brenda Tantzen, for Metrowerks CodeWarrior on MacOS - -* Chris Nentwich, for the Hermes assembly blitters - -* Michael Vance and Jim Kutter for the X11 OpenGL support - -* Stephane Peter, for the AAlib front-end and multi-threaded timer idea. - -* Jon Atkins for SDL_image, SDL_mixer and SDL_net documentation - -* Peter Wiklund, for the 1998 winning SDL logo, - and Arto Hamara, Steven Wong, and Kent Mein for other logo entries. - -* Arne Claus, for the 2004 winning SDL logo, - and Shandy Brown, Jac, Alex Lyman, Mikkel Gjoel, #Guy, Jonas Hartmann, - Daniel Liljeberg, Ronald Sowa, DocD, Pekka Jaervinen, Patrick Avella, - Erkki Kontilla, Levon Gavalian, Hal Emerich, David Wiktorsson, - S. Schury and F. Hufsky, Ciska de Ruyver, Shredweat, Tyler Montbriand, - Martin Andersson, Merlyn Wysard, Fernando Ibanez, David Miller, - Andre Bommele, lovesby.com, Francisco Camenforte Torres, and David Igreja - for other logo entries. - -* Bob Pendleton and David Olofson for being long time contributors to - the SDL mailing list. - -* Everybody at Loki Software, Inc. for their great contributions! - - And a big hand to everyone else who gave me appreciation, advice, - and suggestions, especially the good folks on the SDL mailing list. - -THANKS! :) - - -- Sam Lantinga - diff --git a/distrib/sdl-1.2.12/Makefile b/distrib/sdl-1.2.12/Makefile deleted file mode 100644 index 3bca609..0000000 --- a/distrib/sdl-1.2.12/Makefile +++ /dev/null @@ -1,71 +0,0 @@ -# Copyright (C) 2008 The Android Open Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# this is a set of definitions that allow the usage of Makefile.android -# even if we're not using the Android build system. -# - -OBJS_DIR := objs -CONFIG_MAKE := $(OBJS_DIR)/config.make -CONFIG_H := $(OBJS_DIR)/config-host.h - -ifeq ($(wildcard $(CONFIG_MAKE)),) - $(error "The configuration file '$(CONFIG_MAKE)' doesnt' exist, please run the "android-configure.sh" script) -endif - -include $(CONFIG_MAKE) - -ifeq ($(strip $(BUILD_SYSTEM)),) - $(error "The BUILD_SYSTEM variable was not defined by your configuration sub-makefile. Aborting") -endif - -include $(BUILD_SYSTEM)/definitions.make - -VPATH := $(OBJS_DIR) -VPATH += :$(SRC_PATH)/include -VPATH += :$(SRC_PATH) - -.PHONY: all libraries executables clean clean-config clean-objs-dir \ - clean-executables clean-libraries - -CLEAR_VARS := $(BUILD_SYSTEM)/clear_vars.make -BUILD_HOST_EXECUTABLE := $(BUILD_SYSTEM)/host_executable.make -BUILD_HOST_STATIC_LIBRARY := $(BUILD_SYSTEM)/host_static_library.make - -DEPENDENCY_DIRS := - -all: libraries executables -EXECUTABLES := -LIBRARIES := - -clean: clean-intermediates - -distclean: clean clean-config - -# let's roll -include Makefile.android - -libraries: $(LIBRARIES) -executables: $(EXECUTABLES) - -clean-intermediates: - rm -rf $(OBJS_DIR)/intermediates $(EXECUTABLES) $(LIBRARIES) - -clean-config: - rm -f $(CONFIG_MAKE) $(CONFIG_H) - -# include dependency information -DEPENDENCY_DIRS := $(sort $(DEPENDENCY_DIRS)) --include $(wildcard $(DEPENDENCY_DIRS:%=%/*.d)) diff --git a/distrib/sdl-1.2.12/Makefile.android b/distrib/sdl-1.2.12/Makefile.android deleted file mode 100644 index 2dfa7dd..0000000 --- a/distrib/sdl-1.2.12/Makefile.android +++ /dev/null @@ -1,93 +0,0 @@ -LOCAL_PATH:= $(call my-dir) - -SDL_DIR := $(LOCAL_PATH) -include $(SDL_DIR)/sources.make - -CONFIG_DIRS := \ - $(LOCAL_PATH)/objs \ - $(LOCAL_PATH)/include \ - $(LOCAL_PATH) \ - -CONFIG_INCLUDES := $(CONFIG_DIRS:%=-I%) - -MY_CC := $(CC) -MY_LD := $(LD) -MY_CFLAGS := $(CFLAGS) $(CONFIG_INCLUDES) -MY_LDFLAGS := $(LDFLAGS) - -include $(CLEAR_VARS) - -LOCAL_NO_DEFAULT_COMPILER_FLAGS := true -LOCAL_CC := $(MY_CC) -LOCAL_CFLAGS := $(MY_CFLAGS) $(LOCAL_CFLAGS) -LOCAL_LDFLAGS := $(MY_LDFLAGS) $(LOCAL_LDFLAGS) - -LOCAL_MODULE := libSDL - -LOCAL_SRC_FILES := $(SDL_SOURCES) - -include $(BUILD_HOST_STATIC_LIBRARY) - -## Build libSDLmain -## - -include $(CLEAR_VARS) - -LOCAL_NO_DEFAULT_COMPILER_FLAGS := true -LOCAL_CC := $(MY_CC) -LOCAL_CFLAGS := $(MY_CFLAGS) $(LOCAL_CFLAGS) -LOCAL_LDFLAGS := $(MY_LDFLAGS) $(LOCAL_LDFLAGS) - -LOCAL_MODULE := libSDLmain - -LOCAL_SRC_FILES := $(SDLMAIN_SOURCES) - -include $(BUILD_HOST_STATIC_LIBRARY) - -# handle installation of generated files -# - -SDL_HEADERS := \ - SDL.h \ - SDL_active.h \ - SDL_audio.h \ - SDL_byteorder.h \ - SDL_cdrom.h \ - SDL_copying.h \ - SDL_cpuinfo.h \ - SDL_endian.h \ - SDL_error.h \ - SDL_events.h \ - SDL_getenv.h \ - SDL_joystick.h \ - SDL_keyboard.h \ - SDL_keysym.h \ - SDL_loadso.h \ - SDL_main.h \ - SDL_mouse.h \ - SDL_mutex.h \ - SDL_name.h \ - SDL_opengl.h \ - SDL_platform.h \ - SDL_quit.h \ - SDL_rwops.h \ - SDL_stdinc.h \ - SDL_syswm.h \ - SDL_thread.h \ - SDL_timer.h \ - SDL_types.h \ - SDL_version.h \ - SDL_video.h \ - begin_code.h \ - close_code.h \ - - -$(foreach target,$(INSTALL_TARGETS),\ - $(eval $(call install-target,objs/sdl-config,$(target)/bin/sdl-config)) \ - $(eval $(call install-target,objs/SDL_config.h,$(target)/include/SDL/SDL_config.h)) \ - $(eval $(call install-target,objs/libs/libSDL.a,$(target)/libs/libSDL.a)) \ - $(eval $(call install-target,objs/libs/libSDLmain.a,$(target)/libs/libSDLmain.a)) \ - $(foreach header,$(SDL_HEADERS), \ - $(eval $(call install-target,include/$(header),$(target)/include/SDL/$(header))) \ - ) \ -) diff --git a/distrib/sdl-1.2.12/README b/distrib/sdl-1.2.12/README deleted file mode 100644 index 7c0dd58..0000000 --- a/distrib/sdl-1.2.12/README +++ /dev/null @@ -1,49 +0,0 @@ - - Simple DirectMedia Layer - - (SDL) - - Version 1.2 - ---- -http://www.libsdl.org/ - -This is the Simple DirectMedia Layer, a general API that provides low -level access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL, -and 2D framebuffer across multiple platforms. - -The current version supports Linux, Windows CE/95/98/ME/XP/Vista, BeOS, -MacOS Classic, Mac OS X, FreeBSD, NetBSD, OpenBSD, BSD/OS, Solaris, IRIX, -and QNX. The code contains support for Dreamcast, Atari, AIX, OSF/Tru64, -RISC OS, SymbianOS, Nintendo DS, and OS/2, but these are not officially -supported. - -SDL is written in C, but works with C++ natively, and has bindings to -several other languages, including Ada, C#, Eiffel, Erlang, Euphoria, -Guile, Haskell, Java, Lisp, Lua, ML, Objective C, Pascal, Perl, PHP, -Pike, Pliant, Python, Ruby, and Smalltalk. - -This library is distributed under GNU LGPL version 2, which can be -found in the file "COPYING". This license allows you to use SDL -freely in commercial programs as long as you link with the dynamic -library. - -The best way to learn how to use SDL is to check out the header files in -the "include" subdirectory and the programs in the "test" subdirectory. -The header files and test programs are well commented and always up to date. -More documentation is available in HTML format in "docs/index.html", and -a documentation wiki is available online at: - http://www.libsdl.org/cgi/docwiki.cgi - -The test programs in the "test" subdirectory are in the public domain. - -Frequently asked questions are answered online: - http://www.libsdl.org/faq.php - -If you need help with the library, or just want to discuss SDL related -issues, you can join the developers mailing list: - http://www.libsdl.org/mailing-list.php - -Enjoy! - Sam Lantinga (slouken@libsdl.org) - diff --git a/distrib/sdl-1.2.12/README.ANDROID b/distrib/sdl-1.2.12/README.ANDROID deleted file mode 100644 index ae7f4aa..0000000 --- a/distrib/sdl-1.2.12/README.ANDROID +++ /dev/null @@ -1,9 +0,0 @@ -This is a modified version of SDL 1.2.12 that is used by the Android QEMU emulator. -The modifications are the following: - -To build it as a static library on Linux, OS X and Windows: - -./android-configure.sh [--prefix=] -make -j2 -make install - diff --git a/distrib/sdl-1.2.12/android-configure.sh b/distrib/sdl-1.2.12/android-configure.sh deleted file mode 100755 index 95bb91f..0000000 --- a/distrib/sdl-1.2.12/android-configure.sh +++ /dev/null @@ -1,553 +0,0 @@ -#/bin/sh -# -# this script is used to rebuild SDL from sources in the current -# directory. It depends on the Android emulator build scripts -# that should normally be located in ../emulator/android/build -# but you can also use ANDROID_QEMU_PATH in your environment -# to point to the top of the Android emulator sources -# -# - -# first, let's see which system we're running this on -cd `dirname $0` - -# try to find the Android build directory automatically -if [ -z "$ANDROID_QEMU_PATH" ] ; then - if [ -f ../../android/build/common.sh ] ; then - ANDROID_QEMU_PATH=../.. - else - echo "You must define ANDROID_QEMU_PATH in your environment to point" - echo "to the directory containing the Android emulator's sources." - exit 1 - fi -fi - -if [ ! -d $ANDROID_QEMU_PATH ] ; then - echo "Your ANDROID_QEMU_PATH does not point to a valid directory." - exit 1 -fi - -if [ ! -f $ANDROID_QEMU_PATH/android/build/common.sh ] ; then - echo "Your ANDROID_QEMU_PATH does not point to a directory that" - echo "contains the Android emulator build scripts." - exit 1 -fi - -# source common functions definitions -. $ANDROID_QEMU_PATH/android/build/common.sh - -# Parse options -OPTION_TRY_64=no -OPTION_HELP=no -OPTION_TARGETS= -OPTION_FORCE_AUTODETECT=no -OPTION_NO_TIGER=no - -if [ -z "$CC" ] ; then - CC=gcc -fi - -for opt do - optarg=`expr "x$opt" : 'x[^=]*=\(.*\)'` - case "$opt" in - --help|-h|-\?) OPTION_HELP=yes - ;; - --verbose) - if [ "$VERBOSE" = "yes" ] ; then - VERBOSE2=yes - else - VERBOSE=yes - fi - ;; - --cc=*) CC="$optarg" ; HOSTCC=$CC - ;; - --try-64) OPTION_TRY_64=yes - ;; - --prefix=*) OPTION_TARGETS="$OPTION_TARGETS $optarg" - ;; - --force-autodetect) OPTION_FORCE_AUTODETECT=yes - ;; - --no-tiger) OPTION_NO_TIGER=yes - ;; - *) - echo "unknown option '$opt', use --help" - exit 1 - esac -done - -# Print the help message -# -if [ "$OPTION_HELP" = "yes" ] ; then - cat << EOF - -Usage: rebuild.sh [options] -Options: [defaults in brackets after descriptions] -EOF - echo "Standard options:" - echo " --help print this message" - echo " --cc=PATH specify C compiler [$CC]" - echo " --try-64 try to build a 64-bit executable (may crash)" - echo " --verbose verbose configuration" - echo " --force-autodetect force feature auto-detection" - echo " --no-tiger do not generate Tiger-compatible binaries (OS X only)" - echo "" - exit 1 -fi - -# we only support generating 32-bit binaris on 64-bit systems. -# And we may need to add a -Wa,--32 to CFLAGS to let the assembler -# generate 32-bit binaries on Linux x86_64. -# -if [ "$OPTION_TRY_64" != "yes" ] ; then - force_32bit_binaries -fi - -# default target -if [ -z "$OPTION_TARGETS" ] ; then - OPTION_TARGETS=out/$OS -fi - -# we can build SDL with Cygwin, so enable it -enable_cygwin - -setup_toolchain - -### -### Special compiler and linker flags -### - -case "$OS" in - linux-*) - BUILD_CFLAGS="-D_GNU_SOURCE=1 -fvisibility=hidden -DXTHREADS -D_REENTRANT" - # prevent -fstack-protector or the generated binaries will not link - BUILD_CFLAGS="$BUILD_CFLAGS -fno-stack-protector" - ;; - darwin-*) - BUILD_CFLAGS="-D_GNU_SOURCE=1 -fvisibility=hidden -DTARGET_API_MAC_CARBON -DTARGET_API_MAC_OSX -D_THREAD_SAFE -force_cpusubtype_ALL -fpascal-strings" - # detect the 10.4 SDK and use it automatically - TIGER_SDK=/Developer/SDKs/MacOSX10.4u.sdk - if [ ! -d $TIGER_SDK -a $OPTION_NO_TIGER = no ] ; then - echo "Please install the 10.4 SDK at $TIGER_SDK to generate Tiger-compatible binaries." - echo "If you don't want compatibility, use --no-tiger option instead." - exit 1 - fi - if [ -d $TIGER_SDK ] ; then - TIGER_OPTS="-isysroot $TIGER_SDK -mmacosx-version-min=10.4" - BUILD_CFLAGS="$BUILD_CFLAGS $TIGER_OPTS" - BUILD_LDFLAGS="$BUILD_LDFLAGS $TIGER_OPTS -Wl,-syslibroot,$(TIGER_SDK)" - echo "Using OS X 10.4 SDK to generate Tiger-compatible binaries." - else - echo "Warning: the generated binaries will not be compatible with Tiger." - fi - ;; - windows) - BUILD_CFLAGS="-D_GNU_SOURCE=1" - ;; - *) - BUILD_CFLAGS= -esac - -# BUILD_CFLAGS are used to build SDL, but SDL_CFLAGS are used -# when clients want to use its facilities -# -case "$HOST_OS" in - linux) - SDL_CFLAGS="-D_GNU_SOURCE=1 -D_REENTRANT" - SDL_STATIC_LIBS="-lm -ldl -lpthread -lrt" - ;; - darwin) - SDL_CFLAGS="-D_GNU_SOURCE=1 -D_THREAD_SAFE" - SDL_STATIC_LIBS="-Wl,-framework,OpenGL -Wl,-framework,Cocoa -Wl,-framework,QuickTime -Wl,-framework,ApplicationServices -Wl,-framework,Carbon -Wl,-framework,IOKit" - ;; - windows) - SDL_CFLAGS="-D_GNU_SOURCE=1 -Dmain=SDL_main" - SDL_STATIC_LIBS="-luser32 -lgdi32 -lwinmm" - ;; - *) - SDL_CFLAGS= - SDL_STATIC_LIBS= -esac - -DOLLAR="$" -SDL_STATIC_LIBS="$DOLLAR{libdir}/libSDLmain.a $DOLLAR{libdir}/libSDL.a $SDL_STATIC_LIBS" - -### -### Features probes -### - -CONFIG_LIBC=yes - -### -### Configuration files generation -### - -# create the objs directory that is going to contain all generated files -# including the configuration ones -# -mkdir -p objs - -config_add () -{ - echo "$1" >> $config_h -} - -# used to add a macro define/undef line to the configuration -# $1: macro name -# $2: 1, 0, yes or no -# $3: optional log prefix -config_add_macro () -{ - local logname - logname="${3:-CfgMacro }" - case "$2" in - 0|no|false) - config_add "/* #undef $1 */" - log "$logname: $1=0" - ;; - 1|yes|true) - config_add "#define $1 1" - log "$logname: $1=1" - ;; - esac -} - -# used to add host-os-specific driver macros to the config file -# $1 : driver prefix, e.g. DRIVERS_VIDEO -# $2 : macro prefix -# this will look for DRIVERS_VIDEO_${HOST_OS}, and, if it is not -# defined in DRIVERS_VIDEO_default -# -# then this will call 'config_add ${2}_${driver}' for each driver listed -# -config_add_driver_macros () -{ - local driver_list="`var_value ${1}_${HOST_OS}`" - local driver_name - if [ -z "$driver_list" ] ; then - driver_list="`var_value ${1}_default`" - fi - for driver_name in $driver_list; do - config_add_macro "${2}_${driver_name}" yes - done -} - -config_h=objs/SDL_config.h - -# a function used to check the availability of a given Standard C header -# $1 : header name, without the .h suffix nor enclosing brackets (e.g. 'memory' for ) -# this will update the configuration with a relevant line -sdl_check_header () -{ - local result - local header - local macro - header="<$1.h>" - macro=`to_uppercase $1` - macro=`echo $macro | tr '/' '_'` - feature_check_header result "$header" - config_add_macro HAVE_${macro}_H $result "StdCHeader " -} - -# call sdl_check_header with a list of header names -sdl_check_headers () -{ - for hh in $*; do - sdl_check_header "$hh" - done -} - -# a function used to check that a given function is available in the C library -# this will update the configuration with a relevant line -# $1: function name -# $2: optional, libraries to link against -# -sdl_check_func () -{ - local result - local funcname - local macro - funcname="$1" - macro=`to_uppercase $1` - rm -f $TMPC - cat > $TMPC < -#undef $funcname - -typedef void (*func_t)(void); -extern void $funcname(void); -func_t _dummy = $funcname; -int main(void) -{ - return _dummy == $funcname; -} -EOF - EXTRA_LDFLAGS="$2" - feature_check_link result - config_add_macro HAVE_${macro} $result "StdCFunc " -} - -# call sdl_check_func with a list of functions -sdl_check_funcs () -{ - for ff in $*; do - sdl_check_func "$ff" - done -} - -# check endianess of the host platform -sdl_check_endianess () -{ - cat > $TMPC < $config_h - - config_add "#ifndef _SDL_config_h" - config_add "#define _SDL_config_h" - config_add "" - config_add "#include \"SDL_platform.h\"" - config_add "" - - # true for all architectures these days - config_add_macro SDL_HAS_64BIT_TYPE 1 - - sdl_check_endianess ENDIANESS - config_add "#define SDL_BYTEORDER $ENDIANESS" - config_add "" - - config_add_macro HAVE_LIBC $CONFIG_LIBC - - config_add "#if HAVE_LIBC" - config_add "" - config_add "/* Useful headers */" - - sdl_check_headers alloca sys/types stdio - - # just like configure - force it to 1 - config_add "#define STDC_HEADERS 1" - - sdl_check_headers stdlib stdarg malloc memory string strings inttypes stdint ctype math iconv signal altivec - - config_add "/* C library functions */" - - sdl_check_funcs malloc calloc realloc free alloc - - config_add "#ifndef _WIN32 /* Don't use on Windows */" - - sdl_check_funcs getenv putenv unsetenv - - config_add "#endif" - sdl_check_funcs qsort abs bcopy memset memcpy memmove memcmp strlen strlcpy strlcat - sdl_check_funcs strdup _strrev _strupr _strlwr index rindex strchr strrchr itoa _ltoa - sdl_check_funcs _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull - sdl_check_funcs strtod atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp - sdl_check_funcs vsnprintf iconv sigaction setjmp nanosleep - - sdl_check_func clock_gettime -lrt - sdl_check_func dlvsym -ldl - - sdl_check_funcs getpagesize - - config_add "#else" - config_add "/* We may need some replacement for stdarg.h here */" - config_add "#include " - config_add "#endif /* HAVE_LIBC */" - config_add "" - - config_add "/* Allow disabling of core subsystems */" - - config_add_macro SDL_AUDIO_DISABLED yes - config_add_macro SDL_CDROM_DISABLED yes - config_add_macro SDL_CPUINFO_DISABLED no - config_add_macro SDL_EVENTS_DISABLED no - config_add_macro SDL_FILE_DISABLED yes - config_add_macro SDL_JOYSTICK_DISABLED yes - config_add_macro SDL_LOADSO_DISABLED no - config_add_macro SDL_THREADS_DISABLED no - config_add_macro SDL_TIMERS_DISABLED no - config_add_macro SDL_VIDEO_DISABLED no - - config_add "" - config_add "/* Enable various shared object loading systems */" - - config_add_driver_macros DRIVERS_LOADSO SDL_LOADSO - - config_add "" - config_add "/* Enable various threading systems */" - - config_add_driver_macros DRIVERS_THREAD SDL_THREAD - - config_add "" - config_add "/* Enable various timer systems */" - - config_add_driver_macros DRIVERS_TIMER SDL_TIMER - - config_add "" - config_add "/* Enable various video drivers */" - - config_add_driver_macros DRIVERS_VIDEO SDL_VIDEO_DRIVER - - config_add_driver_macros DRIVERS_MAIN SDL_MAIN - - # the following defines are good enough for all recent Unix distributions - config_add "#define SDL_VIDEO_DRIVER_X11_DYNAMIC \"libX11.so.6\"" - config_add "#define SDL_VIDEO_DRIVER_X11_DYNAMIC_XEXT \"libXext.so.6\"" - config_add "#define SDL_VIDEO_DRIVER_X11_DYNAMIC_XRANDR \"libXrandr.so.2\"" - config_add "#define SDL_VIDEO_DRIVER_X11_DYNAMIC_XRENDER \"libXrender.so.1\"" - - # todo: OpenGL support ? - # todo: Assembly routines support ? - - config_add "#endif /* _SDL_config_h */" -} - -### Build the config sub-makefile -### - -make_add () -{ - echo "$1" >> $config_mk -} - -make_add_driver_macros () -{ - local driver_list="`var_value ${1}_${HOST_OS}`" - local driver_name - if [ -z "$driver_list" ] ; then - driver_list="`var_value ${1}_default`" - fi - for driver_name in $driver_list; do - make_add "SDL_$2_${driver_name} := yes" - done -} - -generate_sdl_config_mk () -{ - CFLAGS="$CFLAGS $BUILD_CFLAGS" - LDFLAGS="$LDFLAGS $BUILD_LDFLAGS" - create_config_mk - - make_add "" - PWD=`pwd` - make_add "SRC_PATH=$PWD" - make_add "BUILD_SYSTEM=$ANDROID_QEMU_PATH/android/build" - - make_add "SDL_CONFIG_LIBC := $CONFIG_LIBC" - make_add "SDL_CONFIG_CPUINFO := yes" - - make_add_driver_macros DRIVERS_LOADSO CONFIG_LOADSO - make_add_driver_macros DRIVERS_THREAD CONFIG_THREAD - make_add_driver_macros DRIVERS_TIMER CONFIG_TIMER - make_add_driver_macros DRIVERS_VIDEO CONFIG_VIDEO - - make_add_driver_macros DRIVERS_MAIN CONFIG_MAIN - - make_add "INSTALL_TARGETS := $OPTION_TARGETS" -} - -### Build the final sdl-config script from the template -### - -generate_sdl_config () -{ - # build a sed script that will replace all @VARIABLES@ in the template - # with appropriate values - rm -f $TMPC - - # replace @exec_prefix@ with "{prefix}", and @libdir@ with "{libdir}" - cat > $TMPC <> $TMPC <> $TMPC <> $TMPC < objs/sdl-config - chmod +x objs/sdl-config -} - -# copy a configuration file or perform auto-detection if one is not available -# or the --force-autodetect option was used -# $1: basename of config file -# $2: command to run to perform auto-detection/generation -# -copy_or_autodetect () -{ - if [ "$OPTION_FORCE_AUTODETECT" != "yes" -a -f android/build/$OS/$1 ] ; then - log "Setup : Copying $1 from android/build/$OS" - cp -f android/build/$OS/$1 objs/$1 - else - log "Setup : Auto-generating $1" - eval $2 - fi -} - -generate_all () -{ - copy_or_autodetect SDL_config.h generate_SDL_config_h - generate_sdl_config_mk - copy_or_autodetect sdl-config generate_sdl_config -} - -DRIVERS_LOADSO_default=DLOPEN -DRIVERS_LOADSO_darwin=DLCOMPAT -DRIVERS_LOADSO_windows=WIN32 - -# TODO: determine if PTHREAD_RECURSIVE or PTHREAD_RECURSIVE_NP is valid for the platform -DRIVERS_THREAD_default="PTHREAD PTHREAD_RECURSIVE_MUTEX" -DRIVERS_THREAD_linux="PTHREAD PTHREAD_RECURSIVE_MUTEX_NP" -DRIVERS_THREAD_windows=WIN32 - -DRIVERS_TIMER_default=UNIX -DRIVERS_TIMER_windows=WIN32 - -# TODO: actually compute this properly for X11 and dynamic loading !! -DRIVERS_VIDEO_default="X11 X11_DPMS X11_XINERAMA X11_XME" -DRIVERS_VIDEO_darwin="QUARTZ" -DRIVERS_VIDEO_windows="WINDIB" - -DRIVERS_MAIN_default=DUMMY -DRIVERS_MAIN_darwin=MACOSX -DRIVERS_MAIN_windows=WIN32 - -generate_all diff --git a/distrib/sdl-1.2.12/include/SDL.h b/distrib/sdl-1.2.12/include/SDL.h deleted file mode 100644 index 60ac26c..0000000 --- a/distrib/sdl-1.2.12/include/SDL.h +++ /dev/null @@ -1,94 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Main include header for the SDL library */ - -#ifndef _SDL_H -#define _SDL_H - -#include "SDL_main.h" -#include "SDL_stdinc.h" -#include "SDL_audio.h" -#include "SDL_cdrom.h" -#include "SDL_cpuinfo.h" -#include "SDL_endian.h" -#include "SDL_error.h" -#include "SDL_events.h" -#include "SDL_loadso.h" -#include "SDL_mutex.h" -#include "SDL_rwops.h" -#include "SDL_thread.h" -#include "SDL_timer.h" -#include "SDL_video.h" -#include "SDL_version.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* As of version 0.5, SDL is loaded dynamically into the application */ - -/* These are the flags which may be passed to SDL_Init() -- you should - specify the subsystems which you will be using in your application. -*/ -#define SDL_INIT_TIMER 0x00000001 -#define SDL_INIT_AUDIO 0x00000010 -#define SDL_INIT_VIDEO 0x00000020 -#define SDL_INIT_CDROM 0x00000100 -#define SDL_INIT_JOYSTICK 0x00000200 -#define SDL_INIT_NOPARACHUTE 0x00100000 /* Don't catch fatal signals */ -#define SDL_INIT_EVENTTHREAD 0x01000000 /* Not supported on all OS's */ -#define SDL_INIT_EVERYTHING 0x0000FFFF - -/* This function loads the SDL dynamically linked library and initializes - * the subsystems specified by 'flags' (and those satisfying dependencies) - * Unless the SDL_INIT_NOPARACHUTE flag is set, it will install cleanup - * signal handlers for some commonly ignored fatal signals (like SIGSEGV) - */ -extern DECLSPEC int SDLCALL SDL_Init(Uint32 flags); - -/* This function initializes specific SDL subsystems */ -extern DECLSPEC int SDLCALL SDL_InitSubSystem(Uint32 flags); - -/* This function cleans up specific SDL subsystems */ -extern DECLSPEC void SDLCALL SDL_QuitSubSystem(Uint32 flags); - -/* This function returns mask of the specified subsystems which have - been initialized. - If 'flags' is 0, it returns a mask of all initialized subsystems. -*/ -extern DECLSPEC Uint32 SDLCALL SDL_WasInit(Uint32 flags); - -/* This function cleans up all initialized subsystems and unloads the - * dynamically linked library. You should call it upon all exit conditions. - */ -extern DECLSPEC void SDLCALL SDL_Quit(void); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_H */ diff --git a/distrib/sdl-1.2.12/include/SDL_active.h b/distrib/sdl-1.2.12/include/SDL_active.h deleted file mode 100644 index 2cf474c..0000000 --- a/distrib/sdl-1.2.12/include/SDL_active.h +++ /dev/null @@ -1,58 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL application focus event handling */ - -#ifndef _SDL_active_h -#define _SDL_active_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* The available application states */ -#define SDL_APPMOUSEFOCUS 0x01 /* The app has mouse coverage */ -#define SDL_APPINPUTFOCUS 0x02 /* The app has input focus */ -#define SDL_APPACTIVE 0x04 /* The application is active */ - -/* Function prototypes */ -/* - * This function returns the current state of the application, which is a - * bitwise combination of SDL_APPMOUSEFOCUS, SDL_APPINPUTFOCUS, and - * SDL_APPACTIVE. If SDL_APPACTIVE is set, then the user is able to - * see your application, otherwise it has been iconified or disabled. - */ -extern DECLSPEC Uint8 SDLCALL SDL_GetAppState(void); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_active_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_audio.h b/distrib/sdl-1.2.12/include/SDL_audio.h deleted file mode 100644 index 68ec475..0000000 --- a/distrib/sdl-1.2.12/include/SDL_audio.h +++ /dev/null @@ -1,253 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Access to the raw audio mixing buffer for the SDL library */ - -#ifndef _SDL_audio_h -#define _SDL_audio_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_endian.h" -#include "SDL_mutex.h" -#include "SDL_thread.h" -#include "SDL_rwops.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* The calculated values in this structure are calculated by SDL_OpenAudio() */ -typedef struct SDL_AudioSpec { - int freq; /* DSP frequency -- samples per second */ - Uint16 format; /* Audio data format */ - Uint8 channels; /* Number of channels: 1 mono, 2 stereo */ - Uint8 silence; /* Audio buffer silence value (calculated) */ - Uint16 samples; /* Audio buffer size in samples (power of 2) */ - Uint16 padding; /* Necessary for some compile environments */ - Uint32 size; /* Audio buffer size in bytes (calculated) */ - /* This function is called when the audio device needs more data. - 'stream' is a pointer to the audio data buffer - 'len' is the length of that buffer in bytes. - Once the callback returns, the buffer will no longer be valid. - Stereo samples are stored in a LRLRLR ordering. - */ - void (SDLCALL *callback)(void *userdata, Uint8 *stream, int len); - void *userdata; -} SDL_AudioSpec; - -/* Audio format flags (defaults to LSB byte order) */ -#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 - -/* Native audio byte ordering */ -#if SDL_BYTEORDER == SDL_LIL_ENDIAN -#define AUDIO_U16SYS AUDIO_U16LSB -#define AUDIO_S16SYS AUDIO_S16LSB -#else -#define AUDIO_U16SYS AUDIO_U16MSB -#define AUDIO_S16SYS AUDIO_S16MSB -#endif - - -/* A structure to hold a set of audio conversion filters and buffers */ -typedef struct SDL_AudioCVT { - int needed; /* Set to 1 if conversion possible */ - Uint16 src_format; /* Source audio format */ - Uint16 dst_format; /* Target audio format */ - double rate_incr; /* Rate conversion increment */ - Uint8 *buf; /* Buffer to hold entire audio data */ - int len; /* Length of original audio buffer */ - int len_cvt; /* Length of converted audio buffer */ - int len_mult; /* buffer must be len*len_mult big */ - double len_ratio; /* Given len, final size is len*len_ratio */ - void (SDLCALL *filters[10])(struct SDL_AudioCVT *cvt, Uint16 format); - int filter_index; /* Current audio conversion function */ -} SDL_AudioCVT; - - -/* Function prototypes */ - -/* These functions are used internally, and should not be used unless you - * have a specific need to specify the audio driver you want to use. - * You should normally use SDL_Init() or SDL_InitSubSystem(). - */ -extern DECLSPEC int SDLCALL SDL_AudioInit(const char *driver_name); -extern DECLSPEC void SDLCALL SDL_AudioQuit(void); - -/* This function fills the given character buffer with the name of the - * current audio driver, and returns a pointer to it if the audio driver has - * been initialized. It returns NULL if no driver has been initialized. - */ -extern DECLSPEC char * SDLCALL SDL_AudioDriverName(char *namebuf, int maxlen); - -/* - * This function opens the audio device with the desired parameters, and - * returns 0 if successful, placing the actual hardware parameters in the - * structure pointed to by 'obtained'. If 'obtained' is NULL, the audio - * data passed to the callback function will be guaranteed to be in the - * requested format, and will be automatically converted to the hardware - * audio format if necessary. This function returns -1 if it failed - * to open the audio device, or couldn't set up the audio thread. - * - * When filling in the desired audio spec structure, - * 'desired->freq' should be the desired audio frequency in samples-per-second. - * 'desired->format' should be the desired audio format. - * 'desired->samples' is the desired size of the audio buffer, in samples. - * This number should be a power of two, and may be adjusted by the audio - * driver to a value more suitable for the hardware. Good values seem to - * range between 512 and 8096 inclusive, depending on the application and - * CPU speed. Smaller values yield faster response time, but can lead - * to underflow if the application is doing heavy processing and cannot - * fill the audio buffer in time. A stereo sample consists of both right - * and left channels in LR ordering. - * Note that the number of samples is directly related to time by the - * following formula: ms = (samples*1000)/freq - * 'desired->size' is the size in bytes of the audio buffer, and is - * calculated by SDL_OpenAudio(). - * 'desired->silence' is the value used to set the buffer to silence, - * and is calculated by SDL_OpenAudio(). - * 'desired->callback' should be set to a function that will be called - * when the audio device is ready for more data. It is passed a pointer - * to the audio buffer, and the length in bytes of the audio buffer. - * This function usually runs in a separate thread, and so you should - * protect data structures that it accesses by calling SDL_LockAudio() - * and SDL_UnlockAudio() in your code. - * 'desired->userdata' is passed as the first parameter to your callback - * function. - * - * The audio device starts out playing silence when it's opened, and should - * be enabled for playing by calling SDL_PauseAudio(0) when you are ready - * for your audio callback function to be called. Since the audio driver - * may modify the requested size of the audio buffer, you should allocate - * any local mixing buffers after you open the audio device. - */ -extern DECLSPEC int SDLCALL SDL_OpenAudio(SDL_AudioSpec *desired, SDL_AudioSpec *obtained); - -/* - * Get the current audio state: - */ -typedef enum { - SDL_AUDIO_STOPPED = 0, - SDL_AUDIO_PLAYING, - SDL_AUDIO_PAUSED -} SDL_audiostatus; -extern DECLSPEC SDL_audiostatus SDLCALL SDL_GetAudioStatus(void); - -/* - * This function pauses and unpauses the audio callback processing. - * It should be called with a parameter of 0 after opening the audio - * device to start playing sound. This is so you can safely initialize - * data for your callback function after opening the audio device. - * Silence will be written to the audio device during the pause. - */ -extern DECLSPEC void SDLCALL SDL_PauseAudio(int pause_on); - -/* - * This function loads a WAVE from the data source, automatically freeing - * that source if 'freesrc' is non-zero. For example, to load a WAVE file, - * you could do: - * SDL_LoadWAV_RW(SDL_RWFromFile("sample.wav", "rb"), 1, ...); - * - * If this function succeeds, it returns the given SDL_AudioSpec, - * filled with the audio data format of the wave data, and sets - * 'audio_buf' to a malloc()'d buffer containing the audio data, - * and sets 'audio_len' to the length of that audio buffer, in bytes. - * You need to free the audio buffer with SDL_FreeWAV() when you are - * done with it. - * - * This function returns NULL and sets the SDL error message if the - * wave file cannot be opened, uses an unknown data format, or is - * corrupt. Currently raw and MS-ADPCM WAVE files are supported. - */ -extern DECLSPEC SDL_AudioSpec * SDLCALL SDL_LoadWAV_RW(SDL_RWops *src, int freesrc, SDL_AudioSpec *spec, Uint8 **audio_buf, Uint32 *audio_len); - -/* Compatibility convenience function -- loads a WAV from a file */ -#define SDL_LoadWAV(file, spec, audio_buf, audio_len) \ - SDL_LoadWAV_RW(SDL_RWFromFile(file, "rb"),1, spec,audio_buf,audio_len) - -/* - * This function frees data previously allocated with SDL_LoadWAV_RW() - */ -extern DECLSPEC void SDLCALL SDL_FreeWAV(Uint8 *audio_buf); - -/* - * This function takes a source format and rate and a destination format - * and rate, and initializes the 'cvt' structure with information needed - * by SDL_ConvertAudio() to convert a buffer of audio data from one format - * to the other. - * This function returns 0, or -1 if there was an error. - */ -extern DECLSPEC int SDLCALL SDL_BuildAudioCVT(SDL_AudioCVT *cvt, - Uint16 src_format, Uint8 src_channels, int src_rate, - Uint16 dst_format, Uint8 dst_channels, int dst_rate); - -/* Once you have initialized the 'cvt' structure using SDL_BuildAudioCVT(), - * created an audio buffer cvt->buf, and filled it with cvt->len bytes of - * audio data in the source format, this function will convert it in-place - * to the desired format. - * The data conversion may expand the size of the audio data, so the buffer - * cvt->buf should be allocated after the cvt structure is initialized by - * SDL_BuildAudioCVT(), and should be cvt->len*cvt->len_mult bytes long. - */ -extern DECLSPEC int SDLCALL SDL_ConvertAudio(SDL_AudioCVT *cvt); - -/* - * This takes two audio buffers of the playing audio format and mixes - * them, performing addition, volume adjustment, and overflow clipping. - * The volume ranges from 0 - 128, and should be set to SDL_MIX_MAXVOLUME - * for full audio volume. Note this does not change hardware volume. - * This is provided for convenience -- you can mix your own audio data. - */ -#define SDL_MIX_MAXVOLUME 128 -extern DECLSPEC void SDLCALL SDL_MixAudio(Uint8 *dst, const Uint8 *src, Uint32 len, int volume); - -/* - * The lock manipulated by these functions protects the callback function. - * During a LockAudio/UnlockAudio pair, you can be guaranteed that the - * callback function is not running. Do not call these from the callback - * function or you will cause deadlock. - */ -extern DECLSPEC void SDLCALL SDL_LockAudio(void); -extern DECLSPEC void SDLCALL SDL_UnlockAudio(void); - -/* - * This function shuts down audio processing and closes the audio device. - */ -extern DECLSPEC void SDLCALL SDL_CloseAudio(void); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_audio_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_byteorder.h b/distrib/sdl-1.2.12/include/SDL_byteorder.h deleted file mode 100644 index 3871cfe..0000000 --- a/distrib/sdl-1.2.12/include/SDL_byteorder.h +++ /dev/null @@ -1,24 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* DEPRECATED */ -#include "SDL_endian.h" diff --git a/distrib/sdl-1.2.12/include/SDL_cdrom.h b/distrib/sdl-1.2.12/include/SDL_cdrom.h deleted file mode 100644 index 5f8f0c6..0000000 --- a/distrib/sdl-1.2.12/include/SDL_cdrom.h +++ /dev/null @@ -1,171 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This is the CD-audio control API for Simple DirectMedia Layer */ - -#ifndef _SDL_cdrom_h -#define _SDL_cdrom_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* In order to use these functions, SDL_Init() must have been called - with the SDL_INIT_CDROM flag. This causes SDL to scan the system - for CD-ROM drives, and load appropriate drivers. -*/ - -/* The maximum number of CD-ROM tracks on a disk */ -#define SDL_MAX_TRACKS 99 - -/* The types of CD-ROM track possible */ -#define SDL_AUDIO_TRACK 0x00 -#define SDL_DATA_TRACK 0x04 - -/* The possible states which a CD-ROM drive can be in. */ -typedef enum { - CD_TRAYEMPTY, - CD_STOPPED, - CD_PLAYING, - CD_PAUSED, - CD_ERROR = -1 -} CDstatus; - -/* Given a status, returns true if there's a disk in the drive */ -#define CD_INDRIVE(status) ((int)(status) > 0) - -typedef struct SDL_CDtrack { - Uint8 id; /* Track number */ - Uint8 type; /* Data or audio track */ - Uint16 unused; - Uint32 length; /* Length, in frames, of this track */ - Uint32 offset; /* Offset, in frames, from start of disk */ -} SDL_CDtrack; - -/* This structure is only current as of the last call to SDL_CDStatus() */ -typedef struct SDL_CD { - int id; /* Private drive identifier */ - CDstatus status; /* Current drive status */ - - /* The rest of this structure is only valid if there's a CD in drive */ - int numtracks; /* Number of tracks on disk */ - int cur_track; /* Current track position */ - int cur_frame; /* Current frame offset within current track */ - SDL_CDtrack track[SDL_MAX_TRACKS+1]; -} SDL_CD; - -/* Conversion functions from frames to Minute/Second/Frames and vice versa */ -#define CD_FPS 75 -#define FRAMES_TO_MSF(f, M,S,F) { \ - int value = f; \ - *(F) = value%CD_FPS; \ - value /= CD_FPS; \ - *(S) = value%60; \ - value /= 60; \ - *(M) = value; \ -} -#define MSF_TO_FRAMES(M, S, F) ((M)*60*CD_FPS+(S)*CD_FPS+(F)) - -/* CD-audio API functions: */ - -/* Returns the number of CD-ROM drives on the system, or -1 if - SDL_Init() has not been called with the SDL_INIT_CDROM flag. - */ -extern DECLSPEC int SDLCALL SDL_CDNumDrives(void); - -/* Returns a human-readable, system-dependent identifier for the CD-ROM. - Example: - "/dev/cdrom" - "E:" - "/dev/disk/ide/1/master" -*/ -extern DECLSPEC const char * SDLCALL SDL_CDName(int drive); - -/* Opens a CD-ROM drive for access. It returns a drive handle on success, - or NULL if the drive was invalid or busy. This newly opened CD-ROM - becomes the default CD used when other CD functions are passed a NULL - CD-ROM handle. - Drives are numbered starting with 0. Drive 0 is the system default CD-ROM. -*/ -extern DECLSPEC SDL_CD * SDLCALL SDL_CDOpen(int drive); - -/* This function returns the current status of the given drive. - If the drive has a CD in it, the table of contents of the CD and current - play position of the CD will be stored in the SDL_CD structure. -*/ -extern DECLSPEC CDstatus SDLCALL SDL_CDStatus(SDL_CD *cdrom); - -/* Play the given CD starting at 'start_track' and 'start_frame' for 'ntracks' - tracks and 'nframes' frames. If both 'ntrack' and 'nframe' are 0, play - until the end of the CD. This function will skip data tracks. - This function should only be called after calling SDL_CDStatus() to - get track information about the CD. - For example: - // Play entire CD: - if ( CD_INDRIVE(SDL_CDStatus(cdrom)) ) - SDL_CDPlayTracks(cdrom, 0, 0, 0, 0); - // Play last track: - if ( CD_INDRIVE(SDL_CDStatus(cdrom)) ) { - SDL_CDPlayTracks(cdrom, cdrom->numtracks-1, 0, 0, 0); - } - // Play first and second track and 10 seconds of third track: - if ( CD_INDRIVE(SDL_CDStatus(cdrom)) ) - SDL_CDPlayTracks(cdrom, 0, 0, 2, 10); - - This function returns 0, or -1 if there was an error. -*/ -extern DECLSPEC int SDLCALL SDL_CDPlayTracks(SDL_CD *cdrom, - int start_track, int start_frame, int ntracks, int nframes); - -/* Play the given CD starting at 'start' frame for 'length' frames. - It returns 0, or -1 if there was an error. -*/ -extern DECLSPEC int SDLCALL SDL_CDPlay(SDL_CD *cdrom, int start, int length); - -/* Pause play -- returns 0, or -1 on error */ -extern DECLSPEC int SDLCALL SDL_CDPause(SDL_CD *cdrom); - -/* Resume play -- returns 0, or -1 on error */ -extern DECLSPEC int SDLCALL SDL_CDResume(SDL_CD *cdrom); - -/* Stop play -- returns 0, or -1 on error */ -extern DECLSPEC int SDLCALL SDL_CDStop(SDL_CD *cdrom); - -/* Eject CD-ROM -- returns 0, or -1 on error */ -extern DECLSPEC int SDLCALL SDL_CDEject(SDL_CD *cdrom); - -/* Closes the handle for the CD-ROM drive */ -extern DECLSPEC void SDLCALL SDL_CDClose(SDL_CD *cdrom); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_video_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config.h.default b/distrib/sdl-1.2.12/include/SDL_config.h.default deleted file mode 100644 index c82f42a..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config.h.default +++ /dev/null @@ -1,45 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_h -#define _SDL_config_h - -#include "SDL_platform.h" - -/* Add any platform that doesn't build using the configure system */ -#if defined(__DREAMCAST__) -#include "SDL_config_dreamcast.h" -#elif defined(__MACOS__) -#include "SDL_config_macos.h" -#elif defined(__MACOSX__) -#include "SDL_config_macosx.h" -#elif defined(__SYMBIAN32__) -#include "SDL_config_symbian.h" /* must be before win32! */ -#elif defined(__WIN32__) -#include "SDL_config_win32.h" -#elif defined(__OS2__) -#include "SDL_config_os2.h" -#else -#include "SDL_config_minimal.h" -#endif /* platform config */ - -#endif /* _SDL_config_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config.h.in b/distrib/sdl-1.2.12/include/SDL_config.h.in deleted file mode 100644 index 13a3f9a..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config.h.in +++ /dev/null @@ -1,305 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_h -#define _SDL_config_h - -/* This is a set of defines to configure the SDL features */ - -/* General platform specific identifiers */ -#include "SDL_platform.h" - -/* Make sure that this isn't included by Visual C++ */ -#ifdef _MSC_VER -#error You should copy include/SDL_config.h.default to include/SDL_config.h -#endif - -/* C language features */ -#undef const -#undef inline -#undef volatile - -/* C datatypes */ -#undef size_t -#undef int8_t -#undef uint8_t -#undef int16_t -#undef uint16_t -#undef int32_t -#undef uint32_t -#undef int64_t -#undef uint64_t -#undef uintptr_t -#undef SDL_HAS_64BIT_TYPE - -/* Endianness */ -#undef SDL_BYTEORDER - -/* Comment this if you want to build without any C library requirements */ -#undef HAVE_LIBC -#if HAVE_LIBC - -/* Useful headers */ -#undef HAVE_ALLOCA_H -#undef HAVE_SYS_TYPES_H -#undef HAVE_STDIO_H -#undef STDC_HEADERS -#undef HAVE_STDLIB_H -#undef HAVE_STDARG_H -#undef HAVE_MALLOC_H -#undef HAVE_MEMORY_H -#undef HAVE_STRING_H -#undef HAVE_STRINGS_H -#undef HAVE_INTTYPES_H -#undef HAVE_STDINT_H -#undef HAVE_CTYPE_H -#undef HAVE_MATH_H -#undef HAVE_ICONV_H -#undef HAVE_SIGNAL_H -#undef HAVE_ALTIVEC_H - -/* C library functions */ -#undef HAVE_MALLOC -#undef HAVE_CALLOC -#undef HAVE_REALLOC -#undef HAVE_FREE -#undef HAVE_ALLOCA -#ifndef _WIN32 /* Don't use C runtime versions of these on Windows */ -#undef HAVE_GETENV -#undef HAVE_PUTENV -#undef HAVE_UNSETENV -#endif -#undef HAVE_QSORT -#undef HAVE_ABS -#undef HAVE_BCOPY -#undef HAVE_MEMSET -#undef HAVE_MEMCPY -#undef HAVE_MEMMOVE -#undef HAVE_MEMCMP -#undef HAVE_STRLEN -#undef HAVE_STRLCPY -#undef HAVE_STRLCAT -#undef HAVE_STRDUP -#undef HAVE__STRREV -#undef HAVE__STRUPR -#undef HAVE__STRLWR -#undef HAVE_INDEX -#undef HAVE_RINDEX -#undef HAVE_STRCHR -#undef HAVE_STRRCHR -#undef HAVE_STRSTR -#undef HAVE_ITOA -#undef HAVE__LTOA -#undef HAVE__UITOA -#undef HAVE__ULTOA -#undef HAVE_STRTOL -#undef HAVE_STRTOUL -#undef HAVE__I64TOA -#undef HAVE__UI64TOA -#undef HAVE_STRTOLL -#undef HAVE_STRTOULL -#undef HAVE_STRTOD -#undef HAVE_ATOI -#undef HAVE_ATOF -#undef HAVE_STRCMP -#undef HAVE_STRNCMP -#undef HAVE__STRICMP -#undef HAVE_STRCASECMP -#undef HAVE__STRNICMP -#undef HAVE_STRNCASECMP -#undef HAVE_SSCANF -#undef HAVE_SNPRINTF -#undef HAVE_VSNPRINTF -#undef HAVE_ICONV -#undef HAVE_SIGACTION -#undef HAVE_SETJMP -#undef HAVE_NANOSLEEP -#undef HAVE_CLOCK_GETTIME -#undef HAVE_DLVSYM -#undef HAVE_GETPAGESIZE - -#else -/* We may need some replacement for stdarg.h here */ -#include -#endif /* HAVE_LIBC */ - -/* Allow disabling of core subsystems */ -#undef SDL_AUDIO_DISABLED -#undef SDL_CDROM_DISABLED -#undef SDL_CPUINFO_DISABLED -#undef SDL_EVENTS_DISABLED -#undef SDL_FILE_DISABLED -#undef SDL_JOYSTICK_DISABLED -#undef SDL_LOADSO_DISABLED -#undef SDL_THREADS_DISABLED -#undef SDL_TIMERS_DISABLED -#undef SDL_VIDEO_DISABLED - -/* Enable various audio drivers */ -#undef SDL_AUDIO_DRIVER_ALSA -#undef SDL_AUDIO_DRIVER_ALSA_DYNAMIC -#undef SDL_AUDIO_DRIVER_ARTS -#undef SDL_AUDIO_DRIVER_ARTS_DYNAMIC -#undef SDL_AUDIO_DRIVER_BAUDIO -#undef SDL_AUDIO_DRIVER_BSD -#undef SDL_AUDIO_DRIVER_COREAUDIO -#undef SDL_AUDIO_DRIVER_DART -#undef SDL_AUDIO_DRIVER_DC -#undef SDL_AUDIO_DRIVER_DISK -#undef SDL_AUDIO_DRIVER_DUMMY -#undef SDL_AUDIO_DRIVER_DMEDIA -#undef SDL_AUDIO_DRIVER_DSOUND -#undef SDL_AUDIO_DRIVER_PULSE -#undef SDL_AUDIO_DRIVER_PULSE_DYNAMIC -#undef SDL_AUDIO_DRIVER_ESD -#undef SDL_AUDIO_DRIVER_ESD_DYNAMIC -#undef SDL_AUDIO_DRIVER_MINT -#undef SDL_AUDIO_DRIVER_MMEAUDIO -#undef SDL_AUDIO_DRIVER_NAS -#undef SDL_AUDIO_DRIVER_OSS -#undef SDL_AUDIO_DRIVER_OSS_SOUNDCARD_H -#undef SDL_AUDIO_DRIVER_PAUD -#undef SDL_AUDIO_DRIVER_QNXNTO -#undef SDL_AUDIO_DRIVER_SNDMGR -#undef SDL_AUDIO_DRIVER_SUNAUDIO -#undef SDL_AUDIO_DRIVER_WAVEOUT - -/* Enable various cdrom drivers */ -#undef SDL_CDROM_AIX -#undef SDL_CDROM_BEOS -#undef SDL_CDROM_BSDI -#undef SDL_CDROM_DC -#undef SDL_CDROM_DUMMY -#undef SDL_CDROM_FREEBSD -#undef SDL_CDROM_LINUX -#undef SDL_CDROM_MACOS -#undef SDL_CDROM_MACOSX -#undef SDL_CDROM_MINT -#undef SDL_CDROM_OPENBSD -#undef SDL_CDROM_OS2 -#undef SDL_CDROM_OSF -#undef SDL_CDROM_QNX -#undef SDL_CDROM_WIN32 - -/* Enable various input drivers */ -#undef SDL_INPUT_TSLIB -#undef SDL_JOYSTICK_BEOS -#undef SDL_JOYSTICK_DC -#undef SDL_JOYSTICK_DUMMY -#undef SDL_JOYSTICK_IOKIT -#undef SDL_JOYSTICK_LINUX -#undef SDL_JOYSTICK_LINUXEV -#undef SDL_JOYSTICK_MACOS -#undef SDL_JOYSTICK_MINT -#undef SDL_JOYSTICK_OS2 -#undef SDL_JOYSTICK_RISCOS -#undef SDL_JOYSTICK_WINMM -#undef SDL_JOYSTICK_USBHID -#undef SDL_JOYSTICK_USBHID_MACHINE_JOYSTICK_H - -/* Enable various shared object loading systems */ -#undef SDL_LOADSO_BEOS -#undef SDL_LOADSO_DLCOMPAT -#undef SDL_LOADSO_DLOPEN -#undef SDL_LOADSO_DUMMY -#undef SDL_LOADSO_LDG -#undef SDL_LOADSO_MACOS -#undef SDL_LOADSO_OS2 -#undef SDL_LOADSO_WIN32 - -/* Enable various threading systems */ -#undef SDL_THREAD_BEOS -#undef SDL_THREAD_DC -#undef SDL_THREAD_OS2 -#undef SDL_THREAD_PTH -#undef SDL_THREAD_PTHREAD -#undef SDL_THREAD_PTHREAD_RECURSIVE_MUTEX -#undef SDL_THREAD_PTHREAD_RECURSIVE_MUTEX_NP -#undef SDL_THREAD_SPROC -#undef SDL_THREAD_WIN32 - -/* Enable various timer systems */ -#undef SDL_TIMER_BEOS -#undef SDL_TIMER_DC -#undef SDL_TIMER_DUMMY -#undef SDL_TIMER_MACOS -#undef SDL_TIMER_MINT -#undef SDL_TIMER_OS2 -#undef SDL_TIMER_RISCOS -#undef SDL_TIMER_UNIX -#undef SDL_TIMER_WIN32 -#undef SDL_TIMER_WINCE - -/* Enable various video drivers */ -#undef SDL_VIDEO_DRIVER_AALIB -#undef SDL_VIDEO_DRIVER_BWINDOW -#undef SDL_VIDEO_DRIVER_DC -#undef SDL_VIDEO_DRIVER_DDRAW -#undef SDL_VIDEO_DRIVER_DGA -#undef SDL_VIDEO_DRIVER_DIRECTFB -#undef SDL_VIDEO_DRIVER_DRAWSPROCKET -#undef SDL_VIDEO_DRIVER_DUMMY -#undef SDL_VIDEO_DRIVER_FBCON -#undef SDL_VIDEO_DRIVER_GAPI -#undef SDL_VIDEO_DRIVER_GEM -#undef SDL_VIDEO_DRIVER_GGI -#undef SDL_VIDEO_DRIVER_IPOD -#undef SDL_VIDEO_DRIVER_NANOX -#undef SDL_VIDEO_DRIVER_OS2FS -#undef SDL_VIDEO_DRIVER_PHOTON -#undef SDL_VIDEO_DRIVER_PICOGUI -#undef SDL_VIDEO_DRIVER_PS2GS -#undef SDL_VIDEO_DRIVER_QTOPIA -#undef SDL_VIDEO_DRIVER_QUARTZ -#undef SDL_VIDEO_DRIVER_RISCOS -#undef SDL_VIDEO_DRIVER_SVGALIB -#undef SDL_VIDEO_DRIVER_TOOLBOX -#undef SDL_VIDEO_DRIVER_VGL -#undef SDL_VIDEO_DRIVER_WINDIB -#undef SDL_VIDEO_DRIVER_WSCONS -#undef SDL_VIDEO_DRIVER_X11 -#undef SDL_VIDEO_DRIVER_X11_DGAMOUSE -#undef SDL_VIDEO_DRIVER_X11_DPMS -#undef SDL_VIDEO_DRIVER_X11_DYNAMIC -#undef SDL_VIDEO_DRIVER_X11_DYNAMIC_XEXT -#undef SDL_VIDEO_DRIVER_X11_DYNAMIC_XRANDR -#undef SDL_VIDEO_DRIVER_X11_DYNAMIC_XRENDER -#undef SDL_VIDEO_DRIVER_X11_VIDMODE -#undef SDL_VIDEO_DRIVER_X11_XINERAMA -#undef SDL_VIDEO_DRIVER_X11_XME -#undef SDL_VIDEO_DRIVER_X11_XRANDR -#undef SDL_VIDEO_DRIVER_X11_XV -#undef SDL_VIDEO_DRIVER_XBIOS - -/* Enable OpenGL support */ -#undef SDL_VIDEO_OPENGL -#undef SDL_VIDEO_OPENGL_GLX -#undef SDL_VIDEO_OPENGL_WGL -#undef SDL_VIDEO_OPENGL_OSMESA -#undef SDL_VIDEO_OPENGL_OSMESA_DYNAMIC - -/* Enable assembly routines */ -#undef SDL_ASSEMBLY_ROUTINES -#undef SDL_HERMES_BLITTERS -#undef SDL_ALTIVEC_BLITTERS - -#endif /* _SDL_config_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_amiga.h b/distrib/sdl-1.2.12/include/SDL_config_amiga.h deleted file mode 100644 index 23e0861..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_amiga.h +++ /dev/null @@ -1,80 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_amiga_h -#define _SDL_config_amiga_h - -#include "SDL_platform.h" - -/* This is a set of defines to configure the SDL features */ - -#define SDL_HAS_64BIT_TYPE 1 - -/* Useful headers */ -#define HAVE_SYS_TYPES_H 1 -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STRING_H 1 -#define HAVE_INTTYPES_H 1 -#define HAVE_SIGNAL_H 1 - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_GETENV 1 -#define HAVE_PUTENV 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 - -/* Enable various audio drivers */ -#define SDL_AUDIO_DRIVER_AHI 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#define SDL_CDROM_DUMMY 1 - -/* Enable various input drivers */ -#define SDL_JOYSTICK_AMIGA 1 - -/* Enable various shared object loading systems */ -#define SDL_LOADSO_DUMMY 1 - -/* Enable various threading systems */ -#define SDL_THREAD_AMIGA 1 - -/* Enable various timer systems */ -#define SDL_TIMER_AMIGA 1 - -/* Enable various video drivers */ -#define SDL_VIDEO_DRIVER_CYBERGRAPHICS 1 -#define SDL_VIDEO_DRIVER_DUMMY 1 - -/* Enable OpenGL support */ -#define SDL_VIDEO_OPENGL 1 - -#endif /* _SDL_config_amiga_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_dreamcast.h b/distrib/sdl-1.2.12/include/SDL_config_dreamcast.h deleted file mode 100644 index 9cbeea3..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_dreamcast.h +++ /dev/null @@ -1,106 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_dreamcast_h -#define _SDL_config_dreamcast_h - -#include "SDL_platform.h" - -/* This is a set of defines to configure the SDL features */ - -typedef signed char int8_t; -typedef unsigned char uint8_t; -typedef signed short int16_t; -typedef unsigned short uint16_t; -typedef signed int int32_t; -typedef unsigned int uint32_t; -typedef signed long long int64_t; -typedef unsigned long long uint64_t; -typedef unsigned long uintptr_t; -#define SDL_HAS_64BIT_TYPE 1 - -/* Useful headers */ -#define HAVE_SYS_TYPES_H 1 -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STRING_H 1 -#define HAVE_CTYPE_H 1 - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_GETENV 1 -#define HAVE_PUTENV 1 -#define HAVE_QSORT 1 -#define HAVE_ABS 1 -#define HAVE_BCOPY 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 -#define HAVE_STRLEN 1 -#define HAVE_STRDUP 1 -#define HAVE_INDEX 1 -#define HAVE_RINDEX 1 -#define HAVE_STRCHR 1 -#define HAVE_STRRCHR 1 -#define HAVE_STRSTR 1 -#define HAVE_STRTOL 1 -#define HAVE_STRTOD 1 -#define HAVE_ATOI 1 -#define HAVE_ATOF 1 -#define HAVE_STRCMP 1 -#define HAVE_STRNCMP 1 -#define HAVE_STRICMP 1 -#define HAVE_STRCASECMP 1 -#define HAVE_SSCANF 1 -#define HAVE_SNPRINTF 1 -#define HAVE_VSNPRINTF 1 - -/* Enable various audio drivers */ -#define SDL_AUDIO_DRIVER_DC 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#define SDL_CDROM_DC 1 - -/* Enable various input drivers */ -#define SDL_JOYSTICK_DC 1 - -/* Enable various shared object loading systems */ -#define SDL_LOADSO_DUMMY 1 - -/* Enable various threading systems */ -#define SDL_THREAD_DC 1 - -/* Enable various timer systems */ -#define SDL_TIMER_DC 1 - -/* Enable various video drivers */ -#define SDL_VIDEO_DRIVER_DC 1 -#define SDL_VIDEO_DRIVER_DUMMY 1 - -#endif /* _SDL_config_dreamcast_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_macos.h b/distrib/sdl-1.2.12/include/SDL_config_macos.h deleted file mode 100644 index c4a1c59..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_macos.h +++ /dev/null @@ -1,112 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_macos_h -#define _SDL_config_macos_h - -#include "SDL_platform.h" - -/* This is a set of defines to configure the SDL features */ - -#include - -typedef SInt8 int8_t; -typedef UInt8 uint8_t; -typedef SInt16 int16_t; -typedef UInt16 uint16_t; -typedef SInt32 int32_t; -typedef UInt32 uint32_t; -typedef SInt64 int64_t; -typedef UInt64 uint64_t; -typedef unsigned long uintptr_t; - -#define SDL_HAS_64BIT_TYPE 1 - -/* Useful headers */ -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STRING_H 1 -#define HAVE_CTYPE_H 1 -#define HAVE_MATH_H 1 -#define HAVE_SIGNAL_H 1 - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_ABS 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 -#define HAVE_STRLEN 1 -#define HAVE_STRCHR 1 -#define HAVE_STRRCHR 1 -#define HAVE_STRSTR 1 -#define HAVE_ITOA 1 -#define HAVE_STRTOL 1 -#define HAVE_STRTOD 1 -#define HAVE_ATOI 1 -#define HAVE_ATOF 1 -#define HAVE_STRCMP 1 -#define HAVE_STRNCMP 1 -#define HAVE_SSCANF 1 - -/* Enable various audio drivers */ -#define SDL_AUDIO_DRIVER_SNDMGR 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#if TARGET_API_MAC_CARBON -#define SDL_CDROM_DUMMY 1 -#else -#define SDL_CDROM_MACOS 1 -#endif - -/* Enable various input drivers */ -#if TARGET_API_MAC_CARBON -#define SDL_JOYSTICK_DUMMY 1 -#else -#define SDL_JOYSTICK_MACOS 1 -#endif - -/* Enable various shared object loading systems */ -#define SDL_LOADSO_MACOS 1 - -/* Enable various threading systems */ -#define SDL_THREADS_DISABLED 1 - -/* Enable various timer systems */ -#define SDL_TIMER_MACOS 1 - -/* Enable various video drivers */ -#define SDL_VIDEO_DRIVER_DUMMY 1 -#define SDL_VIDEO_DRIVER_DRAWSPROCKET 1 -#define SDL_VIDEO_DRIVER_TOOLBOX 1 - -/* Enable OpenGL support */ -#define SDL_VIDEO_OPENGL 1 - -#endif /* _SDL_config_macos_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_macosx.h b/distrib/sdl-1.2.12/include/SDL_config_macosx.h deleted file mode 100644 index 481c22e..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_macosx.h +++ /dev/null @@ -1,135 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_macosx_h -#define _SDL_config_macosx_h - -#include "SDL_platform.h" - -/* This gets us MAC_OS_X_VERSION_MIN_REQUIRED... */ -#include - -/* This is a set of defines to configure the SDL features */ - -#define SDL_HAS_64BIT_TYPE 1 - -/* Useful headers */ -/* If we specified an SDK or have a post-PowerPC chip, then alloca.h exists. */ -#if ( (MAC_OS_X_VERSION_MIN_REQUIRED >= 1030) || (!defined(__POWERPC__)) ) -#define HAVE_ALLOCA_H 1 -#endif -#define HAVE_SYS_TYPES_H 1 -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STRING_H 1 -#define HAVE_INTTYPES_H 1 -#define HAVE_STDINT_H 1 -#define HAVE_CTYPE_H 1 -#define HAVE_MATH_H 1 -#define HAVE_SIGNAL_H 1 - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_GETENV 1 -#define HAVE_PUTENV 1 -#define HAVE_UNSETENV 1 -#define HAVE_QSORT 1 -#define HAVE_ABS 1 -#define HAVE_BCOPY 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 -#define HAVE_STRLEN 1 -#define HAVE_STRLCPY 1 -#define HAVE_STRLCAT 1 -#define HAVE_STRDUP 1 -#define HAVE_STRCHR 1 -#define HAVE_STRRCHR 1 -#define HAVE_STRSTR 1 -#define HAVE_STRTOL 1 -#define HAVE_STRTOUL 1 -#define HAVE_STRTOLL 1 -#define HAVE_STRTOULL 1 -#define HAVE_STRTOD 1 -#define HAVE_ATOI 1 -#define HAVE_ATOF 1 -#define HAVE_STRCMP 1 -#define HAVE_STRNCMP 1 -#define HAVE_STRCASECMP 1 -#define HAVE_STRNCASECMP 1 -#define HAVE_SSCANF 1 -#define HAVE_SNPRINTF 1 -#define HAVE_VSNPRINTF 1 -#define HAVE_SIGACTION 1 -#define HAVE_SETJMP 1 -#define HAVE_NANOSLEEP 1 - -/* Enable various audio drivers */ -#define SDL_AUDIO_DRIVER_COREAUDIO 1 -#define SDL_AUDIO_DRIVER_SNDMGR 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#define SDL_CDROM_MACOSX 1 - -/* Enable various input drivers */ -#define SDL_JOYSTICK_IOKIT 1 - -/* Enable various shared object loading systems */ -#ifdef __ppc__ -/* For Mac OS X 10.2 compatibility */ -#define SDL_LOADSO_DLCOMPAT 1 -#else -#define SDL_LOADSO_DLOPEN 1 -#endif - -/* Enable various threading systems */ -#define SDL_THREAD_PTHREAD 1 -#define SDL_THREAD_PTHREAD_RECURSIVE_MUTEX 1 - -/* Enable various timer systems */ -#define SDL_TIMER_UNIX 1 - -/* Enable various video drivers */ -#define SDL_VIDEO_DRIVER_DUMMY 1 -#if ((defined TARGET_API_MAC_CARBON) && (TARGET_API_MAC_CARBON)) -#define SDL_VIDEO_DRIVER_TOOLBOX 1 -#else -#define SDL_VIDEO_DRIVER_QUARTZ 1 -#endif - -/* Enable OpenGL support */ -#define SDL_VIDEO_OPENGL 1 - -/* Enable assembly routines */ -#define SDL_ASSEMBLY_ROUTINES 1 -#ifdef __ppc__ -#define SDL_ALTIVEC_BLITTERS 1 -#endif - -#endif /* _SDL_config_macosx_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_minimal.h b/distrib/sdl-1.2.12/include/SDL_config_minimal.h deleted file mode 100644 index 78b6148..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_minimal.h +++ /dev/null @@ -1,62 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_minimal_h -#define _SDL_config_minimal_h - -#include "SDL_platform.h" - -/* This is the minimal configuration that can be used to build SDL */ - -#include - -typedef signed char int8_t; -typedef unsigned char uint8_t; -typedef signed short int16_t; -typedef unsigned short uint16_t; -typedef signed int int32_t; -typedef unsigned int uint32_t; -typedef unsigned int size_t; -typedef unsigned long uintptr_t; - -/* Enable the dummy audio driver (src/audio/dummy/\*.c) */ -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable the stub cdrom driver (src/cdrom/dummy/\*.c) */ -#define SDL_CDROM_DISABLED 1 - -/* Enable the stub joystick driver (src/joystick/dummy/\*.c) */ -#define SDL_JOYSTICK_DISABLED 1 - -/* Enable the stub shared object loader (src/loadso/dummy/\*.c) */ -#define SDL_LOADSO_DISABLED 1 - -/* Enable the stub thread support (src/thread/generic/\*.c) */ -#define SDL_THREADS_DISABLED 1 - -/* Enable the stub timer support (src/timer/dummy/\*.c) */ -#define SDL_TIMERS_DISABLED 1 - -/* Enable the dummy video driver (src/video/dummy/\*.c) */ -#define SDL_VIDEO_DRIVER_DUMMY 1 - -#endif /* _SDL_config_minimal_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_os2.h b/distrib/sdl-1.2.12/include/SDL_config_os2.h deleted file mode 100644 index 8cdea9f..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_os2.h +++ /dev/null @@ -1,141 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_os2_h -#define _SDL_config_os2_h - -#include "SDL_platform.h" - -/* This is a set of defines to configure the SDL features */ - -typedef signed char int8_t; -typedef unsigned char uint8_t; -typedef signed short int16_t; -typedef unsigned short uint16_t; -typedef signed int int32_t; -typedef unsigned int uint32_t; -typedef unsigned int size_t; -typedef unsigned long uintptr_t; -typedef signed long long int64_t; -typedef unsigned long long uint64_t; - -#define SDL_HAS_64BIT_TYPE 1 - -/* Use Watcom's LIBC */ -#define HAVE_LIBC 1 - -/* Useful headers */ -#define HAVE_SYS_TYPES_H 1 -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STDLIB_H 1 -#define HAVE_STDARG_H 1 -#define HAVE_MALLOC_H 1 -#define HAVE_MEMORY_H 1 -#define HAVE_STRING_H 1 -#define HAVE_STRINGS_H 1 -#define HAVE_INTTYPES_H 1 -#define HAVE_STDINT_H 1 -#define HAVE_CTYPE_H 1 -#define HAVE_MATH_H 1 -#define HAVE_SIGNAL_H 1 - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_GETENV 1 -#define HAVE_PUTENV 1 -#define HAVE_UNSETENV 1 -#define HAVE_QSORT 1 -#define HAVE_ABS 1 -#define HAVE_BCOPY 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 -#define HAVE_STRLEN 1 -#define HAVE_STRLCPY 1 -#define HAVE_STRLCAT 1 -#define HAVE_STRDUP 1 -#define HAVE__STRREV 1 -#define HAVE__STRUPR 1 -#define HAVE__STRLWR 1 -#define HAVE_INDEX 1 -#define HAVE_RINDEX 1 -#define HAVE_STRCHR 1 -#define HAVE_STRRCHR 1 -#define HAVE_STRSTR 1 -#define HAVE_ITOA 1 -#define HAVE__LTOA 1 -#define HAVE__UITOA 1 -#define HAVE__ULTOA 1 -#define HAVE_STRTOL 1 -#define HAVE__I64TOA 1 -#define HAVE__UI64TOA 1 -#define HAVE_STRTOLL 1 -#define HAVE_STRTOD 1 -#define HAVE_ATOI 1 -#define HAVE_ATOF 1 -#define HAVE_STRCMP 1 -#define HAVE_STRNCMP 1 -#define HAVE_STRICMP 1 -#define HAVE_STRCASECMP 1 -#define HAVE_SSCANF 1 -#define HAVE_SNPRINTF 1 -#define HAVE_VSNPRINTF 1 -#define HAVE_SETJMP 1 -#define HAVE_CLOCK_GETTIME 1 - -/* Enable various audio drivers */ -#define SDL_AUDIO_DRIVER_DART 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#define SDL_CDROM_OS2 1 - -/* Enable various input drivers */ -#define SDL_JOYSTICK_OS2 1 - -/* Enable various shared object loading systems */ -#define SDL_LOADSO_OS2 1 - -/* Enable various threading systems */ -#define SDL_THREAD_OS2 1 - -/* Enable various timer systems */ -#define SDL_TIMER_OS2 1 - -/* Enable various video drivers */ -#define SDL_VIDEO_DRIVER_DUMMY 1 -#define SDL_VIDEO_DRIVER_OS2FS 1 - -/* Enable OpenGL support */ -/* Nothing here yet for OS/2... :( */ - -/* Enable assembly routines where available */ -#define SDL_ASSEMBLY_ROUTINES 1 - -#endif /* _SDL_config_os2_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_config_win32.h b/distrib/sdl-1.2.12/include/SDL_config_win32.h deleted file mode 100644 index cfb44d2..0000000 --- a/distrib/sdl-1.2.12/include/SDL_config_win32.h +++ /dev/null @@ -1,180 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_config_win32_h -#define _SDL_config_win32_h - -#include "SDL_platform.h" - -/* This is a set of defines to configure the SDL features */ - -#if defined(__GNUC__) || defined(__DMC__) -#define HAVE_STDINT_H 1 -#elif defined(_MSC_VER) -typedef signed __int8 int8_t; -typedef unsigned __int8 uint8_t; -typedef signed __int16 int16_t; -typedef unsigned __int16 uint16_t; -typedef signed __int32 int32_t; -typedef unsigned __int32 uint32_t; -typedef signed __int64 int64_t; -typedef unsigned __int64 uint64_t; -#ifndef _UINTPTR_T_DEFINED -#ifdef _WIN64 -typedef unsigned __int64 uintptr_t; -#else -typedef unsigned int uintptr_t; -#endif -#define _UINTPTR_T_DEFINED -#endif -/* Older Visual C++ headers don't have the Win64-compatible typedefs... */ -#if ((_MSC_VER <= 1200) && (!defined(DWORD_PTR))) -#define DWORD_PTR DWORD -#endif -#if ((_MSC_VER <= 1200) && (!defined(LONG_PTR))) -#define LONG_PTR LONG -#endif -#else /* !__GNUC__ && !_MSC_VER */ -typedef signed char int8_t; -typedef unsigned char uint8_t; -typedef signed short int16_t; -typedef unsigned short uint16_t; -typedef signed int int32_t; -typedef unsigned int uint32_t; -typedef signed long long int64_t; -typedef unsigned long long uint64_t; -#ifndef _SIZE_T_DEFINED_ -#define _SIZE_T_DEFINED_ -typedef unsigned int size_t; -#endif -typedef unsigned int uintptr_t; -#endif /* __GNUC__ || _MSC_VER */ -#define SDL_HAS_64BIT_TYPE 1 - -/* Enabled for SDL 1.2 (binary compatibility) */ -#define HAVE_LIBC 1 -#ifdef HAVE_LIBC -/* Useful headers */ -#define HAVE_STDIO_H 1 -#define STDC_HEADERS 1 -#define HAVE_STRING_H 1 -#define HAVE_CTYPE_H 1 -#define HAVE_MATH_H 1 -#ifndef _WIN32_WCE -#define HAVE_SIGNAL_H 1 -#endif - -/* C library functions */ -#define HAVE_MALLOC 1 -#define HAVE_CALLOC 1 -#define HAVE_REALLOC 1 -#define HAVE_FREE 1 -#define HAVE_ALLOCA 1 -#define HAVE_QSORT 1 -#define HAVE_ABS 1 -#define HAVE_MEMSET 1 -#define HAVE_MEMCPY 1 -#define HAVE_MEMMOVE 1 -#define HAVE_MEMCMP 1 -#define HAVE_STRLEN 1 -#define HAVE__STRREV 1 -#define HAVE__STRUPR 1 -#define HAVE__STRLWR 1 -#define HAVE_STRCHR 1 -#define HAVE_STRRCHR 1 -#define HAVE_STRSTR 1 -#define HAVE_ITOA 1 -#define HAVE__LTOA 1 -#define HAVE__ULTOA 1 -#define HAVE_STRTOL 1 -#define HAVE_STRTOUL 1 -#define HAVE_STRTOLL 1 -#define HAVE_STRTOD 1 -#define HAVE_ATOI 1 -#define HAVE_ATOF 1 -#define HAVE_STRCMP 1 -#define HAVE_STRNCMP 1 -#define HAVE__STRICMP 1 -#define HAVE__STRNICMP 1 -#define HAVE_SSCANF 1 -#else -#define HAVE_STDARG_H 1 -#define HAVE_STDDEF_H 1 -#endif - -/* Enable various audio drivers */ -#ifndef _WIN32_WCE -#define SDL_AUDIO_DRIVER_DSOUND 1 -#endif -#define SDL_AUDIO_DRIVER_WAVEOUT 1 -#define SDL_AUDIO_DRIVER_DISK 1 -#define SDL_AUDIO_DRIVER_DUMMY 1 - -/* Enable various cdrom drivers */ -#ifdef _WIN32_WCE -#define SDL_CDROM_DISABLED 1 -#else -#define SDL_CDROM_WIN32 1 -#endif - -/* Enable various input drivers */ -#ifdef _WIN32_WCE -#define SDL_JOYSTICK_DISABLED 1 -#else -#define SDL_JOYSTICK_WINMM 1 -#endif - -/* Enable various shared object loading systems */ -#define SDL_LOADSO_WIN32 1 - -/* Enable various threading systems */ -#define SDL_THREAD_WIN32 1 - -/* Enable various timer systems */ -#ifdef _WIN32_WCE -#define SDL_TIMER_WINCE 1 -#else -#define SDL_TIMER_WIN32 1 -#endif - -/* Enable various video drivers */ -#ifdef _WIN32_WCE -#define SDL_VIDEO_DRIVER_GAPI 1 -#endif -#ifndef _WIN32_WCE -#define SDL_VIDEO_DRIVER_DDRAW 1 -#endif -#define SDL_VIDEO_DRIVER_DUMMY 1 -#define SDL_VIDEO_DRIVER_WINDIB 1 - -/* Enable OpenGL support */ -#ifndef _WIN32_WCE -#define SDL_VIDEO_OPENGL 1 -#define SDL_VIDEO_OPENGL_WGL 1 -#endif - -/* Enable assembly routines (Win64 doesn't have inline asm) */ -#ifndef _WIN64 -#define SDL_ASSEMBLY_ROUTINES 1 -#endif - -#endif /* _SDL_config_win32_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_copying.h b/distrib/sdl-1.2.12/include/SDL_copying.h deleted file mode 100644 index 39e122d..0000000 --- a/distrib/sdl-1.2.12/include/SDL_copying.h +++ /dev/null @@ -1,22 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - diff --git a/distrib/sdl-1.2.12/include/SDL_cpuinfo.h b/distrib/sdl-1.2.12/include/SDL_cpuinfo.h deleted file mode 100644 index 72acbdd..0000000 --- a/distrib/sdl-1.2.12/include/SDL_cpuinfo.h +++ /dev/null @@ -1,75 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* CPU feature detection for SDL */ - -#ifndef _SDL_cpuinfo_h -#define _SDL_cpuinfo_h - -#include "SDL_stdinc.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* This function returns true if the CPU has the RDTSC instruction - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasRDTSC(void); - -/* This function returns true if the CPU has MMX features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasMMX(void); - -/* This function returns true if the CPU has MMX Ext. features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasMMXExt(void); - -/* This function returns true if the CPU has 3DNow features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_Has3DNow(void); - -/* This function returns true if the CPU has 3DNow! Ext. features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_Has3DNowExt(void); - -/* This function returns true if the CPU has SSE features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasSSE(void); - -/* This function returns true if the CPU has SSE2 features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasSSE2(void); - -/* This function returns true if the CPU has AltiVec features - */ -extern DECLSPEC SDL_bool SDLCALL SDL_HasAltiVec(void); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_cpuinfo_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_endian.h b/distrib/sdl-1.2.12/include/SDL_endian.h deleted file mode 100644 index 8f8db4c..0000000 --- a/distrib/sdl-1.2.12/include/SDL_endian.h +++ /dev/null @@ -1,194 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Functions for reading and writing endian-specific values */ - -#ifndef _SDL_endian_h -#define _SDL_endian_h - -#include "SDL_stdinc.h" - -/* The two types of endianness */ -#define SDL_LIL_ENDIAN 1234 -#define SDL_BIG_ENDIAN 4321 - -#ifndef SDL_BYTEORDER /* Not defined in SDL_config.h? */ -#if defined(__hppa__) || \ - defined(__m68k__) || defined(mc68000) || defined(_M_M68K) || \ - (defined(__MIPS__) && defined(__MISPEB__)) || \ - defined(__ppc__) || defined(__POWERPC__) || defined(_M_PPC) || \ - defined(__sparc__) -#define SDL_BYTEORDER SDL_BIG_ENDIAN -#else -#define SDL_BYTEORDER SDL_LIL_ENDIAN -#endif -#endif /* !SDL_BYTEORDER */ - - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Use inline functions for compilers that support them, and static - functions for those that do not. Because these functions become - static for compilers that do not support inline functions, this - header should only be included in files that actually use them. -*/ -#if defined(__GNUC__) && defined(__i386__) && \ - !(__GNUC__ == 2 && __GNUC_MINOR__ <= 95 /* broken gcc version */) -static __inline__ Uint16 SDL_Swap16(Uint16 x) -{ - __asm__("xchgb %b0,%h0" : "=q" (x) : "0" (x)); - return x; -} -#elif defined(__GNUC__) && defined(__x86_64__) -static __inline__ Uint16 SDL_Swap16(Uint16 x) -{ - __asm__("xchgb %b0,%h0" : "=Q" (x) : "0" (x)); - return x; -} -#elif defined(__GNUC__) && (defined(__powerpc__) || defined(__ppc__)) -static __inline__ Uint16 SDL_Swap16(Uint16 x) -{ - Uint16 result; - - __asm__("rlwimi %0,%2,8,16,23" : "=&r" (result) : "0" (x >> 8), "r" (x)); - return result; -} -#elif defined(__GNUC__) && (defined(__M68000__) || defined(__M68020__)) -static __inline__ Uint16 SDL_Swap16(Uint16 x) -{ - __asm__("rorw #8,%0" : "=d" (x) : "0" (x) : "cc"); - return x; -} -#else -static __inline__ Uint16 SDL_Swap16(Uint16 x) { - return((x<<8)|(x>>8)); -} -#endif - -#if defined(__GNUC__) && defined(__i386__) && \ - !(__GNUC__ == 2 && __GNUC_MINOR__ <= 95 /* broken gcc version */) -static __inline__ Uint32 SDL_Swap32(Uint32 x) -{ - __asm__("bswap %0" : "=r" (x) : "0" (x)); - return x; -} -#elif defined(__GNUC__) && defined(__x86_64__) -static __inline__ Uint32 SDL_Swap32(Uint32 x) -{ - __asm__("bswapl %0" : "=r" (x) : "0" (x)); - return x; -} -#elif defined(__GNUC__) && (defined(__powerpc__) || defined(__ppc__)) -static __inline__ Uint32 SDL_Swap32(Uint32 x) -{ - Uint32 result; - - __asm__("rlwimi %0,%2,24,16,23" : "=&r" (result) : "0" (x>>24), "r" (x)); - __asm__("rlwimi %0,%2,8,8,15" : "=&r" (result) : "0" (result), "r" (x)); - __asm__("rlwimi %0,%2,24,0,7" : "=&r" (result) : "0" (result), "r" (x)); - return result; -} -#elif defined(__GNUC__) && (defined(__M68000__) || defined(__M68020__)) -static __inline__ Uint32 SDL_Swap32(Uint32 x) -{ - __asm__("rorw #8,%0\n\tswap %0\n\trorw #8,%0" : "=d" (x) : "0" (x) : "cc"); - return x; -} -#else -static __inline__ Uint32 SDL_Swap32(Uint32 x) { - return((x<<24)|((x<<8)&0x00FF0000)|((x>>8)&0x0000FF00)|(x>>24)); -} -#endif - -#ifdef SDL_HAS_64BIT_TYPE -#if defined(__GNUC__) && defined(__i386__) && \ - !(__GNUC__ == 2 && __GNUC_MINOR__ <= 95 /* broken gcc version */) -static __inline__ Uint64 SDL_Swap64(Uint64 x) -{ - union { - struct { Uint32 a,b; } s; - Uint64 u; - } v; - v.u = x; - __asm__("bswapl %0 ; bswapl %1 ; xchgl %0,%1" - : "=r" (v.s.a), "=r" (v.s.b) - : "0" (v.s.a), "1" (v.s.b)); - return v.u; -} -#elif defined(__GNUC__) && defined(__x86_64__) -static __inline__ Uint64 SDL_Swap64(Uint64 x) -{ - __asm__("bswapq %0" : "=r" (x) : "0" (x)); - return x; -} -#else -static __inline__ Uint64 SDL_Swap64(Uint64 x) -{ - Uint32 hi, lo; - - /* Separate into high and low 32-bit values and swap them */ - lo = (Uint32)(x&0xFFFFFFFF); - x >>= 32; - hi = (Uint32)(x&0xFFFFFFFF); - x = SDL_Swap32(lo); - x <<= 32; - x |= SDL_Swap32(hi); - return(x); -} -#endif -#else -/* This is mainly to keep compilers from complaining in SDL code. - If there is no real 64-bit datatype, then compilers will complain about - the fake 64-bit datatype that SDL provides when it compiles user code. -*/ -#define SDL_Swap64(X) (X) -#endif /* SDL_HAS_64BIT_TYPE */ - - -/* Byteswap item from the specified endianness to the native endianness */ -#if SDL_BYTEORDER == SDL_LIL_ENDIAN -#define SDL_SwapLE16(X) (X) -#define SDL_SwapLE32(X) (X) -#define SDL_SwapLE64(X) (X) -#define SDL_SwapBE16(X) SDL_Swap16(X) -#define SDL_SwapBE32(X) SDL_Swap32(X) -#define SDL_SwapBE64(X) SDL_Swap64(X) -#else -#define SDL_SwapLE16(X) SDL_Swap16(X) -#define SDL_SwapLE32(X) SDL_Swap32(X) -#define SDL_SwapLE64(X) SDL_Swap64(X) -#define SDL_SwapBE16(X) (X) -#define SDL_SwapBE32(X) (X) -#define SDL_SwapBE64(X) (X) -#endif - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_endian_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_error.h b/distrib/sdl-1.2.12/include/SDL_error.h deleted file mode 100644 index 26d6bfa..0000000 --- a/distrib/sdl-1.2.12/include/SDL_error.h +++ /dev/null @@ -1,61 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Simple error message routines for SDL */ - -#ifndef _SDL_error_h -#define _SDL_error_h - -#include "SDL_stdinc.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Public functions */ -extern DECLSPEC void SDLCALL SDL_SetError(const char *fmt, ...); -extern DECLSPEC char * SDLCALL SDL_GetError(void); -extern DECLSPEC void SDLCALL SDL_ClearError(void); - -/* Private error message function - used internally */ -#define SDL_OutOfMemory() SDL_Error(SDL_ENOMEM) -#define SDL_Unsupported() SDL_Error(SDL_UNSUPPORTED) -typedef enum { - SDL_ENOMEM, - SDL_EFREAD, - SDL_EFWRITE, - SDL_EFSEEK, - SDL_UNSUPPORTED, - SDL_LASTERROR -} SDL_errorcode; -extern DECLSPEC void SDLCALL SDL_Error(SDL_errorcode code); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_error_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_events.h b/distrib/sdl-1.2.12/include/SDL_events.h deleted file mode 100644 index 9fe918c..0000000 --- a/distrib/sdl-1.2.12/include/SDL_events.h +++ /dev/null @@ -1,337 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL event handling */ - -#ifndef _SDL_events_h -#define _SDL_events_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_active.h" -#include "SDL_keyboard.h" -#include "SDL_mouse.h" -#include "SDL_joystick.h" -#include "SDL_quit.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* General keyboard/mouse state definitions */ -#define SDL_RELEASED 0 -#define SDL_PRESSED 1 - -/* Event enumerations */ -typedef enum { - SDL_NOEVENT = 0, /* Unused (do not remove) */ - SDL_ACTIVEEVENT, /* Application loses/gains visibility */ - SDL_KEYDOWN, /* Keys pressed */ - SDL_KEYUP, /* Keys released */ - SDL_MOUSEMOTION, /* Mouse moved */ - SDL_MOUSEBUTTONDOWN, /* Mouse button pressed */ - SDL_MOUSEBUTTONUP, /* Mouse button released */ - SDL_JOYAXISMOTION, /* Joystick axis motion */ - SDL_JOYBALLMOTION, /* Joystick trackball motion */ - SDL_JOYHATMOTION, /* Joystick hat position change */ - SDL_JOYBUTTONDOWN, /* Joystick button pressed */ - SDL_JOYBUTTONUP, /* Joystick button released */ - SDL_QUIT, /* User-requested quit */ - SDL_SYSWMEVENT, /* System specific event */ - SDL_EVENT_RESERVEDA, /* Reserved for future use.. */ - SDL_EVENT_RESERVEDB, /* Reserved for future use.. */ - SDL_VIDEORESIZE, /* User resized video mode */ - SDL_VIDEOEXPOSE, /* Screen needs to be redrawn */ - SDL_EVENT_RESERVED2, /* Reserved for future use.. */ - SDL_EVENT_RESERVED3, /* Reserved for future use.. */ - SDL_EVENT_RESERVED4, /* Reserved for future use.. */ - SDL_EVENT_RESERVED5, /* Reserved for future use.. */ - SDL_EVENT_RESERVED6, /* Reserved for future use.. */ - SDL_EVENT_RESERVED7, /* Reserved for future use.. */ - /* Events SDL_USEREVENT through SDL_MAXEVENTS-1 are for your use */ - SDL_USEREVENT = 24, - /* This last event is only for bounding internal arrays - It is the number of bits in the event mask datatype -- Uint32 - */ - SDL_NUMEVENTS = 32 -} SDL_EventType; - -/* Predefined event masks */ -#define SDL_EVENTMASK(X) (1<<(X)) -typedef enum { - SDL_ACTIVEEVENTMASK = SDL_EVENTMASK(SDL_ACTIVEEVENT), - SDL_KEYDOWNMASK = SDL_EVENTMASK(SDL_KEYDOWN), - SDL_KEYUPMASK = SDL_EVENTMASK(SDL_KEYUP), - SDL_KEYEVENTMASK = SDL_EVENTMASK(SDL_KEYDOWN)| - SDL_EVENTMASK(SDL_KEYUP), - SDL_MOUSEMOTIONMASK = SDL_EVENTMASK(SDL_MOUSEMOTION), - SDL_MOUSEBUTTONDOWNMASK = SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN), - SDL_MOUSEBUTTONUPMASK = SDL_EVENTMASK(SDL_MOUSEBUTTONUP), - SDL_MOUSEEVENTMASK = SDL_EVENTMASK(SDL_MOUSEMOTION)| - SDL_EVENTMASK(SDL_MOUSEBUTTONDOWN)| - SDL_EVENTMASK(SDL_MOUSEBUTTONUP), - SDL_JOYAXISMOTIONMASK = SDL_EVENTMASK(SDL_JOYAXISMOTION), - SDL_JOYBALLMOTIONMASK = SDL_EVENTMASK(SDL_JOYBALLMOTION), - SDL_JOYHATMOTIONMASK = SDL_EVENTMASK(SDL_JOYHATMOTION), - SDL_JOYBUTTONDOWNMASK = SDL_EVENTMASK(SDL_JOYBUTTONDOWN), - SDL_JOYBUTTONUPMASK = SDL_EVENTMASK(SDL_JOYBUTTONUP), - SDL_JOYEVENTMASK = SDL_EVENTMASK(SDL_JOYAXISMOTION)| - SDL_EVENTMASK(SDL_JOYBALLMOTION)| - SDL_EVENTMASK(SDL_JOYHATMOTION)| - SDL_EVENTMASK(SDL_JOYBUTTONDOWN)| - SDL_EVENTMASK(SDL_JOYBUTTONUP), - SDL_VIDEORESIZEMASK = SDL_EVENTMASK(SDL_VIDEORESIZE), - SDL_VIDEOEXPOSEMASK = SDL_EVENTMASK(SDL_VIDEOEXPOSE), - SDL_QUITMASK = SDL_EVENTMASK(SDL_QUIT), - SDL_SYSWMEVENTMASK = SDL_EVENTMASK(SDL_SYSWMEVENT) -} SDL_EventMask ; -#define SDL_ALLEVENTS 0xFFFFFFFF - -/* Application visibility event structure */ -typedef struct SDL_ActiveEvent { - Uint8 type; /* SDL_ACTIVEEVENT */ - Uint8 gain; /* Whether given states were gained or lost (1/0) */ - Uint8 state; /* A mask of the focus states */ -} SDL_ActiveEvent; - -/* Keyboard event structure */ -typedef struct SDL_KeyboardEvent { - Uint8 type; /* SDL_KEYDOWN or SDL_KEYUP */ - Uint8 which; /* The keyboard device index */ - Uint8 state; /* SDL_PRESSED or SDL_RELEASED */ - SDL_keysym keysym; -} SDL_KeyboardEvent; - -/* Mouse motion event structure */ -typedef struct SDL_MouseMotionEvent { - Uint8 type; /* SDL_MOUSEMOTION */ - Uint8 which; /* The mouse device index */ - Uint8 state; /* The current button state */ - Uint16 x, y; /* The X/Y coordinates of the mouse */ - Sint16 xrel; /* The relative motion in the X direction */ - Sint16 yrel; /* The relative motion in the Y direction */ -} SDL_MouseMotionEvent; - -/* Mouse button event structure */ -typedef struct SDL_MouseButtonEvent { - Uint8 type; /* SDL_MOUSEBUTTONDOWN or SDL_MOUSEBUTTONUP */ - Uint8 which; /* The mouse device index */ - Uint8 button; /* The mouse button index */ - Uint8 state; /* SDL_PRESSED or SDL_RELEASED */ - Uint16 x, y; /* The X/Y coordinates of the mouse at press time */ -} SDL_MouseButtonEvent; - -/* Joystick axis motion event structure */ -typedef struct SDL_JoyAxisEvent { - Uint8 type; /* SDL_JOYAXISMOTION */ - Uint8 which; /* The joystick device index */ - Uint8 axis; /* The joystick axis index */ - Sint16 value; /* The axis value (range: -32768 to 32767) */ -} SDL_JoyAxisEvent; - -/* Joystick trackball motion event structure */ -typedef struct SDL_JoyBallEvent { - Uint8 type; /* SDL_JOYBALLMOTION */ - Uint8 which; /* The joystick device index */ - Uint8 ball; /* The joystick trackball index */ - Sint16 xrel; /* The relative motion in the X direction */ - Sint16 yrel; /* The relative motion in the Y direction */ -} SDL_JoyBallEvent; - -/* Joystick hat position change event structure */ -typedef struct SDL_JoyHatEvent { - Uint8 type; /* SDL_JOYHATMOTION */ - Uint8 which; /* The joystick device index */ - Uint8 hat; /* The joystick hat index */ - Uint8 value; /* The hat position value: - SDL_HAT_LEFTUP SDL_HAT_UP SDL_HAT_RIGHTUP - SDL_HAT_LEFT SDL_HAT_CENTERED SDL_HAT_RIGHT - SDL_HAT_LEFTDOWN SDL_HAT_DOWN SDL_HAT_RIGHTDOWN - Note that zero means the POV is centered. - */ -} SDL_JoyHatEvent; - -/* Joystick button event structure */ -typedef struct SDL_JoyButtonEvent { - Uint8 type; /* SDL_JOYBUTTONDOWN or SDL_JOYBUTTONUP */ - Uint8 which; /* The joystick device index */ - Uint8 button; /* The joystick button index */ - Uint8 state; /* SDL_PRESSED or SDL_RELEASED */ -} SDL_JoyButtonEvent; - -/* The "window resized" event - When you get this event, you are responsible for setting a new video - mode with the new width and height. - */ -typedef struct SDL_ResizeEvent { - Uint8 type; /* SDL_VIDEORESIZE */ - int w; /* New width */ - int h; /* New height */ -} SDL_ResizeEvent; - -/* The "screen redraw" event */ -typedef struct SDL_ExposeEvent { - Uint8 type; /* SDL_VIDEOEXPOSE */ -} SDL_ExposeEvent; - -/* The "quit requested" event */ -typedef struct SDL_QuitEvent { - Uint8 type; /* SDL_QUIT */ -} SDL_QuitEvent; - -/* A user-defined event type */ -typedef struct SDL_UserEvent { - Uint8 type; /* SDL_USEREVENT through SDL_NUMEVENTS-1 */ - int code; /* User defined event code */ - void *data1; /* User defined data pointer */ - void *data2; /* User defined data pointer */ -} SDL_UserEvent; - -/* If you want to use this event, you should include SDL_syswm.h */ -struct SDL_SysWMmsg; -typedef struct SDL_SysWMmsg SDL_SysWMmsg; -typedef struct SDL_SysWMEvent { - Uint8 type; - SDL_SysWMmsg *msg; -} SDL_SysWMEvent; - -/* General event structure */ -typedef union SDL_Event { - Uint8 type; - SDL_ActiveEvent active; - SDL_KeyboardEvent key; - SDL_MouseMotionEvent motion; - SDL_MouseButtonEvent button; - SDL_JoyAxisEvent jaxis; - SDL_JoyBallEvent jball; - SDL_JoyHatEvent jhat; - SDL_JoyButtonEvent jbutton; - SDL_ResizeEvent resize; - SDL_ExposeEvent expose; - SDL_QuitEvent quit; - SDL_UserEvent user; - SDL_SysWMEvent syswm; -} SDL_Event; - - -/* Function prototypes */ - -/* Pumps the event loop, gathering events from the input devices. - This function updates the event queue and internal input device state. - This should only be run in the thread that sets the video mode. -*/ -extern DECLSPEC void SDLCALL SDL_PumpEvents(void); - -/* Checks the event queue for messages and optionally returns them. - If 'action' is SDL_ADDEVENT, up to 'numevents' events will be added to - the back of the event queue. - If 'action' is SDL_PEEKEVENT, up to 'numevents' events at the front - of the event queue, matching 'mask', will be returned and will not - be removed from the queue. - If 'action' is SDL_GETEVENT, up to 'numevents' events at the front - of the event queue, matching 'mask', will be returned and will be - removed from the queue. - This function returns the number of events actually stored, or -1 - if there was an error. This function is thread-safe. -*/ -typedef enum { - SDL_ADDEVENT, - SDL_PEEKEVENT, - SDL_GETEVENT -} SDL_eventaction; -/* */ -extern DECLSPEC int SDLCALL SDL_PeepEvents(SDL_Event *events, int numevents, - SDL_eventaction action, Uint32 mask); - -/* Polls for currently pending events, and returns 1 if there are any pending - events, or 0 if there are none available. If 'event' is not NULL, the next - event is removed from the queue and stored in that area. - */ -extern DECLSPEC int SDLCALL SDL_PollEvent(SDL_Event *event); - -/* Waits indefinitely for the next available event, returning 1, or 0 if there - was an error while waiting for events. If 'event' is not NULL, the next - event is removed from the queue and stored in that area. - */ -extern DECLSPEC int SDLCALL SDL_WaitEvent(SDL_Event *event); - -/* Add an event to the event queue. - This function returns 0 on success, or -1 if the event queue was full - or there was some other error. - */ -extern DECLSPEC int SDLCALL SDL_PushEvent(SDL_Event *event); - -/* - This function sets up a filter to process all events before they - change internal state and are posted to the internal event queue. - - The filter is protypted as: -*/ -typedef int (SDLCALL *SDL_EventFilter)(const SDL_Event *event); -/* - If the filter returns 1, then the event will be added to the internal queue. - If it returns 0, then the event will be dropped from the queue, but the - internal state will still be updated. This allows selective filtering of - dynamically arriving events. - - WARNING: Be very careful of what you do in the event filter function, as - it may run in a different thread! - - There is one caveat when dealing with the SDL_QUITEVENT event type. The - event filter is only called when the window manager desires to close the - application window. If the event filter returns 1, then the window will - be closed, otherwise the window will remain open if possible. - If the quit event is generated by an interrupt signal, it will bypass the - internal queue and be delivered to the application at the next event poll. -*/ -extern DECLSPEC void SDLCALL SDL_SetEventFilter(SDL_EventFilter filter); - -/* - Return the current event filter - can be used to "chain" filters. - If there is no event filter set, this function returns NULL. -*/ -extern DECLSPEC SDL_EventFilter SDLCALL SDL_GetEventFilter(void); - -/* - This function allows you to set the state of processing certain events. - If 'state' is set to SDL_IGNORE, that event will be automatically dropped - from the event queue and will not event be filtered. - If 'state' is set to SDL_ENABLE, that event will be processed normally. - If 'state' is set to SDL_QUERY, SDL_EventState() will return the - current processing state of the specified event. -*/ -#define SDL_QUERY -1 -#define SDL_IGNORE 0 -#define SDL_DISABLE 0 -#define SDL_ENABLE 1 -extern DECLSPEC Uint8 SDLCALL SDL_EventState(Uint8 type, int state); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_events_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_getenv.h b/distrib/sdl-1.2.12/include/SDL_getenv.h deleted file mode 100644 index 853b9ce..0000000 --- a/distrib/sdl-1.2.12/include/SDL_getenv.h +++ /dev/null @@ -1,24 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* DEPRECATED */ -#include "SDL_stdinc.h" diff --git a/distrib/sdl-1.2.12/include/SDL_joystick.h b/distrib/sdl-1.2.12/include/SDL_joystick.h deleted file mode 100644 index e4f72f1..0000000 --- a/distrib/sdl-1.2.12/include/SDL_joystick.h +++ /dev/null @@ -1,167 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL joystick event handling */ - -#ifndef _SDL_joystick_h -#define _SDL_joystick_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* In order to use these functions, SDL_Init() must have been called - with the SDL_INIT_JOYSTICK flag. This causes SDL to scan the system - for joysticks, and load appropriate drivers. -*/ - -/* The joystick structure used to identify an SDL joystick */ -struct _SDL_Joystick; -typedef struct _SDL_Joystick SDL_Joystick; - - -/* Function prototypes */ -/* - * Count the number of joysticks attached to the system - */ -extern DECLSPEC int SDLCALL SDL_NumJoysticks(void); - -/* - * Get the implementation dependent name of a joystick. - * This can be called before any joysticks are opened. - * If no name can be found, this function returns NULL. - */ -extern DECLSPEC const char * SDLCALL SDL_JoystickName(int device_index); - -/* - * Open a joystick for use - the index passed as an argument refers to - * the N'th joystick on the system. This index is the value which will - * identify this joystick in future joystick events. - * - * This function returns a joystick identifier, or NULL if an error occurred. - */ -extern DECLSPEC SDL_Joystick * SDLCALL SDL_JoystickOpen(int device_index); - -/* - * Returns 1 if the joystick has been opened, or 0 if it has not. - */ -extern DECLSPEC int SDLCALL SDL_JoystickOpened(int device_index); - -/* - * Get the device index of an opened joystick. - */ -extern DECLSPEC int SDLCALL SDL_JoystickIndex(SDL_Joystick *joystick); - -/* - * Get the number of general axis controls on a joystick - */ -extern DECLSPEC int SDLCALL SDL_JoystickNumAxes(SDL_Joystick *joystick); - -/* - * Get the number of trackballs on a joystick - * Joystick trackballs have only relative motion events associated - * with them and their state cannot be polled. - */ -extern DECLSPEC int SDLCALL SDL_JoystickNumBalls(SDL_Joystick *joystick); - -/* - * Get the number of POV hats on a joystick - */ -extern DECLSPEC int SDLCALL SDL_JoystickNumHats(SDL_Joystick *joystick); - -/* - * Get the number of buttons on a joystick - */ -extern DECLSPEC int SDLCALL SDL_JoystickNumButtons(SDL_Joystick *joystick); - -/* - * Update the current state of the open joysticks. - * This is called automatically by the event loop if any joystick - * events are enabled. - */ -extern DECLSPEC void SDLCALL SDL_JoystickUpdate(void); - -/* - * Enable/disable joystick event polling. - * If joystick events are disabled, you must call SDL_JoystickUpdate() - * yourself and check the state of the joystick when you want joystick - * information. - * The state can be one of SDL_QUERY, SDL_ENABLE or SDL_IGNORE. - */ -extern DECLSPEC int SDLCALL SDL_JoystickEventState(int state); - -/* - * Get the current state of an axis control on a joystick - * The state is a value ranging from -32768 to 32767. - * The axis indices start at index 0. - */ -extern DECLSPEC Sint16 SDLCALL SDL_JoystickGetAxis(SDL_Joystick *joystick, int axis); - -/* - * Get the current state of a POV hat on a joystick - * The return value is one of the following positions: - */ -#define SDL_HAT_CENTERED 0x00 -#define SDL_HAT_UP 0x01 -#define SDL_HAT_RIGHT 0x02 -#define SDL_HAT_DOWN 0x04 -#define SDL_HAT_LEFT 0x08 -#define SDL_HAT_RIGHTUP (SDL_HAT_RIGHT|SDL_HAT_UP) -#define SDL_HAT_RIGHTDOWN (SDL_HAT_RIGHT|SDL_HAT_DOWN) -#define SDL_HAT_LEFTUP (SDL_HAT_LEFT|SDL_HAT_UP) -#define SDL_HAT_LEFTDOWN (SDL_HAT_LEFT|SDL_HAT_DOWN) -/* - * The hat indices start at index 0. - */ -extern DECLSPEC Uint8 SDLCALL SDL_JoystickGetHat(SDL_Joystick *joystick, int hat); - -/* - * Get the ball axis change since the last poll - * This returns 0, or -1 if you passed it invalid parameters. - * The ball indices start at index 0. - */ -extern DECLSPEC int SDLCALL SDL_JoystickGetBall(SDL_Joystick *joystick, int ball, int *dx, int *dy); - -/* - * Get the current state of a button on a joystick - * The button indices start at index 0. - */ -extern DECLSPEC Uint8 SDLCALL SDL_JoystickGetButton(SDL_Joystick *joystick, int button); - -/* - * Close a joystick previously opened with SDL_JoystickOpen() - */ -extern DECLSPEC void SDLCALL SDL_JoystickClose(SDL_Joystick *joystick); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_joystick_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_keyboard.h b/distrib/sdl-1.2.12/include/SDL_keyboard.h deleted file mode 100644 index 1ad7dca..0000000 --- a/distrib/sdl-1.2.12/include/SDL_keyboard.h +++ /dev/null @@ -1,121 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL keyboard event handling */ - -#ifndef _SDL_keyboard_h -#define _SDL_keyboard_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_keysym.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Keysym structure - - The scancode is hardware dependent, and should not be used by general - applications. If no hardware scancode is available, it will be 0. - - - The 'unicode' translated character is only available when character - translation is enabled by the SDL_EnableUNICODE() API. If non-zero, - this is a UNICODE character corresponding to the keypress. If the - high 9 bits of the character are 0, then this maps to the equivalent - ASCII character: - char ch; - if ( (keysym.unicode & 0xFF80) == 0 ) { - ch = keysym.unicode & 0x7F; - } else { - An international character.. - } - */ -typedef struct SDL_keysym { - Uint8 scancode; /* hardware specific scancode */ - SDLKey sym; /* SDL virtual keysym */ - SDLMod mod; /* current key modifiers */ - Uint16 unicode; /* translated character */ -} SDL_keysym; - -/* This is the mask which refers to all hotkey bindings */ -#define SDL_ALL_HOTKEYS 0xFFFFFFFF - -/* Function prototypes */ -/* - * Enable/Disable UNICODE translation of keyboard input. - * This translation has some overhead, so translation defaults off. - * If 'enable' is 1, translation is enabled. - * If 'enable' is 0, translation is disabled. - * If 'enable' is -1, the translation state is not changed. - * It returns the previous state of keyboard translation. - */ -extern DECLSPEC int SDLCALL SDL_EnableUNICODE(int enable); - -/* - * Enable/Disable keyboard repeat. Keyboard repeat defaults to off. - * 'delay' is the initial delay in ms between the time when a key is - * pressed, and keyboard repeat begins. - * 'interval' is the time in ms between keyboard repeat events. - */ -#define SDL_DEFAULT_REPEAT_DELAY 500 -#define SDL_DEFAULT_REPEAT_INTERVAL 30 -/* - * If 'delay' is set to 0, keyboard repeat is disabled. - */ -extern DECLSPEC int SDLCALL SDL_EnableKeyRepeat(int delay, int interval); -extern DECLSPEC void SDLCALL SDL_GetKeyRepeat(int *delay, int *interval); - -/* - * Get a snapshot of the current state of the keyboard. - * Returns an array of keystates, indexed by the SDLK_* syms. - * Used: - * Uint8 *keystate = SDL_GetKeyState(NULL); - * if ( keystate[SDLK_RETURN] ) ... is pressed. - */ -extern DECLSPEC Uint8 * SDLCALL SDL_GetKeyState(int *numkeys); - -/* - * Get the current key modifier state - */ -extern DECLSPEC SDLMod SDLCALL SDL_GetModState(void); - -/* - * Set the current key modifier state - * This does not change the keyboard state, only the key modifier flags. - */ -extern DECLSPEC void SDLCALL SDL_SetModState(SDLMod modstate); - -/* - * Get the name of an SDL virtual keysym - */ -extern DECLSPEC char * SDLCALL SDL_GetKeyName(SDLKey key); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_keyboard_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_keysym.h b/distrib/sdl-1.2.12/include/SDL_keysym.h deleted file mode 100644 index ff44a03..0000000 --- a/distrib/sdl-1.2.12/include/SDL_keysym.h +++ /dev/null @@ -1,311 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_keysym_h -#define _SDL_keysym_h - -/* What we really want is a mapping of every raw key on the keyboard. - To support international keyboards, we use the range 0xA1 - 0xFF - as international virtual keycodes. We'll follow in the footsteps of X11... - The names of the keys - */ - -typedef enum { - /* The keyboard syms have been cleverly chosen to map to ASCII */ - SDLK_UNKNOWN = 0, - SDLK_FIRST = 0, - SDLK_BACKSPACE = 8, - SDLK_TAB = 9, - SDLK_CLEAR = 12, - SDLK_RETURN = 13, - SDLK_PAUSE = 19, - SDLK_ESCAPE = 27, - SDLK_SPACE = 32, - SDLK_EXCLAIM = 33, - SDLK_QUOTEDBL = 34, - SDLK_HASH = 35, - SDLK_DOLLAR = 36, - SDLK_AMPERSAND = 38, - SDLK_QUOTE = 39, - SDLK_LEFTPAREN = 40, - SDLK_RIGHTPAREN = 41, - SDLK_ASTERISK = 42, - SDLK_PLUS = 43, - SDLK_COMMA = 44, - SDLK_MINUS = 45, - SDLK_PERIOD = 46, - SDLK_SLASH = 47, - SDLK_0 = 48, - SDLK_1 = 49, - SDLK_2 = 50, - SDLK_3 = 51, - SDLK_4 = 52, - SDLK_5 = 53, - SDLK_6 = 54, - SDLK_7 = 55, - SDLK_8 = 56, - SDLK_9 = 57, - SDLK_COLON = 58, - SDLK_SEMICOLON = 59, - SDLK_LESS = 60, - SDLK_EQUALS = 61, - SDLK_GREATER = 62, - SDLK_QUESTION = 63, - SDLK_AT = 64, - /* - Skip uppercase letters - */ - SDLK_LEFTBRACKET = 91, - SDLK_BACKSLASH = 92, - SDLK_RIGHTBRACKET = 93, - SDLK_CARET = 94, - SDLK_UNDERSCORE = 95, - SDLK_BACKQUOTE = 96, - SDLK_a = 97, - SDLK_b = 98, - SDLK_c = 99, - SDLK_d = 100, - SDLK_e = 101, - SDLK_f = 102, - SDLK_g = 103, - SDLK_h = 104, - SDLK_i = 105, - SDLK_j = 106, - SDLK_k = 107, - SDLK_l = 108, - SDLK_m = 109, - SDLK_n = 110, - SDLK_o = 111, - SDLK_p = 112, - SDLK_q = 113, - SDLK_r = 114, - SDLK_s = 115, - SDLK_t = 116, - SDLK_u = 117, - SDLK_v = 118, - SDLK_w = 119, - SDLK_x = 120, - SDLK_y = 121, - SDLK_z = 122, - SDLK_DELETE = 127, - /* End of ASCII mapped keysyms */ - - /* International keyboard syms */ - SDLK_WORLD_0 = 160, /* 0xA0 */ - SDLK_WORLD_1 = 161, - SDLK_WORLD_2 = 162, - SDLK_WORLD_3 = 163, - SDLK_WORLD_4 = 164, - SDLK_WORLD_5 = 165, - SDLK_WORLD_6 = 166, - SDLK_WORLD_7 = 167, - SDLK_WORLD_8 = 168, - SDLK_WORLD_9 = 169, - SDLK_WORLD_10 = 170, - SDLK_WORLD_11 = 171, - SDLK_WORLD_12 = 172, - SDLK_WORLD_13 = 173, - SDLK_WORLD_14 = 174, - SDLK_WORLD_15 = 175, - SDLK_WORLD_16 = 176, - SDLK_WORLD_17 = 177, - SDLK_WORLD_18 = 178, - SDLK_WORLD_19 = 179, - SDLK_WORLD_20 = 180, - SDLK_WORLD_21 = 181, - SDLK_WORLD_22 = 182, - SDLK_WORLD_23 = 183, - SDLK_WORLD_24 = 184, - SDLK_WORLD_25 = 185, - SDLK_WORLD_26 = 186, - SDLK_WORLD_27 = 187, - SDLK_WORLD_28 = 188, - SDLK_WORLD_29 = 189, - SDLK_WORLD_30 = 190, - SDLK_WORLD_31 = 191, - SDLK_WORLD_32 = 192, - SDLK_WORLD_33 = 193, - SDLK_WORLD_34 = 194, - SDLK_WORLD_35 = 195, - SDLK_WORLD_36 = 196, - SDLK_WORLD_37 = 197, - SDLK_WORLD_38 = 198, - SDLK_WORLD_39 = 199, - SDLK_WORLD_40 = 200, - SDLK_WORLD_41 = 201, - SDLK_WORLD_42 = 202, - SDLK_WORLD_43 = 203, - SDLK_WORLD_44 = 204, - SDLK_WORLD_45 = 205, - SDLK_WORLD_46 = 206, - SDLK_WORLD_47 = 207, - SDLK_WORLD_48 = 208, - SDLK_WORLD_49 = 209, - SDLK_WORLD_50 = 210, - SDLK_WORLD_51 = 211, - SDLK_WORLD_52 = 212, - SDLK_WORLD_53 = 213, - SDLK_WORLD_54 = 214, - SDLK_WORLD_55 = 215, - SDLK_WORLD_56 = 216, - SDLK_WORLD_57 = 217, - SDLK_WORLD_58 = 218, - SDLK_WORLD_59 = 219, - SDLK_WORLD_60 = 220, - SDLK_WORLD_61 = 221, - SDLK_WORLD_62 = 222, - SDLK_WORLD_63 = 223, - SDLK_WORLD_64 = 224, - SDLK_WORLD_65 = 225, - SDLK_WORLD_66 = 226, - SDLK_WORLD_67 = 227, - SDLK_WORLD_68 = 228, - SDLK_WORLD_69 = 229, - SDLK_WORLD_70 = 230, - SDLK_WORLD_71 = 231, - SDLK_WORLD_72 = 232, - SDLK_WORLD_73 = 233, - SDLK_WORLD_74 = 234, - SDLK_WORLD_75 = 235, - SDLK_WORLD_76 = 236, - SDLK_WORLD_77 = 237, - SDLK_WORLD_78 = 238, - SDLK_WORLD_79 = 239, - SDLK_WORLD_80 = 240, - SDLK_WORLD_81 = 241, - SDLK_WORLD_82 = 242, - SDLK_WORLD_83 = 243, - SDLK_WORLD_84 = 244, - SDLK_WORLD_85 = 245, - SDLK_WORLD_86 = 246, - SDLK_WORLD_87 = 247, - SDLK_WORLD_88 = 248, - SDLK_WORLD_89 = 249, - SDLK_WORLD_90 = 250, - SDLK_WORLD_91 = 251, - SDLK_WORLD_92 = 252, - SDLK_WORLD_93 = 253, - SDLK_WORLD_94 = 254, - SDLK_WORLD_95 = 255, /* 0xFF */ - - /* Numeric keypad */ - SDLK_KP0 = 256, - SDLK_KP1 = 257, - SDLK_KP2 = 258, - SDLK_KP3 = 259, - SDLK_KP4 = 260, - SDLK_KP5 = 261, - SDLK_KP6 = 262, - SDLK_KP7 = 263, - SDLK_KP8 = 264, - SDLK_KP9 = 265, - SDLK_KP_PERIOD = 266, - SDLK_KP_DIVIDE = 267, - SDLK_KP_MULTIPLY = 268, - SDLK_KP_MINUS = 269, - SDLK_KP_PLUS = 270, - SDLK_KP_ENTER = 271, - SDLK_KP_EQUALS = 272, - - /* Arrows + Home/End pad */ - SDLK_UP = 273, - SDLK_DOWN = 274, - SDLK_RIGHT = 275, - SDLK_LEFT = 276, - SDLK_INSERT = 277, - SDLK_HOME = 278, - SDLK_END = 279, - SDLK_PAGEUP = 280, - SDLK_PAGEDOWN = 281, - - /* Function keys */ - SDLK_F1 = 282, - SDLK_F2 = 283, - SDLK_F3 = 284, - SDLK_F4 = 285, - SDLK_F5 = 286, - SDLK_F6 = 287, - SDLK_F7 = 288, - SDLK_F8 = 289, - SDLK_F9 = 290, - SDLK_F10 = 291, - SDLK_F11 = 292, - SDLK_F12 = 293, - SDLK_F13 = 294, - SDLK_F14 = 295, - SDLK_F15 = 296, - - /* Key state modifier keys */ - SDLK_NUMLOCK = 300, - SDLK_CAPSLOCK = 301, - SDLK_SCROLLOCK = 302, - SDLK_RSHIFT = 303, - SDLK_LSHIFT = 304, - SDLK_RCTRL = 305, - SDLK_LCTRL = 306, - SDLK_RALT = 307, - SDLK_LALT = 308, - SDLK_RMETA = 309, - SDLK_LMETA = 310, - SDLK_LSUPER = 311, /* Left "Windows" key */ - SDLK_RSUPER = 312, /* Right "Windows" key */ - SDLK_MODE = 313, /* "Alt Gr" key */ - SDLK_COMPOSE = 314, /* Multi-key compose key */ - - /* Miscellaneous function keys */ - SDLK_HELP = 315, - SDLK_PRINT = 316, - SDLK_SYSREQ = 317, - SDLK_BREAK = 318, - SDLK_MENU = 319, - SDLK_POWER = 320, /* Power Macintosh power key */ - SDLK_EURO = 321, /* Some european keyboards */ - SDLK_UNDO = 322, /* Atari keyboard has Undo */ - - /* Add any other keys here */ - - SDLK_LAST -} SDLKey; - -/* Enumeration of valid key mods (possibly OR'd together) */ -typedef enum { - KMOD_NONE = 0x0000, - KMOD_LSHIFT= 0x0001, - KMOD_RSHIFT= 0x0002, - KMOD_LCTRL = 0x0040, - KMOD_RCTRL = 0x0080, - KMOD_LALT = 0x0100, - KMOD_RALT = 0x0200, - KMOD_LMETA = 0x0400, - KMOD_RMETA = 0x0800, - KMOD_NUM = 0x1000, - KMOD_CAPS = 0x2000, - KMOD_MODE = 0x4000, - KMOD_RESERVED = 0x8000 -} SDLMod; - -#define KMOD_CTRL (KMOD_LCTRL|KMOD_RCTRL) -#define KMOD_SHIFT (KMOD_LSHIFT|KMOD_RSHIFT) -#define KMOD_ALT (KMOD_LALT|KMOD_RALT) -#define KMOD_META (KMOD_LMETA|KMOD_RMETA) - -#endif /* _SDL_keysym_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_loadso.h b/distrib/sdl-1.2.12/include/SDL_loadso.h deleted file mode 100644 index ce96449..0000000 --- a/distrib/sdl-1.2.12/include/SDL_loadso.h +++ /dev/null @@ -1,74 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* System dependent library loading routines */ - -/* Some things to keep in mind: - - These functions only work on C function names. Other languages may - have name mangling and intrinsic language support that varies from - compiler to compiler. - - Make sure you declare your function pointers with the same calling - convention as the actual library function. Your code will crash - mysteriously if you do not do this. - - Avoid namespace collisions. If you load a symbol from the library, - it is not defined whether or not it goes into the global symbol - namespace for the application. If it does and it conflicts with - symbols in your code or other shared libraries, you will not get - the results you expect. :) -*/ - - -#ifndef _SDL_loadso_h -#define _SDL_loadso_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* This function dynamically loads a shared object and returns a pointer - * to the object handle (or NULL if there was an error). - * The 'sofile' parameter is a system dependent name of the object file. - */ -extern DECLSPEC void * SDLCALL SDL_LoadObject(const char *sofile); - -/* Given an object handle, this function looks up the address of the - * named function in the shared object and returns it. This address - * is no longer valid after calling SDL_UnloadObject(). - */ -extern DECLSPEC void * SDLCALL SDL_LoadFunction(void *handle, const char *name); - -/* Unload a shared object from memory */ -extern DECLSPEC void SDLCALL SDL_UnloadObject(void *handle); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_loadso_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_main.h b/distrib/sdl-1.2.12/include/SDL_main.h deleted file mode 100644 index cf8b728..0000000 --- a/distrib/sdl-1.2.12/include/SDL_main.h +++ /dev/null @@ -1,98 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_main_h -#define _SDL_main_h - -#include "SDL_stdinc.h" - -/* Redefine main() on Win32 and MacOS so that it is called by winmain.c */ - -#if defined(__WIN32__) || \ - (defined(__MWERKS__) && !defined(__BEOS__)) || \ - defined(__MACOS__) || defined(__MACOSX__) || \ - defined(__SYMBIAN32__) || defined(QWS) - -#ifdef __cplusplus -#define C_LINKAGE "C" -#else -#define C_LINKAGE -#endif /* __cplusplus */ - -/* The application's main() function must be called with C linkage, - and should be declared like this: -#ifdef __cplusplus -extern "C" -#endif - int main(int argc, char *argv[]) - { - } - */ -#define main SDL_main - -/* The prototype for the application's main() function */ -extern C_LINKAGE int SDL_main(int argc, char *argv[]); - - -/* From the SDL library code -- needed for registering the app on Win32 */ -#ifdef __WIN32__ - -#include "begin_code.h" -#ifdef __cplusplus -extern "C" { -#endif - -/* This should be called from your WinMain() function, if any */ -extern DECLSPEC void SDLCALL SDL_SetModuleHandle(void *hInst); -/* This can also be called, but is no longer necessary */ -extern DECLSPEC int SDLCALL SDL_RegisterApp(char *name, Uint32 style, void *hInst); -/* This can also be called, but is no longer necessary (SDL_Quit calls it) */ -extern DECLSPEC void SDLCALL SDL_UnregisterApp(void); -#ifdef __cplusplus -} -#endif -#include "close_code.h" -#endif - -/* From the SDL library code -- needed for registering QuickDraw on MacOS */ -#if defined(__MACOS__) - -#include "begin_code.h" -#ifdef __cplusplus -extern "C" { -#endif - -/* Forward declaration so we don't need to include QuickDraw.h */ -struct QDGlobals; - -/* This should be called from your main() function, if any */ -extern DECLSPEC void SDLCALL SDL_InitQuickDraw(struct QDGlobals *the_qd); - -#ifdef __cplusplus -} -#endif -#include "close_code.h" -#endif - -#endif /* Need to redefine main()? */ - -#endif /* _SDL_main_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_mouse.h b/distrib/sdl-1.2.12/include/SDL_mouse.h deleted file mode 100644 index c2364d8..0000000 --- a/distrib/sdl-1.2.12/include/SDL_mouse.h +++ /dev/null @@ -1,136 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL mouse event handling */ - -#ifndef _SDL_mouse_h -#define _SDL_mouse_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_video.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -typedef struct WMcursor WMcursor; /* Implementation dependent */ -typedef struct SDL_Cursor { - SDL_Rect area; /* The area of the mouse cursor */ - Sint16 hot_x, hot_y; /* The "tip" of the cursor */ - Uint8 *data; /* B/W cursor data */ - Uint8 *mask; /* B/W cursor mask */ - Uint8 *save[2]; /* Place to save cursor area */ - WMcursor *wm_cursor; /* Window-manager cursor */ -} SDL_Cursor; - -/* Function prototypes */ -/* - * Retrieve the current state of the mouse. - * The current button state is returned as a button bitmask, which can - * be tested using the SDL_BUTTON(X) macros, and x and y are set to the - * current mouse cursor position. You can pass NULL for either x or y. - */ -extern DECLSPEC Uint8 SDLCALL SDL_GetMouseState(int *x, int *y); - -/* - * Retrieve the current state of the mouse. - * The current button state is returned as a button bitmask, which can - * be tested using the SDL_BUTTON(X) macros, and x and y are set to the - * mouse deltas since the last call to SDL_GetRelativeMouseState(). - */ -extern DECLSPEC Uint8 SDLCALL SDL_GetRelativeMouseState(int *x, int *y); - -/* - * Set the position of the mouse cursor (generates a mouse motion event) - */ -extern DECLSPEC void SDLCALL SDL_WarpMouse(Uint16 x, Uint16 y); - -/* - * Create a cursor using the specified data and mask (in MSB format). - * The cursor width must be a multiple of 8 bits. - * - * The cursor is created in black and white according to the following: - * data mask resulting pixel on screen - * 0 1 White - * 1 1 Black - * 0 0 Transparent - * 1 0 Inverted color if possible, black if not. - * - * Cursors created with this function must be freed with SDL_FreeCursor(). - */ -extern DECLSPEC SDL_Cursor * SDLCALL SDL_CreateCursor - (Uint8 *data, Uint8 *mask, int w, int h, int hot_x, int hot_y); - -/* - * Set the currently active cursor to the specified one. - * If the cursor is currently visible, the change will be immediately - * represented on the display. - */ -extern DECLSPEC void SDLCALL SDL_SetCursor(SDL_Cursor *cursor); - -/* - * Returns the currently active cursor. - */ -extern DECLSPEC SDL_Cursor * SDLCALL SDL_GetCursor(void); - -/* - * Deallocates a cursor created with SDL_CreateCursor(). - */ -extern DECLSPEC void SDLCALL SDL_FreeCursor(SDL_Cursor *cursor); - -/* - * Toggle whether or not the cursor is shown on the screen. - * The cursor start off displayed, but can be turned off. - * SDL_ShowCursor() returns 1 if the cursor was being displayed - * before the call, or 0 if it was not. You can query the current - * state by passing a 'toggle' value of -1. - */ -extern DECLSPEC int SDLCALL SDL_ShowCursor(int toggle); - -/* Used as a mask when testing buttons in buttonstate - Button 1: Left mouse button - Button 2: Middle mouse button - Button 3: Right mouse button - Button 4: Mouse wheel up (may also be a real button) - Button 5: Mouse wheel down (may also be a real button) - */ -#define SDL_BUTTON(X) (1 << ((X)-1)) -#define SDL_BUTTON_LEFT 1 -#define SDL_BUTTON_MIDDLE 2 -#define SDL_BUTTON_RIGHT 3 -#define SDL_BUTTON_WHEELUP 4 -#define SDL_BUTTON_WHEELDOWN 5 -#define SDL_BUTTON_LMASK SDL_BUTTON(SDL_BUTTON_LEFT) -#define SDL_BUTTON_MMASK SDL_BUTTON(SDL_BUTTON_MIDDLE) -#define SDL_BUTTON_RMASK SDL_BUTTON(SDL_BUTTON_RIGHT) - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_mouse_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_mutex.h b/distrib/sdl-1.2.12/include/SDL_mutex.h deleted file mode 100644 index 0016528..0000000 --- a/distrib/sdl-1.2.12/include/SDL_mutex.h +++ /dev/null @@ -1,162 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_mutex_h -#define _SDL_mutex_h - -/* Functions to provide thread synchronization primitives - - These are independent of the other SDL routines. -*/ - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Synchronization functions which can time out return this value - if they time out. -*/ -#define SDL_MUTEX_TIMEDOUT 1 - -/* This is the timeout value which corresponds to never time out */ -#define SDL_MUTEX_MAXWAIT (~(Uint32)0) - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* Mutex functions */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* The SDL mutex structure, defined in SDL_mutex.c */ -struct SDL_mutex; -typedef struct SDL_mutex SDL_mutex; - -/* Create a mutex, initialized unlocked */ -extern DECLSPEC SDL_mutex * SDLCALL SDL_CreateMutex(void); - -/* Lock the mutex (Returns 0, or -1 on error) */ -#define SDL_LockMutex(m) SDL_mutexP(m) -extern DECLSPEC int SDLCALL SDL_mutexP(SDL_mutex *mutex); - -/* Unlock the mutex (Returns 0, or -1 on error) - It is an error to unlock a mutex that has not been locked by - the current thread, and doing so results in undefined behavior. - */ -#define SDL_UnlockMutex(m) SDL_mutexV(m) -extern DECLSPEC int SDLCALL SDL_mutexV(SDL_mutex *mutex); - -/* Destroy a mutex */ -extern DECLSPEC void SDLCALL SDL_DestroyMutex(SDL_mutex *mutex); - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* Semaphore functions */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* The SDL semaphore structure, defined in SDL_sem.c */ -struct SDL_semaphore; -typedef struct SDL_semaphore SDL_sem; - -/* Create a semaphore, initialized with value, returns NULL on failure. */ -extern DECLSPEC SDL_sem * SDLCALL SDL_CreateSemaphore(Uint32 initial_value); - -/* Destroy a semaphore */ -extern DECLSPEC void SDLCALL SDL_DestroySemaphore(SDL_sem *sem); - -/* This function suspends the calling thread until the semaphore pointed - * to by sem has a positive count. It then atomically decreases the semaphore - * count. - */ -extern DECLSPEC int SDLCALL SDL_SemWait(SDL_sem *sem); - -/* Non-blocking variant of SDL_SemWait(), returns 0 if the wait succeeds, - SDL_MUTEX_TIMEDOUT if the wait would block, and -1 on error. -*/ -extern DECLSPEC int SDLCALL SDL_SemTryWait(SDL_sem *sem); - -/* Variant of SDL_SemWait() with a timeout in milliseconds, returns 0 if - the wait succeeds, SDL_MUTEX_TIMEDOUT if the wait does not succeed in - the allotted time, and -1 on error. - On some platforms this function is implemented by looping with a delay - of 1 ms, and so should be avoided if possible. -*/ -extern DECLSPEC int SDLCALL SDL_SemWaitTimeout(SDL_sem *sem, Uint32 ms); - -/* Atomically increases the semaphore's count (not blocking), returns 0, - or -1 on error. - */ -extern DECLSPEC int SDLCALL SDL_SemPost(SDL_sem *sem); - -/* Returns the current count of the semaphore */ -extern DECLSPEC Uint32 SDLCALL SDL_SemValue(SDL_sem *sem); - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* Condition variable functions */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* The SDL condition variable structure, defined in SDL_cond.c */ -struct SDL_cond; -typedef struct SDL_cond SDL_cond; - -/* Create a condition variable */ -extern DECLSPEC SDL_cond * SDLCALL SDL_CreateCond(void); - -/* Destroy a condition variable */ -extern DECLSPEC void SDLCALL SDL_DestroyCond(SDL_cond *cond); - -/* Restart one of the threads that are waiting on the condition variable, - returns 0 or -1 on error. - */ -extern DECLSPEC int SDLCALL SDL_CondSignal(SDL_cond *cond); - -/* Restart all threads that are waiting on the condition variable, - returns 0 or -1 on error. - */ -extern DECLSPEC int SDLCALL SDL_CondBroadcast(SDL_cond *cond); - -/* Wait on the condition variable, unlocking the provided mutex. - The mutex must be locked before entering this function! - The mutex is re-locked once the condition variable is signaled. - Returns 0 when it is signaled, or -1 on error. - */ -extern DECLSPEC int SDLCALL SDL_CondWait(SDL_cond *cond, SDL_mutex *mut); - -/* Waits for at most 'ms' milliseconds, and returns 0 if the condition - variable is signaled, SDL_MUTEX_TIMEDOUT if the condition is not - signaled in the allotted time, and -1 on error. - On some platforms this function is implemented by looping with a delay - of 1 ms, and so should be avoided if possible. -*/ -extern DECLSPEC int SDLCALL SDL_CondWaitTimeout(SDL_cond *cond, SDL_mutex *mutex, Uint32 ms); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_mutex_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_name.h b/distrib/sdl-1.2.12/include/SDL_name.h deleted file mode 100644 index 511619a..0000000 --- a/distrib/sdl-1.2.12/include/SDL_name.h +++ /dev/null @@ -1,11 +0,0 @@ - -#ifndef _SDLname_h_ -#define _SDLname_h_ - -#if defined(__STDC__) || defined(__cplusplus) -#define NeedFunctionPrototypes 1 -#endif - -#define SDL_NAME(X) SDL_##X - -#endif /* _SDLname_h_ */ diff --git a/distrib/sdl-1.2.12/include/SDL_opengl.h b/distrib/sdl-1.2.12/include/SDL_opengl.h deleted file mode 100644 index 36c0a30..0000000 --- a/distrib/sdl-1.2.12/include/SDL_opengl.h +++ /dev/null @@ -1,6551 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This is a simple file to encapsulate the OpenGL API headers */ - -#include "SDL_config.h" - -#ifdef __WIN32__ -#define WIN32_LEAN_AND_MEAN -#ifndef NOMINMAX -#define NOMINMAX /* Don't defined min() and max() */ -#endif -#include -#endif -#ifndef NO_SDL_GLEXT -#define __glext_h_ /* Don't let gl.h include glext.h */ -#endif -#if defined(__MACOSX__) -#include /* Header File For The OpenGL Library */ -#include /* Header File For The GLU Library */ -#elif defined(__MACOS__) -#include /* Header File For The OpenGL Library */ -#include /* Header File For The GLU Library */ -#else -#include /* Header File For The OpenGL Library */ -#include /* Header File For The GLU Library */ -#endif -#ifndef NO_SDL_GLEXT -#undef __glext_h_ -#endif - -/* This file taken from "GLext.h" from the Jeff Molofee OpenGL tutorials. - It is included here because glext.h is not available on some systems. - If you don't want this version included, simply define "NO_SDL_GLEXT" - */ -#ifndef NO_SDL_GLEXT -#if !defined(__glext_h_) && !defined(GL_GLEXT_LEGACY) -#define __glext_h_ - -#ifdef __cplusplus -extern "C" { -#endif - -/* -** License Applicability. Except to the extent portions of this file are -** made subject to an alternative license as permitted in the SGI Free -** Software License B, Version 1.1 (the "License"), the contents of this -** file are subject only to the provisions of the License. You may not use -** this file except in compliance with the License. You may obtain a copy -** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600 -** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at: -** -** http://oss.sgi.com/projects/FreeB -** -** Note that, as provided in the License, the Software is distributed on an -** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS -** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND -** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A -** PARTICULAR PURPOSE, AND NON-INFRINGEMENT. -** -** Original Code. The Original Code is: OpenGL Sample Implementation, -** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics, -** Inc. The Original Code is Copyright (c) 1991-2004 Silicon Graphics, Inc. -** Copyright in any portions created by third parties is as indicated -** elsewhere herein. All Rights Reserved. -** -** Additional Notice Provisions: This software was created using the -** OpenGL(R) version 1.2.1 Sample Implementation published by SGI, but has -** not been independently verified as being compliant with the OpenGL(R) -** version 1.2.1 Specification. -*/ - -#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) -#define WIN32_LEAN_AND_MEAN 1 -#include -#endif - -#ifndef APIENTRY -#define APIENTRY -#endif -#ifndef APIENTRYP -#define APIENTRYP APIENTRY * -#endif -#ifndef GLAPI -#define GLAPI extern -#endif - -/*************************************************************/ - -/* Header file version number, required by OpenGL ABI for Linux */ -/* glext.h last updated 2005/06/20 */ -/* Current version at http://oss.sgi.com/projects/ogl-sample/registry/ */ -#define GL_GLEXT_VERSION 29 - -#ifndef GL_VERSION_1_2 -#define GL_UNSIGNED_BYTE_3_3_2 0x8032 -#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033 -#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034 -#define GL_UNSIGNED_INT_8_8_8_8 0x8035 -#define GL_UNSIGNED_INT_10_10_10_2 0x8036 -#define GL_RESCALE_NORMAL 0x803A -#define GL_TEXTURE_BINDING_3D 0x806A -#define GL_PACK_SKIP_IMAGES 0x806B -#define GL_PACK_IMAGE_HEIGHT 0x806C -#define GL_UNPACK_SKIP_IMAGES 0x806D -#define GL_UNPACK_IMAGE_HEIGHT 0x806E -#define GL_TEXTURE_3D 0x806F -#define GL_PROXY_TEXTURE_3D 0x8070 -#define GL_TEXTURE_DEPTH 0x8071 -#define GL_TEXTURE_WRAP_R 0x8072 -#define GL_MAX_3D_TEXTURE_SIZE 0x8073 -#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362 -#define GL_UNSIGNED_SHORT_5_6_5 0x8363 -#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364 -#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365 -#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366 -#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367 -#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368 -#define GL_BGR 0x80E0 -#define GL_BGRA 0x80E1 -#define GL_MAX_ELEMENTS_VERTICES 0x80E8 -#define GL_MAX_ELEMENTS_INDICES 0x80E9 -#define GL_CLAMP_TO_EDGE 0x812F -#define GL_TEXTURE_MIN_LOD 0x813A -#define GL_TEXTURE_MAX_LOD 0x813B -#define GL_TEXTURE_BASE_LEVEL 0x813C -#define GL_TEXTURE_MAX_LEVEL 0x813D -#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8 -#define GL_SINGLE_COLOR 0x81F9 -#define GL_SEPARATE_SPECULAR_COLOR 0x81FA -#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12 -#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13 -#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22 -#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23 -#define GL_ALIASED_POINT_SIZE_RANGE 0x846D -#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E -#endif - -#ifndef GL_ARB_imaging -#define GL_CONSTANT_COLOR 0x8001 -#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002 -#define GL_CONSTANT_ALPHA 0x8003 -#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004 -#define GL_BLEND_COLOR 0x8005 -#define GL_FUNC_ADD 0x8006 -#define GL_MIN 0x8007 -#define GL_MAX 0x8008 -#define GL_BLEND_EQUATION 0x8009 -#define GL_FUNC_SUBTRACT 0x800A -#define GL_FUNC_REVERSE_SUBTRACT 0x800B -#define GL_CONVOLUTION_1D 0x8010 -#define GL_CONVOLUTION_2D 0x8011 -#define GL_SEPARABLE_2D 0x8012 -#define GL_CONVOLUTION_BORDER_MODE 0x8013 -#define GL_CONVOLUTION_FILTER_SCALE 0x8014 -#define GL_CONVOLUTION_FILTER_BIAS 0x8015 -#define GL_REDUCE 0x8016 -#define GL_CONVOLUTION_FORMAT 0x8017 -#define GL_CONVOLUTION_WIDTH 0x8018 -#define GL_CONVOLUTION_HEIGHT 0x8019 -#define GL_MAX_CONVOLUTION_WIDTH 0x801A -#define GL_MAX_CONVOLUTION_HEIGHT 0x801B -#define GL_POST_CONVOLUTION_RED_SCALE 0x801C -#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D -#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E -#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F -#define GL_POST_CONVOLUTION_RED_BIAS 0x8020 -#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021 -#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022 -#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023 -#define GL_HISTOGRAM 0x8024 -#define GL_PROXY_HISTOGRAM 0x8025 -#define GL_HISTOGRAM_WIDTH 0x8026 -#define GL_HISTOGRAM_FORMAT 0x8027 -#define GL_HISTOGRAM_RED_SIZE 0x8028 -#define GL_HISTOGRAM_GREEN_SIZE 0x8029 -#define GL_HISTOGRAM_BLUE_SIZE 0x802A -#define GL_HISTOGRAM_ALPHA_SIZE 0x802B -#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C -#define GL_HISTOGRAM_SINK 0x802D -#define GL_MINMAX 0x802E -#define GL_MINMAX_FORMAT 0x802F -#define GL_MINMAX_SINK 0x8030 -#define GL_TABLE_TOO_LARGE 0x8031 -#define GL_COLOR_MATRIX 0x80B1 -#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2 -#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3 -#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4 -#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5 -#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6 -#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7 -#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8 -#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9 -#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA -#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB -#define GL_COLOR_TABLE 0x80D0 -#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1 -#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2 -#define GL_PROXY_COLOR_TABLE 0x80D3 -#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4 -#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5 -#define GL_COLOR_TABLE_SCALE 0x80D6 -#define GL_COLOR_TABLE_BIAS 0x80D7 -#define GL_COLOR_TABLE_FORMAT 0x80D8 -#define GL_COLOR_TABLE_WIDTH 0x80D9 -#define GL_COLOR_TABLE_RED_SIZE 0x80DA -#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB -#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC -#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD -#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE -#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF -#define GL_CONSTANT_BORDER 0x8151 -#define GL_REPLICATE_BORDER 0x8153 -#define GL_CONVOLUTION_BORDER_COLOR 0x8154 -#endif - -#ifndef GL_VERSION_1_3 -#define GL_TEXTURE0 0x84C0 -#define GL_TEXTURE1 0x84C1 -#define GL_TEXTURE2 0x84C2 -#define GL_TEXTURE3 0x84C3 -#define GL_TEXTURE4 0x84C4 -#define GL_TEXTURE5 0x84C5 -#define GL_TEXTURE6 0x84C6 -#define GL_TEXTURE7 0x84C7 -#define GL_TEXTURE8 0x84C8 -#define GL_TEXTURE9 0x84C9 -#define GL_TEXTURE10 0x84CA -#define GL_TEXTURE11 0x84CB -#define GL_TEXTURE12 0x84CC -#define GL_TEXTURE13 0x84CD -#define GL_TEXTURE14 0x84CE -#define GL_TEXTURE15 0x84CF -#define GL_TEXTURE16 0x84D0 -#define GL_TEXTURE17 0x84D1 -#define GL_TEXTURE18 0x84D2 -#define GL_TEXTURE19 0x84D3 -#define GL_TEXTURE20 0x84D4 -#define GL_TEXTURE21 0x84D5 -#define GL_TEXTURE22 0x84D6 -#define GL_TEXTURE23 0x84D7 -#define GL_TEXTURE24 0x84D8 -#define GL_TEXTURE25 0x84D9 -#define GL_TEXTURE26 0x84DA -#define GL_TEXTURE27 0x84DB -#define GL_TEXTURE28 0x84DC -#define GL_TEXTURE29 0x84DD -#define GL_TEXTURE30 0x84DE -#define GL_TEXTURE31 0x84DF -#define GL_ACTIVE_TEXTURE 0x84E0 -#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1 -#define GL_MAX_TEXTURE_UNITS 0x84E2 -#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3 -#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4 -#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5 -#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6 -#define GL_MULTISAMPLE 0x809D -#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE 0x809F -#define GL_SAMPLE_COVERAGE 0x80A0 -#define GL_SAMPLE_BUFFERS 0x80A8 -#define GL_SAMPLES 0x80A9 -#define GL_SAMPLE_COVERAGE_VALUE 0x80AA -#define GL_SAMPLE_COVERAGE_INVERT 0x80AB -#define GL_MULTISAMPLE_BIT 0x20000000 -#define GL_NORMAL_MAP 0x8511 -#define GL_REFLECTION_MAP 0x8512 -#define GL_TEXTURE_CUBE_MAP 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C -#define GL_COMPRESSED_ALPHA 0x84E9 -#define GL_COMPRESSED_LUMINANCE 0x84EA -#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB -#define GL_COMPRESSED_INTENSITY 0x84EC -#define GL_COMPRESSED_RGB 0x84ED -#define GL_COMPRESSED_RGBA 0x84EE -#define GL_TEXTURE_COMPRESSION_HINT 0x84EF -#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0 -#define GL_TEXTURE_COMPRESSED 0x86A1 -#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2 -#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3 -#define GL_CLAMP_TO_BORDER 0x812D -#define GL_COMBINE 0x8570 -#define GL_COMBINE_RGB 0x8571 -#define GL_COMBINE_ALPHA 0x8572 -#define GL_SOURCE0_RGB 0x8580 -#define GL_SOURCE1_RGB 0x8581 -#define GL_SOURCE2_RGB 0x8582 -#define GL_SOURCE0_ALPHA 0x8588 -#define GL_SOURCE1_ALPHA 0x8589 -#define GL_SOURCE2_ALPHA 0x858A -#define GL_OPERAND0_RGB 0x8590 -#define GL_OPERAND1_RGB 0x8591 -#define GL_OPERAND2_RGB 0x8592 -#define GL_OPERAND0_ALPHA 0x8598 -#define GL_OPERAND1_ALPHA 0x8599 -#define GL_OPERAND2_ALPHA 0x859A -#define GL_RGB_SCALE 0x8573 -#define GL_ADD_SIGNED 0x8574 -#define GL_INTERPOLATE 0x8575 -#define GL_SUBTRACT 0x84E7 -#define GL_CONSTANT 0x8576 -#define GL_PRIMARY_COLOR 0x8577 -#define GL_PREVIOUS 0x8578 -#define GL_DOT3_RGB 0x86AE -#define GL_DOT3_RGBA 0x86AF -#endif - -#ifndef GL_VERSION_1_4 -#define GL_BLEND_DST_RGB 0x80C8 -#define GL_BLEND_SRC_RGB 0x80C9 -#define GL_BLEND_DST_ALPHA 0x80CA -#define GL_BLEND_SRC_ALPHA 0x80CB -#define GL_POINT_SIZE_MIN 0x8126 -#define GL_POINT_SIZE_MAX 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128 -#define GL_POINT_DISTANCE_ATTENUATION 0x8129 -#define GL_GENERATE_MIPMAP 0x8191 -#define GL_GENERATE_MIPMAP_HINT 0x8192 -#define GL_DEPTH_COMPONENT16 0x81A5 -#define GL_DEPTH_COMPONENT24 0x81A6 -#define GL_DEPTH_COMPONENT32 0x81A7 -#define GL_MIRRORED_REPEAT 0x8370 -#define GL_FOG_COORDINATE_SOURCE 0x8450 -#define GL_FOG_COORDINATE 0x8451 -#define GL_FRAGMENT_DEPTH 0x8452 -#define GL_CURRENT_FOG_COORDINATE 0x8453 -#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454 -#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455 -#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456 -#define GL_FOG_COORDINATE_ARRAY 0x8457 -#define GL_COLOR_SUM 0x8458 -#define GL_CURRENT_SECONDARY_COLOR 0x8459 -#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A -#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B -#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C -#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D -#define GL_SECONDARY_COLOR_ARRAY 0x845E -#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD -#define GL_TEXTURE_FILTER_CONTROL 0x8500 -#define GL_TEXTURE_LOD_BIAS 0x8501 -#define GL_INCR_WRAP 0x8507 -#define GL_DECR_WRAP 0x8508 -#define GL_TEXTURE_DEPTH_SIZE 0x884A -#define GL_DEPTH_TEXTURE_MODE 0x884B -#define GL_TEXTURE_COMPARE_MODE 0x884C -#define GL_TEXTURE_COMPARE_FUNC 0x884D -#define GL_COMPARE_R_TO_TEXTURE 0x884E -#endif - -#ifndef GL_VERSION_1_5 -#define GL_BUFFER_SIZE 0x8764 -#define GL_BUFFER_USAGE 0x8765 -#define GL_QUERY_COUNTER_BITS 0x8864 -#define GL_CURRENT_QUERY 0x8865 -#define GL_QUERY_RESULT 0x8866 -#define GL_QUERY_RESULT_AVAILABLE 0x8867 -#define GL_ARRAY_BUFFER 0x8892 -#define GL_ELEMENT_ARRAY_BUFFER 0x8893 -#define GL_ARRAY_BUFFER_BINDING 0x8894 -#define GL_ELEMENT_ARRAY_BUFFER_BINDING 0x8895 -#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896 -#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897 -#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898 -#define GL_INDEX_ARRAY_BUFFER_BINDING 0x8899 -#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 0x889A -#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 0x889B -#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 0x889C -#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 0x889D -#define GL_WEIGHT_ARRAY_BUFFER_BINDING 0x889E -#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 0x889F -#define GL_READ_ONLY 0x88B8 -#define GL_WRITE_ONLY 0x88B9 -#define GL_READ_WRITE 0x88BA -#define GL_BUFFER_ACCESS 0x88BB -#define GL_BUFFER_MAPPED 0x88BC -#define GL_BUFFER_MAP_POINTER 0x88BD -#define GL_STREAM_DRAW 0x88E0 -#define GL_STREAM_READ 0x88E1 -#define GL_STREAM_COPY 0x88E2 -#define GL_STATIC_DRAW 0x88E4 -#define GL_STATIC_READ 0x88E5 -#define GL_STATIC_COPY 0x88E6 -#define GL_DYNAMIC_DRAW 0x88E8 -#define GL_DYNAMIC_READ 0x88E9 -#define GL_DYNAMIC_COPY 0x88EA -#define GL_SAMPLES_PASSED 0x8914 -#define GL_FOG_COORD_SRC GL_FOG_COORDINATE_SOURCE -#define GL_FOG_COORD GL_FOG_COORDINATE -#define GL_CURRENT_FOG_COORD GL_CURRENT_FOG_COORDINATE -#define GL_FOG_COORD_ARRAY_TYPE GL_FOG_COORDINATE_ARRAY_TYPE -#define GL_FOG_COORD_ARRAY_STRIDE GL_FOG_COORDINATE_ARRAY_STRIDE -#define GL_FOG_COORD_ARRAY_POINTER GL_FOG_COORDINATE_ARRAY_POINTER -#define GL_FOG_COORD_ARRAY GL_FOG_COORDINATE_ARRAY -#define GL_FOG_COORD_ARRAY_BUFFER_BINDING GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING -#define GL_SRC0_RGB GL_SOURCE0_RGB -#define GL_SRC1_RGB GL_SOURCE1_RGB -#define GL_SRC2_RGB GL_SOURCE2_RGB -#define GL_SRC0_ALPHA GL_SOURCE0_ALPHA -#define GL_SRC1_ALPHA GL_SOURCE1_ALPHA -#define GL_SRC2_ALPHA GL_SOURCE2_ALPHA -#endif - -#ifndef GL_VERSION_2_0 -#define GL_BLEND_EQUATION_RGB GL_BLEND_EQUATION -#define GL_VERTEX_ATTRIB_ARRAY_ENABLED 0x8622 -#define GL_VERTEX_ATTRIB_ARRAY_SIZE 0x8623 -#define GL_VERTEX_ATTRIB_ARRAY_STRIDE 0x8624 -#define GL_VERTEX_ATTRIB_ARRAY_TYPE 0x8625 -#define GL_CURRENT_VERTEX_ATTRIB 0x8626 -#define GL_VERTEX_PROGRAM_POINT_SIZE 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643 -#define GL_VERTEX_ATTRIB_ARRAY_POINTER 0x8645 -#define GL_STENCIL_BACK_FUNC 0x8800 -#define GL_STENCIL_BACK_FAIL 0x8801 -#define GL_STENCIL_BACK_PASS_DEPTH_FAIL 0x8802 -#define GL_STENCIL_BACK_PASS_DEPTH_PASS 0x8803 -#define GL_MAX_DRAW_BUFFERS 0x8824 -#define GL_DRAW_BUFFER0 0x8825 -#define GL_DRAW_BUFFER1 0x8826 -#define GL_DRAW_BUFFER2 0x8827 -#define GL_DRAW_BUFFER3 0x8828 -#define GL_DRAW_BUFFER4 0x8829 -#define GL_DRAW_BUFFER5 0x882A -#define GL_DRAW_BUFFER6 0x882B -#define GL_DRAW_BUFFER7 0x882C -#define GL_DRAW_BUFFER8 0x882D -#define GL_DRAW_BUFFER9 0x882E -#define GL_DRAW_BUFFER10 0x882F -#define GL_DRAW_BUFFER11 0x8830 -#define GL_DRAW_BUFFER12 0x8831 -#define GL_DRAW_BUFFER13 0x8832 -#define GL_DRAW_BUFFER14 0x8833 -#define GL_DRAW_BUFFER15 0x8834 -#define GL_BLEND_EQUATION_ALPHA 0x883D -#define GL_POINT_SPRITE 0x8861 -#define GL_COORD_REPLACE 0x8862 -#define GL_MAX_VERTEX_ATTRIBS 0x8869 -#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED 0x886A -#define GL_MAX_TEXTURE_COORDS 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS 0x8872 -#define GL_FRAGMENT_SHADER 0x8B30 -#define GL_VERTEX_SHADER 0x8B31 -#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS 0x8B49 -#define GL_MAX_VERTEX_UNIFORM_COMPONENTS 0x8B4A -#define GL_MAX_VARYING_FLOATS 0x8B4B -#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS 0x8B4C -#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS 0x8B4D -#define GL_SHADER_TYPE 0x8B4F -#define GL_FLOAT_VEC2 0x8B50 -#define GL_FLOAT_VEC3 0x8B51 -#define GL_FLOAT_VEC4 0x8B52 -#define GL_INT_VEC2 0x8B53 -#define GL_INT_VEC3 0x8B54 -#define GL_INT_VEC4 0x8B55 -#define GL_BOOL 0x8B56 -#define GL_BOOL_VEC2 0x8B57 -#define GL_BOOL_VEC3 0x8B58 -#define GL_BOOL_VEC4 0x8B59 -#define GL_FLOAT_MAT2 0x8B5A -#define GL_FLOAT_MAT3 0x8B5B -#define GL_FLOAT_MAT4 0x8B5C -#define GL_SAMPLER_1D 0x8B5D -#define GL_SAMPLER_2D 0x8B5E -#define GL_SAMPLER_3D 0x8B5F -#define GL_SAMPLER_CUBE 0x8B60 -#define GL_SAMPLER_1D_SHADOW 0x8B61 -#define GL_SAMPLER_2D_SHADOW 0x8B62 -#define GL_DELETE_STATUS 0x8B80 -#define GL_COMPILE_STATUS 0x8B81 -#define GL_LINK_STATUS 0x8B82 -#define GL_VALIDATE_STATUS 0x8B83 -#define GL_INFO_LOG_LENGTH 0x8B84 -#define GL_ATTACHED_SHADERS 0x8B85 -#define GL_ACTIVE_UNIFORMS 0x8B86 -#define GL_ACTIVE_UNIFORM_MAX_LENGTH 0x8B87 -#define GL_SHADER_SOURCE_LENGTH 0x8B88 -#define GL_ACTIVE_ATTRIBUTES 0x8B89 -#define GL_ACTIVE_ATTRIBUTE_MAX_LENGTH 0x8B8A -#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT 0x8B8B -#define GL_SHADING_LANGUAGE_VERSION 0x8B8C -#define GL_CURRENT_PROGRAM 0x8B8D -#define GL_POINT_SPRITE_COORD_ORIGIN 0x8CA0 -#define GL_LOWER_LEFT 0x8CA1 -#define GL_UPPER_LEFT 0x8CA2 -#define GL_STENCIL_BACK_REF 0x8CA3 -#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4 -#define GL_STENCIL_BACK_WRITEMASK 0x8CA5 -#endif - -#ifndef GL_ARB_multitexture -#define GL_TEXTURE0_ARB 0x84C0 -#define GL_TEXTURE1_ARB 0x84C1 -#define GL_TEXTURE2_ARB 0x84C2 -#define GL_TEXTURE3_ARB 0x84C3 -#define GL_TEXTURE4_ARB 0x84C4 -#define GL_TEXTURE5_ARB 0x84C5 -#define GL_TEXTURE6_ARB 0x84C6 -#define GL_TEXTURE7_ARB 0x84C7 -#define GL_TEXTURE8_ARB 0x84C8 -#define GL_TEXTURE9_ARB 0x84C9 -#define GL_TEXTURE10_ARB 0x84CA -#define GL_TEXTURE11_ARB 0x84CB -#define GL_TEXTURE12_ARB 0x84CC -#define GL_TEXTURE13_ARB 0x84CD -#define GL_TEXTURE14_ARB 0x84CE -#define GL_TEXTURE15_ARB 0x84CF -#define GL_TEXTURE16_ARB 0x84D0 -#define GL_TEXTURE17_ARB 0x84D1 -#define GL_TEXTURE18_ARB 0x84D2 -#define GL_TEXTURE19_ARB 0x84D3 -#define GL_TEXTURE20_ARB 0x84D4 -#define GL_TEXTURE21_ARB 0x84D5 -#define GL_TEXTURE22_ARB 0x84D6 -#define GL_TEXTURE23_ARB 0x84D7 -#define GL_TEXTURE24_ARB 0x84D8 -#define GL_TEXTURE25_ARB 0x84D9 -#define GL_TEXTURE26_ARB 0x84DA -#define GL_TEXTURE27_ARB 0x84DB -#define GL_TEXTURE28_ARB 0x84DC -#define GL_TEXTURE29_ARB 0x84DD -#define GL_TEXTURE30_ARB 0x84DE -#define GL_TEXTURE31_ARB 0x84DF -#define GL_ACTIVE_TEXTURE_ARB 0x84E0 -#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1 -#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2 -#endif - -#ifndef GL_ARB_transpose_matrix -#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3 -#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4 -#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5 -#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6 -#endif - -#ifndef GL_ARB_multisample -#define GL_MULTISAMPLE_ARB 0x809D -#define GL_SAMPLE_ALPHA_TO_COVERAGE_ARB 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_ARB 0x809F -#define GL_SAMPLE_COVERAGE_ARB 0x80A0 -#define GL_SAMPLE_BUFFERS_ARB 0x80A8 -#define GL_SAMPLES_ARB 0x80A9 -#define GL_SAMPLE_COVERAGE_VALUE_ARB 0x80AA -#define GL_SAMPLE_COVERAGE_INVERT_ARB 0x80AB -#define GL_MULTISAMPLE_BIT_ARB 0x20000000 -#endif - -#ifndef GL_ARB_texture_env_add -#endif - -#ifndef GL_ARB_texture_cube_map -#define GL_NORMAL_MAP_ARB 0x8511 -#define GL_REFLECTION_MAP_ARB 0x8512 -#define GL_TEXTURE_CUBE_MAP_ARB 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP_ARB 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP_ARB 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB 0x851C -#endif - -#ifndef GL_ARB_texture_compression -#define GL_COMPRESSED_ALPHA_ARB 0x84E9 -#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA -#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB -#define GL_COMPRESSED_INTENSITY_ARB 0x84EC -#define GL_COMPRESSED_RGB_ARB 0x84ED -#define GL_COMPRESSED_RGBA_ARB 0x84EE -#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF -#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0 -#define GL_TEXTURE_COMPRESSED_ARB 0x86A1 -#define GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A2 -#define GL_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A3 -#endif - -#ifndef GL_ARB_texture_border_clamp -#define GL_CLAMP_TO_BORDER_ARB 0x812D -#endif - -#ifndef GL_ARB_point_parameters -#define GL_POINT_SIZE_MIN_ARB 0x8126 -#define GL_POINT_SIZE_MAX_ARB 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_ARB 0x8128 -#define GL_POINT_DISTANCE_ATTENUATION_ARB 0x8129 -#endif - -#ifndef GL_ARB_vertex_blend -#define GL_MAX_VERTEX_UNITS_ARB 0x86A4 -#define GL_ACTIVE_VERTEX_UNITS_ARB 0x86A5 -#define GL_WEIGHT_SUM_UNITY_ARB 0x86A6 -#define GL_VERTEX_BLEND_ARB 0x86A7 -#define GL_CURRENT_WEIGHT_ARB 0x86A8 -#define GL_WEIGHT_ARRAY_TYPE_ARB 0x86A9 -#define GL_WEIGHT_ARRAY_STRIDE_ARB 0x86AA -#define GL_WEIGHT_ARRAY_SIZE_ARB 0x86AB -#define GL_WEIGHT_ARRAY_POINTER_ARB 0x86AC -#define GL_WEIGHT_ARRAY_ARB 0x86AD -#define GL_MODELVIEW0_ARB 0x1700 -#define GL_MODELVIEW1_ARB 0x850A -#define GL_MODELVIEW2_ARB 0x8722 -#define GL_MODELVIEW3_ARB 0x8723 -#define GL_MODELVIEW4_ARB 0x8724 -#define GL_MODELVIEW5_ARB 0x8725 -#define GL_MODELVIEW6_ARB 0x8726 -#define GL_MODELVIEW7_ARB 0x8727 -#define GL_MODELVIEW8_ARB 0x8728 -#define GL_MODELVIEW9_ARB 0x8729 -#define GL_MODELVIEW10_ARB 0x872A -#define GL_MODELVIEW11_ARB 0x872B -#define GL_MODELVIEW12_ARB 0x872C -#define GL_MODELVIEW13_ARB 0x872D -#define GL_MODELVIEW14_ARB 0x872E -#define GL_MODELVIEW15_ARB 0x872F -#define GL_MODELVIEW16_ARB 0x8730 -#define GL_MODELVIEW17_ARB 0x8731 -#define GL_MODELVIEW18_ARB 0x8732 -#define GL_MODELVIEW19_ARB 0x8733 -#define GL_MODELVIEW20_ARB 0x8734 -#define GL_MODELVIEW21_ARB 0x8735 -#define GL_MODELVIEW22_ARB 0x8736 -#define GL_MODELVIEW23_ARB 0x8737 -#define GL_MODELVIEW24_ARB 0x8738 -#define GL_MODELVIEW25_ARB 0x8739 -#define GL_MODELVIEW26_ARB 0x873A -#define GL_MODELVIEW27_ARB 0x873B -#define GL_MODELVIEW28_ARB 0x873C -#define GL_MODELVIEW29_ARB 0x873D -#define GL_MODELVIEW30_ARB 0x873E -#define GL_MODELVIEW31_ARB 0x873F -#endif - -#ifndef GL_ARB_matrix_palette -#define GL_MATRIX_PALETTE_ARB 0x8840 -#define GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB 0x8841 -#define GL_MAX_PALETTE_MATRICES_ARB 0x8842 -#define GL_CURRENT_PALETTE_MATRIX_ARB 0x8843 -#define GL_MATRIX_INDEX_ARRAY_ARB 0x8844 -#define GL_CURRENT_MATRIX_INDEX_ARB 0x8845 -#define GL_MATRIX_INDEX_ARRAY_SIZE_ARB 0x8846 -#define GL_MATRIX_INDEX_ARRAY_TYPE_ARB 0x8847 -#define GL_MATRIX_INDEX_ARRAY_STRIDE_ARB 0x8848 -#define GL_MATRIX_INDEX_ARRAY_POINTER_ARB 0x8849 -#endif - -#ifndef GL_ARB_texture_env_combine -#define GL_COMBINE_ARB 0x8570 -#define GL_COMBINE_RGB_ARB 0x8571 -#define GL_COMBINE_ALPHA_ARB 0x8572 -#define GL_SOURCE0_RGB_ARB 0x8580 -#define GL_SOURCE1_RGB_ARB 0x8581 -#define GL_SOURCE2_RGB_ARB 0x8582 -#define GL_SOURCE0_ALPHA_ARB 0x8588 -#define GL_SOURCE1_ALPHA_ARB 0x8589 -#define GL_SOURCE2_ALPHA_ARB 0x858A -#define GL_OPERAND0_RGB_ARB 0x8590 -#define GL_OPERAND1_RGB_ARB 0x8591 -#define GL_OPERAND2_RGB_ARB 0x8592 -#define GL_OPERAND0_ALPHA_ARB 0x8598 -#define GL_OPERAND1_ALPHA_ARB 0x8599 -#define GL_OPERAND2_ALPHA_ARB 0x859A -#define GL_RGB_SCALE_ARB 0x8573 -#define GL_ADD_SIGNED_ARB 0x8574 -#define GL_INTERPOLATE_ARB 0x8575 -#define GL_SUBTRACT_ARB 0x84E7 -#define GL_CONSTANT_ARB 0x8576 -#define GL_PRIMARY_COLOR_ARB 0x8577 -#define GL_PREVIOUS_ARB 0x8578 -#endif - -#ifndef GL_ARB_texture_env_crossbar -#endif - -#ifndef GL_ARB_texture_env_dot3 -#define GL_DOT3_RGB_ARB 0x86AE -#define GL_DOT3_RGBA_ARB 0x86AF -#endif - -#ifndef GL_ARB_texture_mirrored_repeat -#define GL_MIRRORED_REPEAT_ARB 0x8370 -#endif - -#ifndef GL_ARB_depth_texture -#define GL_DEPTH_COMPONENT16_ARB 0x81A5 -#define GL_DEPTH_COMPONENT24_ARB 0x81A6 -#define GL_DEPTH_COMPONENT32_ARB 0x81A7 -#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A -#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B -#endif - -#ifndef GL_ARB_shadow -#define GL_TEXTURE_COMPARE_MODE_ARB 0x884C -#define GL_TEXTURE_COMPARE_FUNC_ARB 0x884D -#define GL_COMPARE_R_TO_TEXTURE_ARB 0x884E -#endif - -#ifndef GL_ARB_shadow_ambient -#define GL_TEXTURE_COMPARE_FAIL_VALUE_ARB 0x80BF -#endif - -#ifndef GL_ARB_window_pos -#endif - -#ifndef GL_ARB_vertex_program -#define GL_COLOR_SUM_ARB 0x8458 -#define GL_VERTEX_PROGRAM_ARB 0x8620 -#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622 -#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623 -#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624 -#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625 -#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626 -#define GL_PROGRAM_LENGTH_ARB 0x8627 -#define GL_PROGRAM_STRING_ARB 0x8628 -#define GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB 0x862E -#define GL_MAX_PROGRAM_MATRICES_ARB 0x862F -#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640 -#define GL_CURRENT_MATRIX_ARB 0x8641 -#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643 -#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645 -#define GL_PROGRAM_ERROR_POSITION_ARB 0x864B -#define GL_PROGRAM_BINDING_ARB 0x8677 -#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869 -#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A -#define GL_PROGRAM_ERROR_STRING_ARB 0x8874 -#define GL_PROGRAM_FORMAT_ASCII_ARB 0x8875 -#define GL_PROGRAM_FORMAT_ARB 0x8876 -#define GL_PROGRAM_INSTRUCTIONS_ARB 0x88A0 -#define GL_MAX_PROGRAM_INSTRUCTIONS_ARB 0x88A1 -#define GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A2 -#define GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A3 -#define GL_PROGRAM_TEMPORARIES_ARB 0x88A4 -#define GL_MAX_PROGRAM_TEMPORARIES_ARB 0x88A5 -#define GL_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A6 -#define GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A7 -#define GL_PROGRAM_PARAMETERS_ARB 0x88A8 -#define GL_MAX_PROGRAM_PARAMETERS_ARB 0x88A9 -#define GL_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AA -#define GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AB -#define GL_PROGRAM_ATTRIBS_ARB 0x88AC -#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD -#define GL_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AE -#define GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AF -#define GL_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B0 -#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1 -#define GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B2 -#define GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B3 -#define GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB 0x88B4 -#define GL_MAX_PROGRAM_ENV_PARAMETERS_ARB 0x88B5 -#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6 -#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7 -#define GL_MATRIX0_ARB 0x88C0 -#define GL_MATRIX1_ARB 0x88C1 -#define GL_MATRIX2_ARB 0x88C2 -#define GL_MATRIX3_ARB 0x88C3 -#define GL_MATRIX4_ARB 0x88C4 -#define GL_MATRIX5_ARB 0x88C5 -#define GL_MATRIX6_ARB 0x88C6 -#define GL_MATRIX7_ARB 0x88C7 -#define GL_MATRIX8_ARB 0x88C8 -#define GL_MATRIX9_ARB 0x88C9 -#define GL_MATRIX10_ARB 0x88CA -#define GL_MATRIX11_ARB 0x88CB -#define GL_MATRIX12_ARB 0x88CC -#define GL_MATRIX13_ARB 0x88CD -#define GL_MATRIX14_ARB 0x88CE -#define GL_MATRIX15_ARB 0x88CF -#define GL_MATRIX16_ARB 0x88D0 -#define GL_MATRIX17_ARB 0x88D1 -#define GL_MATRIX18_ARB 0x88D2 -#define GL_MATRIX19_ARB 0x88D3 -#define GL_MATRIX20_ARB 0x88D4 -#define GL_MATRIX21_ARB 0x88D5 -#define GL_MATRIX22_ARB 0x88D6 -#define GL_MATRIX23_ARB 0x88D7 -#define GL_MATRIX24_ARB 0x88D8 -#define GL_MATRIX25_ARB 0x88D9 -#define GL_MATRIX26_ARB 0x88DA -#define GL_MATRIX27_ARB 0x88DB -#define GL_MATRIX28_ARB 0x88DC -#define GL_MATRIX29_ARB 0x88DD -#define GL_MATRIX30_ARB 0x88DE -#define GL_MATRIX31_ARB 0x88DF -#endif - -#ifndef GL_ARB_fragment_program -#define GL_FRAGMENT_PROGRAM_ARB 0x8804 -#define GL_PROGRAM_ALU_INSTRUCTIONS_ARB 0x8805 -#define GL_PROGRAM_TEX_INSTRUCTIONS_ARB 0x8806 -#define GL_PROGRAM_TEX_INDIRECTIONS_ARB 0x8807 -#define GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x8808 -#define GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x8809 -#define GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x880A -#define GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB 0x880B -#define GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB 0x880C -#define GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB 0x880D -#define GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB 0x880E -#define GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB 0x880F -#define GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB 0x8810 -#define GL_MAX_TEXTURE_COORDS_ARB 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS_ARB 0x8872 -#endif - -#ifndef GL_ARB_vertex_buffer_object -#define GL_BUFFER_SIZE_ARB 0x8764 -#define GL_BUFFER_USAGE_ARB 0x8765 -#define GL_ARRAY_BUFFER_ARB 0x8892 -#define GL_ELEMENT_ARRAY_BUFFER_ARB 0x8893 -#define GL_ARRAY_BUFFER_BINDING_ARB 0x8894 -#define GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB 0x8895 -#define GL_VERTEX_ARRAY_BUFFER_BINDING_ARB 0x8896 -#define GL_NORMAL_ARRAY_BUFFER_BINDING_ARB 0x8897 -#define GL_COLOR_ARRAY_BUFFER_BINDING_ARB 0x8898 -#define GL_INDEX_ARRAY_BUFFER_BINDING_ARB 0x8899 -#define GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB 0x889A -#define GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB 0x889B -#define GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB 0x889C -#define GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB 0x889D -#define GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB 0x889E -#define GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB 0x889F -#define GL_READ_ONLY_ARB 0x88B8 -#define GL_WRITE_ONLY_ARB 0x88B9 -#define GL_READ_WRITE_ARB 0x88BA -#define GL_BUFFER_ACCESS_ARB 0x88BB -#define GL_BUFFER_MAPPED_ARB 0x88BC -#define GL_BUFFER_MAP_POINTER_ARB 0x88BD -#define GL_STREAM_DRAW_ARB 0x88E0 -#define GL_STREAM_READ_ARB 0x88E1 -#define GL_STREAM_COPY_ARB 0x88E2 -#define GL_STATIC_DRAW_ARB 0x88E4 -#define GL_STATIC_READ_ARB 0x88E5 -#define GL_STATIC_COPY_ARB 0x88E6 -#define GL_DYNAMIC_DRAW_ARB 0x88E8 -#define GL_DYNAMIC_READ_ARB 0x88E9 -#define GL_DYNAMIC_COPY_ARB 0x88EA -#endif - -#ifndef GL_ARB_occlusion_query -#define GL_QUERY_COUNTER_BITS_ARB 0x8864 -#define GL_CURRENT_QUERY_ARB 0x8865 -#define GL_QUERY_RESULT_ARB 0x8866 -#define GL_QUERY_RESULT_AVAILABLE_ARB 0x8867 -#define GL_SAMPLES_PASSED_ARB 0x8914 -#endif - -#ifndef GL_ARB_shader_objects -#define GL_PROGRAM_OBJECT_ARB 0x8B40 -#define GL_SHADER_OBJECT_ARB 0x8B48 -#define GL_OBJECT_TYPE_ARB 0x8B4E -#define GL_OBJECT_SUBTYPE_ARB 0x8B4F -#define GL_FLOAT_VEC2_ARB 0x8B50 -#define GL_FLOAT_VEC3_ARB 0x8B51 -#define GL_FLOAT_VEC4_ARB 0x8B52 -#define GL_INT_VEC2_ARB 0x8B53 -#define GL_INT_VEC3_ARB 0x8B54 -#define GL_INT_VEC4_ARB 0x8B55 -#define GL_BOOL_ARB 0x8B56 -#define GL_BOOL_VEC2_ARB 0x8B57 -#define GL_BOOL_VEC3_ARB 0x8B58 -#define GL_BOOL_VEC4_ARB 0x8B59 -#define GL_FLOAT_MAT2_ARB 0x8B5A -#define GL_FLOAT_MAT3_ARB 0x8B5B -#define GL_FLOAT_MAT4_ARB 0x8B5C -#define GL_SAMPLER_1D_ARB 0x8B5D -#define GL_SAMPLER_2D_ARB 0x8B5E -#define GL_SAMPLER_3D_ARB 0x8B5F -#define GL_SAMPLER_CUBE_ARB 0x8B60 -#define GL_SAMPLER_1D_SHADOW_ARB 0x8B61 -#define GL_SAMPLER_2D_SHADOW_ARB 0x8B62 -#define GL_SAMPLER_2D_RECT_ARB 0x8B63 -#define GL_SAMPLER_2D_RECT_SHADOW_ARB 0x8B64 -#define GL_OBJECT_DELETE_STATUS_ARB 0x8B80 -#define GL_OBJECT_COMPILE_STATUS_ARB 0x8B81 -#define GL_OBJECT_LINK_STATUS_ARB 0x8B82 -#define GL_OBJECT_VALIDATE_STATUS_ARB 0x8B83 -#define GL_OBJECT_INFO_LOG_LENGTH_ARB 0x8B84 -#define GL_OBJECT_ATTACHED_OBJECTS_ARB 0x8B85 -#define GL_OBJECT_ACTIVE_UNIFORMS_ARB 0x8B86 -#define GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB 0x8B87 -#define GL_OBJECT_SHADER_SOURCE_LENGTH_ARB 0x8B88 -#endif - -#ifndef GL_ARB_vertex_shader -#define GL_VERTEX_SHADER_ARB 0x8B31 -#define GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB 0x8B4A -#define GL_MAX_VARYING_FLOATS_ARB 0x8B4B -#define GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB 0x8B4C -#define GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB 0x8B4D -#define GL_OBJECT_ACTIVE_ATTRIBUTES_ARB 0x8B89 -#define GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB 0x8B8A -#endif - -#ifndef GL_ARB_fragment_shader -#define GL_FRAGMENT_SHADER_ARB 0x8B30 -#define GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB 0x8B49 -#define GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB 0x8B8B -#endif - -#ifndef GL_ARB_shading_language_100 -#define GL_SHADING_LANGUAGE_VERSION_ARB 0x8B8C -#endif - -#ifndef GL_ARB_texture_non_power_of_two -#endif - -#ifndef GL_ARB_point_sprite -#define GL_POINT_SPRITE_ARB 0x8861 -#define GL_COORD_REPLACE_ARB 0x8862 -#endif - -#ifndef GL_ARB_fragment_program_shadow -#endif - -#ifndef GL_ARB_draw_buffers -#define GL_MAX_DRAW_BUFFERS_ARB 0x8824 -#define GL_DRAW_BUFFER0_ARB 0x8825 -#define GL_DRAW_BUFFER1_ARB 0x8826 -#define GL_DRAW_BUFFER2_ARB 0x8827 -#define GL_DRAW_BUFFER3_ARB 0x8828 -#define GL_DRAW_BUFFER4_ARB 0x8829 -#define GL_DRAW_BUFFER5_ARB 0x882A -#define GL_DRAW_BUFFER6_ARB 0x882B -#define GL_DRAW_BUFFER7_ARB 0x882C -#define GL_DRAW_BUFFER8_ARB 0x882D -#define GL_DRAW_BUFFER9_ARB 0x882E -#define GL_DRAW_BUFFER10_ARB 0x882F -#define GL_DRAW_BUFFER11_ARB 0x8830 -#define GL_DRAW_BUFFER12_ARB 0x8831 -#define GL_DRAW_BUFFER13_ARB 0x8832 -#define GL_DRAW_BUFFER14_ARB 0x8833 -#define GL_DRAW_BUFFER15_ARB 0x8834 -#endif - -#ifndef GL_ARB_texture_rectangle -#define GL_TEXTURE_RECTANGLE_ARB 0x84F5 -#define GL_TEXTURE_BINDING_RECTANGLE_ARB 0x84F6 -#define GL_PROXY_TEXTURE_RECTANGLE_ARB 0x84F7 -#define GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB 0x84F8 -#endif - -#ifndef GL_ARB_color_buffer_float -#define GL_RGBA_FLOAT_MODE_ARB 0x8820 -#define GL_CLAMP_VERTEX_COLOR_ARB 0x891A -#define GL_CLAMP_FRAGMENT_COLOR_ARB 0x891B -#define GL_CLAMP_READ_COLOR_ARB 0x891C -#define GL_FIXED_ONLY_ARB 0x891D -#endif - -#ifndef GL_ARB_half_float_pixel -#define GL_HALF_FLOAT_ARB 0x140B -#endif - -#ifndef GL_ARB_texture_float -#define GL_TEXTURE_RED_TYPE_ARB 0x8C10 -#define GL_TEXTURE_GREEN_TYPE_ARB 0x8C11 -#define GL_TEXTURE_BLUE_TYPE_ARB 0x8C12 -#define GL_TEXTURE_ALPHA_TYPE_ARB 0x8C13 -#define GL_TEXTURE_LUMINANCE_TYPE_ARB 0x8C14 -#define GL_TEXTURE_INTENSITY_TYPE_ARB 0x8C15 -#define GL_TEXTURE_DEPTH_TYPE_ARB 0x8C16 -#define GL_UNSIGNED_NORMALIZED_ARB 0x8C17 -#define GL_RGBA32F_ARB 0x8814 -#define GL_RGB32F_ARB 0x8815 -#define GL_ALPHA32F_ARB 0x8816 -#define GL_INTENSITY32F_ARB 0x8817 -#define GL_LUMINANCE32F_ARB 0x8818 -#define GL_LUMINANCE_ALPHA32F_ARB 0x8819 -#define GL_RGBA16F_ARB 0x881A -#define GL_RGB16F_ARB 0x881B -#define GL_ALPHA16F_ARB 0x881C -#define GL_INTENSITY16F_ARB 0x881D -#define GL_LUMINANCE16F_ARB 0x881E -#define GL_LUMINANCE_ALPHA16F_ARB 0x881F -#endif - -#ifndef GL_ARB_pixel_buffer_object -#define GL_PIXEL_PACK_BUFFER_ARB 0x88EB -#define GL_PIXEL_UNPACK_BUFFER_ARB 0x88EC -#define GL_PIXEL_PACK_BUFFER_BINDING_ARB 0x88ED -#define GL_PIXEL_UNPACK_BUFFER_BINDING_ARB 0x88EF -#endif - -#ifndef GL_EXT_abgr -#define GL_ABGR_EXT 0x8000 -#endif - -#ifndef GL_EXT_blend_color -#define GL_CONSTANT_COLOR_EXT 0x8001 -#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002 -#define GL_CONSTANT_ALPHA_EXT 0x8003 -#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004 -#define GL_BLEND_COLOR_EXT 0x8005 -#endif - -#ifndef GL_EXT_polygon_offset -#define GL_POLYGON_OFFSET_EXT 0x8037 -#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038 -#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039 -#endif - -#ifndef GL_EXT_texture -#define GL_ALPHA4_EXT 0x803B -#define GL_ALPHA8_EXT 0x803C -#define GL_ALPHA12_EXT 0x803D -#define GL_ALPHA16_EXT 0x803E -#define GL_LUMINANCE4_EXT 0x803F -#define GL_LUMINANCE8_EXT 0x8040 -#define GL_LUMINANCE12_EXT 0x8041 -#define GL_LUMINANCE16_EXT 0x8042 -#define GL_LUMINANCE4_ALPHA4_EXT 0x8043 -#define GL_LUMINANCE6_ALPHA2_EXT 0x8044 -#define GL_LUMINANCE8_ALPHA8_EXT 0x8045 -#define GL_LUMINANCE12_ALPHA4_EXT 0x8046 -#define GL_LUMINANCE12_ALPHA12_EXT 0x8047 -#define GL_LUMINANCE16_ALPHA16_EXT 0x8048 -#define GL_INTENSITY_EXT 0x8049 -#define GL_INTENSITY4_EXT 0x804A -#define GL_INTENSITY8_EXT 0x804B -#define GL_INTENSITY12_EXT 0x804C -#define GL_INTENSITY16_EXT 0x804D -#define GL_RGB2_EXT 0x804E -#define GL_RGB4_EXT 0x804F -#define GL_RGB5_EXT 0x8050 -#define GL_RGB8_EXT 0x8051 -#define GL_RGB10_EXT 0x8052 -#define GL_RGB12_EXT 0x8053 -#define GL_RGB16_EXT 0x8054 -#define GL_RGBA2_EXT 0x8055 -#define GL_RGBA4_EXT 0x8056 -#define GL_RGB5_A1_EXT 0x8057 -#define GL_RGBA8_EXT 0x8058 -#define GL_RGB10_A2_EXT 0x8059 -#define GL_RGBA12_EXT 0x805A -#define GL_RGBA16_EXT 0x805B -#define GL_TEXTURE_RED_SIZE_EXT 0x805C -#define GL_TEXTURE_GREEN_SIZE_EXT 0x805D -#define GL_TEXTURE_BLUE_SIZE_EXT 0x805E -#define GL_TEXTURE_ALPHA_SIZE_EXT 0x805F -#define GL_TEXTURE_LUMINANCE_SIZE_EXT 0x8060 -#define GL_TEXTURE_INTENSITY_SIZE_EXT 0x8061 -#define GL_REPLACE_EXT 0x8062 -#define GL_PROXY_TEXTURE_1D_EXT 0x8063 -#define GL_PROXY_TEXTURE_2D_EXT 0x8064 -#define GL_TEXTURE_TOO_LARGE_EXT 0x8065 -#endif - -#ifndef GL_EXT_texture3D -#define GL_PACK_SKIP_IMAGES_EXT 0x806B -#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C -#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D -#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E -#define GL_TEXTURE_3D_EXT 0x806F -#define GL_PROXY_TEXTURE_3D_EXT 0x8070 -#define GL_TEXTURE_DEPTH_EXT 0x8071 -#define GL_TEXTURE_WRAP_R_EXT 0x8072 -#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073 -#endif - -#ifndef GL_SGIS_texture_filter4 -#define GL_FILTER4_SGIS 0x8146 -#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147 -#endif - -#ifndef GL_EXT_subtexture -#endif - -#ifndef GL_EXT_copy_texture -#endif - -#ifndef GL_EXT_histogram -#define GL_HISTOGRAM_EXT 0x8024 -#define GL_PROXY_HISTOGRAM_EXT 0x8025 -#define GL_HISTOGRAM_WIDTH_EXT 0x8026 -#define GL_HISTOGRAM_FORMAT_EXT 0x8027 -#define GL_HISTOGRAM_RED_SIZE_EXT 0x8028 -#define GL_HISTOGRAM_GREEN_SIZE_EXT 0x8029 -#define GL_HISTOGRAM_BLUE_SIZE_EXT 0x802A -#define GL_HISTOGRAM_ALPHA_SIZE_EXT 0x802B -#define GL_HISTOGRAM_LUMINANCE_SIZE_EXT 0x802C -#define GL_HISTOGRAM_SINK_EXT 0x802D -#define GL_MINMAX_EXT 0x802E -#define GL_MINMAX_FORMAT_EXT 0x802F -#define GL_MINMAX_SINK_EXT 0x8030 -#define GL_TABLE_TOO_LARGE_EXT 0x8031 -#endif - -#ifndef GL_EXT_convolution -#define GL_CONVOLUTION_1D_EXT 0x8010 -#define GL_CONVOLUTION_2D_EXT 0x8011 -#define GL_SEPARABLE_2D_EXT 0x8012 -#define GL_CONVOLUTION_BORDER_MODE_EXT 0x8013 -#define GL_CONVOLUTION_FILTER_SCALE_EXT 0x8014 -#define GL_CONVOLUTION_FILTER_BIAS_EXT 0x8015 -#define GL_REDUCE_EXT 0x8016 -#define GL_CONVOLUTION_FORMAT_EXT 0x8017 -#define GL_CONVOLUTION_WIDTH_EXT 0x8018 -#define GL_CONVOLUTION_HEIGHT_EXT 0x8019 -#define GL_MAX_CONVOLUTION_WIDTH_EXT 0x801A -#define GL_MAX_CONVOLUTION_HEIGHT_EXT 0x801B -#define GL_POST_CONVOLUTION_RED_SCALE_EXT 0x801C -#define GL_POST_CONVOLUTION_GREEN_SCALE_EXT 0x801D -#define GL_POST_CONVOLUTION_BLUE_SCALE_EXT 0x801E -#define GL_POST_CONVOLUTION_ALPHA_SCALE_EXT 0x801F -#define GL_POST_CONVOLUTION_RED_BIAS_EXT 0x8020 -#define GL_POST_CONVOLUTION_GREEN_BIAS_EXT 0x8021 -#define GL_POST_CONVOLUTION_BLUE_BIAS_EXT 0x8022 -#define GL_POST_CONVOLUTION_ALPHA_BIAS_EXT 0x8023 -#endif - -#ifndef GL_SGI_color_matrix -#define GL_COLOR_MATRIX_SGI 0x80B1 -#define GL_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B2 -#define GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B3 -#define GL_POST_COLOR_MATRIX_RED_SCALE_SGI 0x80B4 -#define GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI 0x80B5 -#define GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI 0x80B6 -#define GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI 0x80B7 -#define GL_POST_COLOR_MATRIX_RED_BIAS_SGI 0x80B8 -#define GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI 0x80B9 -#define GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI 0x80BA -#define GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI 0x80BB -#endif - -#ifndef GL_SGI_color_table -#define GL_COLOR_TABLE_SGI 0x80D0 -#define GL_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D1 -#define GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D2 -#define GL_PROXY_COLOR_TABLE_SGI 0x80D3 -#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D4 -#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D5 -#define GL_COLOR_TABLE_SCALE_SGI 0x80D6 -#define GL_COLOR_TABLE_BIAS_SGI 0x80D7 -#define GL_COLOR_TABLE_FORMAT_SGI 0x80D8 -#define GL_COLOR_TABLE_WIDTH_SGI 0x80D9 -#define GL_COLOR_TABLE_RED_SIZE_SGI 0x80DA -#define GL_COLOR_TABLE_GREEN_SIZE_SGI 0x80DB -#define GL_COLOR_TABLE_BLUE_SIZE_SGI 0x80DC -#define GL_COLOR_TABLE_ALPHA_SIZE_SGI 0x80DD -#define GL_COLOR_TABLE_LUMINANCE_SIZE_SGI 0x80DE -#define GL_COLOR_TABLE_INTENSITY_SIZE_SGI 0x80DF -#endif - -#ifndef GL_SGIS_pixel_texture -#define GL_PIXEL_TEXTURE_SGIS 0x8353 -#define GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS 0x8354 -#define GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS 0x8355 -#define GL_PIXEL_GROUP_COLOR_SGIS 0x8356 -#endif - -#ifndef GL_SGIX_pixel_texture -#define GL_PIXEL_TEX_GEN_SGIX 0x8139 -#define GL_PIXEL_TEX_GEN_MODE_SGIX 0x832B -#endif - -#ifndef GL_SGIS_texture4D -#define GL_PACK_SKIP_VOLUMES_SGIS 0x8130 -#define GL_PACK_IMAGE_DEPTH_SGIS 0x8131 -#define GL_UNPACK_SKIP_VOLUMES_SGIS 0x8132 -#define GL_UNPACK_IMAGE_DEPTH_SGIS 0x8133 -#define GL_TEXTURE_4D_SGIS 0x8134 -#define GL_PROXY_TEXTURE_4D_SGIS 0x8135 -#define GL_TEXTURE_4DSIZE_SGIS 0x8136 -#define GL_TEXTURE_WRAP_Q_SGIS 0x8137 -#define GL_MAX_4D_TEXTURE_SIZE_SGIS 0x8138 -#define GL_TEXTURE_4D_BINDING_SGIS 0x814F -#endif - -#ifndef GL_SGI_texture_color_table -#define GL_TEXTURE_COLOR_TABLE_SGI 0x80BC -#define GL_PROXY_TEXTURE_COLOR_TABLE_SGI 0x80BD -#endif - -#ifndef GL_EXT_cmyka -#define GL_CMYK_EXT 0x800C -#define GL_CMYKA_EXT 0x800D -#define GL_PACK_CMYK_HINT_EXT 0x800E -#define GL_UNPACK_CMYK_HINT_EXT 0x800F -#endif - -#ifndef GL_EXT_texture_object -#define GL_TEXTURE_PRIORITY_EXT 0x8066 -#define GL_TEXTURE_RESIDENT_EXT 0x8067 -#define GL_TEXTURE_1D_BINDING_EXT 0x8068 -#define GL_TEXTURE_2D_BINDING_EXT 0x8069 -#define GL_TEXTURE_3D_BINDING_EXT 0x806A -#endif - -#ifndef GL_SGIS_detail_texture -#define GL_DETAIL_TEXTURE_2D_SGIS 0x8095 -#define GL_DETAIL_TEXTURE_2D_BINDING_SGIS 0x8096 -#define GL_LINEAR_DETAIL_SGIS 0x8097 -#define GL_LINEAR_DETAIL_ALPHA_SGIS 0x8098 -#define GL_LINEAR_DETAIL_COLOR_SGIS 0x8099 -#define GL_DETAIL_TEXTURE_LEVEL_SGIS 0x809A -#define GL_DETAIL_TEXTURE_MODE_SGIS 0x809B -#define GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS 0x809C -#endif - -#ifndef GL_SGIS_sharpen_texture -#define GL_LINEAR_SHARPEN_SGIS 0x80AD -#define GL_LINEAR_SHARPEN_ALPHA_SGIS 0x80AE -#define GL_LINEAR_SHARPEN_COLOR_SGIS 0x80AF -#define GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS 0x80B0 -#endif - -#ifndef GL_EXT_packed_pixels -#define GL_UNSIGNED_BYTE_3_3_2_EXT 0x8032 -#define GL_UNSIGNED_SHORT_4_4_4_4_EXT 0x8033 -#define GL_UNSIGNED_SHORT_5_5_5_1_EXT 0x8034 -#define GL_UNSIGNED_INT_8_8_8_8_EXT 0x8035 -#define GL_UNSIGNED_INT_10_10_10_2_EXT 0x8036 -#endif - -#ifndef GL_SGIS_texture_lod -#define GL_TEXTURE_MIN_LOD_SGIS 0x813A -#define GL_TEXTURE_MAX_LOD_SGIS 0x813B -#define GL_TEXTURE_BASE_LEVEL_SGIS 0x813C -#define GL_TEXTURE_MAX_LEVEL_SGIS 0x813D -#endif - -#ifndef GL_SGIS_multisample -#define GL_MULTISAMPLE_SGIS 0x809D -#define GL_SAMPLE_ALPHA_TO_MASK_SGIS 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_SGIS 0x809F -#define GL_SAMPLE_MASK_SGIS 0x80A0 -#define GL_1PASS_SGIS 0x80A1 -#define GL_2PASS_0_SGIS 0x80A2 -#define GL_2PASS_1_SGIS 0x80A3 -#define GL_4PASS_0_SGIS 0x80A4 -#define GL_4PASS_1_SGIS 0x80A5 -#define GL_4PASS_2_SGIS 0x80A6 -#define GL_4PASS_3_SGIS 0x80A7 -#define GL_SAMPLE_BUFFERS_SGIS 0x80A8 -#define GL_SAMPLES_SGIS 0x80A9 -#define GL_SAMPLE_MASK_VALUE_SGIS 0x80AA -#define GL_SAMPLE_MASK_INVERT_SGIS 0x80AB -#define GL_SAMPLE_PATTERN_SGIS 0x80AC -#endif - -#ifndef GL_EXT_rescale_normal -#define GL_RESCALE_NORMAL_EXT 0x803A -#endif - -#ifndef GL_EXT_vertex_array -#define GL_VERTEX_ARRAY_EXT 0x8074 -#define GL_NORMAL_ARRAY_EXT 0x8075 -#define GL_COLOR_ARRAY_EXT 0x8076 -#define GL_INDEX_ARRAY_EXT 0x8077 -#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078 -#define GL_EDGE_FLAG_ARRAY_EXT 0x8079 -#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A -#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B -#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C -#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D -#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E -#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F -#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080 -#define GL_COLOR_ARRAY_SIZE_EXT 0x8081 -#define GL_COLOR_ARRAY_TYPE_EXT 0x8082 -#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083 -#define GL_COLOR_ARRAY_COUNT_EXT 0x8084 -#define GL_INDEX_ARRAY_TYPE_EXT 0x8085 -#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086 -#define GL_INDEX_ARRAY_COUNT_EXT 0x8087 -#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088 -#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089 -#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A -#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B -#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C -#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D -#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E -#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F -#define GL_COLOR_ARRAY_POINTER_EXT 0x8090 -#define GL_INDEX_ARRAY_POINTER_EXT 0x8091 -#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092 -#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093 -#endif - -#ifndef GL_EXT_misc_attribute -#endif - -#ifndef GL_SGIS_generate_mipmap -#define GL_GENERATE_MIPMAP_SGIS 0x8191 -#define GL_GENERATE_MIPMAP_HINT_SGIS 0x8192 -#endif - -#ifndef GL_SGIX_clipmap -#define GL_LINEAR_CLIPMAP_LINEAR_SGIX 0x8170 -#define GL_TEXTURE_CLIPMAP_CENTER_SGIX 0x8171 -#define GL_TEXTURE_CLIPMAP_FRAME_SGIX 0x8172 -#define GL_TEXTURE_CLIPMAP_OFFSET_SGIX 0x8173 -#define GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8174 -#define GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX 0x8175 -#define GL_TEXTURE_CLIPMAP_DEPTH_SGIX 0x8176 -#define GL_MAX_CLIPMAP_DEPTH_SGIX 0x8177 -#define GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8178 -#define GL_NEAREST_CLIPMAP_NEAREST_SGIX 0x844D -#define GL_NEAREST_CLIPMAP_LINEAR_SGIX 0x844E -#define GL_LINEAR_CLIPMAP_NEAREST_SGIX 0x844F -#endif - -#ifndef GL_SGIX_shadow -#define GL_TEXTURE_COMPARE_SGIX 0x819A -#define GL_TEXTURE_COMPARE_OPERATOR_SGIX 0x819B -#define GL_TEXTURE_LEQUAL_R_SGIX 0x819C -#define GL_TEXTURE_GEQUAL_R_SGIX 0x819D -#endif - -#ifndef GL_SGIS_texture_edge_clamp -#define GL_CLAMP_TO_EDGE_SGIS 0x812F -#endif - -#ifndef GL_SGIS_texture_border_clamp -#define GL_CLAMP_TO_BORDER_SGIS 0x812D -#endif - -#ifndef GL_EXT_blend_minmax -#define GL_FUNC_ADD_EXT 0x8006 -#define GL_MIN_EXT 0x8007 -#define GL_MAX_EXT 0x8008 -#define GL_BLEND_EQUATION_EXT 0x8009 -#endif - -#ifndef GL_EXT_blend_subtract -#define GL_FUNC_SUBTRACT_EXT 0x800A -#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B -#endif - -#ifndef GL_EXT_blend_logic_op -#endif - -#ifndef GL_SGIX_interlace -#define GL_INTERLACE_SGIX 0x8094 -#endif - -#ifndef GL_SGIX_pixel_tiles -#define GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX 0x813E -#define GL_PIXEL_TILE_CACHE_INCREMENT_SGIX 0x813F -#define GL_PIXEL_TILE_WIDTH_SGIX 0x8140 -#define GL_PIXEL_TILE_HEIGHT_SGIX 0x8141 -#define GL_PIXEL_TILE_GRID_WIDTH_SGIX 0x8142 -#define GL_PIXEL_TILE_GRID_HEIGHT_SGIX 0x8143 -#define GL_PIXEL_TILE_GRID_DEPTH_SGIX 0x8144 -#define GL_PIXEL_TILE_CACHE_SIZE_SGIX 0x8145 -#endif - -#ifndef GL_SGIS_texture_select -#define GL_DUAL_ALPHA4_SGIS 0x8110 -#define GL_DUAL_ALPHA8_SGIS 0x8111 -#define GL_DUAL_ALPHA12_SGIS 0x8112 -#define GL_DUAL_ALPHA16_SGIS 0x8113 -#define GL_DUAL_LUMINANCE4_SGIS 0x8114 -#define GL_DUAL_LUMINANCE8_SGIS 0x8115 -#define GL_DUAL_LUMINANCE12_SGIS 0x8116 -#define GL_DUAL_LUMINANCE16_SGIS 0x8117 -#define GL_DUAL_INTENSITY4_SGIS 0x8118 -#define GL_DUAL_INTENSITY8_SGIS 0x8119 -#define GL_DUAL_INTENSITY12_SGIS 0x811A -#define GL_DUAL_INTENSITY16_SGIS 0x811B -#define GL_DUAL_LUMINANCE_ALPHA4_SGIS 0x811C -#define GL_DUAL_LUMINANCE_ALPHA8_SGIS 0x811D -#define GL_QUAD_ALPHA4_SGIS 0x811E -#define GL_QUAD_ALPHA8_SGIS 0x811F -#define GL_QUAD_LUMINANCE4_SGIS 0x8120 -#define GL_QUAD_LUMINANCE8_SGIS 0x8121 -#define GL_QUAD_INTENSITY4_SGIS 0x8122 -#define GL_QUAD_INTENSITY8_SGIS 0x8123 -#define GL_DUAL_TEXTURE_SELECT_SGIS 0x8124 -#define GL_QUAD_TEXTURE_SELECT_SGIS 0x8125 -#endif - -#ifndef GL_SGIX_sprite -#define GL_SPRITE_SGIX 0x8148 -#define GL_SPRITE_MODE_SGIX 0x8149 -#define GL_SPRITE_AXIS_SGIX 0x814A -#define GL_SPRITE_TRANSLATION_SGIX 0x814B -#define GL_SPRITE_AXIAL_SGIX 0x814C -#define GL_SPRITE_OBJECT_ALIGNED_SGIX 0x814D -#define GL_SPRITE_EYE_ALIGNED_SGIX 0x814E -#endif - -#ifndef GL_SGIX_texture_multi_buffer -#define GL_TEXTURE_MULTI_BUFFER_HINT_SGIX 0x812E -#endif - -#ifndef GL_EXT_point_parameters -#define GL_POINT_SIZE_MIN_EXT 0x8126 -#define GL_POINT_SIZE_MAX_EXT 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128 -#define GL_DISTANCE_ATTENUATION_EXT 0x8129 -#endif - -#ifndef GL_SGIS_point_parameters -#define GL_POINT_SIZE_MIN_SGIS 0x8126 -#define GL_POINT_SIZE_MAX_SGIS 0x8127 -#define GL_POINT_FADE_THRESHOLD_SIZE_SGIS 0x8128 -#define GL_DISTANCE_ATTENUATION_SGIS 0x8129 -#endif - -#ifndef GL_SGIX_instruments -#define GL_INSTRUMENT_BUFFER_POINTER_SGIX 0x8180 -#define GL_INSTRUMENT_MEASUREMENTS_SGIX 0x8181 -#endif - -#ifndef GL_SGIX_texture_scale_bias -#define GL_POST_TEXTURE_FILTER_BIAS_SGIX 0x8179 -#define GL_POST_TEXTURE_FILTER_SCALE_SGIX 0x817A -#define GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX 0x817B -#define GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX 0x817C -#endif - -#ifndef GL_SGIX_framezoom -#define GL_FRAMEZOOM_SGIX 0x818B -#define GL_FRAMEZOOM_FACTOR_SGIX 0x818C -#define GL_MAX_FRAMEZOOM_FACTOR_SGIX 0x818D -#endif - -#ifndef GL_SGIX_tag_sample_buffer -#endif - -#ifndef GL_FfdMaskSGIX -#define GL_TEXTURE_DEFORMATION_BIT_SGIX 0x00000001 -#define GL_GEOMETRY_DEFORMATION_BIT_SGIX 0x00000002 -#endif - -#ifndef GL_SGIX_polynomial_ffd -#define GL_GEOMETRY_DEFORMATION_SGIX 0x8194 -#define GL_TEXTURE_DEFORMATION_SGIX 0x8195 -#define GL_DEFORMATIONS_MASK_SGIX 0x8196 -#define GL_MAX_DEFORMATION_ORDER_SGIX 0x8197 -#endif - -#ifndef GL_SGIX_reference_plane -#define GL_REFERENCE_PLANE_SGIX 0x817D -#define GL_REFERENCE_PLANE_EQUATION_SGIX 0x817E -#endif - -#ifndef GL_SGIX_flush_raster -#endif - -#ifndef GL_SGIX_depth_texture -#define GL_DEPTH_COMPONENT16_SGIX 0x81A5 -#define GL_DEPTH_COMPONENT24_SGIX 0x81A6 -#define GL_DEPTH_COMPONENT32_SGIX 0x81A7 -#endif - -#ifndef GL_SGIS_fog_function -#define GL_FOG_FUNC_SGIS 0x812A -#define GL_FOG_FUNC_POINTS_SGIS 0x812B -#define GL_MAX_FOG_FUNC_POINTS_SGIS 0x812C -#endif - -#ifndef GL_SGIX_fog_offset -#define GL_FOG_OFFSET_SGIX 0x8198 -#define GL_FOG_OFFSET_VALUE_SGIX 0x8199 -#endif - -#ifndef GL_HP_image_transform -#define GL_IMAGE_SCALE_X_HP 0x8155 -#define GL_IMAGE_SCALE_Y_HP 0x8156 -#define GL_IMAGE_TRANSLATE_X_HP 0x8157 -#define GL_IMAGE_TRANSLATE_Y_HP 0x8158 -#define GL_IMAGE_ROTATE_ANGLE_HP 0x8159 -#define GL_IMAGE_ROTATE_ORIGIN_X_HP 0x815A -#define GL_IMAGE_ROTATE_ORIGIN_Y_HP 0x815B -#define GL_IMAGE_MAG_FILTER_HP 0x815C -#define GL_IMAGE_MIN_FILTER_HP 0x815D -#define GL_IMAGE_CUBIC_WEIGHT_HP 0x815E -#define GL_CUBIC_HP 0x815F -#define GL_AVERAGE_HP 0x8160 -#define GL_IMAGE_TRANSFORM_2D_HP 0x8161 -#define GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8162 -#define GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8163 -#endif - -#ifndef GL_HP_convolution_border_modes -#define GL_IGNORE_BORDER_HP 0x8150 -#define GL_CONSTANT_BORDER_HP 0x8151 -#define GL_REPLICATE_BORDER_HP 0x8153 -#define GL_CONVOLUTION_BORDER_COLOR_HP 0x8154 -#endif - -#ifndef GL_INGR_palette_buffer -#endif - -#ifndef GL_SGIX_texture_add_env -#define GL_TEXTURE_ENV_BIAS_SGIX 0x80BE -#endif - -#ifndef GL_EXT_color_subtable -#endif - -#ifndef GL_PGI_vertex_hints -#define GL_VERTEX_DATA_HINT_PGI 0x1A22A -#define GL_VERTEX_CONSISTENT_HINT_PGI 0x1A22B -#define GL_MATERIAL_SIDE_HINT_PGI 0x1A22C -#define GL_MAX_VERTEX_HINT_PGI 0x1A22D -#define GL_COLOR3_BIT_PGI 0x00010000 -#define GL_COLOR4_BIT_PGI 0x00020000 -#define GL_EDGEFLAG_BIT_PGI 0x00040000 -#define GL_INDEX_BIT_PGI 0x00080000 -#define GL_MAT_AMBIENT_BIT_PGI 0x00100000 -#define GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI 0x00200000 -#define GL_MAT_DIFFUSE_BIT_PGI 0x00400000 -#define GL_MAT_EMISSION_BIT_PGI 0x00800000 -#define GL_MAT_COLOR_INDEXES_BIT_PGI 0x01000000 -#define GL_MAT_SHININESS_BIT_PGI 0x02000000 -#define GL_MAT_SPECULAR_BIT_PGI 0x04000000 -#define GL_NORMAL_BIT_PGI 0x08000000 -#define GL_TEXCOORD1_BIT_PGI 0x10000000 -#define GL_TEXCOORD2_BIT_PGI 0x20000000 -#define GL_TEXCOORD3_BIT_PGI 0x40000000 -#define GL_TEXCOORD4_BIT_PGI 0x80000000 -#define GL_VERTEX23_BIT_PGI 0x00000004 -#define GL_VERTEX4_BIT_PGI 0x00000008 -#endif - -#ifndef GL_PGI_misc_hints -#define GL_PREFER_DOUBLEBUFFER_HINT_PGI 0x1A1F8 -#define GL_CONSERVE_MEMORY_HINT_PGI 0x1A1FD -#define GL_RECLAIM_MEMORY_HINT_PGI 0x1A1FE -#define GL_NATIVE_GRAPHICS_HANDLE_PGI 0x1A202 -#define GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI 0x1A203 -#define GL_NATIVE_GRAPHICS_END_HINT_PGI 0x1A204 -#define GL_ALWAYS_FAST_HINT_PGI 0x1A20C -#define GL_ALWAYS_SOFT_HINT_PGI 0x1A20D -#define GL_ALLOW_DRAW_OBJ_HINT_PGI 0x1A20E -#define GL_ALLOW_DRAW_WIN_HINT_PGI 0x1A20F -#define GL_ALLOW_DRAW_FRG_HINT_PGI 0x1A210 -#define GL_ALLOW_DRAW_MEM_HINT_PGI 0x1A211 -#define GL_STRICT_DEPTHFUNC_HINT_PGI 0x1A216 -#define GL_STRICT_LIGHTING_HINT_PGI 0x1A217 -#define GL_STRICT_SCISSOR_HINT_PGI 0x1A218 -#define GL_FULL_STIPPLE_HINT_PGI 0x1A219 -#define GL_CLIP_NEAR_HINT_PGI 0x1A220 -#define GL_CLIP_FAR_HINT_PGI 0x1A221 -#define GL_WIDE_LINE_HINT_PGI 0x1A222 -#define GL_BACK_NORMALS_HINT_PGI 0x1A223 -#endif - -#ifndef GL_EXT_paletted_texture -#define GL_COLOR_INDEX1_EXT 0x80E2 -#define GL_COLOR_INDEX2_EXT 0x80E3 -#define GL_COLOR_INDEX4_EXT 0x80E4 -#define GL_COLOR_INDEX8_EXT 0x80E5 -#define GL_COLOR_INDEX12_EXT 0x80E6 -#define GL_COLOR_INDEX16_EXT 0x80E7 -#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED -#endif - -#ifndef GL_EXT_clip_volume_hint -#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0 -#endif - -#ifndef GL_SGIX_list_priority -#define GL_LIST_PRIORITY_SGIX 0x8182 -#endif - -#ifndef GL_SGIX_ir_instrument1 -#define GL_IR_INSTRUMENT1_SGIX 0x817F -#endif - -#ifndef GL_SGIX_calligraphic_fragment -#define GL_CALLIGRAPHIC_FRAGMENT_SGIX 0x8183 -#endif - -#ifndef GL_SGIX_texture_lod_bias -#define GL_TEXTURE_LOD_BIAS_S_SGIX 0x818E -#define GL_TEXTURE_LOD_BIAS_T_SGIX 0x818F -#define GL_TEXTURE_LOD_BIAS_R_SGIX 0x8190 -#endif - -#ifndef GL_SGIX_shadow_ambient -#define GL_SHADOW_AMBIENT_SGIX 0x80BF -#endif - -#ifndef GL_EXT_index_texture -#endif - -#ifndef GL_EXT_index_material -#define GL_INDEX_MATERIAL_EXT 0x81B8 -#define GL_INDEX_MATERIAL_PARAMETER_EXT 0x81B9 -#define GL_INDEX_MATERIAL_FACE_EXT 0x81BA -#endif - -#ifndef GL_EXT_index_func -#define GL_INDEX_TEST_EXT 0x81B5 -#define GL_INDEX_TEST_FUNC_EXT 0x81B6 -#define GL_INDEX_TEST_REF_EXT 0x81B7 -#endif - -#ifndef GL_EXT_index_array_formats -#define GL_IUI_V2F_EXT 0x81AD -#define GL_IUI_V3F_EXT 0x81AE -#define GL_IUI_N3F_V2F_EXT 0x81AF -#define GL_IUI_N3F_V3F_EXT 0x81B0 -#define GL_T2F_IUI_V2F_EXT 0x81B1 -#define GL_T2F_IUI_V3F_EXT 0x81B2 -#define GL_T2F_IUI_N3F_V2F_EXT 0x81B3 -#define GL_T2F_IUI_N3F_V3F_EXT 0x81B4 -#endif - -#ifndef GL_EXT_compiled_vertex_array -#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8 -#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9 -#endif - -#ifndef GL_EXT_cull_vertex -#define GL_CULL_VERTEX_EXT 0x81AA -#define GL_CULL_VERTEX_EYE_POSITION_EXT 0x81AB -#define GL_CULL_VERTEX_OBJECT_POSITION_EXT 0x81AC -#endif - -#ifndef GL_SGIX_ycrcb -#define GL_YCRCB_422_SGIX 0x81BB -#define GL_YCRCB_444_SGIX 0x81BC -#endif - -#ifndef GL_SGIX_fragment_lighting -#define GL_FRAGMENT_LIGHTING_SGIX 0x8400 -#define GL_FRAGMENT_COLOR_MATERIAL_SGIX 0x8401 -#define GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX 0x8402 -#define GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX 0x8403 -#define GL_MAX_FRAGMENT_LIGHTS_SGIX 0x8404 -#define GL_MAX_ACTIVE_LIGHTS_SGIX 0x8405 -#define GL_CURRENT_RASTER_NORMAL_SGIX 0x8406 -#define GL_LIGHT_ENV_MODE_SGIX 0x8407 -#define GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX 0x8408 -#define GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX 0x8409 -#define GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX 0x840A -#define GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX 0x840B -#define GL_FRAGMENT_LIGHT0_SGIX 0x840C -#define GL_FRAGMENT_LIGHT1_SGIX 0x840D -#define GL_FRAGMENT_LIGHT2_SGIX 0x840E -#define GL_FRAGMENT_LIGHT3_SGIX 0x840F -#define GL_FRAGMENT_LIGHT4_SGIX 0x8410 -#define GL_FRAGMENT_LIGHT5_SGIX 0x8411 -#define GL_FRAGMENT_LIGHT6_SGIX 0x8412 -#define GL_FRAGMENT_LIGHT7_SGIX 0x8413 -#endif - -#ifndef GL_IBM_rasterpos_clip -#define GL_RASTER_POSITION_UNCLIPPED_IBM 0x19262 -#endif - -#ifndef GL_HP_texture_lighting -#define GL_TEXTURE_LIGHTING_MODE_HP 0x8167 -#define GL_TEXTURE_POST_SPECULAR_HP 0x8168 -#define GL_TEXTURE_PRE_SPECULAR_HP 0x8169 -#endif - -#ifndef GL_EXT_draw_range_elements -#define GL_MAX_ELEMENTS_VERTICES_EXT 0x80E8 -#define GL_MAX_ELEMENTS_INDICES_EXT 0x80E9 -#endif - -#ifndef GL_WIN_phong_shading -#define GL_PHONG_WIN 0x80EA -#define GL_PHONG_HINT_WIN 0x80EB -#endif - -#ifndef GL_WIN_specular_fog -#define GL_FOG_SPECULAR_TEXTURE_WIN 0x80EC -#endif - -#ifndef GL_EXT_light_texture -#define GL_FRAGMENT_MATERIAL_EXT 0x8349 -#define GL_FRAGMENT_NORMAL_EXT 0x834A -#define GL_FRAGMENT_COLOR_EXT 0x834C -#define GL_ATTENUATION_EXT 0x834D -#define GL_SHADOW_ATTENUATION_EXT 0x834E -#define GL_TEXTURE_APPLICATION_MODE_EXT 0x834F -#define GL_TEXTURE_LIGHT_EXT 0x8350 -#define GL_TEXTURE_MATERIAL_FACE_EXT 0x8351 -#define GL_TEXTURE_MATERIAL_PARAMETER_EXT 0x8352 -/* reuse GL_FRAGMENT_DEPTH_EXT */ -#endif - -#ifndef GL_SGIX_blend_alpha_minmax -#define GL_ALPHA_MIN_SGIX 0x8320 -#define GL_ALPHA_MAX_SGIX 0x8321 -#endif - -#ifndef GL_SGIX_impact_pixel_texture -#define GL_PIXEL_TEX_GEN_Q_CEILING_SGIX 0x8184 -#define GL_PIXEL_TEX_GEN_Q_ROUND_SGIX 0x8185 -#define GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX 0x8186 -#define GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX 0x8187 -#define GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX 0x8188 -#define GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX 0x8189 -#define GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX 0x818A -#endif - -#ifndef GL_EXT_bgra -#define GL_BGR_EXT 0x80E0 -#define GL_BGRA_EXT 0x80E1 -#endif - -#ifndef GL_SGIX_async -#define GL_ASYNC_MARKER_SGIX 0x8329 -#endif - -#ifndef GL_SGIX_async_pixel -#define GL_ASYNC_TEX_IMAGE_SGIX 0x835C -#define GL_ASYNC_DRAW_PIXELS_SGIX 0x835D -#define GL_ASYNC_READ_PIXELS_SGIX 0x835E -#define GL_MAX_ASYNC_TEX_IMAGE_SGIX 0x835F -#define GL_MAX_ASYNC_DRAW_PIXELS_SGIX 0x8360 -#define GL_MAX_ASYNC_READ_PIXELS_SGIX 0x8361 -#endif - -#ifndef GL_SGIX_async_histogram -#define GL_ASYNC_HISTOGRAM_SGIX 0x832C -#define GL_MAX_ASYNC_HISTOGRAM_SGIX 0x832D -#endif - -#ifndef GL_INTEL_texture_scissor -#endif - -#ifndef GL_INTEL_parallel_arrays -#define GL_PARALLEL_ARRAYS_INTEL 0x83F4 -#define GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL 0x83F5 -#define GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL 0x83F6 -#define GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL 0x83F7 -#define GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL 0x83F8 -#endif - -#ifndef GL_HP_occlusion_test -#define GL_OCCLUSION_TEST_HP 0x8165 -#define GL_OCCLUSION_TEST_RESULT_HP 0x8166 -#endif - -#ifndef GL_EXT_pixel_transform -#define GL_PIXEL_TRANSFORM_2D_EXT 0x8330 -#define GL_PIXEL_MAG_FILTER_EXT 0x8331 -#define GL_PIXEL_MIN_FILTER_EXT 0x8332 -#define GL_PIXEL_CUBIC_WEIGHT_EXT 0x8333 -#define GL_CUBIC_EXT 0x8334 -#define GL_AVERAGE_EXT 0x8335 -#define GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8336 -#define GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8337 -#define GL_PIXEL_TRANSFORM_2D_MATRIX_EXT 0x8338 -#endif - -#ifndef GL_EXT_pixel_transform_color_table -#endif - -#ifndef GL_EXT_shared_texture_palette -#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB -#endif - -#ifndef GL_EXT_separate_specular_color -#define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8 -#define GL_SINGLE_COLOR_EXT 0x81F9 -#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA -#endif - -#ifndef GL_EXT_secondary_color -#define GL_COLOR_SUM_EXT 0x8458 -#define GL_CURRENT_SECONDARY_COLOR_EXT 0x8459 -#define GL_SECONDARY_COLOR_ARRAY_SIZE_EXT 0x845A -#define GL_SECONDARY_COLOR_ARRAY_TYPE_EXT 0x845B -#define GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT 0x845C -#define GL_SECONDARY_COLOR_ARRAY_POINTER_EXT 0x845D -#define GL_SECONDARY_COLOR_ARRAY_EXT 0x845E -#endif - -#ifndef GL_EXT_texture_perturb_normal -#define GL_PERTURB_EXT 0x85AE -#define GL_TEXTURE_NORMAL_EXT 0x85AF -#endif - -#ifndef GL_EXT_multi_draw_arrays -#endif - -#ifndef GL_EXT_fog_coord -#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450 -#define GL_FOG_COORDINATE_EXT 0x8451 -#define GL_FRAGMENT_DEPTH_EXT 0x8452 -#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453 -#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454 -#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455 -#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456 -#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457 -#endif - -#ifndef GL_REND_screen_coordinates -#define GL_SCREEN_COORDINATES_REND 0x8490 -#define GL_INVERTED_SCREEN_W_REND 0x8491 -#endif - -#ifndef GL_EXT_coordinate_frame -#define GL_TANGENT_ARRAY_EXT 0x8439 -#define GL_BINORMAL_ARRAY_EXT 0x843A -#define GL_CURRENT_TANGENT_EXT 0x843B -#define GL_CURRENT_BINORMAL_EXT 0x843C -#define GL_TANGENT_ARRAY_TYPE_EXT 0x843E -#define GL_TANGENT_ARRAY_STRIDE_EXT 0x843F -#define GL_BINORMAL_ARRAY_TYPE_EXT 0x8440 -#define GL_BINORMAL_ARRAY_STRIDE_EXT 0x8441 -#define GL_TANGENT_ARRAY_POINTER_EXT 0x8442 -#define GL_BINORMAL_ARRAY_POINTER_EXT 0x8443 -#define GL_MAP1_TANGENT_EXT 0x8444 -#define GL_MAP2_TANGENT_EXT 0x8445 -#define GL_MAP1_BINORMAL_EXT 0x8446 -#define GL_MAP2_BINORMAL_EXT 0x8447 -#endif - -#ifndef GL_EXT_texture_env_combine -#define GL_COMBINE_EXT 0x8570 -#define GL_COMBINE_RGB_EXT 0x8571 -#define GL_COMBINE_ALPHA_EXT 0x8572 -#define GL_RGB_SCALE_EXT 0x8573 -#define GL_ADD_SIGNED_EXT 0x8574 -#define GL_INTERPOLATE_EXT 0x8575 -#define GL_CONSTANT_EXT 0x8576 -#define GL_PRIMARY_COLOR_EXT 0x8577 -#define GL_PREVIOUS_EXT 0x8578 -#define GL_SOURCE0_RGB_EXT 0x8580 -#define GL_SOURCE1_RGB_EXT 0x8581 -#define GL_SOURCE2_RGB_EXT 0x8582 -#define GL_SOURCE0_ALPHA_EXT 0x8588 -#define GL_SOURCE1_ALPHA_EXT 0x8589 -#define GL_SOURCE2_ALPHA_EXT 0x858A -#define GL_OPERAND0_RGB_EXT 0x8590 -#define GL_OPERAND1_RGB_EXT 0x8591 -#define GL_OPERAND2_RGB_EXT 0x8592 -#define GL_OPERAND0_ALPHA_EXT 0x8598 -#define GL_OPERAND1_ALPHA_EXT 0x8599 -#define GL_OPERAND2_ALPHA_EXT 0x859A -#endif - -#ifndef GL_APPLE_specular_vector -#define GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE 0x85B0 -#endif - -#ifndef GL_APPLE_transform_hint -#define GL_TRANSFORM_HINT_APPLE 0x85B1 -#endif - -#ifndef GL_SGIX_fog_scale -#define GL_FOG_SCALE_SGIX 0x81FC -#define GL_FOG_SCALE_VALUE_SGIX 0x81FD -#endif - -#ifndef GL_SUNX_constant_data -#define GL_UNPACK_CONSTANT_DATA_SUNX 0x81D5 -#define GL_TEXTURE_CONSTANT_DATA_SUNX 0x81D6 -#endif - -#ifndef GL_SUN_global_alpha -#define GL_GLOBAL_ALPHA_SUN 0x81D9 -#define GL_GLOBAL_ALPHA_FACTOR_SUN 0x81DA -#endif - -#ifndef GL_SUN_triangle_list -#define GL_RESTART_SUN 0x0001 -#define GL_REPLACE_MIDDLE_SUN 0x0002 -#define GL_REPLACE_OLDEST_SUN 0x0003 -#define GL_TRIANGLE_LIST_SUN 0x81D7 -#define GL_REPLACEMENT_CODE_SUN 0x81D8 -#define GL_REPLACEMENT_CODE_ARRAY_SUN 0x85C0 -#define GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN 0x85C1 -#define GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN 0x85C2 -#define GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN 0x85C3 -#define GL_R1UI_V3F_SUN 0x85C4 -#define GL_R1UI_C4UB_V3F_SUN 0x85C5 -#define GL_R1UI_C3F_V3F_SUN 0x85C6 -#define GL_R1UI_N3F_V3F_SUN 0x85C7 -#define GL_R1UI_C4F_N3F_V3F_SUN 0x85C8 -#define GL_R1UI_T2F_V3F_SUN 0x85C9 -#define GL_R1UI_T2F_N3F_V3F_SUN 0x85CA -#define GL_R1UI_T2F_C4F_N3F_V3F_SUN 0x85CB -#endif - -#ifndef GL_SUN_vertex -#endif - -#ifndef GL_EXT_blend_func_separate -#define GL_BLEND_DST_RGB_EXT 0x80C8 -#define GL_BLEND_SRC_RGB_EXT 0x80C9 -#define GL_BLEND_DST_ALPHA_EXT 0x80CA -#define GL_BLEND_SRC_ALPHA_EXT 0x80CB -#endif - -#ifndef GL_INGR_color_clamp -#define GL_RED_MIN_CLAMP_INGR 0x8560 -#define GL_GREEN_MIN_CLAMP_INGR 0x8561 -#define GL_BLUE_MIN_CLAMP_INGR 0x8562 -#define GL_ALPHA_MIN_CLAMP_INGR 0x8563 -#define GL_RED_MAX_CLAMP_INGR 0x8564 -#define GL_GREEN_MAX_CLAMP_INGR 0x8565 -#define GL_BLUE_MAX_CLAMP_INGR 0x8566 -#define GL_ALPHA_MAX_CLAMP_INGR 0x8567 -#endif - -#ifndef GL_INGR_interlace_read -#define GL_INTERLACE_READ_INGR 0x8568 -#endif - -#ifndef GL_EXT_stencil_wrap -#define GL_INCR_WRAP_EXT 0x8507 -#define GL_DECR_WRAP_EXT 0x8508 -#endif - -#ifndef GL_EXT_422_pixels -#define GL_422_EXT 0x80CC -#define GL_422_REV_EXT 0x80CD -#define GL_422_AVERAGE_EXT 0x80CE -#define GL_422_REV_AVERAGE_EXT 0x80CF -#endif - -#ifndef GL_NV_texgen_reflection -#define GL_NORMAL_MAP_NV 0x8511 -#define GL_REFLECTION_MAP_NV 0x8512 -#endif - -#ifndef GL_EXT_texture_cube_map -#define GL_NORMAL_MAP_EXT 0x8511 -#define GL_REFLECTION_MAP_EXT 0x8512 -#define GL_TEXTURE_CUBE_MAP_EXT 0x8513 -#define GL_TEXTURE_BINDING_CUBE_MAP_EXT 0x8514 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT 0x8515 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT 0x8516 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT 0x8517 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT 0x8518 -#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT 0x8519 -#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT 0x851A -#define GL_PROXY_TEXTURE_CUBE_MAP_EXT 0x851B -#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT 0x851C -#endif - -#ifndef GL_SUN_convolution_border_modes -#define GL_WRAP_BORDER_SUN 0x81D4 -#endif - -#ifndef GL_EXT_texture_env_add -#endif - -#ifndef GL_EXT_texture_lod_bias -#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD -#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500 -#define GL_TEXTURE_LOD_BIAS_EXT 0x8501 -#endif - -#ifndef GL_EXT_texture_filter_anisotropic -#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE -#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF -#endif - -#ifndef GL_EXT_vertex_weighting -#define GL_MODELVIEW0_STACK_DEPTH_EXT GL_MODELVIEW_STACK_DEPTH -#define GL_MODELVIEW1_STACK_DEPTH_EXT 0x8502 -#define GL_MODELVIEW0_MATRIX_EXT GL_MODELVIEW_MATRIX -#define GL_MODELVIEW1_MATRIX_EXT 0x8506 -#define GL_VERTEX_WEIGHTING_EXT 0x8509 -#define GL_MODELVIEW0_EXT GL_MODELVIEW -#define GL_MODELVIEW1_EXT 0x850A -#define GL_CURRENT_VERTEX_WEIGHT_EXT 0x850B -#define GL_VERTEX_WEIGHT_ARRAY_EXT 0x850C -#define GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT 0x850D -#define GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT 0x850E -#define GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT 0x850F -#define GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT 0x8510 -#endif - -#ifndef GL_NV_light_max_exponent -#define GL_MAX_SHININESS_NV 0x8504 -#define GL_MAX_SPOT_EXPONENT_NV 0x8505 -#endif - -#ifndef GL_NV_vertex_array_range -#define GL_VERTEX_ARRAY_RANGE_NV 0x851D -#define GL_VERTEX_ARRAY_RANGE_LENGTH_NV 0x851E -#define GL_VERTEX_ARRAY_RANGE_VALID_NV 0x851F -#define GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV 0x8520 -#define GL_VERTEX_ARRAY_RANGE_POINTER_NV 0x8521 -#endif - -#ifndef GL_NV_register_combiners -#define GL_REGISTER_COMBINERS_NV 0x8522 -#define GL_VARIABLE_A_NV 0x8523 -#define GL_VARIABLE_B_NV 0x8524 -#define GL_VARIABLE_C_NV 0x8525 -#define GL_VARIABLE_D_NV 0x8526 -#define GL_VARIABLE_E_NV 0x8527 -#define GL_VARIABLE_F_NV 0x8528 -#define GL_VARIABLE_G_NV 0x8529 -#define GL_CONSTANT_COLOR0_NV 0x852A -#define GL_CONSTANT_COLOR1_NV 0x852B -#define GL_PRIMARY_COLOR_NV 0x852C -#define GL_SECONDARY_COLOR_NV 0x852D -#define GL_SPARE0_NV 0x852E -#define GL_SPARE1_NV 0x852F -#define GL_DISCARD_NV 0x8530 -#define GL_E_TIMES_F_NV 0x8531 -#define GL_SPARE0_PLUS_SECONDARY_COLOR_NV 0x8532 -#define GL_UNSIGNED_IDENTITY_NV 0x8536 -#define GL_UNSIGNED_INVERT_NV 0x8537 -#define GL_EXPAND_NORMAL_NV 0x8538 -#define GL_EXPAND_NEGATE_NV 0x8539 -#define GL_HALF_BIAS_NORMAL_NV 0x853A -#define GL_HALF_BIAS_NEGATE_NV 0x853B -#define GL_SIGNED_IDENTITY_NV 0x853C -#define GL_SIGNED_NEGATE_NV 0x853D -#define GL_SCALE_BY_TWO_NV 0x853E -#define GL_SCALE_BY_FOUR_NV 0x853F -#define GL_SCALE_BY_ONE_HALF_NV 0x8540 -#define GL_BIAS_BY_NEGATIVE_ONE_HALF_NV 0x8541 -#define GL_COMBINER_INPUT_NV 0x8542 -#define GL_COMBINER_MAPPING_NV 0x8543 -#define GL_COMBINER_COMPONENT_USAGE_NV 0x8544 -#define GL_COMBINER_AB_DOT_PRODUCT_NV 0x8545 -#define GL_COMBINER_CD_DOT_PRODUCT_NV 0x8546 -#define GL_COMBINER_MUX_SUM_NV 0x8547 -#define GL_COMBINER_SCALE_NV 0x8548 -#define GL_COMBINER_BIAS_NV 0x8549 -#define GL_COMBINER_AB_OUTPUT_NV 0x854A -#define GL_COMBINER_CD_OUTPUT_NV 0x854B -#define GL_COMBINER_SUM_OUTPUT_NV 0x854C -#define GL_MAX_GENERAL_COMBINERS_NV 0x854D -#define GL_NUM_GENERAL_COMBINERS_NV 0x854E -#define GL_COLOR_SUM_CLAMP_NV 0x854F -#define GL_COMBINER0_NV 0x8550 -#define GL_COMBINER1_NV 0x8551 -#define GL_COMBINER2_NV 0x8552 -#define GL_COMBINER3_NV 0x8553 -#define GL_COMBINER4_NV 0x8554 -#define GL_COMBINER5_NV 0x8555 -#define GL_COMBINER6_NV 0x8556 -#define GL_COMBINER7_NV 0x8557 -/* reuse GL_TEXTURE0_ARB */ -/* reuse GL_TEXTURE1_ARB */ -/* reuse GL_ZERO */ -/* reuse GL_NONE */ -/* reuse GL_FOG */ -#endif - -#ifndef GL_NV_fog_distance -#define GL_FOG_DISTANCE_MODE_NV 0x855A -#define GL_EYE_RADIAL_NV 0x855B -#define GL_EYE_PLANE_ABSOLUTE_NV 0x855C -/* reuse GL_EYE_PLANE */ -#endif - -#ifndef GL_NV_texgen_emboss -#define GL_EMBOSS_LIGHT_NV 0x855D -#define GL_EMBOSS_CONSTANT_NV 0x855E -#define GL_EMBOSS_MAP_NV 0x855F -#endif - -#ifndef GL_NV_blend_square -#endif - -#ifndef GL_NV_texture_env_combine4 -#define GL_COMBINE4_NV 0x8503 -#define GL_SOURCE3_RGB_NV 0x8583 -#define GL_SOURCE3_ALPHA_NV 0x858B -#define GL_OPERAND3_RGB_NV 0x8593 -#define GL_OPERAND3_ALPHA_NV 0x859B -#endif - -#ifndef GL_MESA_resize_buffers -#endif - -#ifndef GL_MESA_window_pos -#endif - -#ifndef GL_EXT_texture_compression_s3tc -#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0 -#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1 -#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2 -#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3 -#endif - -#ifndef GL_IBM_cull_vertex -#define GL_CULL_VERTEX_IBM 103050 -#endif - -#ifndef GL_IBM_multimode_draw_arrays -#endif - -#ifndef GL_IBM_vertex_array_lists -#define GL_VERTEX_ARRAY_LIST_IBM 103070 -#define GL_NORMAL_ARRAY_LIST_IBM 103071 -#define GL_COLOR_ARRAY_LIST_IBM 103072 -#define GL_INDEX_ARRAY_LIST_IBM 103073 -#define GL_TEXTURE_COORD_ARRAY_LIST_IBM 103074 -#define GL_EDGE_FLAG_ARRAY_LIST_IBM 103075 -#define GL_FOG_COORDINATE_ARRAY_LIST_IBM 103076 -#define GL_SECONDARY_COLOR_ARRAY_LIST_IBM 103077 -#define GL_VERTEX_ARRAY_LIST_STRIDE_IBM 103080 -#define GL_NORMAL_ARRAY_LIST_STRIDE_IBM 103081 -#define GL_COLOR_ARRAY_LIST_STRIDE_IBM 103082 -#define GL_INDEX_ARRAY_LIST_STRIDE_IBM 103083 -#define GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM 103084 -#define GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM 103085 -#define GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM 103086 -#define GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM 103087 -#endif - -#ifndef GL_SGIX_subsample -#define GL_PACK_SUBSAMPLE_RATE_SGIX 0x85A0 -#define GL_UNPACK_SUBSAMPLE_RATE_SGIX 0x85A1 -#define GL_PIXEL_SUBSAMPLE_4444_SGIX 0x85A2 -#define GL_PIXEL_SUBSAMPLE_2424_SGIX 0x85A3 -#define GL_PIXEL_SUBSAMPLE_4242_SGIX 0x85A4 -#endif - -#ifndef GL_SGIX_ycrcb_subsample -#endif - -#ifndef GL_SGIX_ycrcba -#define GL_YCRCB_SGIX 0x8318 -#define GL_YCRCBA_SGIX 0x8319 -#endif - -#ifndef GL_SGI_depth_pass_instrument -#define GL_DEPTH_PASS_INSTRUMENT_SGIX 0x8310 -#define GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX 0x8311 -#define GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX 0x8312 -#endif - -#ifndef GL_3DFX_texture_compression_FXT1 -#define GL_COMPRESSED_RGB_FXT1_3DFX 0x86B0 -#define GL_COMPRESSED_RGBA_FXT1_3DFX 0x86B1 -#endif - -#ifndef GL_3DFX_multisample -#define GL_MULTISAMPLE_3DFX 0x86B2 -#define GL_SAMPLE_BUFFERS_3DFX 0x86B3 -#define GL_SAMPLES_3DFX 0x86B4 -#define GL_MULTISAMPLE_BIT_3DFX 0x20000000 -#endif - -#ifndef GL_3DFX_tbuffer -#endif - -#ifndef GL_EXT_multisample -#define GL_MULTISAMPLE_EXT 0x809D -#define GL_SAMPLE_ALPHA_TO_MASK_EXT 0x809E -#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F -#define GL_SAMPLE_MASK_EXT 0x80A0 -#define GL_1PASS_EXT 0x80A1 -#define GL_2PASS_0_EXT 0x80A2 -#define GL_2PASS_1_EXT 0x80A3 -#define GL_4PASS_0_EXT 0x80A4 -#define GL_4PASS_1_EXT 0x80A5 -#define GL_4PASS_2_EXT 0x80A6 -#define GL_4PASS_3_EXT 0x80A7 -#define GL_SAMPLE_BUFFERS_EXT 0x80A8 -#define GL_SAMPLES_EXT 0x80A9 -#define GL_SAMPLE_MASK_VALUE_EXT 0x80AA -#define GL_SAMPLE_MASK_INVERT_EXT 0x80AB -#define GL_SAMPLE_PATTERN_EXT 0x80AC -#define GL_MULTISAMPLE_BIT_EXT 0x20000000 -#endif - -#ifndef GL_SGIX_vertex_preclip -#define GL_VERTEX_PRECLIP_SGIX 0x83EE -#define GL_VERTEX_PRECLIP_HINT_SGIX 0x83EF -#endif - -#ifndef GL_SGIX_convolution_accuracy -#define GL_CONVOLUTION_HINT_SGIX 0x8316 -#endif - -#ifndef GL_SGIX_resample -#define GL_PACK_RESAMPLE_SGIX 0x842C -#define GL_UNPACK_RESAMPLE_SGIX 0x842D -#define GL_RESAMPLE_REPLICATE_SGIX 0x842E -#define GL_RESAMPLE_ZERO_FILL_SGIX 0x842F -#define GL_RESAMPLE_DECIMATE_SGIX 0x8430 -#endif - -#ifndef GL_SGIS_point_line_texgen -#define GL_EYE_DISTANCE_TO_POINT_SGIS 0x81F0 -#define GL_OBJECT_DISTANCE_TO_POINT_SGIS 0x81F1 -#define GL_EYE_DISTANCE_TO_LINE_SGIS 0x81F2 -#define GL_OBJECT_DISTANCE_TO_LINE_SGIS 0x81F3 -#define GL_EYE_POINT_SGIS 0x81F4 -#define GL_OBJECT_POINT_SGIS 0x81F5 -#define GL_EYE_LINE_SGIS 0x81F6 -#define GL_OBJECT_LINE_SGIS 0x81F7 -#endif - -#ifndef GL_SGIS_texture_color_mask -#define GL_TEXTURE_COLOR_WRITEMASK_SGIS 0x81EF -#endif - -#ifndef GL_EXT_texture_env_dot3 -#define GL_DOT3_RGB_EXT 0x8740 -#define GL_DOT3_RGBA_EXT 0x8741 -#endif - -#ifndef GL_ATI_texture_mirror_once -#define GL_MIRROR_CLAMP_ATI 0x8742 -#define GL_MIRROR_CLAMP_TO_EDGE_ATI 0x8743 -#endif - -#ifndef GL_NV_fence -#define GL_ALL_COMPLETED_NV 0x84F2 -#define GL_FENCE_STATUS_NV 0x84F3 -#define GL_FENCE_CONDITION_NV 0x84F4 -#endif - -#ifndef GL_IBM_texture_mirrored_repeat -#define GL_MIRRORED_REPEAT_IBM 0x8370 -#endif - -#ifndef GL_NV_evaluators -#define GL_EVAL_2D_NV 0x86C0 -#define GL_EVAL_TRIANGULAR_2D_NV 0x86C1 -#define GL_MAP_TESSELLATION_NV 0x86C2 -#define GL_MAP_ATTRIB_U_ORDER_NV 0x86C3 -#define GL_MAP_ATTRIB_V_ORDER_NV 0x86C4 -#define GL_EVAL_FRACTIONAL_TESSELLATION_NV 0x86C5 -#define GL_EVAL_VERTEX_ATTRIB0_NV 0x86C6 -#define GL_EVAL_VERTEX_ATTRIB1_NV 0x86C7 -#define GL_EVAL_VERTEX_ATTRIB2_NV 0x86C8 -#define GL_EVAL_VERTEX_ATTRIB3_NV 0x86C9 -#define GL_EVAL_VERTEX_ATTRIB4_NV 0x86CA -#define GL_EVAL_VERTEX_ATTRIB5_NV 0x86CB -#define GL_EVAL_VERTEX_ATTRIB6_NV 0x86CC -#define GL_EVAL_VERTEX_ATTRIB7_NV 0x86CD -#define GL_EVAL_VERTEX_ATTRIB8_NV 0x86CE -#define GL_EVAL_VERTEX_ATTRIB9_NV 0x86CF -#define GL_EVAL_VERTEX_ATTRIB10_NV 0x86D0 -#define GL_EVAL_VERTEX_ATTRIB11_NV 0x86D1 -#define GL_EVAL_VERTEX_ATTRIB12_NV 0x86D2 -#define GL_EVAL_VERTEX_ATTRIB13_NV 0x86D3 -#define GL_EVAL_VERTEX_ATTRIB14_NV 0x86D4 -#define GL_EVAL_VERTEX_ATTRIB15_NV 0x86D5 -#define GL_MAX_MAP_TESSELLATION_NV 0x86D6 -#define GL_MAX_RATIONAL_EVAL_ORDER_NV 0x86D7 -#endif - -#ifndef GL_NV_packed_depth_stencil -#define GL_DEPTH_STENCIL_NV 0x84F9 -#define GL_UNSIGNED_INT_24_8_NV 0x84FA -#endif - -#ifndef GL_NV_register_combiners2 -#define GL_PER_STAGE_CONSTANTS_NV 0x8535 -#endif - -#ifndef GL_NV_texture_compression_vtc -#endif - -#ifndef GL_NV_texture_rectangle -#define GL_TEXTURE_RECTANGLE_NV 0x84F5 -#define GL_TEXTURE_BINDING_RECTANGLE_NV 0x84F6 -#define GL_PROXY_TEXTURE_RECTANGLE_NV 0x84F7 -#define GL_MAX_RECTANGLE_TEXTURE_SIZE_NV 0x84F8 -#endif - -#ifndef GL_NV_texture_shader -#define GL_OFFSET_TEXTURE_RECTANGLE_NV 0x864C -#define GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV 0x864D -#define GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV 0x864E -#define GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV 0x86D9 -#define GL_UNSIGNED_INT_S8_S8_8_8_NV 0x86DA -#define GL_UNSIGNED_INT_8_8_S8_S8_REV_NV 0x86DB -#define GL_DSDT_MAG_INTENSITY_NV 0x86DC -#define GL_SHADER_CONSISTENT_NV 0x86DD -#define GL_TEXTURE_SHADER_NV 0x86DE -#define GL_SHADER_OPERATION_NV 0x86DF -#define GL_CULL_MODES_NV 0x86E0 -#define GL_OFFSET_TEXTURE_MATRIX_NV 0x86E1 -#define GL_OFFSET_TEXTURE_SCALE_NV 0x86E2 -#define GL_OFFSET_TEXTURE_BIAS_NV 0x86E3 -#define GL_OFFSET_TEXTURE_2D_MATRIX_NV GL_OFFSET_TEXTURE_MATRIX_NV -#define GL_OFFSET_TEXTURE_2D_SCALE_NV GL_OFFSET_TEXTURE_SCALE_NV -#define GL_OFFSET_TEXTURE_2D_BIAS_NV GL_OFFSET_TEXTURE_BIAS_NV -#define GL_PREVIOUS_TEXTURE_INPUT_NV 0x86E4 -#define GL_CONST_EYE_NV 0x86E5 -#define GL_PASS_THROUGH_NV 0x86E6 -#define GL_CULL_FRAGMENT_NV 0x86E7 -#define GL_OFFSET_TEXTURE_2D_NV 0x86E8 -#define GL_DEPENDENT_AR_TEXTURE_2D_NV 0x86E9 -#define GL_DEPENDENT_GB_TEXTURE_2D_NV 0x86EA -#define GL_DOT_PRODUCT_NV 0x86EC -#define GL_DOT_PRODUCT_DEPTH_REPLACE_NV 0x86ED -#define GL_DOT_PRODUCT_TEXTURE_2D_NV 0x86EE -#define GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV 0x86F0 -#define GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV 0x86F1 -#define GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV 0x86F2 -#define GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV 0x86F3 -#define GL_HILO_NV 0x86F4 -#define GL_DSDT_NV 0x86F5 -#define GL_DSDT_MAG_NV 0x86F6 -#define GL_DSDT_MAG_VIB_NV 0x86F7 -#define GL_HILO16_NV 0x86F8 -#define GL_SIGNED_HILO_NV 0x86F9 -#define GL_SIGNED_HILO16_NV 0x86FA -#define GL_SIGNED_RGBA_NV 0x86FB -#define GL_SIGNED_RGBA8_NV 0x86FC -#define GL_SIGNED_RGB_NV 0x86FE -#define GL_SIGNED_RGB8_NV 0x86FF -#define GL_SIGNED_LUMINANCE_NV 0x8701 -#define GL_SIGNED_LUMINANCE8_NV 0x8702 -#define GL_SIGNED_LUMINANCE_ALPHA_NV 0x8703 -#define GL_SIGNED_LUMINANCE8_ALPHA8_NV 0x8704 -#define GL_SIGNED_ALPHA_NV 0x8705 -#define GL_SIGNED_ALPHA8_NV 0x8706 -#define GL_SIGNED_INTENSITY_NV 0x8707 -#define GL_SIGNED_INTENSITY8_NV 0x8708 -#define GL_DSDT8_NV 0x8709 -#define GL_DSDT8_MAG8_NV 0x870A -#define GL_DSDT8_MAG8_INTENSITY8_NV 0x870B -#define GL_SIGNED_RGB_UNSIGNED_ALPHA_NV 0x870C -#define GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV 0x870D -#define GL_HI_SCALE_NV 0x870E -#define GL_LO_SCALE_NV 0x870F -#define GL_DS_SCALE_NV 0x8710 -#define GL_DT_SCALE_NV 0x8711 -#define GL_MAGNITUDE_SCALE_NV 0x8712 -#define GL_VIBRANCE_SCALE_NV 0x8713 -#define GL_HI_BIAS_NV 0x8714 -#define GL_LO_BIAS_NV 0x8715 -#define GL_DS_BIAS_NV 0x8716 -#define GL_DT_BIAS_NV 0x8717 -#define GL_MAGNITUDE_BIAS_NV 0x8718 -#define GL_VIBRANCE_BIAS_NV 0x8719 -#define GL_TEXTURE_BORDER_VALUES_NV 0x871A -#define GL_TEXTURE_HI_SIZE_NV 0x871B -#define GL_TEXTURE_LO_SIZE_NV 0x871C -#define GL_TEXTURE_DS_SIZE_NV 0x871D -#define GL_TEXTURE_DT_SIZE_NV 0x871E -#define GL_TEXTURE_MAG_SIZE_NV 0x871F -#endif - -#ifndef GL_NV_texture_shader2 -#define GL_DOT_PRODUCT_TEXTURE_3D_NV 0x86EF -#endif - -#ifndef GL_NV_vertex_array_range2 -#define GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV 0x8533 -#endif - -#ifndef GL_NV_vertex_program -#define GL_VERTEX_PROGRAM_NV 0x8620 -#define GL_VERTEX_STATE_PROGRAM_NV 0x8621 -#define GL_ATTRIB_ARRAY_SIZE_NV 0x8623 -#define GL_ATTRIB_ARRAY_STRIDE_NV 0x8624 -#define GL_ATTRIB_ARRAY_TYPE_NV 0x8625 -#define GL_CURRENT_ATTRIB_NV 0x8626 -#define GL_PROGRAM_LENGTH_NV 0x8627 -#define GL_PROGRAM_STRING_NV 0x8628 -#define GL_MODELVIEW_PROJECTION_NV 0x8629 -#define GL_IDENTITY_NV 0x862A -#define GL_INVERSE_NV 0x862B -#define GL_TRANSPOSE_NV 0x862C -#define GL_INVERSE_TRANSPOSE_NV 0x862D -#define GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV 0x862E -#define GL_MAX_TRACK_MATRICES_NV 0x862F -#define GL_MATRIX0_NV 0x8630 -#define GL_MATRIX1_NV 0x8631 -#define GL_MATRIX2_NV 0x8632 -#define GL_MATRIX3_NV 0x8633 -#define GL_MATRIX4_NV 0x8634 -#define GL_MATRIX5_NV 0x8635 -#define GL_MATRIX6_NV 0x8636 -#define GL_MATRIX7_NV 0x8637 -#define GL_CURRENT_MATRIX_STACK_DEPTH_NV 0x8640 -#define GL_CURRENT_MATRIX_NV 0x8641 -#define GL_VERTEX_PROGRAM_POINT_SIZE_NV 0x8642 -#define GL_VERTEX_PROGRAM_TWO_SIDE_NV 0x8643 -#define GL_PROGRAM_PARAMETER_NV 0x8644 -#define GL_ATTRIB_ARRAY_POINTER_NV 0x8645 -#define GL_PROGRAM_TARGET_NV 0x8646 -#define GL_PROGRAM_RESIDENT_NV 0x8647 -#define GL_TRACK_MATRIX_NV 0x8648 -#define GL_TRACK_MATRIX_TRANSFORM_NV 0x8649 -#define GL_VERTEX_PROGRAM_BINDING_NV 0x864A -#define GL_PROGRAM_ERROR_POSITION_NV 0x864B -#define GL_VERTEX_ATTRIB_ARRAY0_NV 0x8650 -#define GL_VERTEX_ATTRIB_ARRAY1_NV 0x8651 -#define GL_VERTEX_ATTRIB_ARRAY2_NV 0x8652 -#define GL_VERTEX_ATTRIB_ARRAY3_NV 0x8653 -#define GL_VERTEX_ATTRIB_ARRAY4_NV 0x8654 -#define GL_VERTEX_ATTRIB_ARRAY5_NV 0x8655 -#define GL_VERTEX_ATTRIB_ARRAY6_NV 0x8656 -#define GL_VERTEX_ATTRIB_ARRAY7_NV 0x8657 -#define GL_VERTEX_ATTRIB_ARRAY8_NV 0x8658 -#define GL_VERTEX_ATTRIB_ARRAY9_NV 0x8659 -#define GL_VERTEX_ATTRIB_ARRAY10_NV 0x865A -#define GL_VERTEX_ATTRIB_ARRAY11_NV 0x865B -#define GL_VERTEX_ATTRIB_ARRAY12_NV 0x865C -#define GL_VERTEX_ATTRIB_ARRAY13_NV 0x865D -#define GL_VERTEX_ATTRIB_ARRAY14_NV 0x865E -#define GL_VERTEX_ATTRIB_ARRAY15_NV 0x865F -#define GL_MAP1_VERTEX_ATTRIB0_4_NV 0x8660 -#define GL_MAP1_VERTEX_ATTRIB1_4_NV 0x8661 -#define GL_MAP1_VERTEX_ATTRIB2_4_NV 0x8662 -#define GL_MAP1_VERTEX_ATTRIB3_4_NV 0x8663 -#define GL_MAP1_VERTEX_ATTRIB4_4_NV 0x8664 -#define GL_MAP1_VERTEX_ATTRIB5_4_NV 0x8665 -#define GL_MAP1_VERTEX_ATTRIB6_4_NV 0x8666 -#define GL_MAP1_VERTEX_ATTRIB7_4_NV 0x8667 -#define GL_MAP1_VERTEX_ATTRIB8_4_NV 0x8668 -#define GL_MAP1_VERTEX_ATTRIB9_4_NV 0x8669 -#define GL_MAP1_VERTEX_ATTRIB10_4_NV 0x866A -#define GL_MAP1_VERTEX_ATTRIB11_4_NV 0x866B -#define GL_MAP1_VERTEX_ATTRIB12_4_NV 0x866C -#define GL_MAP1_VERTEX_ATTRIB13_4_NV 0x866D -#define GL_MAP1_VERTEX_ATTRIB14_4_NV 0x866E -#define GL_MAP1_VERTEX_ATTRIB15_4_NV 0x866F -#define GL_MAP2_VERTEX_ATTRIB0_4_NV 0x8670 -#define GL_MAP2_VERTEX_ATTRIB1_4_NV 0x8671 -#define GL_MAP2_VERTEX_ATTRIB2_4_NV 0x8672 -#define GL_MAP2_VERTEX_ATTRIB3_4_NV 0x8673 -#define GL_MAP2_VERTEX_ATTRIB4_4_NV 0x8674 -#define GL_MAP2_VERTEX_ATTRIB5_4_NV 0x8675 -#define GL_MAP2_VERTEX_ATTRIB6_4_NV 0x8676 -#define GL_MAP2_VERTEX_ATTRIB7_4_NV 0x8677 -#define GL_MAP2_VERTEX_ATTRIB8_4_NV 0x8678 -#define GL_MAP2_VERTEX_ATTRIB9_4_NV 0x8679 -#define GL_MAP2_VERTEX_ATTRIB10_4_NV 0x867A -#define GL_MAP2_VERTEX_ATTRIB11_4_NV 0x867B -#define GL_MAP2_VERTEX_ATTRIB12_4_NV 0x867C -#define GL_MAP2_VERTEX_ATTRIB13_4_NV 0x867D -#define GL_MAP2_VERTEX_ATTRIB14_4_NV 0x867E -#define GL_MAP2_VERTEX_ATTRIB15_4_NV 0x867F -#endif - -#ifndef GL_SGIX_texture_coordinate_clamp -#define GL_TEXTURE_MAX_CLAMP_S_SGIX 0x8369 -#define GL_TEXTURE_MAX_CLAMP_T_SGIX 0x836A -#define GL_TEXTURE_MAX_CLAMP_R_SGIX 0x836B -#endif - -#ifndef GL_SGIX_scalebias_hint -#define GL_SCALEBIAS_HINT_SGIX 0x8322 -#endif - -#ifndef GL_OML_interlace -#define GL_INTERLACE_OML 0x8980 -#define GL_INTERLACE_READ_OML 0x8981 -#endif - -#ifndef GL_OML_subsample -#define GL_FORMAT_SUBSAMPLE_24_24_OML 0x8982 -#define GL_FORMAT_SUBSAMPLE_244_244_OML 0x8983 -#endif - -#ifndef GL_OML_resample -#define GL_PACK_RESAMPLE_OML 0x8984 -#define GL_UNPACK_RESAMPLE_OML 0x8985 -#define GL_RESAMPLE_REPLICATE_OML 0x8986 -#define GL_RESAMPLE_ZERO_FILL_OML 0x8987 -#define GL_RESAMPLE_AVERAGE_OML 0x8988 -#define GL_RESAMPLE_DECIMATE_OML 0x8989 -#endif - -#ifndef GL_NV_copy_depth_to_color -#define GL_DEPTH_STENCIL_TO_RGBA_NV 0x886E -#define GL_DEPTH_STENCIL_TO_BGRA_NV 0x886F -#endif - -#ifndef GL_ATI_envmap_bumpmap -#define GL_BUMP_ROT_MATRIX_ATI 0x8775 -#define GL_BUMP_ROT_MATRIX_SIZE_ATI 0x8776 -#define GL_BUMP_NUM_TEX_UNITS_ATI 0x8777 -#define GL_BUMP_TEX_UNITS_ATI 0x8778 -#define GL_DUDV_ATI 0x8779 -#define GL_DU8DV8_ATI 0x877A -#define GL_BUMP_ENVMAP_ATI 0x877B -#define GL_BUMP_TARGET_ATI 0x877C -#endif - -#ifndef GL_ATI_fragment_shader -#define GL_FRAGMENT_SHADER_ATI 0x8920 -#define GL_REG_0_ATI 0x8921 -#define GL_REG_1_ATI 0x8922 -#define GL_REG_2_ATI 0x8923 -#define GL_REG_3_ATI 0x8924 -#define GL_REG_4_ATI 0x8925 -#define GL_REG_5_ATI 0x8926 -#define GL_REG_6_ATI 0x8927 -#define GL_REG_7_ATI 0x8928 -#define GL_REG_8_ATI 0x8929 -#define GL_REG_9_ATI 0x892A -#define GL_REG_10_ATI 0x892B -#define GL_REG_11_ATI 0x892C -#define GL_REG_12_ATI 0x892D -#define GL_REG_13_ATI 0x892E -#define GL_REG_14_ATI 0x892F -#define GL_REG_15_ATI 0x8930 -#define GL_REG_16_ATI 0x8931 -#define GL_REG_17_ATI 0x8932 -#define GL_REG_18_ATI 0x8933 -#define GL_REG_19_ATI 0x8934 -#define GL_REG_20_ATI 0x8935 -#define GL_REG_21_ATI 0x8936 -#define GL_REG_22_ATI 0x8937 -#define GL_REG_23_ATI 0x8938 -#define GL_REG_24_ATI 0x8939 -#define GL_REG_25_ATI 0x893A -#define GL_REG_26_ATI 0x893B -#define GL_REG_27_ATI 0x893C -#define GL_REG_28_ATI 0x893D -#define GL_REG_29_ATI 0x893E -#define GL_REG_30_ATI 0x893F -#define GL_REG_31_ATI 0x8940 -#define GL_CON_0_ATI 0x8941 -#define GL_CON_1_ATI 0x8942 -#define GL_CON_2_ATI 0x8943 -#define GL_CON_3_ATI 0x8944 -#define GL_CON_4_ATI 0x8945 -#define GL_CON_5_ATI 0x8946 -#define GL_CON_6_ATI 0x8947 -#define GL_CON_7_ATI 0x8948 -#define GL_CON_8_ATI 0x8949 -#define GL_CON_9_ATI 0x894A -#define GL_CON_10_ATI 0x894B -#define GL_CON_11_ATI 0x894C -#define GL_CON_12_ATI 0x894D -#define GL_CON_13_ATI 0x894E -#define GL_CON_14_ATI 0x894F -#define GL_CON_15_ATI 0x8950 -#define GL_CON_16_ATI 0x8951 -#define GL_CON_17_ATI 0x8952 -#define GL_CON_18_ATI 0x8953 -#define GL_CON_19_ATI 0x8954 -#define GL_CON_20_ATI 0x8955 -#define GL_CON_21_ATI 0x8956 -#define GL_CON_22_ATI 0x8957 -#define GL_CON_23_ATI 0x8958 -#define GL_CON_24_ATI 0x8959 -#define GL_CON_25_ATI 0x895A -#define GL_CON_26_ATI 0x895B -#define GL_CON_27_ATI 0x895C -#define GL_CON_28_ATI 0x895D -#define GL_CON_29_ATI 0x895E -#define GL_CON_30_ATI 0x895F -#define GL_CON_31_ATI 0x8960 -#define GL_MOV_ATI 0x8961 -#define GL_ADD_ATI 0x8963 -#define GL_MUL_ATI 0x8964 -#define GL_SUB_ATI 0x8965 -#define GL_DOT3_ATI 0x8966 -#define GL_DOT4_ATI 0x8967 -#define GL_MAD_ATI 0x8968 -#define GL_LERP_ATI 0x8969 -#define GL_CND_ATI 0x896A -#define GL_CND0_ATI 0x896B -#define GL_DOT2_ADD_ATI 0x896C -#define GL_SECONDARY_INTERPOLATOR_ATI 0x896D -#define GL_NUM_FRAGMENT_REGISTERS_ATI 0x896E -#define GL_NUM_FRAGMENT_CONSTANTS_ATI 0x896F -#define GL_NUM_PASSES_ATI 0x8970 -#define GL_NUM_INSTRUCTIONS_PER_PASS_ATI 0x8971 -#define GL_NUM_INSTRUCTIONS_TOTAL_ATI 0x8972 -#define GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI 0x8973 -#define GL_NUM_LOOPBACK_COMPONENTS_ATI 0x8974 -#define GL_COLOR_ALPHA_PAIRING_ATI 0x8975 -#define GL_SWIZZLE_STR_ATI 0x8976 -#define GL_SWIZZLE_STQ_ATI 0x8977 -#define GL_SWIZZLE_STR_DR_ATI 0x8978 -#define GL_SWIZZLE_STQ_DQ_ATI 0x8979 -#define GL_SWIZZLE_STRQ_ATI 0x897A -#define GL_SWIZZLE_STRQ_DQ_ATI 0x897B -#define GL_RED_BIT_ATI 0x00000001 -#define GL_GREEN_BIT_ATI 0x00000002 -#define GL_BLUE_BIT_ATI 0x00000004 -#define GL_2X_BIT_ATI 0x00000001 -#define GL_4X_BIT_ATI 0x00000002 -#define GL_8X_BIT_ATI 0x00000004 -#define GL_HALF_BIT_ATI 0x00000008 -#define GL_QUARTER_BIT_ATI 0x00000010 -#define GL_EIGHTH_BIT_ATI 0x00000020 -#define GL_SATURATE_BIT_ATI 0x00000040 -#define GL_COMP_BIT_ATI 0x00000002 -#define GL_NEGATE_BIT_ATI 0x00000004 -#define GL_BIAS_BIT_ATI 0x00000008 -#endif - -#ifndef GL_ATI_pn_triangles -#define GL_PN_TRIANGLES_ATI 0x87F0 -#define GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F1 -#define GL_PN_TRIANGLES_POINT_MODE_ATI 0x87F2 -#define GL_PN_TRIANGLES_NORMAL_MODE_ATI 0x87F3 -#define GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F4 -#define GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI 0x87F5 -#define GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI 0x87F6 -#define GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI 0x87F7 -#define GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI 0x87F8 -#endif - -#ifndef GL_ATI_vertex_array_object -#define GL_STATIC_ATI 0x8760 -#define GL_DYNAMIC_ATI 0x8761 -#define GL_PRESERVE_ATI 0x8762 -#define GL_DISCARD_ATI 0x8763 -#define GL_OBJECT_BUFFER_SIZE_ATI 0x8764 -#define GL_OBJECT_BUFFER_USAGE_ATI 0x8765 -#define GL_ARRAY_OBJECT_BUFFER_ATI 0x8766 -#define GL_ARRAY_OBJECT_OFFSET_ATI 0x8767 -#endif - -#ifndef GL_EXT_vertex_shader -#define GL_VERTEX_SHADER_EXT 0x8780 -#define GL_VERTEX_SHADER_BINDING_EXT 0x8781 -#define GL_OP_INDEX_EXT 0x8782 -#define GL_OP_NEGATE_EXT 0x8783 -#define GL_OP_DOT3_EXT 0x8784 -#define GL_OP_DOT4_EXT 0x8785 -#define GL_OP_MUL_EXT 0x8786 -#define GL_OP_ADD_EXT 0x8787 -#define GL_OP_MADD_EXT 0x8788 -#define GL_OP_FRAC_EXT 0x8789 -#define GL_OP_MAX_EXT 0x878A -#define GL_OP_MIN_EXT 0x878B -#define GL_OP_SET_GE_EXT 0x878C -#define GL_OP_SET_LT_EXT 0x878D -#define GL_OP_CLAMP_EXT 0x878E -#define GL_OP_FLOOR_EXT 0x878F -#define GL_OP_ROUND_EXT 0x8790 -#define GL_OP_EXP_BASE_2_EXT 0x8791 -#define GL_OP_LOG_BASE_2_EXT 0x8792 -#define GL_OP_POWER_EXT 0x8793 -#define GL_OP_RECIP_EXT 0x8794 -#define GL_OP_RECIP_SQRT_EXT 0x8795 -#define GL_OP_SUB_EXT 0x8796 -#define GL_OP_CROSS_PRODUCT_EXT 0x8797 -#define GL_OP_MULTIPLY_MATRIX_EXT 0x8798 -#define GL_OP_MOV_EXT 0x8799 -#define GL_OUTPUT_VERTEX_EXT 0x879A -#define GL_OUTPUT_COLOR0_EXT 0x879B -#define GL_OUTPUT_COLOR1_EXT 0x879C -#define GL_OUTPUT_TEXTURE_COORD0_EXT 0x879D -#define GL_OUTPUT_TEXTURE_COORD1_EXT 0x879E -#define GL_OUTPUT_TEXTURE_COORD2_EXT 0x879F -#define GL_OUTPUT_TEXTURE_COORD3_EXT 0x87A0 -#define GL_OUTPUT_TEXTURE_COORD4_EXT 0x87A1 -#define GL_OUTPUT_TEXTURE_COORD5_EXT 0x87A2 -#define GL_OUTPUT_TEXTURE_COORD6_EXT 0x87A3 -#define GL_OUTPUT_TEXTURE_COORD7_EXT 0x87A4 -#define GL_OUTPUT_TEXTURE_COORD8_EXT 0x87A5 -#define GL_OUTPUT_TEXTURE_COORD9_EXT 0x87A6 -#define GL_OUTPUT_TEXTURE_COORD10_EXT 0x87A7 -#define GL_OUTPUT_TEXTURE_COORD11_EXT 0x87A8 -#define GL_OUTPUT_TEXTURE_COORD12_EXT 0x87A9 -#define GL_OUTPUT_TEXTURE_COORD13_EXT 0x87AA -#define GL_OUTPUT_TEXTURE_COORD14_EXT 0x87AB -#define GL_OUTPUT_TEXTURE_COORD15_EXT 0x87AC -#define GL_OUTPUT_TEXTURE_COORD16_EXT 0x87AD -#define GL_OUTPUT_TEXTURE_COORD17_EXT 0x87AE -#define GL_OUTPUT_TEXTURE_COORD18_EXT 0x87AF -#define GL_OUTPUT_TEXTURE_COORD19_EXT 0x87B0 -#define GL_OUTPUT_TEXTURE_COORD20_EXT 0x87B1 -#define GL_OUTPUT_TEXTURE_COORD21_EXT 0x87B2 -#define GL_OUTPUT_TEXTURE_COORD22_EXT 0x87B3 -#define GL_OUTPUT_TEXTURE_COORD23_EXT 0x87B4 -#define GL_OUTPUT_TEXTURE_COORD24_EXT 0x87B5 -#define GL_OUTPUT_TEXTURE_COORD25_EXT 0x87B6 -#define GL_OUTPUT_TEXTURE_COORD26_EXT 0x87B7 -#define GL_OUTPUT_TEXTURE_COORD27_EXT 0x87B8 -#define GL_OUTPUT_TEXTURE_COORD28_EXT 0x87B9 -#define GL_OUTPUT_TEXTURE_COORD29_EXT 0x87BA -#define GL_OUTPUT_TEXTURE_COORD30_EXT 0x87BB -#define GL_OUTPUT_TEXTURE_COORD31_EXT 0x87BC -#define GL_OUTPUT_FOG_EXT 0x87BD -#define GL_SCALAR_EXT 0x87BE -#define GL_VECTOR_EXT 0x87BF -#define GL_MATRIX_EXT 0x87C0 -#define GL_VARIANT_EXT 0x87C1 -#define GL_INVARIANT_EXT 0x87C2 -#define GL_LOCAL_CONSTANT_EXT 0x87C3 -#define GL_LOCAL_EXT 0x87C4 -#define GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87C5 -#define GL_MAX_VERTEX_SHADER_VARIANTS_EXT 0x87C6 -#define GL_MAX_VERTEX_SHADER_INVARIANTS_EXT 0x87C7 -#define GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87C8 -#define GL_MAX_VERTEX_SHADER_LOCALS_EXT 0x87C9 -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CA -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT 0x87CB -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87CC -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT 0x87CD -#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT 0x87CE -#define GL_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CF -#define GL_VERTEX_SHADER_VARIANTS_EXT 0x87D0 -#define GL_VERTEX_SHADER_INVARIANTS_EXT 0x87D1 -#define GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87D2 -#define GL_VERTEX_SHADER_LOCALS_EXT 0x87D3 -#define GL_VERTEX_SHADER_OPTIMIZED_EXT 0x87D4 -#define GL_X_EXT 0x87D5 -#define GL_Y_EXT 0x87D6 -#define GL_Z_EXT 0x87D7 -#define GL_W_EXT 0x87D8 -#define GL_NEGATIVE_X_EXT 0x87D9 -#define GL_NEGATIVE_Y_EXT 0x87DA -#define GL_NEGATIVE_Z_EXT 0x87DB -#define GL_NEGATIVE_W_EXT 0x87DC -#define GL_ZERO_EXT 0x87DD -#define GL_ONE_EXT 0x87DE -#define GL_NEGATIVE_ONE_EXT 0x87DF -#define GL_NORMALIZED_RANGE_EXT 0x87E0 -#define GL_FULL_RANGE_EXT 0x87E1 -#define GL_CURRENT_VERTEX_EXT 0x87E2 -#define GL_MVP_MATRIX_EXT 0x87E3 -#define GL_VARIANT_VALUE_EXT 0x87E4 -#define GL_VARIANT_DATATYPE_EXT 0x87E5 -#define GL_VARIANT_ARRAY_STRIDE_EXT 0x87E6 -#define GL_VARIANT_ARRAY_TYPE_EXT 0x87E7 -#define GL_VARIANT_ARRAY_EXT 0x87E8 -#define GL_VARIANT_ARRAY_POINTER_EXT 0x87E9 -#define GL_INVARIANT_VALUE_EXT 0x87EA -#define GL_INVARIANT_DATATYPE_EXT 0x87EB -#define GL_LOCAL_CONSTANT_VALUE_EXT 0x87EC -#define GL_LOCAL_CONSTANT_DATATYPE_EXT 0x87ED -#endif - -#ifndef GL_ATI_vertex_streams -#define GL_MAX_VERTEX_STREAMS_ATI 0x876B -#define GL_VERTEX_STREAM0_ATI 0x876C -#define GL_VERTEX_STREAM1_ATI 0x876D -#define GL_VERTEX_STREAM2_ATI 0x876E -#define GL_VERTEX_STREAM3_ATI 0x876F -#define GL_VERTEX_STREAM4_ATI 0x8770 -#define GL_VERTEX_STREAM5_ATI 0x8771 -#define GL_VERTEX_STREAM6_ATI 0x8772 -#define GL_VERTEX_STREAM7_ATI 0x8773 -#define GL_VERTEX_SOURCE_ATI 0x8774 -#endif - -#ifndef GL_ATI_element_array -#define GL_ELEMENT_ARRAY_ATI 0x8768 -#define GL_ELEMENT_ARRAY_TYPE_ATI 0x8769 -#define GL_ELEMENT_ARRAY_POINTER_ATI 0x876A -#endif - -#ifndef GL_SUN_mesh_array -#define GL_QUAD_MESH_SUN 0x8614 -#define GL_TRIANGLE_MESH_SUN 0x8615 -#endif - -#ifndef GL_SUN_slice_accum -#define GL_SLICE_ACCUM_SUN 0x85CC -#endif - -#ifndef GL_NV_multisample_filter_hint -#define GL_MULTISAMPLE_FILTER_HINT_NV 0x8534 -#endif - -#ifndef GL_NV_depth_clamp -#define GL_DEPTH_CLAMP_NV 0x864F -#endif - -#ifndef GL_NV_occlusion_query -#define GL_PIXEL_COUNTER_BITS_NV 0x8864 -#define GL_CURRENT_OCCLUSION_QUERY_ID_NV 0x8865 -#define GL_PIXEL_COUNT_NV 0x8866 -#define GL_PIXEL_COUNT_AVAILABLE_NV 0x8867 -#endif - -#ifndef GL_NV_point_sprite -#define GL_POINT_SPRITE_NV 0x8861 -#define GL_COORD_REPLACE_NV 0x8862 -#define GL_POINT_SPRITE_R_MODE_NV 0x8863 -#endif - -#ifndef GL_NV_texture_shader3 -#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV 0x8850 -#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV 0x8851 -#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8852 -#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV 0x8853 -#define GL_OFFSET_HILO_TEXTURE_2D_NV 0x8854 -#define GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV 0x8855 -#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV 0x8856 -#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8857 -#define GL_DEPENDENT_HILO_TEXTURE_2D_NV 0x8858 -#define GL_DEPENDENT_RGB_TEXTURE_3D_NV 0x8859 -#define GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV 0x885A -#define GL_DOT_PRODUCT_PASS_THROUGH_NV 0x885B -#define GL_DOT_PRODUCT_TEXTURE_1D_NV 0x885C -#define GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV 0x885D -#define GL_HILO8_NV 0x885E -#define GL_SIGNED_HILO8_NV 0x885F -#define GL_FORCE_BLUE_TO_ONE_NV 0x8860 -#endif - -#ifndef GL_NV_vertex_program1_1 -#endif - -#ifndef GL_EXT_shadow_funcs -#endif - -#ifndef GL_EXT_stencil_two_side -#define GL_STENCIL_TEST_TWO_SIDE_EXT 0x8910 -#define GL_ACTIVE_STENCIL_FACE_EXT 0x8911 -#endif - -#ifndef GL_ATI_text_fragment_shader -#define GL_TEXT_FRAGMENT_SHADER_ATI 0x8200 -#endif - -#ifndef GL_APPLE_client_storage -#define GL_UNPACK_CLIENT_STORAGE_APPLE 0x85B2 -#endif - -#ifndef GL_APPLE_element_array -#define GL_ELEMENT_ARRAY_APPLE 0x8768 -#define GL_ELEMENT_ARRAY_TYPE_APPLE 0x8769 -#define GL_ELEMENT_ARRAY_POINTER_APPLE 0x876A -#endif - -#ifndef GL_APPLE_fence -#define GL_DRAW_PIXELS_APPLE 0x8A0A -#define GL_FENCE_APPLE 0x8A0B -#endif - -#ifndef GL_APPLE_vertex_array_object -#define GL_VERTEX_ARRAY_BINDING_APPLE 0x85B5 -#endif - -#ifndef GL_APPLE_vertex_array_range -#define GL_VERTEX_ARRAY_RANGE_APPLE 0x851D -#define GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE 0x851E -#define GL_VERTEX_ARRAY_STORAGE_HINT_APPLE 0x851F -#define GL_VERTEX_ARRAY_RANGE_POINTER_APPLE 0x8521 -#define GL_STORAGE_CACHED_APPLE 0x85BE -#define GL_STORAGE_SHARED_APPLE 0x85BF -#endif - -#ifndef GL_APPLE_ycbcr_422 -#define GL_YCBCR_422_APPLE 0x85B9 -#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA -#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB -#endif - -#ifndef GL_S3_s3tc -#define GL_RGB_S3TC 0x83A0 -#define GL_RGB4_S3TC 0x83A1 -#define GL_RGBA_S3TC 0x83A2 -#define GL_RGBA4_S3TC 0x83A3 -#endif - -#ifndef GL_ATI_draw_buffers -#define GL_MAX_DRAW_BUFFERS_ATI 0x8824 -#define GL_DRAW_BUFFER0_ATI 0x8825 -#define GL_DRAW_BUFFER1_ATI 0x8826 -#define GL_DRAW_BUFFER2_ATI 0x8827 -#define GL_DRAW_BUFFER3_ATI 0x8828 -#define GL_DRAW_BUFFER4_ATI 0x8829 -#define GL_DRAW_BUFFER5_ATI 0x882A -#define GL_DRAW_BUFFER6_ATI 0x882B -#define GL_DRAW_BUFFER7_ATI 0x882C -#define GL_DRAW_BUFFER8_ATI 0x882D -#define GL_DRAW_BUFFER9_ATI 0x882E -#define GL_DRAW_BUFFER10_ATI 0x882F -#define GL_DRAW_BUFFER11_ATI 0x8830 -#define GL_DRAW_BUFFER12_ATI 0x8831 -#define GL_DRAW_BUFFER13_ATI 0x8832 -#define GL_DRAW_BUFFER14_ATI 0x8833 -#define GL_DRAW_BUFFER15_ATI 0x8834 -#endif - -#ifndef GL_ATI_pixel_format_float -#define GL_TYPE_RGBA_FLOAT_ATI 0x8820 -#define GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI 0x8835 -#endif - -#ifndef GL_ATI_texture_env_combine3 -#define GL_MODULATE_ADD_ATI 0x8744 -#define GL_MODULATE_SIGNED_ADD_ATI 0x8745 -#define GL_MODULATE_SUBTRACT_ATI 0x8746 -#endif - -#ifndef GL_ATI_texture_float -#define GL_RGBA_FLOAT32_ATI 0x8814 -#define GL_RGB_FLOAT32_ATI 0x8815 -#define GL_ALPHA_FLOAT32_ATI 0x8816 -#define GL_INTENSITY_FLOAT32_ATI 0x8817 -#define GL_LUMINANCE_FLOAT32_ATI 0x8818 -#define GL_LUMINANCE_ALPHA_FLOAT32_ATI 0x8819 -#define GL_RGBA_FLOAT16_ATI 0x881A -#define GL_RGB_FLOAT16_ATI 0x881B -#define GL_ALPHA_FLOAT16_ATI 0x881C -#define GL_INTENSITY_FLOAT16_ATI 0x881D -#define GL_LUMINANCE_FLOAT16_ATI 0x881E -#define GL_LUMINANCE_ALPHA_FLOAT16_ATI 0x881F -#endif - -#ifndef GL_NV_float_buffer -#define GL_FLOAT_R_NV 0x8880 -#define GL_FLOAT_RG_NV 0x8881 -#define GL_FLOAT_RGB_NV 0x8882 -#define GL_FLOAT_RGBA_NV 0x8883 -#define GL_FLOAT_R16_NV 0x8884 -#define GL_FLOAT_R32_NV 0x8885 -#define GL_FLOAT_RG16_NV 0x8886 -#define GL_FLOAT_RG32_NV 0x8887 -#define GL_FLOAT_RGB16_NV 0x8888 -#define GL_FLOAT_RGB32_NV 0x8889 -#define GL_FLOAT_RGBA16_NV 0x888A -#define GL_FLOAT_RGBA32_NV 0x888B -#define GL_TEXTURE_FLOAT_COMPONENTS_NV 0x888C -#define GL_FLOAT_CLEAR_COLOR_VALUE_NV 0x888D -#define GL_FLOAT_RGBA_MODE_NV 0x888E -#endif - -#ifndef GL_NV_fragment_program -#define GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV 0x8868 -#define GL_FRAGMENT_PROGRAM_NV 0x8870 -#define GL_MAX_TEXTURE_COORDS_NV 0x8871 -#define GL_MAX_TEXTURE_IMAGE_UNITS_NV 0x8872 -#define GL_FRAGMENT_PROGRAM_BINDING_NV 0x8873 -#define GL_PROGRAM_ERROR_STRING_NV 0x8874 -#endif - -#ifndef GL_NV_half_float -#define GL_HALF_FLOAT_NV 0x140B -#endif - -#ifndef GL_NV_pixel_data_range -#define GL_WRITE_PIXEL_DATA_RANGE_NV 0x8878 -#define GL_READ_PIXEL_DATA_RANGE_NV 0x8879 -#define GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV 0x887A -#define GL_READ_PIXEL_DATA_RANGE_LENGTH_NV 0x887B -#define GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV 0x887C -#define GL_READ_PIXEL_DATA_RANGE_POINTER_NV 0x887D -#endif - -#ifndef GL_NV_primitive_restart -#define GL_PRIMITIVE_RESTART_NV 0x8558 -#define GL_PRIMITIVE_RESTART_INDEX_NV 0x8559 -#endif - -#ifndef GL_NV_texture_expand_normal -#define GL_TEXTURE_UNSIGNED_REMAP_MODE_NV 0x888F -#endif - -#ifndef GL_NV_vertex_program2 -#endif - -#ifndef GL_ATI_map_object_buffer -#endif - -#ifndef GL_ATI_separate_stencil -#define GL_STENCIL_BACK_FUNC_ATI 0x8800 -#define GL_STENCIL_BACK_FAIL_ATI 0x8801 -#define GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI 0x8802 -#define GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI 0x8803 -#endif - -#ifndef GL_ATI_vertex_attrib_array_object -#endif - -#ifndef GL_OES_read_format -#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A -#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B -#endif - -#ifndef GL_EXT_depth_bounds_test -#define GL_DEPTH_BOUNDS_TEST_EXT 0x8890 -#define GL_DEPTH_BOUNDS_EXT 0x8891 -#endif - -#ifndef GL_EXT_texture_mirror_clamp -#define GL_MIRROR_CLAMP_EXT 0x8742 -#define GL_MIRROR_CLAMP_TO_EDGE_EXT 0x8743 -#define GL_MIRROR_CLAMP_TO_BORDER_EXT 0x8912 -#endif - -#ifndef GL_EXT_blend_equation_separate -#define GL_BLEND_EQUATION_RGB_EXT GL_BLEND_EQUATION -#define GL_BLEND_EQUATION_ALPHA_EXT 0x883D -#endif - -#ifndef GL_MESA_pack_invert -#define GL_PACK_INVERT_MESA 0x8758 -#endif - -#ifndef GL_MESA_ycbcr_texture -#define GL_UNSIGNED_SHORT_8_8_MESA 0x85BA -#define GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB -#define GL_YCBCR_MESA 0x8757 -#endif - -#ifndef GL_EXT_pixel_buffer_object -#define GL_PIXEL_PACK_BUFFER_EXT 0x88EB -#define GL_PIXEL_UNPACK_BUFFER_EXT 0x88EC -#define GL_PIXEL_PACK_BUFFER_BINDING_EXT 0x88ED -#define GL_PIXEL_UNPACK_BUFFER_BINDING_EXT 0x88EF -#endif - -#ifndef GL_NV_fragment_program_option -#endif - -#ifndef GL_NV_fragment_program2 -#define GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV 0x88F4 -#define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 -#define GL_MAX_PROGRAM_IF_DEPTH_NV 0x88F6 -#define GL_MAX_PROGRAM_LOOP_DEPTH_NV 0x88F7 -#define GL_MAX_PROGRAM_LOOP_COUNT_NV 0x88F8 -#endif - -#ifndef GL_NV_vertex_program2_option -/* reuse GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV */ -/* reuse GL_MAX_PROGRAM_CALL_DEPTH_NV */ -#endif - -#ifndef GL_NV_vertex_program3 -/* reuse GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB */ -#endif - -#ifndef GL_EXT_framebuffer_object -#define GL_INVALID_FRAMEBUFFER_OPERATION_EXT 0x0506 -#define GL_MAX_RENDERBUFFER_SIZE_EXT 0x84E8 -#define GL_FRAMEBUFFER_BINDING_EXT 0x8CA6 -#define GL_RENDERBUFFER_BINDING_EXT 0x8CA7 -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT 0x8CD0 -#define GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT 0x8CD1 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT 0x8CD2 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT 0x8CD3 -#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT 0x8CD4 -#define GL_FRAMEBUFFER_COMPLETE_EXT 0x8CD5 -#define GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT 0x8CD6 -#define GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT 0x8CD7 -#define GL_FRAMEBUFFER_INCOMPLETE_DUPLICATE_ATTACHMENT_EXT 0x8CD8 -#define GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT 0x8CD9 -#define GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT 0x8CDA -#define GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT 0x8CDB -#define GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT 0x8CDC -#define GL_FRAMEBUFFER_UNSUPPORTED_EXT 0x8CDD -#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF -#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0 -#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1 -#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2 -#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3 -#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4 -#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5 -#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6 -#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7 -#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8 -#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9 -#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA -#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB -#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC -#define GL_COLOR_ATTACHMENT13_EXT 0x8CED -#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE -#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF -#define GL_DEPTH_ATTACHMENT_EXT 0x8D00 -#define GL_STENCIL_ATTACHMENT_EXT 0x8D20 -#define GL_FRAMEBUFFER_EXT 0x8D40 -#define GL_RENDERBUFFER_EXT 0x8D41 -#define GL_RENDERBUFFER_WIDTH_EXT 0x8D42 -#define GL_RENDERBUFFER_HEIGHT_EXT 0x8D43 -#define GL_RENDERBUFFER_INTERNAL_FORMAT_EXT 0x8D44 -#define GL_STENCIL_INDEX1_EXT 0x8D46 -#define GL_STENCIL_INDEX4_EXT 0x8D47 -#define GL_STENCIL_INDEX8_EXT 0x8D48 -#define GL_STENCIL_INDEX16_EXT 0x8D49 -#define GL_RENDERBUFFER_RED_SIZE_EXT 0x8D50 -#define GL_RENDERBUFFER_GREEN_SIZE_EXT 0x8D51 -#define GL_RENDERBUFFER_BLUE_SIZE_EXT 0x8D52 -#define GL_RENDERBUFFER_ALPHA_SIZE_EXT 0x8D53 -#define GL_RENDERBUFFER_DEPTH_SIZE_EXT 0x8D54 -#define GL_RENDERBUFFER_STENCIL_SIZE_EXT 0x8D55 -#endif - -#ifndef GL_GREMEDY_string_marker -#endif - - -/*************************************************************/ - -#include -#ifndef GL_VERSION_2_0 -/* GL type for program/shader text */ -typedef char GLchar; /* native character */ -#endif - -#ifndef GL_VERSION_1_5 -/* GL types for handling large vertex buffer objects */ -typedef ptrdiff_t GLintptr; -typedef ptrdiff_t GLsizeiptr; -#endif - -#ifndef GL_ARB_vertex_buffer_object -/* GL types for handling large vertex buffer objects */ -typedef ptrdiff_t GLintptrARB; -typedef ptrdiff_t GLsizeiptrARB; -#endif - -#ifndef GL_ARB_shader_objects -/* GL types for handling shader object handles and program/shader text */ -typedef char GLcharARB; /* native character */ -typedef unsigned int GLhandleARB; /* shader object handle */ -#endif - -/* GL types for "half" precision (s10e5) float data in host memory */ -#ifndef GL_ARB_half_float_pixel -typedef unsigned short GLhalfARB; -#endif - -#ifndef GL_NV_half_float -typedef unsigned short GLhalfNV; -#endif - -#ifndef GL_VERSION_1_2 -#define GL_VERSION_1_2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendColor (GLclampf, GLclampf, GLclampf, GLclampf); -GLAPI void APIENTRY glBlendEquation (GLenum); -GLAPI void APIENTRY glDrawRangeElements (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTable (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTableParameterfv (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glColorTableParameteriv (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyColorTable (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glGetColorTable (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetColorTableParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glColorSubTable (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyColorSubTable (GLenum, GLsizei, GLint, GLint, GLsizei); -GLAPI void APIENTRY glConvolutionFilter1D (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionParameterf (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glConvolutionParameterfv (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glConvolutionParameteri (GLenum, GLenum, GLint); -GLAPI void APIENTRY glConvolutionParameteriv (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyConvolutionFilter1D (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyConvolutionFilter2D (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetConvolutionFilter (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetConvolutionParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetConvolutionParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetSeparableFilter (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); -GLAPI void APIENTRY glSeparableFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); -GLAPI void APIENTRY glGetHistogram (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetHistogramParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetHistogramParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMinmax (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetMinmaxParameterfv (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMinmaxParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glHistogram (GLenum, GLsizei, GLenum, GLboolean); -GLAPI void APIENTRY glMinmax (GLenum, GLenum, GLboolean); -GLAPI void APIENTRY glResetHistogram (GLenum); -GLAPI void APIENTRY glResetMinmax (GLenum); -GLAPI void APIENTRY glTexImage3D (GLenum, GLint, GLint, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); -typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); -typedef void (APIENTRYP PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIPROC) (GLenum target, GLenum pname, GLint params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSEPARABLEFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); -typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMINMAXPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLHISTOGRAMPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLMINMAXPROC) (GLenum target, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLRESETHISTOGRAMPROC) (GLenum target); -typedef void (APIENTRYP PFNGLRESETMINMAXPROC) (GLenum target); -typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif - -#ifndef GL_VERSION_1_3 -#define GL_VERSION_1_3 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveTexture (GLenum); -GLAPI void APIENTRY glClientActiveTexture (GLenum); -GLAPI void APIENTRY glMultiTexCoord1d (GLenum, GLdouble); -GLAPI void APIENTRY glMultiTexCoord1dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord1f (GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexCoord1fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord1i (GLenum, GLint); -GLAPI void APIENTRY glMultiTexCoord1iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord1s (GLenum, GLshort); -GLAPI void APIENTRY glMultiTexCoord1sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord2d (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord2dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord2f (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord2fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord2i (GLenum, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord2iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord2s (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord2sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord3d (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord3dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord3f (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord3fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord3i (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord3iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord3s (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord3sv (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord4d (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord4dv (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord4f (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord4fv (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord4i (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord4iv (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord4s (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord4sv (GLenum, const GLshort *); -GLAPI void APIENTRY glLoadTransposeMatrixf (const GLfloat *); -GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *); -GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *); -GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *); -GLAPI void APIENTRY glSampleCoverage (GLclampf, GLboolean); -GLAPI void APIENTRY glCompressedTexImage3D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage2D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage1D (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedTexImage (GLenum, GLint, GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FPROC) (GLenum target, GLfloat s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IPROC) (GLenum target, GLint s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SPROC) (GLenum target, GLshort s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DPROC) (GLenum target, GLdouble s, GLdouble t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FPROC) (GLenum target, GLfloat s, GLfloat t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IPROC) (GLenum target, GLint s, GLint t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SPROC) (GLenum target, GLshort s, GLshort t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IPROC) (GLenum target, GLint s, GLint t, GLint r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SPROC) (GLenum target, GLshort s, GLshort t, GLshort r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img); -#endif - -#ifndef GL_VERSION_1_4 -#define GL_VERSION_1_4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparate (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glFogCoordf (GLfloat); -GLAPI void APIENTRY glFogCoordfv (const GLfloat *); -GLAPI void APIENTRY glFogCoordd (GLdouble); -GLAPI void APIENTRY glFogCoorddv (const GLdouble *); -GLAPI void APIENTRY glFogCoordPointer (GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glMultiDrawArrays (GLenum, GLint *, GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawElements (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); -GLAPI void APIENTRY glPointParameterf (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfv (GLenum, const GLfloat *); -GLAPI void APIENTRY glPointParameteri (GLenum, GLint); -GLAPI void APIENTRY glPointParameteriv (GLenum, const GLint *); -GLAPI void APIENTRY glSecondaryColor3b (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glSecondaryColor3bv (const GLbyte *); -GLAPI void APIENTRY glSecondaryColor3d (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glSecondaryColor3dv (const GLdouble *); -GLAPI void APIENTRY glSecondaryColor3f (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glSecondaryColor3fv (const GLfloat *); -GLAPI void APIENTRY glSecondaryColor3i (GLint, GLint, GLint); -GLAPI void APIENTRY glSecondaryColor3iv (const GLint *); -GLAPI void APIENTRY glSecondaryColor3s (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glSecondaryColor3sv (const GLshort *); -GLAPI void APIENTRY glSecondaryColor3ub (GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glSecondaryColor3ubv (const GLubyte *); -GLAPI void APIENTRY glSecondaryColor3ui (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSecondaryColor3uiv (const GLuint *); -GLAPI void APIENTRY glSecondaryColor3us (GLushort, GLushort, GLushort); -GLAPI void APIENTRY glSecondaryColor3usv (const GLushort *); -GLAPI void APIENTRY glSecondaryColorPointer (GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glWindowPos2d (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dv (const GLdouble *); -GLAPI void APIENTRY glWindowPos2f (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fv (const GLfloat *); -GLAPI void APIENTRY glWindowPos2i (GLint, GLint); -GLAPI void APIENTRY glWindowPos2iv (const GLint *); -GLAPI void APIENTRY glWindowPos2s (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2sv (const GLshort *); -GLAPI void APIENTRY glWindowPos3d (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dv (const GLdouble *); -GLAPI void APIENTRY glWindowPos3f (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fv (const GLfloat *); -GLAPI void APIENTRY glWindowPos3i (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3iv (const GLint *); -GLAPI void APIENTRY glWindowPos3s (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3sv (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -typedef void (APIENTRYP PFNGLFOGCOORDFPROC) (GLfloat coord); -typedef void (APIENTRYP PFNGLFOGCOORDFVPROC) (const GLfloat *coord); -typedef void (APIENTRYP PFNGLFOGCOORDDPROC) (GLdouble coord); -typedef void (APIENTRYP PFNGLFOGCOORDDVPROC) (const GLdouble *coord); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTERPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BPROC) (GLbyte red, GLbyte green, GLbyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DPROC) (GLdouble red, GLdouble green, GLdouble blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FPROC) (GLfloat red, GLfloat green, GLfloat blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IPROC) (GLint red, GLint green, GLint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SPROC) (GLshort red, GLshort green, GLshort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBPROC) (GLubyte red, GLubyte green, GLubyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVPROC) (const GLubyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIPROC) (GLuint red, GLuint green, GLuint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVPROC) (const GLuint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USPROC) (GLushort red, GLushort green, GLushort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVPROC) (const GLushort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLWINDOWPOS2DPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVPROC) (const GLshort *v); -#endif - -#ifndef GL_VERSION_1_5 -#define GL_VERSION_1_5 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenQueries (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteQueries (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsQuery (GLuint); -GLAPI void APIENTRY glBeginQuery (GLenum, GLuint); -GLAPI void APIENTRY glEndQuery (GLenum); -GLAPI void APIENTRY glGetQueryiv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectuiv (GLuint, GLenum, GLuint *); -GLAPI void APIENTRY glBindBuffer (GLenum, GLuint); -GLAPI void APIENTRY glDeleteBuffers (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenBuffers (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsBuffer (GLuint); -GLAPI void APIENTRY glBufferData (GLenum, GLsizeiptr, const GLvoid *, GLenum); -GLAPI void APIENTRY glBufferSubData (GLenum, GLintptr, GLsizeiptr, const GLvoid *); -GLAPI void APIENTRY glGetBufferSubData (GLenum, GLintptr, GLsizeiptr, GLvoid *); -GLAPI GLvoid* APIENTRY glMapBuffer (GLenum, GLenum); -GLAPI GLboolean APIENTRY glUnmapBuffer (GLenum); -GLAPI void APIENTRY glGetBufferParameteriv (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetBufferPointerv (GLenum, GLenum, GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENQUERIESPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEQUERIESPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISQUERYPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINQUERYPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLENDQUERYPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETQUERYIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVPROC) (GLuint id, GLenum pname, GLuint *params); -typedef void (APIENTRYP PFNGLBINDBUFFERPROC) (GLenum target, GLuint buffer); -typedef void (APIENTRYP PFNGLDELETEBUFFERSPROC) (GLsizei n, const GLuint *buffers); -typedef void (APIENTRYP PFNGLGENBUFFERSPROC) (GLsizei n, GLuint *buffers); -typedef GLboolean (APIENTRYP PFNGLISBUFFERPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLBUFFERDATAPROC) (GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage); -typedef void (APIENTRYP PFNGLBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAPROC) (GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data); -typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERPROC) (GLenum target, GLenum access); -typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVPROC) (GLenum target, GLenum pname, GLvoid* *params); -#endif - -#ifndef GL_VERSION_2_0 -#define GL_VERSION_2_0 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationSeparate (GLenum, GLenum); -GLAPI void APIENTRY glDrawBuffers (GLsizei, const GLenum *); -GLAPI void APIENTRY glStencilOpSeparate (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glStencilFuncSeparate (GLenum, GLenum, GLint, GLuint); -GLAPI void APIENTRY glStencilMaskSeparate (GLenum, GLuint); -GLAPI void APIENTRY glAttachShader (GLuint, GLuint); -GLAPI void APIENTRY glBindAttribLocation (GLuint, GLuint, const GLchar *); -GLAPI void APIENTRY glCompileShader (GLuint); -GLAPI GLuint APIENTRY glCreateProgram (void); -GLAPI GLuint APIENTRY glCreateShader (GLenum); -GLAPI void APIENTRY glDeleteProgram (GLuint); -GLAPI void APIENTRY glDeleteShader (GLuint); -GLAPI void APIENTRY glDetachShader (GLuint, GLuint); -GLAPI void APIENTRY glDisableVertexAttribArray (GLuint); -GLAPI void APIENTRY glEnableVertexAttribArray (GLuint); -GLAPI void APIENTRY glGetActiveAttrib (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); -GLAPI void APIENTRY glGetActiveUniform (GLuint, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLchar *); -GLAPI void APIENTRY glGetAttachedShaders (GLuint, GLsizei, GLsizei *, GLuint *); -GLAPI GLint APIENTRY glGetAttribLocation (GLuint, const GLchar *); -GLAPI void APIENTRY glGetProgramiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI void APIENTRY glGetShaderiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetShaderInfoLog (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI void APIENTRY glGetShaderSource (GLuint, GLsizei, GLsizei *, GLchar *); -GLAPI GLint APIENTRY glGetUniformLocation (GLuint, const GLchar *); -GLAPI void APIENTRY glGetUniformfv (GLuint, GLint, GLfloat *); -GLAPI void APIENTRY glGetUniformiv (GLuint, GLint, GLint *); -GLAPI void APIENTRY glGetVertexAttribdv (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfv (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribiv (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointerv (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgram (GLuint); -GLAPI GLboolean APIENTRY glIsShader (GLuint); -GLAPI void APIENTRY glLinkProgram (GLuint); -GLAPI void APIENTRY glShaderSource (GLuint, GLsizei, const GLchar* *, const GLint *); -GLAPI void APIENTRY glUseProgram (GLuint); -GLAPI void APIENTRY glUniform1f (GLint, GLfloat); -GLAPI void APIENTRY glUniform2f (GLint, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform3f (GLint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform4f (GLint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform1i (GLint, GLint); -GLAPI void APIENTRY glUniform2i (GLint, GLint, GLint); -GLAPI void APIENTRY glUniform3i (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform4i (GLint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform1fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform2fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform3fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform4fv (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform1iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform2iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform3iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform4iv (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniformMatrix2fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4fv (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glValidateProgram (GLuint); -GLAPI void APIENTRY glVertexAttrib1d (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1f (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1s (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2d (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2f (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2s (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3d (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3f (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3s (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4Nbv (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4Niv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4Nsv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4Nub (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4Nubv (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4Nuiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4Nusv (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttrib4bv (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4d (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dv (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4f (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fv (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4iv (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4s (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4sv (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubv (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4uiv (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4usv (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribPointer (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEPROC) (GLenum modeRGB, GLenum modeAlpha); -typedef void (APIENTRYP PFNGLDRAWBUFFERSPROC) (GLsizei n, const GLenum *bufs); -typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); -typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); -typedef void (APIENTRYP PFNGLSTENCILMASKSEPARATEPROC) (GLenum face, GLuint mask); -typedef void (APIENTRYP PFNGLATTACHSHADERPROC) (GLuint program, GLuint shader); -typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONPROC) (GLuint program, GLuint index, const GLchar *name); -typedef void (APIENTRYP PFNGLCOMPILESHADERPROC) (GLuint shader); -typedef GLuint (APIENTRYP PFNGLCREATEPROGRAMPROC) (void); -typedef GLuint (APIENTRYP PFNGLCREATESHADERPROC) (GLenum type); -typedef void (APIENTRYP PFNGLDELETEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLDELETESHADERPROC) (GLuint shader); -typedef void (APIENTRYP PFNGLDETACHSHADERPROC) (GLuint program, GLuint shader); -typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYPROC) (GLuint index); -typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYPROC) (GLuint index); -typedef void (APIENTRYP PFNGLGETACTIVEATTRIBPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); -typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMPROC) (GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name); -typedef void (APIENTRYP PFNGLGETATTACHEDSHADERSPROC) (GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj); -typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLGETPROGRAMIVPROC) (GLuint program, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMINFOLOGPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog); -typedef void (APIENTRYP PFNGLGETSHADERIVPROC) (GLuint shader, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSHADERINFOLOGPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog); -typedef void (APIENTRYP PFNGLGETSHADERSOURCEPROC) (GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source); -typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONPROC) (GLuint program, const GLchar *name); -typedef void (APIENTRYP PFNGLGETUNIFORMFVPROC) (GLuint program, GLint location, GLfloat *params); -typedef void (APIENTRYP PFNGLGETUNIFORMIVPROC) (GLuint program, GLint location, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMPROC) (GLuint program); -typedef GLboolean (APIENTRYP PFNGLISSHADERPROC) (GLuint shader); -typedef void (APIENTRYP PFNGLLINKPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLSHADERSOURCEPROC) (GLuint shader, GLsizei count, const GLchar* *string, const GLint *length); -typedef void (APIENTRYP PFNGLUSEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLUNIFORM1FPROC) (GLint location, GLfloat v0); -typedef void (APIENTRYP PFNGLUNIFORM2FPROC) (GLint location, GLfloat v0, GLfloat v1); -typedef void (APIENTRYP PFNGLUNIFORM3FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); -typedef void (APIENTRYP PFNGLUNIFORM4FPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); -typedef void (APIENTRYP PFNGLUNIFORM1IPROC) (GLint location, GLint v0); -typedef void (APIENTRYP PFNGLUNIFORM2IPROC) (GLint location, GLint v0, GLint v1); -typedef void (APIENTRYP PFNGLUNIFORM3IPROC) (GLint location, GLint v0, GLint v1, GLint v2); -typedef void (APIENTRYP PFNGLUNIFORM4IPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); -typedef void (APIENTRYP PFNGLUNIFORM1FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM2FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM3FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM4FVPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM1IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM2IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM3IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM4IVPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLVALIDATEPROGRAMPROC) (GLuint program); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_ARB_multitexture -#define GL_ARB_multitexture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveTextureARB (GLenum); -GLAPI void APIENTRY glClientActiveTextureARB (GLenum); -GLAPI void APIENTRY glMultiTexCoord1dARB (GLenum, GLdouble); -GLAPI void APIENTRY glMultiTexCoord1dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord1fARB (GLenum, GLfloat); -GLAPI void APIENTRY glMultiTexCoord1fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord1iARB (GLenum, GLint); -GLAPI void APIENTRY glMultiTexCoord1ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord1sARB (GLenum, GLshort); -GLAPI void APIENTRY glMultiTexCoord1svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord2dARB (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord2dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord2fARB (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord2fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord2iARB (GLenum, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord2ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord2sARB (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord2svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord3dARB (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord3dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord3fARB (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord3fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord3iARB (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord3ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord3sARB (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord3svARB (GLenum, const GLshort *); -GLAPI void APIENTRY glMultiTexCoord4dARB (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glMultiTexCoord4dvARB (GLenum, const GLdouble *); -GLAPI void APIENTRY glMultiTexCoord4fARB (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glMultiTexCoord4fvARB (GLenum, const GLfloat *); -GLAPI void APIENTRY glMultiTexCoord4iARB (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glMultiTexCoord4ivARB (GLenum, const GLint *); -GLAPI void APIENTRY glMultiTexCoord4sARB (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glMultiTexCoord4svARB (GLenum, const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v); -#endif - -#ifndef GL_ARB_transpose_matrix -#define GL_ARB_transpose_matrix 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glLoadTransposeMatrixfARB (const GLfloat *); -GLAPI void APIENTRY glLoadTransposeMatrixdARB (const GLdouble *); -GLAPI void APIENTRY glMultTransposeMatrixfARB (const GLfloat *); -GLAPI void APIENTRY glMultTransposeMatrixdARB (const GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXFARBPROC) (const GLfloat *m); -typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDARBPROC) (const GLdouble *m); -#endif - -#ifndef GL_ARB_multisample -#define GL_ARB_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleCoverageARB (GLclampf, GLboolean); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLECOVERAGEARBPROC) (GLclampf value, GLboolean invert); -#endif - -#ifndef GL_ARB_texture_env_add -#define GL_ARB_texture_env_add 1 -#endif - -#ifndef GL_ARB_texture_cube_map -#define GL_ARB_texture_cube_map 1 -#endif - -#ifndef GL_ARB_texture_compression -#define GL_ARB_texture_compression 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCompressedTexImage3DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage2DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexImage1DARB (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage3DARB (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage2DARB (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glCompressedTexSubImage1DARB (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glGetCompressedTexImageARB (GLenum, GLint, GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DARBPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEARBPROC) (GLenum target, GLint level, GLvoid *img); -#endif - -#ifndef GL_ARB_texture_border_clamp -#define GL_ARB_texture_border_clamp 1 -#endif - -#ifndef GL_ARB_point_parameters -#define GL_ARB_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfARB (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvARB (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFARBPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVARBPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_ARB_vertex_blend -#define GL_ARB_vertex_blend 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWeightbvARB (GLint, const GLbyte *); -GLAPI void APIENTRY glWeightsvARB (GLint, const GLshort *); -GLAPI void APIENTRY glWeightivARB (GLint, const GLint *); -GLAPI void APIENTRY glWeightfvARB (GLint, const GLfloat *); -GLAPI void APIENTRY glWeightdvARB (GLint, const GLdouble *); -GLAPI void APIENTRY glWeightubvARB (GLint, const GLubyte *); -GLAPI void APIENTRY glWeightusvARB (GLint, const GLushort *); -GLAPI void APIENTRY glWeightuivARB (GLint, const GLuint *); -GLAPI void APIENTRY glWeightPointerARB (GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexBlendARB (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWEIGHTBVARBPROC) (GLint size, const GLbyte *weights); -typedef void (APIENTRYP PFNGLWEIGHTSVARBPROC) (GLint size, const GLshort *weights); -typedef void (APIENTRYP PFNGLWEIGHTIVARBPROC) (GLint size, const GLint *weights); -typedef void (APIENTRYP PFNGLWEIGHTFVARBPROC) (GLint size, const GLfloat *weights); -typedef void (APIENTRYP PFNGLWEIGHTDVARBPROC) (GLint size, const GLdouble *weights); -typedef void (APIENTRYP PFNGLWEIGHTUBVARBPROC) (GLint size, const GLubyte *weights); -typedef void (APIENTRYP PFNGLWEIGHTUSVARBPROC) (GLint size, const GLushort *weights); -typedef void (APIENTRYP PFNGLWEIGHTUIVARBPROC) (GLint size, const GLuint *weights); -typedef void (APIENTRYP PFNGLWEIGHTPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXBLENDARBPROC) (GLint count); -#endif - -#ifndef GL_ARB_matrix_palette -#define GL_ARB_matrix_palette 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCurrentPaletteMatrixARB (GLint); -GLAPI void APIENTRY glMatrixIndexubvARB (GLint, const GLubyte *); -GLAPI void APIENTRY glMatrixIndexusvARB (GLint, const GLushort *); -GLAPI void APIENTRY glMatrixIndexuivARB (GLint, const GLuint *); -GLAPI void APIENTRY glMatrixIndexPointerARB (GLint, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCURRENTPALETTEMATRIXARBPROC) (GLint index); -typedef void (APIENTRYP PFNGLMATRIXINDEXUBVARBPROC) (GLint size, const GLubyte *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXUSVARBPROC) (GLint size, const GLushort *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXUIVARBPROC) (GLint size, const GLuint *indices); -typedef void (APIENTRYP PFNGLMATRIXINDEXPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_ARB_texture_env_combine -#define GL_ARB_texture_env_combine 1 -#endif - -#ifndef GL_ARB_texture_env_crossbar -#define GL_ARB_texture_env_crossbar 1 -#endif - -#ifndef GL_ARB_texture_env_dot3 -#define GL_ARB_texture_env_dot3 1 -#endif - -#ifndef GL_ARB_texture_mirrored_repeat -#define GL_ARB_texture_mirrored_repeat 1 -#endif - -#ifndef GL_ARB_depth_texture -#define GL_ARB_depth_texture 1 -#endif - -#ifndef GL_ARB_shadow -#define GL_ARB_shadow 1 -#endif - -#ifndef GL_ARB_shadow_ambient -#define GL_ARB_shadow_ambient 1 -#endif - -#ifndef GL_ARB_window_pos -#define GL_ARB_window_pos 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWindowPos2dARB (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dvARB (const GLdouble *); -GLAPI void APIENTRY glWindowPos2fARB (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fvARB (const GLfloat *); -GLAPI void APIENTRY glWindowPos2iARB (GLint, GLint); -GLAPI void APIENTRY glWindowPos2ivARB (const GLint *); -GLAPI void APIENTRY glWindowPos2sARB (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2svARB (const GLshort *); -GLAPI void APIENTRY glWindowPos3dARB (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dvARB (const GLdouble *); -GLAPI void APIENTRY glWindowPos3fARB (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fvARB (const GLfloat *); -GLAPI void APIENTRY glWindowPos3iARB (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3ivARB (const GLint *); -GLAPI void APIENTRY glWindowPos3sARB (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3svARB (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWINDOWPOS2DARBPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVARBPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FARBPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVARBPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IARBPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVARBPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SARBPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVARBPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DARBPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVARBPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FARBPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVARBPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IARBPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVARBPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SARBPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVARBPROC) (const GLshort *v); -#endif - -#ifndef GL_ARB_vertex_program -#define GL_ARB_vertex_program 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttrib1dARB (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1fARB (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1sARB (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2dARB (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2fARB (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2sARB (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3dARB (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3fARB (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3sARB (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4NbvARB (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4NivARB (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4NsvARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4NubARB (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4NubvARB (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4NuivARB (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4NusvARB (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttrib4bvARB (GLuint, const GLbyte *); -GLAPI void APIENTRY glVertexAttrib4dARB (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dvARB (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4fARB (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fvARB (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4ivARB (GLuint, const GLint *); -GLAPI void APIENTRY glVertexAttrib4sARB (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4svARB (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubvARB (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttrib4uivARB (GLuint, const GLuint *); -GLAPI void APIENTRY glVertexAttrib4usvARB (GLuint, const GLushort *); -GLAPI void APIENTRY glVertexAttribPointerARB (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *); -GLAPI void APIENTRY glEnableVertexAttribArrayARB (GLuint); -GLAPI void APIENTRY glDisableVertexAttribArrayARB (GLuint); -GLAPI void APIENTRY glProgramStringARB (GLenum, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glBindProgramARB (GLenum, GLuint); -GLAPI void APIENTRY glDeleteProgramsARB (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenProgramsARB (GLsizei, GLuint *); -GLAPI void APIENTRY glProgramEnvParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramEnvParameter4dvARB (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramEnvParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramEnvParameter4fvARB (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glProgramLocalParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramLocalParameter4dvARB (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramLocalParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramLocalParameter4fvARB (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glGetProgramEnvParameterdvARB (GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetProgramEnvParameterfvARB (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetProgramLocalParameterdvARB (GLenum, GLuint, GLdouble *); -GLAPI void APIENTRY glGetProgramLocalParameterfvARB (GLenum, GLuint, GLfloat *); -GLAPI void APIENTRY glGetProgramivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramStringARB (GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetVertexAttribdvARB (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfvARB (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribivARB (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointervARB (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgramARB (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DARBPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FARBPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SARBPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DARBPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FARBPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SARBPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NBVARBPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NIVARBPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NSVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBARBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUBVARBPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUIVARBPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4NUSVARBPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4BVARBPROC) (GLuint index, const GLbyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVARBPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVARBPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4IVARBPROC) (GLuint index, const GLint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVARBPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVARBPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UIVARBPROC) (GLuint index, const GLuint *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4USVARBPROC) (GLuint index, const GLushort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERARBPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLENABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); -typedef void (APIENTRYP PFNGLDISABLEVERTEXATTRIBARRAYARBPROC) (GLuint index); -typedef void (APIENTRYP PFNGLPROGRAMSTRINGARBPROC) (GLenum target, GLenum format, GLsizei len, const GLvoid *string); -typedef void (APIENTRYP PFNGLBINDPROGRAMARBPROC) (GLenum target, GLuint program); -typedef void (APIENTRYP PFNGLDELETEPROGRAMSARBPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLGENPROGRAMSARBPROC) (GLsizei n, GLuint *programs); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMENVPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMLOCALPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMENVPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMLOCALPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGARBPROC) (GLenum target, GLenum pname, GLvoid *string); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVARBPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVARBPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVARBPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVARBPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMARBPROC) (GLuint program); -#endif - -#ifndef GL_ARB_fragment_program -#define GL_ARB_fragment_program 1 -/* All ARB_fragment_program entry points are shared with ARB_vertex_program. */ -#endif - -#ifndef GL_ARB_vertex_buffer_object -#define GL_ARB_vertex_buffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindBufferARB (GLenum, GLuint); -GLAPI void APIENTRY glDeleteBuffersARB (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenBuffersARB (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsBufferARB (GLuint); -GLAPI void APIENTRY glBufferDataARB (GLenum, GLsizeiptrARB, const GLvoid *, GLenum); -GLAPI void APIENTRY glBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, const GLvoid *); -GLAPI void APIENTRY glGetBufferSubDataARB (GLenum, GLintptrARB, GLsizeiptrARB, GLvoid *); -GLAPI GLvoid* APIENTRY glMapBufferARB (GLenum, GLenum); -GLAPI GLboolean APIENTRY glUnmapBufferARB (GLenum); -GLAPI void APIENTRY glGetBufferParameterivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetBufferPointervARB (GLenum, GLenum, GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDBUFFERARBPROC) (GLenum target, GLuint buffer); -typedef void (APIENTRYP PFNGLDELETEBUFFERSARBPROC) (GLsizei n, const GLuint *buffers); -typedef void (APIENTRYP PFNGLGENBUFFERSARBPROC) (GLsizei n, GLuint *buffers); -typedef GLboolean (APIENTRYP PFNGLISBUFFERARBPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLBUFFERDATAARBPROC) (GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage); -typedef void (APIENTRYP PFNGLBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data); -typedef void (APIENTRYP PFNGLGETBUFFERSUBDATAARBPROC) (GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data); -typedef GLvoid* (APIENTRYP PFNGLMAPBUFFERARBPROC) (GLenum target, GLenum access); -typedef GLboolean (APIENTRYP PFNGLUNMAPBUFFERARBPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETBUFFERPARAMETERIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETBUFFERPOINTERVARBPROC) (GLenum target, GLenum pname, GLvoid* *params); -#endif - -#ifndef GL_ARB_occlusion_query -#define GL_ARB_occlusion_query 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenQueriesARB (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteQueriesARB (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsQueryARB (GLuint); -GLAPI void APIENTRY glBeginQueryARB (GLenum, GLuint); -GLAPI void APIENTRY glEndQueryARB (GLenum); -GLAPI void APIENTRY glGetQueryivARB (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectivARB (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetQueryObjectuivARB (GLuint, GLenum, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENQUERIESARBPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEQUERIESARBPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISQUERYARBPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINQUERYARBPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLENDQUERYARBPROC) (GLenum target); -typedef void (APIENTRYP PFNGLGETQUERYIVARBPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTIVARBPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETQUERYOBJECTUIVARBPROC) (GLuint id, GLenum pname, GLuint *params); -#endif - -#ifndef GL_ARB_shader_objects -#define GL_ARB_shader_objects 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeleteObjectARB (GLhandleARB); -GLAPI GLhandleARB APIENTRY glGetHandleARB (GLenum); -GLAPI void APIENTRY glDetachObjectARB (GLhandleARB, GLhandleARB); -GLAPI GLhandleARB APIENTRY glCreateShaderObjectARB (GLenum); -GLAPI void APIENTRY glShaderSourceARB (GLhandleARB, GLsizei, const GLcharARB* *, const GLint *); -GLAPI void APIENTRY glCompileShaderARB (GLhandleARB); -GLAPI GLhandleARB APIENTRY glCreateProgramObjectARB (void); -GLAPI void APIENTRY glAttachObjectARB (GLhandleARB, GLhandleARB); -GLAPI void APIENTRY glLinkProgramARB (GLhandleARB); -GLAPI void APIENTRY glUseProgramObjectARB (GLhandleARB); -GLAPI void APIENTRY glValidateProgramARB (GLhandleARB); -GLAPI void APIENTRY glUniform1fARB (GLint, GLfloat); -GLAPI void APIENTRY glUniform2fARB (GLint, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform3fARB (GLint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform4fARB (GLint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glUniform1iARB (GLint, GLint); -GLAPI void APIENTRY glUniform2iARB (GLint, GLint, GLint); -GLAPI void APIENTRY glUniform3iARB (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform4iARB (GLint, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glUniform1fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform2fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform3fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform4fvARB (GLint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glUniform1ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform2ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform3ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniform4ivARB (GLint, GLsizei, const GLint *); -GLAPI void APIENTRY glUniformMatrix2fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix3fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glUniformMatrix4fvARB (GLint, GLsizei, GLboolean, const GLfloat *); -GLAPI void APIENTRY glGetObjectParameterfvARB (GLhandleARB, GLenum, GLfloat *); -GLAPI void APIENTRY glGetObjectParameterivARB (GLhandleARB, GLenum, GLint *); -GLAPI void APIENTRY glGetInfoLogARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); -GLAPI void APIENTRY glGetAttachedObjectsARB (GLhandleARB, GLsizei, GLsizei *, GLhandleARB *); -GLAPI GLint APIENTRY glGetUniformLocationARB (GLhandleARB, const GLcharARB *); -GLAPI void APIENTRY glGetActiveUniformARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); -GLAPI void APIENTRY glGetUniformfvARB (GLhandleARB, GLint, GLfloat *); -GLAPI void APIENTRY glGetUniformivARB (GLhandleARB, GLint, GLint *); -GLAPI void APIENTRY glGetShaderSourceARB (GLhandleARB, GLsizei, GLsizei *, GLcharARB *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDELETEOBJECTARBPROC) (GLhandleARB obj); -typedef GLhandleARB (APIENTRYP PFNGLGETHANDLEARBPROC) (GLenum pname); -typedef void (APIENTRYP PFNGLDETACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB attachedObj); -typedef GLhandleARB (APIENTRYP PFNGLCREATESHADEROBJECTARBPROC) (GLenum shaderType); -typedef void (APIENTRYP PFNGLSHADERSOURCEARBPROC) (GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length); -typedef void (APIENTRYP PFNGLCOMPILESHADERARBPROC) (GLhandleARB shaderObj); -typedef GLhandleARB (APIENTRYP PFNGLCREATEPROGRAMOBJECTARBPROC) (void); -typedef void (APIENTRYP PFNGLATTACHOBJECTARBPROC) (GLhandleARB containerObj, GLhandleARB obj); -typedef void (APIENTRYP PFNGLLINKPROGRAMARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLUSEPROGRAMOBJECTARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLVALIDATEPROGRAMARBPROC) (GLhandleARB programObj); -typedef void (APIENTRYP PFNGLUNIFORM1FARBPROC) (GLint location, GLfloat v0); -typedef void (APIENTRYP PFNGLUNIFORM2FARBPROC) (GLint location, GLfloat v0, GLfloat v1); -typedef void (APIENTRYP PFNGLUNIFORM3FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2); -typedef void (APIENTRYP PFNGLUNIFORM4FARBPROC) (GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3); -typedef void (APIENTRYP PFNGLUNIFORM1IARBPROC) (GLint location, GLint v0); -typedef void (APIENTRYP PFNGLUNIFORM2IARBPROC) (GLint location, GLint v0, GLint v1); -typedef void (APIENTRYP PFNGLUNIFORM3IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2); -typedef void (APIENTRYP PFNGLUNIFORM4IARBPROC) (GLint location, GLint v0, GLint v1, GLint v2, GLint v3); -typedef void (APIENTRYP PFNGLUNIFORM1FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM2FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM3FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM4FVARBPROC) (GLint location, GLsizei count, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORM1IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM2IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM3IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORM4IVARBPROC) (GLint location, GLsizei count, const GLint *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX2FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX3FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLUNIFORMMATRIX4FVARBPROC) (GLint location, GLsizei count, GLboolean transpose, const GLfloat *value); -typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERFVARBPROC) (GLhandleARB obj, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETOBJECTPARAMETERIVARBPROC) (GLhandleARB obj, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETINFOLOGARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog); -typedef void (APIENTRYP PFNGLGETATTACHEDOBJECTSARBPROC) (GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj); -typedef GLint (APIENTRYP PFNGLGETUNIFORMLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); -typedef void (APIENTRYP PFNGLGETACTIVEUNIFORMARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); -typedef void (APIENTRYP PFNGLGETUNIFORMFVARBPROC) (GLhandleARB programObj, GLint location, GLfloat *params); -typedef void (APIENTRYP PFNGLGETUNIFORMIVARBPROC) (GLhandleARB programObj, GLint location, GLint *params); -typedef void (APIENTRYP PFNGLGETSHADERSOURCEARBPROC) (GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source); -#endif - -#ifndef GL_ARB_vertex_shader -#define GL_ARB_vertex_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindAttribLocationARB (GLhandleARB, GLuint, const GLcharARB *); -GLAPI void APIENTRY glGetActiveAttribARB (GLhandleARB, GLuint, GLsizei, GLsizei *, GLint *, GLenum *, GLcharARB *); -GLAPI GLint APIENTRY glGetAttribLocationARB (GLhandleARB, const GLcharARB *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDATTRIBLOCATIONARBPROC) (GLhandleARB programObj, GLuint index, const GLcharARB *name); -typedef void (APIENTRYP PFNGLGETACTIVEATTRIBARBPROC) (GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name); -typedef GLint (APIENTRYP PFNGLGETATTRIBLOCATIONARBPROC) (GLhandleARB programObj, const GLcharARB *name); -#endif - -#ifndef GL_ARB_fragment_shader -#define GL_ARB_fragment_shader 1 -#endif - -#ifndef GL_ARB_shading_language_100 -#define GL_ARB_shading_language_100 1 -#endif - -#ifndef GL_ARB_texture_non_power_of_two -#define GL_ARB_texture_non_power_of_two 1 -#endif - -#ifndef GL_ARB_point_sprite -#define GL_ARB_point_sprite 1 -#endif - -#ifndef GL_ARB_fragment_program_shadow -#define GL_ARB_fragment_program_shadow 1 -#endif - -#ifndef GL_ARB_draw_buffers -#define GL_ARB_draw_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawBuffersARB (GLsizei, const GLenum *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWBUFFERSARBPROC) (GLsizei n, const GLenum *bufs); -#endif - -#ifndef GL_ARB_texture_rectangle -#define GL_ARB_texture_rectangle 1 -#endif - -#ifndef GL_ARB_color_buffer_float -#define GL_ARB_color_buffer_float 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glClampColorARB (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCLAMPCOLORARBPROC) (GLenum target, GLenum clamp); -#endif - -#ifndef GL_ARB_half_float_pixel -#define GL_ARB_half_float_pixel 1 -#endif - -#ifndef GL_ARB_texture_float -#define GL_ARB_texture_float 1 -#endif - -#ifndef GL_ARB_pixel_buffer_object -#define GL_ARB_pixel_buffer_object 1 -#endif - -#ifndef GL_EXT_abgr -#define GL_EXT_abgr 1 -#endif - -#ifndef GL_EXT_blend_color -#define GL_EXT_blend_color 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendColorEXT (GLclampf, GLclampf, GLclampf, GLclampf); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDCOLOREXTPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha); -#endif - -#ifndef GL_EXT_polygon_offset -#define GL_EXT_polygon_offset 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPolygonOffsetEXT (GLfloat, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOLYGONOFFSETEXTPROC) (GLfloat factor, GLfloat bias); -#endif - -#ifndef GL_EXT_texture -#define GL_EXT_texture 1 -#endif - -#ifndef GL_EXT_texture3D -#define GL_EXT_texture3D 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexImage3DEXT (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXIMAGE3DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_SGIS_texture_filter4 -#define GL_SGIS_texture_filter4 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetTexFilterFuncSGIS (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glTexFilterFuncSGIS (GLenum, GLenum, GLsizei, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLfloat *weights); -typedef void (APIENTRYP PFNGLTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLsizei n, const GLfloat *weights); -#endif - -#ifndef GL_EXT_subtexture -#define GL_EXT_subtexture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexSubImage1DEXT (GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_EXT_copy_texture -#define GL_EXT_copy_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCopyTexImage1DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint); -GLAPI void APIENTRY glCopyTexImage2DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint); -GLAPI void APIENTRY glCopyTexSubImage1DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glCopyTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOPYTEXIMAGE1DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXIMAGE2DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height); -#endif - -#ifndef GL_EXT_histogram -#define GL_EXT_histogram 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetHistogramEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetHistogramParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetHistogramParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMinmaxEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetMinmaxParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMinmaxParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glHistogramEXT (GLenum, GLsizei, GLenum, GLboolean); -GLAPI void APIENTRY glMinmaxEXT (GLenum, GLenum, GLboolean); -GLAPI void APIENTRY glResetHistogramEXT (GLenum); -GLAPI void APIENTRY glResetMinmaxEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETHISTOGRAMEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMINMAXEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMINMAXPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLHISTOGRAMEXTPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLMINMAXEXTPROC) (GLenum target, GLenum internalformat, GLboolean sink); -typedef void (APIENTRYP PFNGLRESETHISTOGRAMEXTPROC) (GLenum target); -typedef void (APIENTRYP PFNGLRESETMINMAXEXTPROC) (GLenum target); -#endif - -#ifndef GL_EXT_convolution -#define GL_EXT_convolution 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glConvolutionFilter1DEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glConvolutionParameterfEXT (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glConvolutionParameterfvEXT (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glConvolutionParameteriEXT (GLenum, GLenum, GLint); -GLAPI void APIENTRY glConvolutionParameterivEXT (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyConvolutionFilter1DEXT (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glCopyConvolutionFilter2DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei); -GLAPI void APIENTRY glGetConvolutionFilterEXT (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetConvolutionParameterfvEXT (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetConvolutionParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetSeparableFilterEXT (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *); -GLAPI void APIENTRY glSeparableFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint params); -typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLCOPYCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETSEPARABLEFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span); -typedef void (APIENTRYP PFNGLSEPARABLEFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column); -#endif - -#ifndef GL_EXT_color_matrix -#define GL_EXT_color_matrix 1 -#endif - -#ifndef GL_SGI_color_table -#define GL_SGI_color_table 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorTableSGI (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glColorTableParameterfvSGI (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glColorTableParameterivSGI (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glCopyColorTableSGI (GLenum, GLenum, GLint, GLint, GLsizei); -GLAPI void APIENTRY glGetColorTableSGI (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterfvSGI (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetColorTableParameterivSGI (GLenum, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOPYCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width); -typedef void (APIENTRYP PFNGLGETCOLORTABLESGIPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, GLint *params); -#endif - -#ifndef GL_SGIX_pixel_texture -#define GL_SGIX_pixel_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTexGenSGIX (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTEXGENSGIXPROC) (GLenum mode); -#endif - -#ifndef GL_SGIS_pixel_texture -#define GL_SGIS_pixel_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTexGenParameteriSGIS (GLenum, GLint); -GLAPI void APIENTRY glPixelTexGenParameterivSGIS (GLenum, const GLint *); -GLAPI void APIENTRY glPixelTexGenParameterfSGIS (GLenum, GLfloat); -GLAPI void APIENTRY glPixelTexGenParameterfvSGIS (GLenum, const GLfloat *); -GLAPI void APIENTRY glGetPixelTexGenParameterivSGIS (GLenum, GLint *); -GLAPI void APIENTRY glGetPixelTexGenParameterfvSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERISGISPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFSGISPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, GLfloat *params); -#endif - -#ifndef GL_SGIS_texture4D -#define GL_SGIS_texture4D 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexImage4DSGIS (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glTexSubImage4DSGIS (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXIMAGE4DSGISPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels); -typedef void (APIENTRYP PFNGLTEXSUBIMAGE4DSGISPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels); -#endif - -#ifndef GL_SGI_texture_color_table -#define GL_SGI_texture_color_table 1 -#endif - -#ifndef GL_EXT_cmyka -#define GL_EXT_cmyka 1 -#endif - -#ifndef GL_EXT_texture_object -#define GL_EXT_texture_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glAreTexturesResidentEXT (GLsizei, const GLuint *, GLboolean *); -GLAPI void APIENTRY glBindTextureEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteTexturesEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenTexturesEXT (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsTextureEXT (GLuint); -GLAPI void APIENTRY glPrioritizeTexturesEXT (GLsizei, const GLuint *, const GLclampf *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLARETEXTURESRESIDENTEXTPROC) (GLsizei n, const GLuint *textures, GLboolean *residences); -typedef void (APIENTRYP PFNGLBINDTEXTUREEXTPROC) (GLenum target, GLuint texture); -typedef void (APIENTRYP PFNGLDELETETEXTURESEXTPROC) (GLsizei n, const GLuint *textures); -typedef void (APIENTRYP PFNGLGENTEXTURESEXTPROC) (GLsizei n, GLuint *textures); -typedef GLboolean (APIENTRYP PFNGLISTEXTUREEXTPROC) (GLuint texture); -typedef void (APIENTRYP PFNGLPRIORITIZETEXTURESEXTPROC) (GLsizei n, const GLuint *textures, const GLclampf *priorities); -#endif - -#ifndef GL_SGIS_detail_texture -#define GL_SGIS_detail_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDetailTexFuncSGIS (GLenum, GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetDetailTexFuncSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDETAILTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETDETAILTEXFUNCSGISPROC) (GLenum target, GLfloat *points); -#endif - -#ifndef GL_SGIS_sharpen_texture -#define GL_SGIS_sharpen_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSharpenTexFuncSGIS (GLenum, GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetSharpenTexFuncSGIS (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSHARPENTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETSHARPENTEXFUNCSGISPROC) (GLenum target, GLfloat *points); -#endif - -#ifndef GL_EXT_packed_pixels -#define GL_EXT_packed_pixels 1 -#endif - -#ifndef GL_SGIS_texture_lod -#define GL_SGIS_texture_lod 1 -#endif - -#ifndef GL_SGIS_multisample -#define GL_SGIS_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleMaskSGIS (GLclampf, GLboolean); -GLAPI void APIENTRY glSamplePatternSGIS (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLEMASKSGISPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLSAMPLEPATTERNSGISPROC) (GLenum pattern); -#endif - -#ifndef GL_EXT_rescale_normal -#define GL_EXT_rescale_normal 1 -#endif - -#ifndef GL_EXT_vertex_array -#define GL_EXT_vertex_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glArrayElementEXT (GLint); -GLAPI void APIENTRY glColorPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glDrawArraysEXT (GLenum, GLint, GLsizei); -GLAPI void APIENTRY glEdgeFlagPointerEXT (GLsizei, GLsizei, const GLboolean *); -GLAPI void APIENTRY glGetPointervEXT (GLenum, GLvoid* *); -GLAPI void APIENTRY glIndexPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glNormalPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glTexCoordPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLARRAYELEMENTEXTPROC) (GLint i); -typedef void (APIENTRYP PFNGLCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWARRAYSEXTPROC) (GLenum mode, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLEDGEFLAGPOINTEREXTPROC) (GLsizei stride, GLsizei count, const GLboolean *pointer); -typedef void (APIENTRYP PFNGLGETPOINTERVEXTPROC) (GLenum pname, GLvoid* *params); -typedef void (APIENTRYP PFNGLINDEXPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLNORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_misc_attribute -#define GL_EXT_misc_attribute 1 -#endif - -#ifndef GL_SGIS_generate_mipmap -#define GL_SGIS_generate_mipmap 1 -#endif - -#ifndef GL_SGIX_clipmap -#define GL_SGIX_clipmap 1 -#endif - -#ifndef GL_SGIX_shadow -#define GL_SGIX_shadow 1 -#endif - -#ifndef GL_SGIS_texture_edge_clamp -#define GL_SGIS_texture_edge_clamp 1 -#endif - -#ifndef GL_SGIS_texture_border_clamp -#define GL_SGIS_texture_border_clamp 1 -#endif - -#ifndef GL_EXT_blend_minmax -#define GL_EXT_blend_minmax 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONEXTPROC) (GLenum mode); -#endif - -#ifndef GL_EXT_blend_subtract -#define GL_EXT_blend_subtract 1 -#endif - -#ifndef GL_EXT_blend_logic_op -#define GL_EXT_blend_logic_op 1 -#endif - -#ifndef GL_SGIX_interlace -#define GL_SGIX_interlace 1 -#endif - -#ifndef GL_SGIX_pixel_tiles -#define GL_SGIX_pixel_tiles 1 -#endif - -#ifndef GL_SGIX_texture_select -#define GL_SGIX_texture_select 1 -#endif - -#ifndef GL_SGIX_sprite -#define GL_SGIX_sprite 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSpriteParameterfSGIX (GLenum, GLfloat); -GLAPI void APIENTRY glSpriteParameterfvSGIX (GLenum, const GLfloat *); -GLAPI void APIENTRY glSpriteParameteriSGIX (GLenum, GLint); -GLAPI void APIENTRY glSpriteParameterivSGIX (GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSPRITEPARAMETERFSGIXPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERFVSGIXPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERISGIXPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLSPRITEPARAMETERIVSGIXPROC) (GLenum pname, const GLint *params); -#endif - -#ifndef GL_SGIX_texture_multi_buffer -#define GL_SGIX_texture_multi_buffer 1 -#endif - -#ifndef GL_EXT_point_parameters -#define GL_EXT_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfEXT (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvEXT (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFEXTPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVEXTPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_SGIS_point_parameters -#define GL_SGIS_point_parameters 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameterfSGIS (GLenum, GLfloat); -GLAPI void APIENTRY glPointParameterfvSGIS (GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERFSGISPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_SGIX_instruments -#define GL_SGIX_instruments 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLint APIENTRY glGetInstrumentsSGIX (void); -GLAPI void APIENTRY glInstrumentsBufferSGIX (GLsizei, GLint *); -GLAPI GLint APIENTRY glPollInstrumentsSGIX (GLint *); -GLAPI void APIENTRY glReadInstrumentsSGIX (GLint); -GLAPI void APIENTRY glStartInstrumentsSGIX (void); -GLAPI void APIENTRY glStopInstrumentsSGIX (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLint (APIENTRYP PFNGLGETINSTRUMENTSSGIXPROC) (void); -typedef void (APIENTRYP PFNGLINSTRUMENTSBUFFERSGIXPROC) (GLsizei size, GLint *buffer); -typedef GLint (APIENTRYP PFNGLPOLLINSTRUMENTSSGIXPROC) (GLint *marker_p); -typedef void (APIENTRYP PFNGLREADINSTRUMENTSSGIXPROC) (GLint marker); -typedef void (APIENTRYP PFNGLSTARTINSTRUMENTSSGIXPROC) (void); -typedef void (APIENTRYP PFNGLSTOPINSTRUMENTSSGIXPROC) (GLint marker); -#endif - -#ifndef GL_SGIX_texture_scale_bias -#define GL_SGIX_texture_scale_bias 1 -#endif - -#ifndef GL_SGIX_framezoom -#define GL_SGIX_framezoom 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFrameZoomSGIX (GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFRAMEZOOMSGIXPROC) (GLint factor); -#endif - -#ifndef GL_SGIX_tag_sample_buffer -#define GL_SGIX_tag_sample_buffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTagSampleBufferSGIX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTAGSAMPLEBUFFERSGIXPROC) (void); -#endif - -#ifndef GL_SGIX_polynomial_ffd -#define GL_SGIX_polynomial_ffd 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeformationMap3dSGIX (GLenum, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, const GLdouble *); -GLAPI void APIENTRY glDeformationMap3fSGIX (GLenum, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, const GLfloat *); -GLAPI void APIENTRY glDeformSGIX (GLbitfield); -GLAPI void APIENTRY glLoadIdentityDeformationMapSGIX (GLbitfield); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDEFORMATIONMAP3DSGIXPROC) (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points); -typedef void (APIENTRYP PFNGLDEFORMATIONMAP3FSGIXPROC) (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points); -typedef void (APIENTRYP PFNGLDEFORMSGIXPROC) (GLbitfield mask); -typedef void (APIENTRYP PFNGLLOADIDENTITYDEFORMATIONMAPSGIXPROC) (GLbitfield mask); -#endif - -#ifndef GL_SGIX_reference_plane -#define GL_SGIX_reference_plane 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glReferencePlaneSGIX (const GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLREFERENCEPLANESGIXPROC) (const GLdouble *equation); -#endif - -#ifndef GL_SGIX_flush_raster -#define GL_SGIX_flush_raster 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFlushRasterSGIX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFLUSHRASTERSGIXPROC) (void); -#endif - -#ifndef GL_SGIX_depth_texture -#define GL_SGIX_depth_texture 1 -#endif - -#ifndef GL_SGIS_fog_function -#define GL_SGIS_fog_function 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFogFuncSGIS (GLsizei, const GLfloat *); -GLAPI void APIENTRY glGetFogFuncSGIS (GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFOGFUNCSGISPROC) (GLsizei n, const GLfloat *points); -typedef void (APIENTRYP PFNGLGETFOGFUNCSGISPROC) (GLfloat *points); -#endif - -#ifndef GL_SGIX_fog_offset -#define GL_SGIX_fog_offset 1 -#endif - -#ifndef GL_HP_image_transform -#define GL_HP_image_transform 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glImageTransformParameteriHP (GLenum, GLenum, GLint); -GLAPI void APIENTRY glImageTransformParameterfHP (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glImageTransformParameterivHP (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glImageTransformParameterfvHP (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetImageTransformParameterivHP (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetImageTransformParameterfvHP (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIHPPROC) (GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFHPPROC) (GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_HP_convolution_border_modes -#define GL_HP_convolution_border_modes 1 -#endif - -#ifndef GL_SGIX_texture_add_env -#define GL_SGIX_texture_add_env 1 -#endif - -#ifndef GL_EXT_color_subtable -#define GL_EXT_color_subtable 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorSubTableEXT (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glCopyColorSubTableEXT (GLenum, GLsizei, GLint, GLint, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data); -typedef void (APIENTRYP PFNGLCOPYCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width); -#endif - -#ifndef GL_PGI_vertex_hints -#define GL_PGI_vertex_hints 1 -#endif - -#ifndef GL_PGI_misc_hints -#define GL_PGI_misc_hints 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glHintPGI (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLHINTPGIPROC) (GLenum target, GLint mode); -#endif - -#ifndef GL_EXT_paletted_texture -#define GL_EXT_paletted_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorTableEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); -GLAPI void APIENTRY glGetColorTableEXT (GLenum, GLenum, GLenum, GLvoid *); -GLAPI void APIENTRY glGetColorTableParameterivEXT (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetColorTableParameterfvEXT (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORTABLEEXTPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table); -typedef void (APIENTRYP PFNGLGETCOLORTABLEEXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *data); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETCOLORTABLEPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_EXT_clip_volume_hint -#define GL_EXT_clip_volume_hint 1 -#endif - -#ifndef GL_SGIX_list_priority -#define GL_SGIX_list_priority 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGetListParameterfvSGIX (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetListParameterivSGIX (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glListParameterfSGIX (GLuint, GLenum, GLfloat); -GLAPI void APIENTRY glListParameterfvSGIX (GLuint, GLenum, const GLfloat *); -GLAPI void APIENTRY glListParameteriSGIX (GLuint, GLenum, GLint); -GLAPI void APIENTRY glListParameterivSGIX (GLuint, GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGETLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLLISTPARAMETERFSGIXPROC) (GLuint list, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLLISTPARAMETERISGIXPROC) (GLuint list, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, const GLint *params); -#endif - -#ifndef GL_SGIX_ir_instrument1 -#define GL_SGIX_ir_instrument1 1 -#endif - -#ifndef GL_SGIX_calligraphic_fragment -#define GL_SGIX_calligraphic_fragment 1 -#endif - -#ifndef GL_SGIX_texture_lod_bias -#define GL_SGIX_texture_lod_bias 1 -#endif - -#ifndef GL_SGIX_shadow_ambient -#define GL_SGIX_shadow_ambient 1 -#endif - -#ifndef GL_EXT_index_texture -#define GL_EXT_index_texture 1 -#endif - -#ifndef GL_EXT_index_material -#define GL_EXT_index_material 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIndexMaterialEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLINDEXMATERIALEXTPROC) (GLenum face, GLenum mode); -#endif - -#ifndef GL_EXT_index_func -#define GL_EXT_index_func 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIndexFuncEXT (GLenum, GLclampf); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLINDEXFUNCEXTPROC) (GLenum func, GLclampf ref); -#endif - -#ifndef GL_EXT_index_array_formats -#define GL_EXT_index_array_formats 1 -#endif - -#ifndef GL_EXT_compiled_vertex_array -#define GL_EXT_compiled_vertex_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glLockArraysEXT (GLint, GLsizei); -GLAPI void APIENTRY glUnlockArraysEXT (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLLOCKARRAYSEXTPROC) (GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLUNLOCKARRAYSEXTPROC) (void); -#endif - -#ifndef GL_EXT_cull_vertex -#define GL_EXT_cull_vertex 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCullParameterdvEXT (GLenum, GLdouble *); -GLAPI void APIENTRY glCullParameterfvEXT (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCULLPARAMETERDVEXTPROC) (GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLCULLPARAMETERFVEXTPROC) (GLenum pname, GLfloat *params); -#endif - -#ifndef GL_SGIX_ycrcb -#define GL_SGIX_ycrcb 1 -#endif - -#ifndef GL_SGIX_fragment_lighting -#define GL_SGIX_fragment_lighting 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFragmentColorMaterialSGIX (GLenum, GLenum); -GLAPI void APIENTRY glFragmentLightfSGIX (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glFragmentLightfvSGIX (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentLightiSGIX (GLenum, GLenum, GLint); -GLAPI void APIENTRY glFragmentLightivSGIX (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glFragmentLightModelfSGIX (GLenum, GLfloat); -GLAPI void APIENTRY glFragmentLightModelfvSGIX (GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentLightModeliSGIX (GLenum, GLint); -GLAPI void APIENTRY glFragmentLightModelivSGIX (GLenum, const GLint *); -GLAPI void APIENTRY glFragmentMaterialfSGIX (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glFragmentMaterialfvSGIX (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glFragmentMaterialiSGIX (GLenum, GLenum, GLint); -GLAPI void APIENTRY glFragmentMaterialivSGIX (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glGetFragmentLightfvSGIX (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFragmentLightivSGIX (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetFragmentMaterialfvSGIX (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFragmentMaterialivSGIX (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glLightEnviSGIX (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFRAGMENTCOLORMATERIALSGIXPROC) (GLenum face, GLenum mode); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFSGIXPROC) (GLenum light, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTISGIXPROC) (GLenum light, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFSGIXPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELFVSGIXPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELISGIXPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTLIGHTMODELIVSGIXPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFSGIXPROC) (GLenum face, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALISGIXPROC) (GLenum face, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLLIGHTENVISGIXPROC) (GLenum pname, GLint param); -#endif - -#ifndef GL_IBM_rasterpos_clip -#define GL_IBM_rasterpos_clip 1 -#endif - -#ifndef GL_HP_texture_lighting -#define GL_HP_texture_lighting 1 -#endif - -#ifndef GL_EXT_draw_range_elements -#define GL_EXT_draw_range_elements 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawRangeElementsEXT (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSEXTPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices); -#endif - -#ifndef GL_WIN_phong_shading -#define GL_WIN_phong_shading 1 -#endif - -#ifndef GL_WIN_specular_fog -#define GL_WIN_specular_fog 1 -#endif - -#ifndef GL_EXT_light_texture -#define GL_EXT_light_texture 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glApplyTextureEXT (GLenum); -GLAPI void APIENTRY glTextureLightEXT (GLenum); -GLAPI void APIENTRY glTextureMaterialEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLAPPLYTEXTUREEXTPROC) (GLenum mode); -typedef void (APIENTRYP PFNGLTEXTURELIGHTEXTPROC) (GLenum pname); -typedef void (APIENTRYP PFNGLTEXTUREMATERIALEXTPROC) (GLenum face, GLenum mode); -#endif - -#ifndef GL_SGIX_blend_alpha_minmax -#define GL_SGIX_blend_alpha_minmax 1 -#endif - -#ifndef GL_EXT_bgra -#define GL_EXT_bgra 1 -#endif - -#ifndef GL_SGIX_async -#define GL_SGIX_async 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glAsyncMarkerSGIX (GLuint); -GLAPI GLint APIENTRY glFinishAsyncSGIX (GLuint *); -GLAPI GLint APIENTRY glPollAsyncSGIX (GLuint *); -GLAPI GLuint APIENTRY glGenAsyncMarkersSGIX (GLsizei); -GLAPI void APIENTRY glDeleteAsyncMarkersSGIX (GLuint, GLsizei); -GLAPI GLboolean APIENTRY glIsAsyncMarkerSGIX (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLASYNCMARKERSGIXPROC) (GLuint marker); -typedef GLint (APIENTRYP PFNGLFINISHASYNCSGIXPROC) (GLuint *markerp); -typedef GLint (APIENTRYP PFNGLPOLLASYNCSGIXPROC) (GLuint *markerp); -typedef GLuint (APIENTRYP PFNGLGENASYNCMARKERSSGIXPROC) (GLsizei range); -typedef void (APIENTRYP PFNGLDELETEASYNCMARKERSSGIXPROC) (GLuint marker, GLsizei range); -typedef GLboolean (APIENTRYP PFNGLISASYNCMARKERSGIXPROC) (GLuint marker); -#endif - -#ifndef GL_SGIX_async_pixel -#define GL_SGIX_async_pixel 1 -#endif - -#ifndef GL_SGIX_async_histogram -#define GL_SGIX_async_histogram 1 -#endif - -#ifndef GL_INTEL_parallel_arrays -#define GL_INTEL_parallel_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexPointervINTEL (GLint, GLenum, const GLvoid* *); -GLAPI void APIENTRY glNormalPointervINTEL (GLenum, const GLvoid* *); -GLAPI void APIENTRY glColorPointervINTEL (GLint, GLenum, const GLvoid* *); -GLAPI void APIENTRY glTexCoordPointervINTEL (GLint, GLenum, const GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLNORMALPOINTERVINTELPROC) (GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLCOLORPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer); -#endif - -#ifndef GL_HP_occlusion_test -#define GL_HP_occlusion_test 1 -#endif - -#ifndef GL_EXT_pixel_transform -#define GL_EXT_pixel_transform 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum, GLenum, GLint); -GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum, GLenum, GLfloat); -GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum, GLenum, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params); -#endif - -#ifndef GL_EXT_pixel_transform_color_table -#define GL_EXT_pixel_transform_color_table 1 -#endif - -#ifndef GL_EXT_shared_texture_palette -#define GL_EXT_shared_texture_palette 1 -#endif - -#ifndef GL_EXT_separate_specular_color -#define GL_EXT_separate_specular_color 1 -#endif - -#ifndef GL_EXT_secondary_color -#define GL_EXT_secondary_color 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSecondaryColor3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glSecondaryColor3bvEXT (const GLbyte *); -GLAPI void APIENTRY glSecondaryColor3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glSecondaryColor3dvEXT (const GLdouble *); -GLAPI void APIENTRY glSecondaryColor3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glSecondaryColor3fvEXT (const GLfloat *); -GLAPI void APIENTRY glSecondaryColor3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glSecondaryColor3ivEXT (const GLint *); -GLAPI void APIENTRY glSecondaryColor3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glSecondaryColor3svEXT (const GLshort *); -GLAPI void APIENTRY glSecondaryColor3ubEXT (GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glSecondaryColor3ubvEXT (const GLubyte *); -GLAPI void APIENTRY glSecondaryColor3uiEXT (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSecondaryColor3uivEXT (const GLuint *); -GLAPI void APIENTRY glSecondaryColor3usEXT (GLushort, GLushort, GLushort); -GLAPI void APIENTRY glSecondaryColor3usvEXT (const GLushort *); -GLAPI void APIENTRY glSecondaryColorPointerEXT (GLint, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BEXTPROC) (GLbyte red, GLbyte green, GLbyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DEXTPROC) (GLdouble red, GLdouble green, GLdouble blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FEXTPROC) (GLfloat red, GLfloat green, GLfloat blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IEXTPROC) (GLint red, GLint green, GLint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SEXTPROC) (GLshort red, GLshort green, GLshort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBEXTPROC) (GLubyte red, GLubyte green, GLubyte blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UBVEXTPROC) (const GLubyte *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIEXTPROC) (GLuint red, GLuint green, GLuint blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3UIVEXTPROC) (const GLuint *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USEXTPROC) (GLushort red, GLushort green, GLushort blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3USVEXTPROC) (const GLushort *v); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_texture_perturb_normal -#define GL_EXT_texture_perturb_normal 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTextureNormalEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXTURENORMALEXTPROC) (GLenum mode); -#endif - -#ifndef GL_EXT_multi_draw_arrays -#define GL_EXT_multi_draw_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMultiDrawArraysEXT (GLenum, GLint *, GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawElementsEXT (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount); -#endif - -#ifndef GL_EXT_fog_coord -#define GL_EXT_fog_coord 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFogCoordfEXT (GLfloat); -GLAPI void APIENTRY glFogCoordfvEXT (const GLfloat *); -GLAPI void APIENTRY glFogCoorddEXT (GLdouble); -GLAPI void APIENTRY glFogCoorddvEXT (const GLdouble *); -GLAPI void APIENTRY glFogCoordPointerEXT (GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFOGCOORDFEXTPROC) (GLfloat coord); -typedef void (APIENTRYP PFNGLFOGCOORDFVEXTPROC) (const GLfloat *coord); -typedef void (APIENTRYP PFNGLFOGCOORDDEXTPROC) (GLdouble coord); -typedef void (APIENTRYP PFNGLFOGCOORDDVEXTPROC) (const GLdouble *coord); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_REND_screen_coordinates -#define GL_REND_screen_coordinates 1 -#endif - -#ifndef GL_EXT_coordinate_frame -#define GL_EXT_coordinate_frame 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTangent3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glTangent3bvEXT (const GLbyte *); -GLAPI void APIENTRY glTangent3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glTangent3dvEXT (const GLdouble *); -GLAPI void APIENTRY glTangent3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTangent3fvEXT (const GLfloat *); -GLAPI void APIENTRY glTangent3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glTangent3ivEXT (const GLint *); -GLAPI void APIENTRY glTangent3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glTangent3svEXT (const GLshort *); -GLAPI void APIENTRY glBinormal3bEXT (GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glBinormal3bvEXT (const GLbyte *); -GLAPI void APIENTRY glBinormal3dEXT (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glBinormal3dvEXT (const GLdouble *); -GLAPI void APIENTRY glBinormal3fEXT (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glBinormal3fvEXT (const GLfloat *); -GLAPI void APIENTRY glBinormal3iEXT (GLint, GLint, GLint); -GLAPI void APIENTRY glBinormal3ivEXT (const GLint *); -GLAPI void APIENTRY glBinormal3sEXT (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glBinormal3svEXT (const GLshort *); -GLAPI void APIENTRY glTangentPointerEXT (GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glBinormalPointerEXT (GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTANGENT3BEXTPROC) (GLbyte tx, GLbyte ty, GLbyte tz); -typedef void (APIENTRYP PFNGLTANGENT3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLTANGENT3DEXTPROC) (GLdouble tx, GLdouble ty, GLdouble tz); -typedef void (APIENTRYP PFNGLTANGENT3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLTANGENT3FEXTPROC) (GLfloat tx, GLfloat ty, GLfloat tz); -typedef void (APIENTRYP PFNGLTANGENT3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLTANGENT3IEXTPROC) (GLint tx, GLint ty, GLint tz); -typedef void (APIENTRYP PFNGLTANGENT3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLTANGENT3SEXTPROC) (GLshort tx, GLshort ty, GLshort tz); -typedef void (APIENTRYP PFNGLTANGENT3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLBINORMAL3BEXTPROC) (GLbyte bx, GLbyte by, GLbyte bz); -typedef void (APIENTRYP PFNGLBINORMAL3BVEXTPROC) (const GLbyte *v); -typedef void (APIENTRYP PFNGLBINORMAL3DEXTPROC) (GLdouble bx, GLdouble by, GLdouble bz); -typedef void (APIENTRYP PFNGLBINORMAL3DVEXTPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLBINORMAL3FEXTPROC) (GLfloat bx, GLfloat by, GLfloat bz); -typedef void (APIENTRYP PFNGLBINORMAL3FVEXTPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLBINORMAL3IEXTPROC) (GLint bx, GLint by, GLint bz); -typedef void (APIENTRYP PFNGLBINORMAL3IVEXTPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLBINORMAL3SEXTPROC) (GLshort bx, GLshort by, GLshort bz); -typedef void (APIENTRYP PFNGLBINORMAL3SVEXTPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLTANGENTPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLBINORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_EXT_texture_env_combine -#define GL_EXT_texture_env_combine 1 -#endif - -#ifndef GL_APPLE_specular_vector -#define GL_APPLE_specular_vector 1 -#endif - -#ifndef GL_APPLE_transform_hint -#define GL_APPLE_transform_hint 1 -#endif - -#ifndef GL_SGIX_fog_scale -#define GL_SGIX_fog_scale 1 -#endif - -#ifndef GL_SUNX_constant_data -#define GL_SUNX_constant_data 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFinishTextureSUNX (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFINISHTEXTURESUNXPROC) (void); -#endif - -#ifndef GL_SUN_global_alpha -#define GL_SUN_global_alpha 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGlobalAlphaFactorbSUN (GLbyte); -GLAPI void APIENTRY glGlobalAlphaFactorsSUN (GLshort); -GLAPI void APIENTRY glGlobalAlphaFactoriSUN (GLint); -GLAPI void APIENTRY glGlobalAlphaFactorfSUN (GLfloat); -GLAPI void APIENTRY glGlobalAlphaFactordSUN (GLdouble); -GLAPI void APIENTRY glGlobalAlphaFactorubSUN (GLubyte); -GLAPI void APIENTRY glGlobalAlphaFactorusSUN (GLushort); -GLAPI void APIENTRY glGlobalAlphaFactoruiSUN (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORBSUNPROC) (GLbyte factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORSSUNPROC) (GLshort factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORISUNPROC) (GLint factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORFSUNPROC) (GLfloat factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORDSUNPROC) (GLdouble factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUBSUNPROC) (GLubyte factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUSSUNPROC) (GLushort factor); -typedef void (APIENTRYP PFNGLGLOBALALPHAFACTORUISUNPROC) (GLuint factor); -#endif - -#ifndef GL_SUN_triangle_list -#define GL_SUN_triangle_list 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glReplacementCodeuiSUN (GLuint); -GLAPI void APIENTRY glReplacementCodeusSUN (GLushort); -GLAPI void APIENTRY glReplacementCodeubSUN (GLubyte); -GLAPI void APIENTRY glReplacementCodeuivSUN (const GLuint *); -GLAPI void APIENTRY glReplacementCodeusvSUN (const GLushort *); -GLAPI void APIENTRY glReplacementCodeubvSUN (const GLubyte *); -GLAPI void APIENTRY glReplacementCodePointerSUN (GLenum, GLsizei, const GLvoid* *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUISUNPROC) (GLuint code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSSUNPROC) (GLushort code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBSUNPROC) (GLubyte code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVSUNPROC) (const GLuint *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUSVSUNPROC) (const GLushort *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUBVSUNPROC) (const GLubyte *code); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEPOINTERSUNPROC) (GLenum type, GLsizei stride, const GLvoid* *pointer); -#endif - -#ifndef GL_SUN_vertex -#define GL_SUN_vertex 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColor4ubVertex2fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4ubVertex2fvSUN (const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glColor4ubVertex3fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4ubVertex3fvSUN (const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor3fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fVertex3fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord4fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord4fVertex4fvSUN (const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fSUN (GLfloat, GLfloat, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fvSUN (const GLfloat *, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiVertex3fvSUN (const GLuint *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fSUN (GLuint, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fvSUN (const GLuint *, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX2FVSUNPROC) (const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR4UBVERTEX3FVSUNPROC) (const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FSUNPROC) (GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLTEXCOORD4FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4UBVERTEX3FVSUNPROC) (const GLfloat *tc, const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FSUNPROC) (GLuint rc, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUIVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FSUNPROC) (GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FVSUNPROC) (const GLuint *rc, const GLubyte *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v); -#endif - -#ifndef GL_EXT_blend_func_separate -#define GL_EXT_blend_func_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparateEXT (GLenum, GLenum, GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEEXTPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -#endif - -#ifndef GL_INGR_blend_func_separate -#define GL_INGR_blend_func_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendFuncSeparateINGR (GLenum, GLenum, GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); -#endif - -#ifndef GL_INGR_color_clamp -#define GL_INGR_color_clamp 1 -#endif - -#ifndef GL_INGR_interlace_read -#define GL_INGR_interlace_read 1 -#endif - -#ifndef GL_EXT_stencil_wrap -#define GL_EXT_stencil_wrap 1 -#endif - -#ifndef GL_EXT_422_pixels -#define GL_EXT_422_pixels 1 -#endif - -#ifndef GL_NV_texgen_reflection -#define GL_NV_texgen_reflection 1 -#endif - -#ifndef GL_SUN_convolution_border_modes -#define GL_SUN_convolution_border_modes 1 -#endif - -#ifndef GL_EXT_texture_env_add -#define GL_EXT_texture_env_add 1 -#endif - -#ifndef GL_EXT_texture_lod_bias -#define GL_EXT_texture_lod_bias 1 -#endif - -#ifndef GL_EXT_texture_filter_anisotropic -#define GL_EXT_texture_filter_anisotropic 1 -#endif - -#ifndef GL_EXT_vertex_weighting -#define GL_EXT_vertex_weighting 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexWeightfEXT (GLfloat); -GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *); -GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei, GLenum, GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer); -#endif - -#ifndef GL_NV_light_max_exponent -#define GL_NV_light_max_exponent 1 -#endif - -#ifndef GL_NV_vertex_array_range -#define GL_NV_vertex_array_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glFlushVertexArrayRangeNV (void); -GLAPI void APIENTRY glVertexArrayRangeNV (GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGENVPROC) (void); -typedef void (APIENTRYP PFNGLVERTEXARRAYRANGENVPROC) (GLsizei length, const GLvoid *pointer); -#endif - -#ifndef GL_NV_register_combiners -#define GL_NV_register_combiners 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCombinerParameterfvNV (GLenum, const GLfloat *); -GLAPI void APIENTRY glCombinerParameterfNV (GLenum, GLfloat); -GLAPI void APIENTRY glCombinerParameterivNV (GLenum, const GLint *); -GLAPI void APIENTRY glCombinerParameteriNV (GLenum, GLint); -GLAPI void APIENTRY glCombinerInputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glCombinerOutputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLboolean, GLboolean, GLboolean); -GLAPI void APIENTRY glFinalCombinerInputNV (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glGetCombinerInputParameterfvNV (GLenum, GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetCombinerInputParameterivNV (GLenum, GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetCombinerOutputParameterfvNV (GLenum, GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetCombinerOutputParameterivNV (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetFinalCombinerInputParameterfvNV (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetFinalCombinerInputParameterivNV (GLenum, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFVNVPROC) (GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERFNVPROC) (GLenum pname, GLfloat param); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERIVNVPROC) (GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLCOMBINERPARAMETERINVPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLCOMBINERINPUTNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); -typedef void (APIENTRYP PFNGLCOMBINEROUTPUTNVPROC) (GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum); -typedef void (APIENTRYP PFNGLFINALCOMBINERINPUTNVPROC) (GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); -typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINERINPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINEROUTPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERFVNVPROC) (GLenum variable, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETFINALCOMBINERINPUTPARAMETERIVNVPROC) (GLenum variable, GLenum pname, GLint *params); -#endif - -#ifndef GL_NV_fog_distance -#define GL_NV_fog_distance 1 -#endif - -#ifndef GL_NV_texgen_emboss -#define GL_NV_texgen_emboss 1 -#endif - -#ifndef GL_NV_blend_square -#define GL_NV_blend_square 1 -#endif - -#ifndef GL_NV_texture_env_combine4 -#define GL_NV_texture_env_combine4 1 -#endif - -#ifndef GL_MESA_resize_buffers -#define GL_MESA_resize_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glResizeBuffersMESA (void); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLRESIZEBUFFERSMESAPROC) (void); -#endif - -#ifndef GL_MESA_window_pos -#define GL_MESA_window_pos 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glWindowPos2dMESA (GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos2dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos2fMESA (GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos2fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos2iMESA (GLint, GLint); -GLAPI void APIENTRY glWindowPos2ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos2sMESA (GLshort, GLshort); -GLAPI void APIENTRY glWindowPos2svMESA (const GLshort *); -GLAPI void APIENTRY glWindowPos3dMESA (GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos3dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos3fMESA (GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos3fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos3iMESA (GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos3ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos3sMESA (GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos3svMESA (const GLshort *); -GLAPI void APIENTRY glWindowPos4dMESA (GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glWindowPos4dvMESA (const GLdouble *); -GLAPI void APIENTRY glWindowPos4fMESA (GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glWindowPos4fvMESA (const GLfloat *); -GLAPI void APIENTRY glWindowPos4iMESA (GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glWindowPos4ivMESA (const GLint *); -GLAPI void APIENTRY glWindowPos4sMESA (GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glWindowPos4svMESA (const GLshort *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLWINDOWPOS2DMESAPROC) (GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLWINDOWPOS2DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2FMESAPROC) (GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLWINDOWPOS2FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2IMESAPROC) (GLint x, GLint y); -typedef void (APIENTRYP PFNGLWINDOWPOS2IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS2SMESAPROC) (GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLWINDOWPOS2SVMESAPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3DMESAPROC) (GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLWINDOWPOS3DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3FMESAPROC) (GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLWINDOWPOS3FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3IMESAPROC) (GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLWINDOWPOS3IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS3SMESAPROC) (GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLWINDOWPOS3SVMESAPROC) (const GLshort *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4DMESAPROC) (GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLWINDOWPOS4DVMESAPROC) (const GLdouble *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4FMESAPROC) (GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLWINDOWPOS4FVMESAPROC) (const GLfloat *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4IMESAPROC) (GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLWINDOWPOS4IVMESAPROC) (const GLint *v); -typedef void (APIENTRYP PFNGLWINDOWPOS4SMESAPROC) (GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLWINDOWPOS4SVMESAPROC) (const GLshort *v); -#endif - -#ifndef GL_IBM_cull_vertex -#define GL_IBM_cull_vertex 1 -#endif - -#ifndef GL_IBM_multimode_draw_arrays -#define GL_IBM_multimode_draw_arrays 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMultiModeDrawArraysIBM (const GLenum *, const GLint *, const GLsizei *, GLsizei, GLint); -GLAPI void APIENTRY glMultiModeDrawElementsIBM (const GLenum *, const GLsizei *, GLenum, const GLvoid* const *, GLsizei, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMULTIMODEDRAWARRAYSIBMPROC) (const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride); -typedef void (APIENTRYP PFNGLMULTIMODEDRAWELEMENTSIBMPROC) (const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride); -#endif - -#ifndef GL_IBM_vertex_array_lists -#define GL_IBM_vertex_array_lists 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glSecondaryColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glEdgeFlagPointerListIBM (GLint, const GLboolean* *, GLint); -GLAPI void APIENTRY glFogCoordPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glIndexPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glNormalPointerListIBM (GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glTexCoordPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -GLAPI void APIENTRY glVertexPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLSECONDARYCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLEDGEFLAGPOINTERLISTIBMPROC) (GLint stride, const GLboolean* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLFOGCOORDPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLINDEXPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLNORMALPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLTEXCOORDPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -typedef void (APIENTRYP PFNGLVERTEXPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride); -#endif - -#ifndef GL_SGIX_subsample -#define GL_SGIX_subsample 1 -#endif - -#ifndef GL_SGIX_ycrcba -#define GL_SGIX_ycrcba 1 -#endif - -#ifndef GL_SGIX_ycrcb_subsample -#define GL_SGIX_ycrcb_subsample 1 -#endif - -#ifndef GL_SGIX_depth_pass_instrument -#define GL_SGIX_depth_pass_instrument 1 -#endif - -#ifndef GL_3DFX_texture_compression_FXT1 -#define GL_3DFX_texture_compression_FXT1 1 -#endif - -#ifndef GL_3DFX_multisample -#define GL_3DFX_multisample 1 -#endif - -#ifndef GL_3DFX_tbuffer -#define GL_3DFX_tbuffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTbufferMask3DFX (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTBUFFERMASK3DFXPROC) (GLuint mask); -#endif - -#ifndef GL_EXT_multisample -#define GL_EXT_multisample 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glSampleMaskEXT (GLclampf, GLboolean); -GLAPI void APIENTRY glSamplePatternEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSAMPLEMASKEXTPROC) (GLclampf value, GLboolean invert); -typedef void (APIENTRYP PFNGLSAMPLEPATTERNEXTPROC) (GLenum pattern); -#endif - -#ifndef GL_SGIX_vertex_preclip -#define GL_SGIX_vertex_preclip 1 -#endif - -#ifndef GL_SGIX_convolution_accuracy -#define GL_SGIX_convolution_accuracy 1 -#endif - -#ifndef GL_SGIX_resample -#define GL_SGIX_resample 1 -#endif - -#ifndef GL_SGIS_point_line_texgen -#define GL_SGIS_point_line_texgen 1 -#endif - -#ifndef GL_SGIS_texture_color_mask -#define GL_SGIS_texture_color_mask 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTextureColorMaskSGIS (GLboolean, GLboolean, GLboolean, GLboolean); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXTURECOLORMASKSGISPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha); -#endif - -#ifndef GL_SGIX_igloo_interface -#define GL_SGIX_igloo_interface 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glIglooInterfaceSGIX (GLenum, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLIGLOOINTERFACESGIXPROC) (GLenum pname, const GLvoid *params); -#endif - -#ifndef GL_EXT_texture_env_dot3 -#define GL_EXT_texture_env_dot3 1 -#endif - -#ifndef GL_ATI_texture_mirror_once -#define GL_ATI_texture_mirror_once 1 -#endif - -#ifndef GL_NV_fence -#define GL_NV_fence 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDeleteFencesNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenFencesNV (GLsizei, GLuint *); -GLAPI GLboolean APIENTRY glIsFenceNV (GLuint); -GLAPI GLboolean APIENTRY glTestFenceNV (GLuint); -GLAPI void APIENTRY glGetFenceivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glFinishFenceNV (GLuint); -GLAPI void APIENTRY glSetFenceNV (GLuint, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences); -typedef void (APIENTRYP PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences); -typedef GLboolean (APIENTRYP PFNGLISFENCENVPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTFENCENVPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition); -#endif - -#ifndef GL_NV_evaluators -#define GL_NV_evaluators 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLint, GLint, GLboolean, const GLvoid *); -GLAPI void APIENTRY glMapParameterivNV (GLenum, GLenum, const GLint *); -GLAPI void APIENTRY glMapParameterfvNV (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLboolean, GLvoid *); -GLAPI void APIENTRY glGetMapParameterivNV (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGetMapParameterfvNV (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetMapAttribParameterivNV (GLenum, GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetMapAttribParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glEvalMapsNV (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points); -typedef void (APIENTRYP PFNGLMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, const GLint *params); -typedef void (APIENTRYP PFNGLMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points); -typedef void (APIENTRYP PFNGLGETMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERIVNVPROC) (GLenum target, GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETMAPATTRIBPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLEVALMAPSNVPROC) (GLenum target, GLenum mode); -#endif - -#ifndef GL_NV_packed_depth_stencil -#define GL_NV_packed_depth_stencil 1 -#endif - -#ifndef GL_NV_register_combiners2 -#define GL_NV_register_combiners2 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glCombinerStageParameterfvNV (GLenum, GLenum, const GLfloat *); -GLAPI void APIENTRY glGetCombinerStageParameterfvNV (GLenum, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, const GLfloat *params); -typedef void (APIENTRYP PFNGLGETCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, GLfloat *params); -#endif - -#ifndef GL_NV_texture_compression_vtc -#define GL_NV_texture_compression_vtc 1 -#endif - -#ifndef GL_NV_texture_rectangle -#define GL_NV_texture_rectangle 1 -#endif - -#ifndef GL_NV_texture_shader -#define GL_NV_texture_shader 1 -#endif - -#ifndef GL_NV_texture_shader2 -#define GL_NV_texture_shader2 1 -#endif - -#ifndef GL_NV_vertex_array_range2 -#define GL_NV_vertex_array_range2 1 -#endif - -#ifndef GL_NV_vertex_program -#define GL_NV_vertex_program 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glAreProgramsResidentNV (GLsizei, const GLuint *, GLboolean *); -GLAPI void APIENTRY glBindProgramNV (GLenum, GLuint); -GLAPI void APIENTRY glDeleteProgramsNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glExecuteProgramNV (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glGenProgramsNV (GLsizei, GLuint *); -GLAPI void APIENTRY glGetProgramParameterdvNV (GLenum, GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetProgramParameterfvNV (GLenum, GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetProgramivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetProgramStringNV (GLuint, GLenum, GLubyte *); -GLAPI void APIENTRY glGetTrackMatrixivNV (GLenum, GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribdvNV (GLuint, GLenum, GLdouble *); -GLAPI void APIENTRY glGetVertexAttribfvNV (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVertexAttribPointervNV (GLuint, GLenum, GLvoid* *); -GLAPI GLboolean APIENTRY glIsProgramNV (GLuint); -GLAPI void APIENTRY glLoadProgramNV (GLenum, GLuint, GLsizei, const GLubyte *); -GLAPI void APIENTRY glProgramParameter4dNV (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramParameter4dvNV (GLenum, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramParameter4fNV (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramParameter4fvNV (GLenum, GLuint, const GLfloat *); -GLAPI void APIENTRY glProgramParameters4dvNV (GLenum, GLuint, GLuint, const GLdouble *); -GLAPI void APIENTRY glProgramParameters4fvNV (GLenum, GLuint, GLuint, const GLfloat *); -GLAPI void APIENTRY glRequestResidentProgramsNV (GLsizei, const GLuint *); -GLAPI void APIENTRY glTrackMatrixNV (GLenum, GLuint, GLenum, GLenum); -GLAPI void APIENTRY glVertexAttribPointerNV (GLuint, GLint, GLenum, GLsizei, const GLvoid *); -GLAPI void APIENTRY glVertexAttrib1dNV (GLuint, GLdouble); -GLAPI void APIENTRY glVertexAttrib1dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib1fNV (GLuint, GLfloat); -GLAPI void APIENTRY glVertexAttrib1fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib1sNV (GLuint, GLshort); -GLAPI void APIENTRY glVertexAttrib1svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib2dNV (GLuint, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib2dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib2fNV (GLuint, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib2fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib2sNV (GLuint, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib2svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib3dNV (GLuint, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib3dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib3fNV (GLuint, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib3fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib3sNV (GLuint, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib3svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4dNV (GLuint, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexAttrib4dvNV (GLuint, const GLdouble *); -GLAPI void APIENTRY glVertexAttrib4fNV (GLuint, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexAttrib4fvNV (GLuint, const GLfloat *); -GLAPI void APIENTRY glVertexAttrib4sNV (GLuint, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexAttrib4svNV (GLuint, const GLshort *); -GLAPI void APIENTRY glVertexAttrib4ubNV (GLuint, GLubyte, GLubyte, GLubyte, GLubyte); -GLAPI void APIENTRY glVertexAttrib4ubvNV (GLuint, const GLubyte *); -GLAPI void APIENTRY glVertexAttribs1dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs1fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs1svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs2dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs2fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs2svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs3dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs3fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs3svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs4dvNV (GLuint, GLsizei, const GLdouble *); -GLAPI void APIENTRY glVertexAttribs4fvNV (GLuint, GLsizei, const GLfloat *); -GLAPI void APIENTRY glVertexAttribs4svNV (GLuint, GLsizei, const GLshort *); -GLAPI void APIENTRY glVertexAttribs4ubvNV (GLuint, GLsizei, const GLubyte *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLAREPROGRAMSRESIDENTNVPROC) (GLsizei n, const GLuint *programs, GLboolean *residences); -typedef void (APIENTRYP PFNGLBINDPROGRAMNVPROC) (GLenum target, GLuint id); -typedef void (APIENTRYP PFNGLDELETEPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLEXECUTEPROGRAMNVPROC) (GLenum target, GLuint id, const GLfloat *params); -typedef void (APIENTRYP PFNGLGENPROGRAMSNVPROC) (GLsizei n, GLuint *programs); -typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERDVNVPROC) (GLenum target, GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETPROGRAMPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMIVNVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETPROGRAMSTRINGNVPROC) (GLuint id, GLenum pname, GLubyte *program); -typedef void (APIENTRYP PFNGLGETTRACKMATRIXIVNVPROC) (GLenum target, GLuint address, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBDVNVPROC) (GLuint index, GLenum pname, GLdouble *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBFVNVPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBIVNVPROC) (GLuint index, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBPOINTERVNVPROC) (GLuint index, GLenum pname, GLvoid* *pointer); -typedef GLboolean (APIENTRYP PFNGLISPROGRAMNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLLOADPROGRAMNVPROC) (GLenum target, GLuint id, GLsizei len, const GLubyte *program); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DNVPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4DVNVPROC) (GLenum target, GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FNVPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETER4FVNVPROC) (GLenum target, GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4DVNVPROC) (GLenum target, GLuint index, GLuint count, const GLdouble *v); -typedef void (APIENTRYP PFNGLPROGRAMPARAMETERS4FVNVPROC) (GLenum target, GLuint index, GLuint count, const GLfloat *v); -typedef void (APIENTRYP PFNGLREQUESTRESIDENTPROGRAMSNVPROC) (GLsizei n, const GLuint *programs); -typedef void (APIENTRYP PFNGLTRACKMATRIXNVPROC) (GLenum target, GLuint address, GLenum matrix, GLenum transform); -typedef void (APIENTRYP PFNGLVERTEXATTRIBPOINTERNVPROC) (GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DNVPROC) (GLuint index, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FNVPROC) (GLuint index, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SNVPROC) (GLuint index, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DNVPROC) (GLuint index, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FNVPROC) (GLuint index, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SNVPROC) (GLuint index, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4DVNVPROC) (GLuint index, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4FVNVPROC) (GLuint index, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4SVNVPROC) (GLuint index, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBNVPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4UBVNVPROC) (GLuint index, const GLubyte *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4SVNVPROC) (GLuint index, GLsizei count, const GLshort *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4UBVNVPROC) (GLuint index, GLsizei count, const GLubyte *v); -#endif - -#ifndef GL_SGIX_texture_coordinate_clamp -#define GL_SGIX_texture_coordinate_clamp 1 -#endif - -#ifndef GL_SGIX_scalebias_hint -#define GL_SGIX_scalebias_hint 1 -#endif - -#ifndef GL_OML_interlace -#define GL_OML_interlace 1 -#endif - -#ifndef GL_OML_subsample -#define GL_OML_subsample 1 -#endif - -#ifndef GL_OML_resample -#define GL_OML_resample 1 -#endif - -#ifndef GL_NV_copy_depth_to_color -#define GL_NV_copy_depth_to_color 1 -#endif - -#ifndef GL_ATI_envmap_bumpmap -#define GL_ATI_envmap_bumpmap 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glTexBumpParameterivATI (GLenum, const GLint *); -GLAPI void APIENTRY glTexBumpParameterfvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glGetTexBumpParameterivATI (GLenum, GLint *); -GLAPI void APIENTRY glGetTexBumpParameterfvATI (GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERIVATIPROC) (GLenum pname, const GLint *param); -typedef void (APIENTRYP PFNGLTEXBUMPPARAMETERFVATIPROC) (GLenum pname, const GLfloat *param); -typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERIVATIPROC) (GLenum pname, GLint *param); -typedef void (APIENTRYP PFNGLGETTEXBUMPPARAMETERFVATIPROC) (GLenum pname, GLfloat *param); -#endif - -#ifndef GL_ATI_fragment_shader -#define GL_ATI_fragment_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLuint APIENTRY glGenFragmentShadersATI (GLuint); -GLAPI void APIENTRY glBindFragmentShaderATI (GLuint); -GLAPI void APIENTRY glDeleteFragmentShaderATI (GLuint); -GLAPI void APIENTRY glBeginFragmentShaderATI (void); -GLAPI void APIENTRY glEndFragmentShaderATI (void); -GLAPI void APIENTRY glPassTexCoordATI (GLuint, GLuint, GLenum); -GLAPI void APIENTRY glSampleMapATI (GLuint, GLuint, GLenum); -GLAPI void APIENTRY glColorFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glColorFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glColorFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glAlphaFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSetFragmentShaderConstantATI (GLuint, const GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLuint (APIENTRYP PFNGLGENFRAGMENTSHADERSATIPROC) (GLuint range); -typedef void (APIENTRYP PFNGLBINDFRAGMENTSHADERATIPROC) (GLuint id); -typedef void (APIENTRYP PFNGLDELETEFRAGMENTSHADERATIPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINFRAGMENTSHADERATIPROC) (void); -typedef void (APIENTRYP PFNGLENDFRAGMENTSHADERATIPROC) (void); -typedef void (APIENTRYP PFNGLPASSTEXCOORDATIPROC) (GLuint dst, GLuint coord, GLenum swizzle); -typedef void (APIENTRYP PFNGLSAMPLEMAPATIPROC) (GLuint dst, GLuint interp, GLenum swizzle); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); -typedef void (APIENTRYP PFNGLCOLORFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); -typedef void (APIENTRYP PFNGLALPHAFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); -typedef void (APIENTRYP PFNGLSETFRAGMENTSHADERCONSTANTATIPROC) (GLuint dst, const GLfloat *value); -#endif - -#ifndef GL_ATI_pn_triangles -#define GL_ATI_pn_triangles 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPNTrianglesiATI (GLenum, GLint); -GLAPI void APIENTRY glPNTrianglesfATI (GLenum, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPNTRIANGLESIATIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPNTRIANGLESFATIPROC) (GLenum pname, GLfloat param); -#endif - -#ifndef GL_ATI_vertex_array_object -#define GL_ATI_vertex_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLuint APIENTRY glNewObjectBufferATI (GLsizei, const GLvoid *, GLenum); -GLAPI GLboolean APIENTRY glIsObjectBufferATI (GLuint); -GLAPI void APIENTRY glUpdateObjectBufferATI (GLuint, GLuint, GLsizei, const GLvoid *, GLenum); -GLAPI void APIENTRY glGetObjectBufferfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetObjectBufferivATI (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glFreeObjectBufferATI (GLuint); -GLAPI void APIENTRY glArrayObjectATI (GLenum, GLint, GLenum, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetArrayObjectfvATI (GLenum, GLenum, GLfloat *); -GLAPI void APIENTRY glGetArrayObjectivATI (GLenum, GLenum, GLint *); -GLAPI void APIENTRY glVariantArrayObjectATI (GLuint, GLenum, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetVariantArrayObjectfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVariantArrayObjectivATI (GLuint, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLuint (APIENTRYP PFNGLNEWOBJECTBUFFERATIPROC) (GLsizei size, const GLvoid *pointer, GLenum usage); -typedef GLboolean (APIENTRYP PFNGLISOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLUPDATEOBJECTBUFFERATIPROC) (GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve); -typedef void (APIENTRYP PFNGLGETOBJECTBUFFERFVATIPROC) (GLuint buffer, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETOBJECTBUFFERIVATIPROC) (GLuint buffer, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLFREEOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLARRAYOBJECTATIPROC) (GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETARRAYOBJECTFVATIPROC) (GLenum array, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETARRAYOBJECTIVATIPROC) (GLenum array, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLVARIANTARRAYOBJECTATIPROC) (GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTFVATIPROC) (GLuint id, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVARIANTARRAYOBJECTIVATIPROC) (GLuint id, GLenum pname, GLint *params); -#endif - -#ifndef GL_EXT_vertex_shader -#define GL_EXT_vertex_shader 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBeginVertexShaderEXT (void); -GLAPI void APIENTRY glEndVertexShaderEXT (void); -GLAPI void APIENTRY glBindVertexShaderEXT (GLuint); -GLAPI GLuint APIENTRY glGenVertexShadersEXT (GLuint); -GLAPI void APIENTRY glDeleteVertexShaderEXT (GLuint); -GLAPI void APIENTRY glShaderOp1EXT (GLenum, GLuint, GLuint); -GLAPI void APIENTRY glShaderOp2EXT (GLenum, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glShaderOp3EXT (GLenum, GLuint, GLuint, GLuint, GLuint); -GLAPI void APIENTRY glSwizzleEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glWriteMaskEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glInsertComponentEXT (GLuint, GLuint, GLuint); -GLAPI void APIENTRY glExtractComponentEXT (GLuint, GLuint, GLuint); -GLAPI GLuint APIENTRY glGenSymbolsEXT (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glSetInvariantEXT (GLuint, GLenum, const GLvoid *); -GLAPI void APIENTRY glSetLocalConstantEXT (GLuint, GLenum, const GLvoid *); -GLAPI void APIENTRY glVariantbvEXT (GLuint, const GLbyte *); -GLAPI void APIENTRY glVariantsvEXT (GLuint, const GLshort *); -GLAPI void APIENTRY glVariantivEXT (GLuint, const GLint *); -GLAPI void APIENTRY glVariantfvEXT (GLuint, const GLfloat *); -GLAPI void APIENTRY glVariantdvEXT (GLuint, const GLdouble *); -GLAPI void APIENTRY glVariantubvEXT (GLuint, const GLubyte *); -GLAPI void APIENTRY glVariantusvEXT (GLuint, const GLushort *); -GLAPI void APIENTRY glVariantuivEXT (GLuint, const GLuint *); -GLAPI void APIENTRY glVariantPointerEXT (GLuint, GLenum, GLuint, const GLvoid *); -GLAPI void APIENTRY glEnableVariantClientStateEXT (GLuint); -GLAPI void APIENTRY glDisableVariantClientStateEXT (GLuint); -GLAPI GLuint APIENTRY glBindLightParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindMaterialParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindTexGenParameterEXT (GLenum, GLenum, GLenum); -GLAPI GLuint APIENTRY glBindTextureUnitParameterEXT (GLenum, GLenum); -GLAPI GLuint APIENTRY glBindParameterEXT (GLenum); -GLAPI GLboolean APIENTRY glIsVariantEnabledEXT (GLuint, GLenum); -GLAPI void APIENTRY glGetVariantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetVariantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetVariantFloatvEXT (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVariantPointervEXT (GLuint, GLenum, GLvoid* *); -GLAPI void APIENTRY glGetInvariantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetInvariantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetInvariantFloatvEXT (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetLocalConstantBooleanvEXT (GLuint, GLenum, GLboolean *); -GLAPI void APIENTRY glGetLocalConstantIntegervEXT (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetLocalConstantFloatvEXT (GLuint, GLenum, GLfloat *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBEGINVERTEXSHADEREXTPROC) (void); -typedef void (APIENTRYP PFNGLENDVERTEXSHADEREXTPROC) (void); -typedef void (APIENTRYP PFNGLBINDVERTEXSHADEREXTPROC) (GLuint id); -typedef GLuint (APIENTRYP PFNGLGENVERTEXSHADERSEXTPROC) (GLuint range); -typedef void (APIENTRYP PFNGLDELETEVERTEXSHADEREXTPROC) (GLuint id); -typedef void (APIENTRYP PFNGLSHADEROP1EXTPROC) (GLenum op, GLuint res, GLuint arg1); -typedef void (APIENTRYP PFNGLSHADEROP2EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2); -typedef void (APIENTRYP PFNGLSHADEROP3EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3); -typedef void (APIENTRYP PFNGLSWIZZLEEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); -typedef void (APIENTRYP PFNGLWRITEMASKEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW); -typedef void (APIENTRYP PFNGLINSERTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); -typedef void (APIENTRYP PFNGLEXTRACTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num); -typedef GLuint (APIENTRYP PFNGLGENSYMBOLSEXTPROC) (GLenum datatype, GLenum storagetype, GLenum range, GLuint components); -typedef void (APIENTRYP PFNGLSETINVARIANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); -typedef void (APIENTRYP PFNGLSETLOCALCONSTANTEXTPROC) (GLuint id, GLenum type, const GLvoid *addr); -typedef void (APIENTRYP PFNGLVARIANTBVEXTPROC) (GLuint id, const GLbyte *addr); -typedef void (APIENTRYP PFNGLVARIANTSVEXTPROC) (GLuint id, const GLshort *addr); -typedef void (APIENTRYP PFNGLVARIANTIVEXTPROC) (GLuint id, const GLint *addr); -typedef void (APIENTRYP PFNGLVARIANTFVEXTPROC) (GLuint id, const GLfloat *addr); -typedef void (APIENTRYP PFNGLVARIANTDVEXTPROC) (GLuint id, const GLdouble *addr); -typedef void (APIENTRYP PFNGLVARIANTUBVEXTPROC) (GLuint id, const GLubyte *addr); -typedef void (APIENTRYP PFNGLVARIANTUSVEXTPROC) (GLuint id, const GLushort *addr); -typedef void (APIENTRYP PFNGLVARIANTUIVEXTPROC) (GLuint id, const GLuint *addr); -typedef void (APIENTRYP PFNGLVARIANTPOINTEREXTPROC) (GLuint id, GLenum type, GLuint stride, const GLvoid *addr); -typedef void (APIENTRYP PFNGLENABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); -typedef void (APIENTRYP PFNGLDISABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id); -typedef GLuint (APIENTRYP PFNGLBINDLIGHTPARAMETEREXTPROC) (GLenum light, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDMATERIALPARAMETEREXTPROC) (GLenum face, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDTEXGENPARAMETEREXTPROC) (GLenum unit, GLenum coord, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDTEXTUREUNITPARAMETEREXTPROC) (GLenum unit, GLenum value); -typedef GLuint (APIENTRYP PFNGLBINDPARAMETEREXTPROC) (GLenum value); -typedef GLboolean (APIENTRYP PFNGLISVARIANTENABLEDEXTPROC) (GLuint id, GLenum cap); -typedef void (APIENTRYP PFNGLGETVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -typedef void (APIENTRYP PFNGLGETVARIANTPOINTERVEXTPROC) (GLuint id, GLenum value, GLvoid* *data); -typedef void (APIENTRYP PFNGLGETINVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETINVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETINVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data); -typedef void (APIENTRYP PFNGLGETLOCALCONSTANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data); -#endif - -#ifndef GL_ATI_vertex_streams -#define GL_ATI_vertex_streams 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexStream1sATI (GLenum, GLshort); -GLAPI void APIENTRY glVertexStream1svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream1iATI (GLenum, GLint); -GLAPI void APIENTRY glVertexStream1ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream1fATI (GLenum, GLfloat); -GLAPI void APIENTRY glVertexStream1fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream1dATI (GLenum, GLdouble); -GLAPI void APIENTRY glVertexStream1dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream2sATI (GLenum, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream2svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream2iATI (GLenum, GLint, GLint); -GLAPI void APIENTRY glVertexStream2ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream2fATI (GLenum, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream2fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream2dATI (GLenum, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream2dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream3sATI (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream3svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream3iATI (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexStream3ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream3fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream3dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glVertexStream4sATI (GLenum, GLshort, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glVertexStream4svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glVertexStream4iATI (GLenum, GLint, GLint, GLint, GLint); -GLAPI void APIENTRY glVertexStream4ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glVertexStream4fATI (GLenum, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glVertexStream4fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glVertexStream4dATI (GLenum, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glVertexStream4dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glNormalStream3bATI (GLenum, GLbyte, GLbyte, GLbyte); -GLAPI void APIENTRY glNormalStream3bvATI (GLenum, const GLbyte *); -GLAPI void APIENTRY glNormalStream3sATI (GLenum, GLshort, GLshort, GLshort); -GLAPI void APIENTRY glNormalStream3svATI (GLenum, const GLshort *); -GLAPI void APIENTRY glNormalStream3iATI (GLenum, GLint, GLint, GLint); -GLAPI void APIENTRY glNormalStream3ivATI (GLenum, const GLint *); -GLAPI void APIENTRY glNormalStream3fATI (GLenum, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glNormalStream3fvATI (GLenum, const GLfloat *); -GLAPI void APIENTRY glNormalStream3dATI (GLenum, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glNormalStream3dvATI (GLenum, const GLdouble *); -GLAPI void APIENTRY glClientActiveVertexStreamATI (GLenum); -GLAPI void APIENTRY glVertexBlendEnviATI (GLenum, GLint); -GLAPI void APIENTRY glVertexBlendEnvfATI (GLenum, GLfloat); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXSTREAM1SATIPROC) (GLenum stream, GLshort x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1IATIPROC) (GLenum stream, GLint x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1FATIPROC) (GLenum stream, GLfloat x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1DATIPROC) (GLenum stream, GLdouble x); -typedef void (APIENTRYP PFNGLVERTEXSTREAM1DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2SATIPROC) (GLenum stream, GLshort x, GLshort y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2IATIPROC) (GLenum stream, GLint x, GLint y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2FATIPROC) (GLenum stream, GLfloat x, GLfloat y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2DATIPROC) (GLenum stream, GLdouble x, GLdouble y); -typedef void (APIENTRYP PFNGLVERTEXSTREAM2DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3IATIPROC) (GLenum stream, GLint x, GLint y, GLint z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z); -typedef void (APIENTRYP PFNGLVERTEXSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4IATIPROC) (GLenum stream, GLint x, GLint y, GLint z, GLint w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLVERTEXSTREAM4DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3BATIPROC) (GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3BVATIPROC) (GLenum stream, const GLbyte *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3SATIPROC) (GLenum stream, GLshort nx, GLshort ny, GLshort nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3IATIPROC) (GLenum stream, GLint nx, GLint ny, GLint nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3IVATIPROC) (GLenum stream, const GLint *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3FATIPROC) (GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords); -typedef void (APIENTRYP PFNGLNORMALSTREAM3DATIPROC) (GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz); -typedef void (APIENTRYP PFNGLNORMALSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords); -typedef void (APIENTRYP PFNGLCLIENTACTIVEVERTEXSTREAMATIPROC) (GLenum stream); -typedef void (APIENTRYP PFNGLVERTEXBLENDENVIATIPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLVERTEXBLENDENVFATIPROC) (GLenum pname, GLfloat param); -#endif - -#ifndef GL_ATI_element_array -#define GL_ATI_element_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glElementPointerATI (GLenum, const GLvoid *); -GLAPI void APIENTRY glDrawElementArrayATI (GLenum, GLsizei); -GLAPI void APIENTRY glDrawRangeElementArrayATI (GLenum, GLuint, GLuint, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLELEMENTPOINTERATIPROC) (GLenum type, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYATIPROC) (GLenum mode, GLsizei count); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYATIPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count); -#endif - -#ifndef GL_SUN_mesh_array -#define GL_SUN_mesh_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawMeshArraysSUN (GLenum, GLint, GLsizei, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWMESHARRAYSSUNPROC) (GLenum mode, GLint first, GLsizei count, GLsizei width); -#endif - -#ifndef GL_SUN_slice_accum -#define GL_SUN_slice_accum 1 -#endif - -#ifndef GL_NV_multisample_filter_hint -#define GL_NV_multisample_filter_hint 1 -#endif - -#ifndef GL_NV_depth_clamp -#define GL_NV_depth_clamp 1 -#endif - -#ifndef GL_NV_occlusion_query -#define GL_NV_occlusion_query 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenOcclusionQueriesNV (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteOcclusionQueriesNV (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsOcclusionQueryNV (GLuint); -GLAPI void APIENTRY glBeginOcclusionQueryNV (GLuint); -GLAPI void APIENTRY glEndOcclusionQueryNV (void); -GLAPI void APIENTRY glGetOcclusionQueryivNV (GLuint, GLenum, GLint *); -GLAPI void APIENTRY glGetOcclusionQueryuivNV (GLuint, GLenum, GLuint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENOCCLUSIONQUERIESNVPROC) (GLsizei n, GLuint *ids); -typedef void (APIENTRYP PFNGLDELETEOCCLUSIONQUERIESNVPROC) (GLsizei n, const GLuint *ids); -typedef GLboolean (APIENTRYP PFNGLISOCCLUSIONQUERYNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLBEGINOCCLUSIONQUERYNVPROC) (GLuint id); -typedef void (APIENTRYP PFNGLENDOCCLUSIONQUERYNVPROC) (void); -typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYIVNVPROC) (GLuint id, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGETOCCLUSIONQUERYUIVNVPROC) (GLuint id, GLenum pname, GLuint *params); -#endif - -#ifndef GL_NV_point_sprite -#define GL_NV_point_sprite 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPointParameteriNV (GLenum, GLint); -GLAPI void APIENTRY glPointParameterivNV (GLenum, const GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPOINTPARAMETERINVPROC) (GLenum pname, GLint param); -typedef void (APIENTRYP PFNGLPOINTPARAMETERIVNVPROC) (GLenum pname, const GLint *params); -#endif - -#ifndef GL_NV_texture_shader3 -#define GL_NV_texture_shader3 1 -#endif - -#ifndef GL_NV_vertex_program1_1 -#define GL_NV_vertex_program1_1 1 -#endif - -#ifndef GL_EXT_shadow_funcs -#define GL_EXT_shadow_funcs 1 -#endif - -#ifndef GL_EXT_stencil_two_side -#define GL_EXT_stencil_two_side 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glActiveStencilFaceEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLACTIVESTENCILFACEEXTPROC) (GLenum face); -#endif - -#ifndef GL_ATI_text_fragment_shader -#define GL_ATI_text_fragment_shader 1 -#endif - -#ifndef GL_APPLE_client_storage -#define GL_APPLE_client_storage 1 -#endif - -#ifndef GL_APPLE_element_array -#define GL_APPLE_element_array 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glElementPointerAPPLE (GLenum, const GLvoid *); -GLAPI void APIENTRY glDrawElementArrayAPPLE (GLenum, GLint, GLsizei); -GLAPI void APIENTRY glDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, GLint, GLsizei); -GLAPI void APIENTRY glMultiDrawElementArrayAPPLE (GLenum, const GLint *, const GLsizei *, GLsizei); -GLAPI void APIENTRY glMultiDrawRangeElementArrayAPPLE (GLenum, GLuint, GLuint, const GLint *, const GLsizei *, GLsizei); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLELEMENTPOINTERAPPLEPROC) (GLenum type, const GLvoid *pointer); -typedef void (APIENTRYP PFNGLDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count); -typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTARRAYAPPLEPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount); -typedef void (APIENTRYP PFNGLMULTIDRAWRANGEELEMENTARRAYAPPLEPROC) (GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount); -#endif - -#ifndef GL_APPLE_fence -#define GL_APPLE_fence 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glGenFencesAPPLE (GLsizei, GLuint *); -GLAPI void APIENTRY glDeleteFencesAPPLE (GLsizei, const GLuint *); -GLAPI void APIENTRY glSetFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glIsFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glTestFenceAPPLE (GLuint); -GLAPI void APIENTRY glFinishFenceAPPLE (GLuint); -GLAPI GLboolean APIENTRY glTestObjectAPPLE (GLenum, GLuint); -GLAPI void APIENTRY glFinishObjectAPPLE (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLGENFENCESAPPLEPROC) (GLsizei n, GLuint *fences); -typedef void (APIENTRYP PFNGLDELETEFENCESAPPLEPROC) (GLsizei n, const GLuint *fences); -typedef void (APIENTRYP PFNGLSETFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLISFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTFENCEAPPLEPROC) (GLuint fence); -typedef void (APIENTRYP PFNGLFINISHFENCEAPPLEPROC) (GLuint fence); -typedef GLboolean (APIENTRYP PFNGLTESTOBJECTAPPLEPROC) (GLenum object, GLuint name); -typedef void (APIENTRYP PFNGLFINISHOBJECTAPPLEPROC) (GLenum object, GLint name); -#endif - -#ifndef GL_APPLE_vertex_array_object -#define GL_APPLE_vertex_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBindVertexArrayAPPLE (GLuint); -GLAPI void APIENTRY glDeleteVertexArraysAPPLE (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenVertexArraysAPPLE (GLsizei, const GLuint *); -GLAPI GLboolean APIENTRY glIsVertexArrayAPPLE (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBINDVERTEXARRAYAPPLEPROC) (GLuint array); -typedef void (APIENTRYP PFNGLDELETEVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays); -typedef void (APIENTRYP PFNGLGENVERTEXARRAYSAPPLEPROC) (GLsizei n, const GLuint *arrays); -typedef GLboolean (APIENTRYP PFNGLISVERTEXARRAYAPPLEPROC) (GLuint array); -#endif - -#ifndef GL_APPLE_vertex_array_range -#define GL_APPLE_vertex_array_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexArrayRangeAPPLE (GLsizei, GLvoid *); -GLAPI void APIENTRY glFlushVertexArrayRangeAPPLE (GLsizei, GLvoid *); -GLAPI void APIENTRY glVertexArrayParameteriAPPLE (GLenum, GLint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLFLUSHVERTEXARRAYRANGEAPPLEPROC) (GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLVERTEXARRAYPARAMETERIAPPLEPROC) (GLenum pname, GLint param); -#endif - -#ifndef GL_APPLE_ycbcr_422 -#define GL_APPLE_ycbcr_422 1 -#endif - -#ifndef GL_S3_s3tc -#define GL_S3_s3tc 1 -#endif - -#ifndef GL_ATI_draw_buffers -#define GL_ATI_draw_buffers 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDrawBuffersATI (GLsizei, const GLenum *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDRAWBUFFERSATIPROC) (GLsizei n, const GLenum *bufs); -#endif - -#ifndef GL_ATI_pixel_format_float -#define GL_ATI_pixel_format_float 1 -/* This is really a WGL extension, but defines some associated GL enums. - * ATI does not export "GL_ATI_pixel_format_float" in the GL_EXTENSIONS string. - */ -#endif - -#ifndef GL_ATI_texture_env_combine3 -#define GL_ATI_texture_env_combine3 1 -#endif - -#ifndef GL_ATI_texture_float -#define GL_ATI_texture_float 1 -#endif - -#ifndef GL_NV_float_buffer -#define GL_NV_float_buffer 1 -#endif - -#ifndef GL_NV_fragment_program -#define GL_NV_fragment_program 1 -/* Some NV_fragment_program entry points are shared with ARB_vertex_program. */ -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glProgramNamedParameter4fNV (GLuint, GLsizei, const GLubyte *, GLfloat, GLfloat, GLfloat, GLfloat); -GLAPI void APIENTRY glProgramNamedParameter4dNV (GLuint, GLsizei, const GLubyte *, GLdouble, GLdouble, GLdouble, GLdouble); -GLAPI void APIENTRY glProgramNamedParameter4fvNV (GLuint, GLsizei, const GLubyte *, const GLfloat *); -GLAPI void APIENTRY glProgramNamedParameter4dvNV (GLuint, GLsizei, const GLubyte *, const GLdouble *); -GLAPI void APIENTRY glGetProgramNamedParameterfvNV (GLuint, GLsizei, const GLubyte *, GLfloat *); -GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint, GLsizei, const GLubyte *, GLdouble *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v); -typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v); -typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERFVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat *params); -typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERDVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble *params); -#endif - -#ifndef GL_NV_half_float -#define GL_NV_half_float 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertex2hNV (GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex2hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertex3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertex4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertex4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glNormal3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glNormal3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glColor3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glColor4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glColor4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord1hNV (GLhalfNV); -GLAPI void APIENTRY glTexCoord1hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord2hNV (GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord2hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glTexCoord4hNV (GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glTexCoord4hvNV (const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord1hNV (GLenum, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord1hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord2hNV (GLenum, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord2hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord3hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord3hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glMultiTexCoord4hNV (GLenum, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glMultiTexCoord4hvNV (GLenum, const GLhalfNV *); -GLAPI void APIENTRY glFogCoordhNV (GLhalfNV); -GLAPI void APIENTRY glFogCoordhvNV (const GLhalfNV *); -GLAPI void APIENTRY glSecondaryColor3hNV (GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glSecondaryColor3hvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertexWeighthNV (GLhalfNV); -GLAPI void APIENTRY glVertexWeighthvNV (const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib1hNV (GLuint, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib1hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib2hNV (GLuint, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib2hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib3hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib3hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttrib4hNV (GLuint, GLhalfNV, GLhalfNV, GLhalfNV, GLhalfNV); -GLAPI void APIENTRY glVertexAttrib4hvNV (GLuint, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs1hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs2hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs3hvNV (GLuint, GLsizei, const GLhalfNV *); -GLAPI void APIENTRY glVertexAttribs4hvNV (GLuint, GLsizei, const GLhalfNV *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEX2HNVPROC) (GLhalfNV x, GLhalfNV y); -typedef void (APIENTRYP PFNGLVERTEX2HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEX3HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z); -typedef void (APIENTRYP PFNGLVERTEX3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEX4HNVPROC) (GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); -typedef void (APIENTRYP PFNGLVERTEX4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLNORMAL3HNVPROC) (GLhalfNV nx, GLhalfNV ny, GLhalfNV nz); -typedef void (APIENTRYP PFNGLNORMAL3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); -typedef void (APIENTRYP PFNGLCOLOR3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLCOLOR4HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha); -typedef void (APIENTRYP PFNGLCOLOR4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD1HNVPROC) (GLhalfNV s); -typedef void (APIENTRYP PFNGLTEXCOORD1HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD2HNVPROC) (GLhalfNV s, GLhalfNV t); -typedef void (APIENTRYP PFNGLTEXCOORD2HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD3HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r); -typedef void (APIENTRYP PFNGLTEXCOORD3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLTEXCOORD4HNVPROC) (GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); -typedef void (APIENTRYP PFNGLTEXCOORD4HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1HNVPROC) (GLenum target, GLhalfNV s); -typedef void (APIENTRYP PFNGLMULTITEXCOORD1HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t); -typedef void (APIENTRYP PFNGLMULTITEXCOORD2HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r); -typedef void (APIENTRYP PFNGLMULTITEXCOORD3HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4HNVPROC) (GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q); -typedef void (APIENTRYP PFNGLMULTITEXCOORD4HVNVPROC) (GLenum target, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLFOGCOORDHNVPROC) (GLhalfNV fog); -typedef void (APIENTRYP PFNGLFOGCOORDHVNVPROC) (const GLhalfNV *fog); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HNVPROC) (GLhalfNV red, GLhalfNV green, GLhalfNV blue); -typedef void (APIENTRYP PFNGLSECONDARYCOLOR3HVNVPROC) (const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTHNVPROC) (GLhalfNV weight); -typedef void (APIENTRYP PFNGLVERTEXWEIGHTHVNVPROC) (const GLhalfNV *weight); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1HNVPROC) (GLuint index, GLhalfNV x); -typedef void (APIENTRYP PFNGLVERTEXATTRIB1HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y); -typedef void (APIENTRYP PFNGLVERTEXATTRIB2HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z); -typedef void (APIENTRYP PFNGLVERTEXATTRIB3HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4HNVPROC) (GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w); -typedef void (APIENTRYP PFNGLVERTEXATTRIB4HVNVPROC) (GLuint index, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS1HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS2HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS3HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -typedef void (APIENTRYP PFNGLVERTEXATTRIBS4HVNVPROC) (GLuint index, GLsizei n, const GLhalfNV *v); -#endif - -#ifndef GL_NV_pixel_data_range -#define GL_NV_pixel_data_range 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPixelDataRangeNV (GLenum, GLsizei, GLvoid *); -GLAPI void APIENTRY glFlushPixelDataRangeNV (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, GLvoid *pointer); -typedef void (APIENTRYP PFNGLFLUSHPIXELDATARANGENVPROC) (GLenum target); -#endif - -#ifndef GL_NV_primitive_restart -#define GL_NV_primitive_restart 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glPrimitiveRestartNV (void); -GLAPI void APIENTRY glPrimitiveRestartIndexNV (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLPRIMITIVERESTARTNVPROC) (void); -typedef void (APIENTRYP PFNGLPRIMITIVERESTARTINDEXNVPROC) (GLuint index); -#endif - -#ifndef GL_NV_texture_expand_normal -#define GL_NV_texture_expand_normal 1 -#endif - -#ifndef GL_NV_vertex_program2 -#define GL_NV_vertex_program2 1 -#endif - -#ifndef GL_ATI_map_object_buffer -#define GL_ATI_map_object_buffer 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLvoid* APIENTRY glMapObjectBufferATI (GLuint); -GLAPI void APIENTRY glUnmapObjectBufferATI (GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLvoid* (APIENTRYP PFNGLMAPOBJECTBUFFERATIPROC) (GLuint buffer); -typedef void (APIENTRYP PFNGLUNMAPOBJECTBUFFERATIPROC) (GLuint buffer); -#endif - -#ifndef GL_ATI_separate_stencil -#define GL_ATI_separate_stencil 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glStencilOpSeparateATI (GLenum, GLenum, GLenum, GLenum); -GLAPI void APIENTRY glStencilFuncSeparateATI (GLenum, GLenum, GLint, GLuint); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSTENCILOPSEPARATEATIPROC) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass); -typedef void (APIENTRYP PFNGLSTENCILFUNCSEPARATEATIPROC) (GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); -#endif - -#ifndef GL_ATI_vertex_attrib_array_object -#define GL_ATI_vertex_attrib_array_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glVertexAttribArrayObjectATI (GLuint, GLint, GLenum, GLboolean, GLsizei, GLuint, GLuint); -GLAPI void APIENTRY glGetVertexAttribArrayObjectfvATI (GLuint, GLenum, GLfloat *); -GLAPI void APIENTRY glGetVertexAttribArrayObjectivATI (GLuint, GLenum, GLint *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLVERTEXATTRIBARRAYOBJECTATIPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTFVATIPROC) (GLuint index, GLenum pname, GLfloat *params); -typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTIVATIPROC) (GLuint index, GLenum pname, GLint *params); -#endif - -#ifndef GL_OES_read_format -#define GL_OES_read_format 1 -#endif - -#ifndef GL_EXT_depth_bounds_test -#define GL_EXT_depth_bounds_test 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glDepthBoundsEXT (GLclampd, GLclampd); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLDEPTHBOUNDSEXTPROC) (GLclampd zmin, GLclampd zmax); -#endif - -#ifndef GL_EXT_texture_mirror_clamp -#define GL_EXT_texture_mirror_clamp 1 -#endif - -#ifndef GL_EXT_blend_equation_separate -#define GL_EXT_blend_equation_separate 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glBlendEquationSeparateEXT (GLenum, GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLBLENDEQUATIONSEPARATEEXTPROC) (GLenum modeRGB, GLenum modeAlpha); -#endif - -#ifndef GL_MESA_pack_invert -#define GL_MESA_pack_invert 1 -#endif - -#ifndef GL_MESA_ycbcr_texture -#define GL_MESA_ycbcr_texture 1 -#endif - -#ifndef GL_EXT_pixel_buffer_object -#define GL_EXT_pixel_buffer_object 1 -#endif - -#ifndef GL_NV_fragment_program_option -#define GL_NV_fragment_program_option 1 -#endif - -#ifndef GL_NV_fragment_program2 -#define GL_NV_fragment_program2 1 -#endif - -#ifndef GL_NV_vertex_program2_option -#define GL_NV_vertex_program2_option 1 -#endif - -#ifndef GL_NV_vertex_program3 -#define GL_NV_vertex_program3 1 -#endif - -#ifndef GL_EXT_framebuffer_object -#define GL_EXT_framebuffer_object 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI GLboolean APIENTRY glIsRenderbufferEXT (GLuint); -GLAPI void APIENTRY glBindRenderbufferEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteRenderbuffersEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenRenderbuffersEXT (GLsizei, GLuint *); -GLAPI void APIENTRY glRenderbufferStorageEXT (GLenum, GLenum, GLsizei, GLsizei); -GLAPI void APIENTRY glGetRenderbufferParameterivEXT (GLenum, GLenum, GLint *); -GLAPI GLboolean APIENTRY glIsFramebufferEXT (GLuint); -GLAPI void APIENTRY glBindFramebufferEXT (GLenum, GLuint); -GLAPI void APIENTRY glDeleteFramebuffersEXT (GLsizei, const GLuint *); -GLAPI void APIENTRY glGenFramebuffersEXT (GLsizei, GLuint *); -GLAPI GLenum APIENTRY glCheckFramebufferStatusEXT (GLenum); -GLAPI void APIENTRY glFramebufferTexture1DEXT (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture2DEXT (GLenum, GLenum, GLenum, GLuint, GLint); -GLAPI void APIENTRY glFramebufferTexture3DEXT (GLenum, GLenum, GLenum, GLuint, GLint, GLint); -GLAPI void APIENTRY glFramebufferRenderbufferEXT (GLenum, GLenum, GLenum, GLuint); -GLAPI void APIENTRY glGetFramebufferAttachmentParameterivEXT (GLenum, GLenum, GLenum, GLint *); -GLAPI void APIENTRY glGenerateMipmapEXT (GLenum); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef GLboolean (APIENTRYP PFNGLISRENDERBUFFEREXTPROC) (GLuint renderbuffer); -typedef void (APIENTRYP PFNGLBINDRENDERBUFFEREXTPROC) (GLenum target, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLDELETERENDERBUFFERSEXTPROC) (GLsizei n, const GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLGENRENDERBUFFERSEXTPROC) (GLsizei n, GLuint *renderbuffers); -typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height); -typedef void (APIENTRYP PFNGLGETRENDERBUFFERPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params); -typedef GLboolean (APIENTRYP PFNGLISFRAMEBUFFEREXTPROC) (GLuint framebuffer); -typedef void (APIENTRYP PFNGLBINDFRAMEBUFFEREXTPROC) (GLenum target, GLuint framebuffer); -typedef void (APIENTRYP PFNGLDELETEFRAMEBUFFERSEXTPROC) (GLsizei n, const GLuint *framebuffers); -typedef void (APIENTRYP PFNGLGENFRAMEBUFFERSEXTPROC) (GLsizei n, GLuint *framebuffers); -typedef GLenum (APIENTRYP PFNGLCHECKFRAMEBUFFERSTATUSEXTPROC) (GLenum target); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE1DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); -typedef void (APIENTRYP PFNGLFRAMEBUFFERTEXTURE3DEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); -typedef void (APIENTRYP PFNGLFRAMEBUFFERRENDERBUFFEREXTPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); -typedef void (APIENTRYP PFNGLGETFRAMEBUFFERATTACHMENTPARAMETERIVEXTPROC) (GLenum target, GLenum attachment, GLenum pname, GLint *params); -typedef void (APIENTRYP PFNGLGENERATEMIPMAPEXTPROC) (GLenum target); -#endif - -#ifndef GL_GREMEDY_string_marker -#define GL_GREMEDY_string_marker 1 -#ifdef GL_GLEXT_PROTOTYPES -GLAPI void APIENTRY glStringMarkerGREMEDY (GLsizei, const GLvoid *); -#endif /* GL_GLEXT_PROTOTYPES */ -typedef void (APIENTRYP PFNGLSTRINGMARKERGREMEDYPROC) (GLsizei len, const GLvoid *string); -#endif - - -#ifdef __cplusplus -} -#endif - -#endif -#endif /* NO_SDL_GLEXT */ diff --git a/distrib/sdl-1.2.12/include/SDL_platform.h b/distrib/sdl-1.2.12/include/SDL_platform.h deleted file mode 100644 index 1bfee29..0000000 --- a/distrib/sdl-1.2.12/include/SDL_platform.h +++ /dev/null @@ -1,100 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Try to get a standard set of platform defines */ - -#ifndef _SDL_platform_h -#define _SDL_platform_h - -#if defined(_AIX) -#undef __AIX__ -#define __AIX__ 1 -#endif -#if defined(__BEOS__) -#undef __BEOS__ -#define __BEOS__ 1 -#endif -#if defined(bsdi) || defined(__bsdi) || defined(__bsdi__) -#undef __BSDI__ -#define __BSDI__ 1 -#endif -#if defined(_arch_dreamcast) -#undef __DREAMCAST__ -#define __DREAMCAST__ 1 -#endif -#if defined(__FreeBSD__) || defined(__DragonFly__) -#undef __FREEBSD__ -#define __FREEBSD__ 1 -#endif -#if defined(hpux) || defined(__hpux) || defined(__hpux__) -#undef __HPUX__ -#define __HPUX__ 1 -#endif -#if defined(sgi) || defined(__sgi) || defined(__sgi__) || defined(_SGI_SOURCE) -#undef __IRIX__ -#define __IRIX__ 1 -#endif -#if defined(linux) || defined(__linux) || defined(__linux__) -#undef __LINUX__ -#define __LINUX__ 1 -#endif -#if defined(__APPLE__) -#undef __MACOSX__ -#define __MACOSX__ 1 -#elif defined(macintosh) -#undef __MACOS__ -#define __MACOS__ 1 -#endif -#if defined(__NetBSD__) -#undef __NETBSD__ -#define __NETBSD__ 1 -#endif -#if defined(__OpenBSD__) -#undef __OPENBSD__ -#define __OPENBSD__ 1 -#endif -#if defined(__OS2__) -#undef __OS2__ -#define __OS2__ 1 -#endif -#if defined(osf) || defined(__osf) || defined(__osf__) || defined(_OSF_SOURCE) -#undef __OSF__ -#define __OSF__ 1 -#endif -#if defined(__QNXNTO__) -#undef __QNXNTO__ -#define __QNXNTO__ 1 -#endif -#if defined(riscos) || defined(__riscos) || defined(__riscos__) -#undef __RISCOS__ -#define __RISCOS__ 1 -#endif -#if defined(__SVR4) -#undef __SOLARIS__ -#define __SOLARIS__ 1 -#endif -#if defined(WIN32) || defined(_WIN32) -#undef __WIN32__ -#define __WIN32__ 1 -#endif - -#endif /* _SDL_platform_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_quit.h b/distrib/sdl-1.2.12/include/SDL_quit.h deleted file mode 100644 index fcf40fb..0000000 --- a/distrib/sdl-1.2.12/include/SDL_quit.h +++ /dev/null @@ -1,50 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL quit event handling */ - -#ifndef _SDL_quit_h -#define _SDL_quit_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -/* - An SDL_QUITEVENT is generated when the user tries to close the application - window. If it is ignored or filtered out, the window will remain open. - If it is not ignored or filtered, it is queued normally and the window - is allowed to close. When the window is closed, screen updates will - complete, but have no effect. - - SDL_Init() installs signal handlers for SIGINT (keyboard interrupt) - and SIGTERM (system termination request), if handlers do not already - exist, that generate SDL_QUITEVENT events as well. There is no way - to determine the cause of an SDL_QUITEVENT, but setting a signal - handler in your application will override the default generation of - quit events for that signal. -*/ - -/* There are no functions directly affecting the quit event */ -#define SDL_QuitRequested() \ - (SDL_PumpEvents(), SDL_PeepEvents(NULL,0,SDL_PEEKEVENT,SDL_QUITMASK)) - -#endif /* _SDL_quit_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_rwops.h b/distrib/sdl-1.2.12/include/SDL_rwops.h deleted file mode 100644 index 8c17701..0000000 --- a/distrib/sdl-1.2.12/include/SDL_rwops.h +++ /dev/null @@ -1,144 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This file provides a general interface for SDL to read and write - data sources. It can easily be extended to files, memory, etc. -*/ - -#ifndef _SDL_rwops_h -#define _SDL_rwops_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* This is the read/write operation structure -- very basic */ - -typedef struct SDL_RWops { - /* Seek to 'offset' relative to whence, one of stdio's whence values: - SEEK_SET, SEEK_CUR, SEEK_END - Returns the final offset in the data source. - */ - int (SDLCALL *seek)(struct SDL_RWops *context, int offset, int whence); - - /* Read up to 'num' objects each of size 'objsize' from the data - source to the area pointed at by 'ptr'. - Returns the number of objects read, or -1 if the read failed. - */ - int (SDLCALL *read)(struct SDL_RWops *context, void *ptr, int size, int maxnum); - - /* Write exactly 'num' objects each of size 'objsize' from the area - pointed at by 'ptr' to data source. - Returns 'num', or -1 if the write failed. - */ - int (SDLCALL *write)(struct SDL_RWops *context, const void *ptr, int size, int num); - - /* Close and free an allocated SDL_FSops structure */ - int (SDLCALL *close)(struct SDL_RWops *context); - - Uint32 type; - union { -#if defined(__WIN32__) && !defined(__SYMBIAN32__) - struct { - int append; - void *h; - struct { - void *data; - int size; - int left; - } buffer; - } win32io; -#endif -#ifdef HAVE_STDIO_H - struct { - int autoclose; - FILE *fp; - } stdio; -#endif - struct { - Uint8 *base; - Uint8 *here; - Uint8 *stop; - } mem; - struct { - void *data1; - } unknown; - } hidden; - -} SDL_RWops; - - -/* Functions to create SDL_RWops structures from various data sources */ - -extern DECLSPEC SDL_RWops * SDLCALL SDL_RWFromFile(const char *file, const char *mode); - -#ifdef HAVE_STDIO_H -extern DECLSPEC SDL_RWops * SDLCALL SDL_RWFromFP(FILE *fp, int autoclose); -#endif - -extern DECLSPEC SDL_RWops * SDLCALL SDL_RWFromMem(void *mem, int size); -extern DECLSPEC SDL_RWops * SDLCALL SDL_RWFromConstMem(const void *mem, int size); - -extern DECLSPEC SDL_RWops * SDLCALL SDL_AllocRW(void); -extern DECLSPEC void SDLCALL SDL_FreeRW(SDL_RWops *area); - -#define RW_SEEK_SET 0 /* Seek from the beginning of data */ -#define RW_SEEK_CUR 1 /* Seek relative to current read point */ -#define RW_SEEK_END 2 /* Seek relative to the end of data */ - -/* Macros to easily read and write from an SDL_RWops structure */ -#define SDL_RWseek(ctx, offset, whence) (ctx)->seek(ctx, offset, whence) -#define SDL_RWtell(ctx) (ctx)->seek(ctx, 0, RW_SEEK_CUR) -#define SDL_RWread(ctx, ptr, size, n) (ctx)->read(ctx, ptr, size, n) -#define SDL_RWwrite(ctx, ptr, size, n) (ctx)->write(ctx, ptr, size, n) -#define SDL_RWclose(ctx) (ctx)->close(ctx) - - -/* Read an item of the specified endianness and return in native format */ -extern DECLSPEC Uint16 SDLCALL SDL_ReadLE16(SDL_RWops *src); -extern DECLSPEC Uint16 SDLCALL SDL_ReadBE16(SDL_RWops *src); -extern DECLSPEC Uint32 SDLCALL SDL_ReadLE32(SDL_RWops *src); -extern DECLSPEC Uint32 SDLCALL SDL_ReadBE32(SDL_RWops *src); -extern DECLSPEC Uint64 SDLCALL SDL_ReadLE64(SDL_RWops *src); -extern DECLSPEC Uint64 SDLCALL SDL_ReadBE64(SDL_RWops *src); - -/* Write an item of native format to the specified endianness */ -extern DECLSPEC int SDLCALL SDL_WriteLE16(SDL_RWops *dst, Uint16 value); -extern DECLSPEC int SDLCALL SDL_WriteBE16(SDL_RWops *dst, Uint16 value); -extern DECLSPEC int SDLCALL SDL_WriteLE32(SDL_RWops *dst, Uint32 value); -extern DECLSPEC int SDLCALL SDL_WriteBE32(SDL_RWops *dst, Uint32 value); -extern DECLSPEC int SDLCALL SDL_WriteLE64(SDL_RWops *dst, Uint64 value); -extern DECLSPEC int SDLCALL SDL_WriteBE64(SDL_RWops *dst, Uint64 value); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_rwops_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_stdinc.h b/distrib/sdl-1.2.12/include/SDL_stdinc.h deleted file mode 100644 index 891a9ac..0000000 --- a/distrib/sdl-1.2.12/include/SDL_stdinc.h +++ /dev/null @@ -1,594 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This is a general header that includes C language support */ - -#ifndef _SDL_stdinc_h -#define _SDL_stdinc_h - -#include "SDL_config.h" - - -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef HAVE_STDIO_H -#include -#endif -#if defined(STDC_HEADERS) -# include -# include -# include -#else -# if defined(HAVE_STDLIB_H) -# include -# elif defined(HAVE_MALLOC_H) -# include -# endif -# if defined(HAVE_STDDEF_H) -# include -# endif -# if defined(HAVE_STDARG_H) -# include -# endif -#endif -#ifdef HAVE_STRING_H -# if !defined(STDC_HEADERS) && defined(HAVE_MEMORY_H) -# include -# endif -# include -#endif -#ifdef HAVE_STRINGS_H -# include -#endif -#if defined(HAVE_INTTYPES_H) -# include -#elif defined(HAVE_STDINT_H) -# include -#endif -#ifdef HAVE_CTYPE_H -# include -#endif -#ifdef HAVE_ICONV_H -# include -#endif - -/* The number of elements in an array */ -#define SDL_arraysize(array) (sizeof(array)/sizeof(array[0])) -#define SDL_TABLESIZE(table) SDL_arraysize(table) - -/* Basic data types */ -typedef enum SDL_bool { - SDL_FALSE = 0, - SDL_TRUE = 1 -} SDL_bool; - -typedef int8_t Sint8; -typedef uint8_t Uint8; -typedef int16_t Sint16; -typedef uint16_t Uint16; -typedef int32_t Sint32; -typedef uint32_t Uint32; - -#ifdef SDL_HAS_64BIT_TYPE -typedef int64_t Sint64; -#ifndef SYMBIAN32_GCCE -typedef uint64_t Uint64; -#endif -#else -/* This is really just a hack to prevent the compiler from complaining */ -typedef struct { - Uint32 hi; - Uint32 lo; -} Uint64, Sint64; -#endif - -/* Make sure the types really have the right sizes */ -#define SDL_COMPILE_TIME_ASSERT(name, x) \ - typedef int SDL_dummy_ ## name[(x) * 2 - 1] - -SDL_COMPILE_TIME_ASSERT(uint8, sizeof(Uint8) == 1); -SDL_COMPILE_TIME_ASSERT(sint8, sizeof(Sint8) == 1); -SDL_COMPILE_TIME_ASSERT(uint16, sizeof(Uint16) == 2); -SDL_COMPILE_TIME_ASSERT(sint16, sizeof(Sint16) == 2); -SDL_COMPILE_TIME_ASSERT(uint32, sizeof(Uint32) == 4); -SDL_COMPILE_TIME_ASSERT(sint32, sizeof(Sint32) == 4); -SDL_COMPILE_TIME_ASSERT(uint64, sizeof(Uint64) == 8); -SDL_COMPILE_TIME_ASSERT(sint64, sizeof(Sint64) == 8); - -/* Check to make sure enums are the size of ints, for structure packing. - For both Watcom C/C++ and Borland C/C++ the compiler option that makes - enums having the size of an int must be enabled. - This is "-b" for Borland C/C++ and "-ei" for Watcom C/C++ (v11). -*/ -/* Enable enums always int in CodeWarrior (for MPW use "-enum int") */ -#ifdef __MWERKS__ -#pragma enumsalwaysint on -#endif - -typedef enum { - DUMMY_ENUM_VALUE -} SDL_DUMMY_ENUM; - -#ifndef __NDS__ -SDL_COMPILE_TIME_ASSERT(enum, sizeof(SDL_DUMMY_ENUM) == sizeof(int)); -#endif - - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -#ifdef HAVE_MALLOC -#define SDL_malloc malloc -#else -extern DECLSPEC void * SDLCALL SDL_malloc(size_t size); -#endif - -#ifdef HAVE_CALLOC -#define SDL_calloc calloc -#else -extern DECLSPEC void * SDLCALL SDL_calloc(size_t nmemb, size_t size); -#endif - -#ifdef HAVE_REALLOC -#define SDL_realloc realloc -#else -extern DECLSPEC void * SDLCALL SDL_realloc(void *mem, size_t size); -#endif - -#ifdef HAVE_FREE -#define SDL_free free -#else -extern DECLSPEC void SDLCALL SDL_free(void *mem); -#endif - -#if defined(HAVE_ALLOCA) && !defined(alloca) -# if defined(HAVE_ALLOCA_H) -# include -# elif defined(__GNUC__) -# define alloca __builtin_alloca -# elif defined(_MSC_VER) -# include -# define alloca _alloca -# elif defined(__WATCOMC__) -# include -# elif defined(__DMC__) -# include -# elif defined(__AIX__) - #pragma alloca -# elif defined(__MRC__) - void *alloca (unsigned); -# else - char *alloca (); -# endif -#endif -#ifdef HAVE_ALLOCA -#define SDL_stack_alloc(type, count) (type*)alloca(sizeof(type)*(count)) -#define SDL_stack_free(data) -#else -#define SDL_stack_alloc(type, count) (type*)SDL_malloc(sizeof(type)*(count)) -#define SDL_stack_free(data) SDL_free(data) -#endif - -#ifdef HAVE_GETENV -#define SDL_getenv getenv -#else -extern DECLSPEC char * SDLCALL SDL_getenv(const char *name); -#endif - -#ifdef HAVE_PUTENV -#define SDL_putenv putenv -#else -extern DECLSPEC int SDLCALL SDL_putenv(const char *variable); -#endif - -#ifdef HAVE_QSORT -#define SDL_qsort qsort -#else -extern DECLSPEC void SDLCALL SDL_qsort(void *base, size_t nmemb, size_t size, - int (*compare)(const void *, const void *)); -#endif - -#ifdef HAVE_ABS -#define SDL_abs abs -#else -#define SDL_abs(X) ((X) < 0 ? -(X) : (X)) -#endif - -#define SDL_min(x, y) (((x) < (y)) ? (x) : (y)) -#define SDL_max(x, y) (((x) > (y)) ? (x) : (y)) - -#ifdef HAVE_CTYPE_H -#define SDL_isdigit(X) isdigit(X) -#define SDL_isspace(X) isspace(X) -#define SDL_toupper(X) toupper(X) -#define SDL_tolower(X) tolower(X) -#else -#define SDL_isdigit(X) (((X) >= '0') && ((X) <= '9')) -#define SDL_isspace(X) (((X) == ' ') || ((X) == '\t') || ((X) == '\r') || ((X) == '\n')) -#define SDL_toupper(X) (((X) >= 'a') && ((X) <= 'z') ? ('A'+((X)-'a')) : (X)) -#define SDL_tolower(X) (((X) >= 'A') && ((X) <= 'Z') ? ('a'+((X)-'A')) : (X)) -#endif - -#ifdef HAVE_MEMSET -#define SDL_memset memset -#else -extern DECLSPEC void * SDLCALL SDL_memset(void *dst, int c, size_t len); -#endif - -#if defined(__GNUC__) && defined(i386) -#define SDL_memset4(dst, val, len) \ -do { \ - int u0, u1, u2; \ - __asm__ __volatile__ ( \ - "cld\n\t" \ - "rep ; stosl\n\t" \ - : "=&D" (u0), "=&a" (u1), "=&c" (u2) \ - : "0" (dst), "1" (val), "2" ((Uint32)(len)) \ - : "memory" ); \ -} while(0) -#endif -#ifndef SDL_memset4 -#define SDL_memset4(dst, val, len) \ -do { \ - unsigned _count = (len); \ - unsigned _n = (_count + 3) / 4; \ - Uint32 *_p = (Uint32 *)(dst); \ - Uint32 _val = (val); \ - switch (_count % 4) { \ - case 0: do { *_p++ = _val; \ - case 3: *_p++ = _val; \ - case 2: *_p++ = _val; \ - case 1: *_p++ = _val; \ - } while ( --_n ); \ - } \ -} while(0) -#endif - -/* We can count on memcpy existing on Mac OS X and being well-tuned. */ -#if defined(__MACH__) && defined(__APPLE__) -#define SDL_memcpy(dst, src, len) memcpy(dst, src, len) -#elif defined(__GNUC__) && defined(i386) -#define SDL_memcpy(dst, src, len) \ -do { \ - int u0, u1, u2; \ - __asm__ __volatile__ ( \ - "cld\n\t" \ - "rep ; movsl\n\t" \ - "testb $2,%b4\n\t" \ - "je 1f\n\t" \ - "movsw\n" \ - "1:\ttestb $1,%b4\n\t" \ - "je 2f\n\t" \ - "movsb\n" \ - "2:" \ - : "=&c" (u0), "=&D" (u1), "=&S" (u2) \ - : "0" ((unsigned)(len)/4), "q" (len), "1" (dst),"2" (src) \ - : "memory" ); \ -} while(0) -#endif -#ifndef SDL_memcpy -#ifdef HAVE_MEMCPY -#define SDL_memcpy memcpy -#elif defined(HAVE_BCOPY) -#define SDL_memcpy(d, s, n) bcopy((s), (d), (n)) -#else -extern DECLSPEC void * SDLCALL SDL_memcpy(void *dst, const void *src, size_t len); -#endif -#endif - -/* We can count on memcpy existing on Mac OS X and being well-tuned. */ -#if defined(__MACH__) && defined(__APPLE__) -#define SDL_memcpy4(dst, src, len) memcpy(dst, src, (len)*4) -#elif defined(__GNUC__) && defined(i386) -#define SDL_memcpy4(dst, src, len) \ -do { \ - int ecx, edi, esi; \ - __asm__ __volatile__ ( \ - "cld\n\t" \ - "rep ; movsl" \ - : "=&c" (ecx), "=&D" (edi), "=&S" (esi) \ - : "0" ((unsigned)(len)), "1" (dst), "2" (src) \ - : "memory" ); \ -} while(0) -#endif -#ifndef SDL_memcpy4 -#define SDL_memcpy4(dst, src, len) SDL_memcpy(dst, src, (len) << 2) -#endif - -#if defined(__GNUC__) && defined(i386) -#define SDL_revcpy(dst, src, len) \ -do { \ - int u0, u1, u2; \ - char *dstp = (char *)(dst); \ - char *srcp = (char *)(src); \ - int n = (len); \ - if ( n >= 4 ) { \ - __asm__ __volatile__ ( \ - "std\n\t" \ - "rep ; movsl\n\t" \ - : "=&c" (u0), "=&D" (u1), "=&S" (u2) \ - : "0" (n >> 2), \ - "1" (dstp+(n-4)), "2" (srcp+(n-4)) \ - : "memory" ); \ - } \ - switch (n & 3) { \ - case 3: dstp[2] = srcp[2]; \ - case 2: dstp[1] = srcp[1]; \ - case 1: dstp[0] = srcp[0]; \ - break; \ - default: \ - break; \ - } \ -} while(0) -#endif -#ifndef SDL_revcpy -extern DECLSPEC void * SDLCALL SDL_revcpy(void *dst, const void *src, size_t len); -#endif - -#ifdef HAVE_MEMMOVE -#define SDL_memmove memmove -#elif defined(HAVE_BCOPY) -#define SDL_memmove(d, s, n) bcopy((s), (d), (n)) -#else -#define SDL_memmove(dst, src, len) \ -do { \ - if ( dst < src ) { \ - SDL_memcpy(dst, src, len); \ - } else { \ - SDL_revcpy(dst, src, len); \ - } \ -} while(0) -#endif - -#ifdef HAVE_MEMCMP -#define SDL_memcmp memcmp -#else -extern DECLSPEC int SDLCALL SDL_memcmp(const void *s1, const void *s2, size_t len); -#endif - -#ifdef HAVE_STRLEN -#define SDL_strlen strlen -#else -extern DECLSPEC size_t SDLCALL SDL_strlen(const char *string); -#endif - -#ifdef HAVE_STRLCPY -#define SDL_strlcpy strlcpy -#else -extern DECLSPEC size_t SDLCALL SDL_strlcpy(char *dst, const char *src, size_t maxlen); -#endif - -#ifdef HAVE_STRLCAT -#define SDL_strlcat strlcat -#else -extern DECLSPEC size_t SDLCALL SDL_strlcat(char *dst, const char *src, size_t maxlen); -#endif - -#ifdef HAVE_STRDUP -#define SDL_strdup strdup -#else -extern DECLSPEC char * SDLCALL SDL_strdup(const char *string); -#endif - -#ifdef HAVE__STRREV -#define SDL_strrev _strrev -#else -extern DECLSPEC char * SDLCALL SDL_strrev(char *string); -#endif - -#ifdef HAVE__STRUPR -#define SDL_strupr _strupr -#else -extern DECLSPEC char * SDLCALL SDL_strupr(char *string); -#endif - -#ifdef HAVE__STRLWR -#define SDL_strlwr _strlwr -#else -extern DECLSPEC char * SDLCALL SDL_strlwr(char *string); -#endif - -#ifdef HAVE_STRCHR -#define SDL_strchr strchr -#elif defined(HAVE_INDEX) -#define SDL_strchr index -#else -extern DECLSPEC char * SDLCALL SDL_strchr(const char *string, int c); -#endif - -#ifdef HAVE_STRRCHR -#define SDL_strrchr strrchr -#elif defined(HAVE_RINDEX) -#define SDL_strrchr rindex -#else -extern DECLSPEC char * SDLCALL SDL_strrchr(const char *string, int c); -#endif - -#ifdef HAVE_STRSTR -#define SDL_strstr strstr -#else -extern DECLSPEC char * SDLCALL SDL_strstr(const char *haystack, const char *needle); -#endif - -#ifdef HAVE_ITOA -#define SDL_itoa itoa -#else -#define SDL_itoa(value, string, radix) SDL_ltoa((long)value, string, radix) -#endif - -#ifdef HAVE__LTOA -#define SDL_ltoa _ltoa -#else -extern DECLSPEC char * SDLCALL SDL_ltoa(long value, char *string, int radix); -#endif - -#ifdef HAVE__UITOA -#define SDL_uitoa _uitoa -#else -#define SDL_uitoa(value, string, radix) SDL_ultoa((long)value, string, radix) -#endif - -#ifdef HAVE__ULTOA -#define SDL_ultoa _ultoa -#else -extern DECLSPEC char * SDLCALL SDL_ultoa(unsigned long value, char *string, int radix); -#endif - -#ifdef HAVE_STRTOL -#define SDL_strtol strtol -#else -extern DECLSPEC long SDLCALL SDL_strtol(const char *string, char **endp, int base); -#endif - -#ifdef HAVE_STRTOUL -#define SDL_strtoul strtoul -#else -extern DECLSPEC unsigned long SDLCALL SDL_strtoul(const char *string, char **endp, int base); -#endif - -#ifdef SDL_HAS_64BIT_TYPE - -#ifdef HAVE__I64TOA -#define SDL_lltoa _i64toa -#else -extern DECLSPEC char* SDLCALL SDL_lltoa(Sint64 value, char *string, int radix); -#endif - -#ifdef HAVE__UI64TOA -#define SDL_ulltoa _ui64toa -#else -extern DECLSPEC char* SDLCALL SDL_ulltoa(Uint64 value, char *string, int radix); -#endif - -#ifdef HAVE_STRTOLL -#define SDL_strtoll strtoll -#else -extern DECLSPEC Sint64 SDLCALL SDL_strtoll(const char *string, char **endp, int base); -#endif - -#ifdef HAVE_STRTOULL -#define SDL_strtoull strtoull -#else -extern DECLSPEC Uint64 SDLCALL SDL_strtoull(const char *string, char **endp, int base); -#endif - -#endif /* SDL_HAS_64BIT_TYPE */ - -#ifdef HAVE_STRTOD -#define SDL_strtod strtod -#else -extern DECLSPEC double SDLCALL SDL_strtod(const char *string, char **endp); -#endif - -#ifdef HAVE_ATOI -#define SDL_atoi atoi -#else -#define SDL_atoi(X) SDL_strtol(X, NULL, 0) -#endif - -#ifdef HAVE_ATOF -#define SDL_atof atof -#else -#define SDL_atof(X) SDL_strtod(X, NULL) -#endif - -#ifdef HAVE_STRCMP -#define SDL_strcmp strcmp -#else -extern DECLSPEC int SDLCALL SDL_strcmp(const char *str1, const char *str2); -#endif - -#ifdef HAVE_STRNCMP -#define SDL_strncmp strncmp -#else -extern DECLSPEC int SDLCALL SDL_strncmp(const char *str1, const char *str2, size_t maxlen); -#endif - -#ifdef HAVE_STRCASECMP -#define SDL_strcasecmp strcasecmp -#elif defined(HAVE__STRICMP) -#define SDL_strcasecmp _stricmp -#else -extern DECLSPEC int SDLCALL SDL_strcasecmp(const char *str1, const char *str2); -#endif - -#ifdef HAVE_STRNCASECMP -#define SDL_strncasecmp strncasecmp -#elif defined(HAVE__STRNICMP) -#define SDL_strncasecmp _strnicmp -#else -extern DECLSPEC int SDLCALL SDL_strncasecmp(const char *str1, const char *str2, size_t maxlen); -#endif - -#ifdef HAVE_SSCANF -#define SDL_sscanf sscanf -#else -extern DECLSPEC int SDLCALL SDL_sscanf(const char *text, const char *fmt, ...); -#endif - -#ifdef HAVE_SNPRINTF -#define SDL_snprintf snprintf -#else -extern DECLSPEC int SDLCALL SDL_snprintf(char *text, size_t maxlen, const char *fmt, ...); -#endif - -#ifdef HAVE_VSNPRINTF -#define SDL_vsnprintf vsnprintf -#else -extern DECLSPEC int SDLCALL SDL_vsnprintf(char *text, size_t maxlen, const char *fmt, va_list ap); -#endif - -/* The SDL implementation of iconv() returns these error codes */ -#define SDL_ICONV_ERROR (size_t)-1 -#define SDL_ICONV_E2BIG (size_t)-2 -#define SDL_ICONV_EILSEQ (size_t)-3 -#define SDL_ICONV_EINVAL (size_t)-4 - -#ifdef HAVE_ICONV -#define SDL_iconv_t iconv_t -#define SDL_iconv_open iconv_open -#define SDL_iconv_close iconv_close -#else -typedef struct _SDL_iconv_t *SDL_iconv_t; -extern DECLSPEC SDL_iconv_t SDLCALL SDL_iconv_open(const char *tocode, const char *fromcode); -extern DECLSPEC int SDLCALL SDL_iconv_close(SDL_iconv_t cd); -#endif -extern DECLSPEC size_t SDLCALL SDL_iconv(SDL_iconv_t cd, const char **inbuf, size_t *inbytesleft, char **outbuf, size_t *outbytesleft); -/* This function converts a string between encodings in one pass, returning a - string that must be freed with SDL_free() or NULL on error. -*/ -extern DECLSPEC char * SDLCALL SDL_iconv_string(const char *tocode, const char *fromcode, const char *inbuf, size_t inbytesleft); -#define SDL_iconv_utf8_locale(S) SDL_iconv_string("", "UTF-8", S, SDL_strlen(S)+1) -#define SDL_iconv_utf8_ucs2(S) (Uint16 *)SDL_iconv_string("UCS-2", "UTF-8", S, SDL_strlen(S)+1) -#define SDL_iconv_utf8_ucs4(S) (Uint32 *)SDL_iconv_string("UCS-4", "UTF-8", S, SDL_strlen(S)+1) - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_stdinc_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_syswm.h b/distrib/sdl-1.2.12/include/SDL_syswm.h deleted file mode 100644 index 0502037..0000000 --- a/distrib/sdl-1.2.12/include/SDL_syswm.h +++ /dev/null @@ -1,226 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Include file for SDL custom system window manager hooks */ - -#ifndef _SDL_syswm_h -#define _SDL_syswm_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_version.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Your application has access to a special type of event 'SDL_SYSWMEVENT', - which contains window-manager specific information and arrives whenever - an unhandled window event occurs. This event is ignored by default, but - you can enable it with SDL_EventState() -*/ -#ifdef SDL_PROTOTYPES_ONLY -struct SDL_SysWMinfo; -typedef struct SDL_SysWMinfo SDL_SysWMinfo; -#else - -/* This is the structure for custom window manager events */ -#if defined(SDL_VIDEO_DRIVER_X11) -#if defined(__APPLE__) && defined(__MACH__) -/* conflicts with Quickdraw.h */ -#define Cursor X11Cursor -#endif - -#include -#include - -#if defined(__APPLE__) && defined(__MACH__) -/* matches the re-define above */ -#undef Cursor -#endif - -/* These are the various supported subsystems under UNIX */ -typedef enum { - SDL_SYSWM_X11 -} SDL_SYSWM_TYPE; - -/* The UNIX custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - SDL_SYSWM_TYPE subsystem; - union { - XEvent xevent; - } event; -}; - -/* The UNIX custom window manager information structure. - When this structure is returned, it holds information about which - low level system it is using, and will be one of SDL_SYSWM_TYPE. - */ -typedef struct SDL_SysWMinfo { - SDL_version version; - SDL_SYSWM_TYPE subsystem; - union { - struct { - Display *display; /* The X11 display */ - Window window; /* The X11 display window */ - /* These locking functions should be called around - any X11 functions using the display variable, - but not the gfxdisplay variable. - They lock the event thread, so should not be - called around event functions or from event filters. - */ - void (*lock_func)(void); - void (*unlock_func)(void); - - /* Introduced in SDL 1.0.2 */ - Window fswindow; /* The X11 fullscreen window */ - Window wmwindow; /* The X11 managed input window */ - - /* Introduced in SDL 1.2.12 */ - Display *gfxdisplay; /* The X11 display to which rendering is done */ - } x11; - } info; -} SDL_SysWMinfo; - -#elif defined(SDL_VIDEO_DRIVER_NANOX) -#include - -/* The generic custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - int data; -}; - -/* The windows custom window manager information structure */ -typedef struct SDL_SysWMinfo { - SDL_version version ; - GR_WINDOW_ID window ; /* The display window */ -} SDL_SysWMinfo; - -#elif defined(SDL_VIDEO_DRIVER_WINDIB) || defined(SDL_VIDEO_DRIVER_DDRAW) || defined(SDL_VIDEO_DRIVER_GAPI) -#define WIN32_LEAN_AND_MEAN -#include - -/* The windows custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - HWND hwnd; /* The window for the message */ - UINT msg; /* The type of message */ - WPARAM wParam; /* WORD message parameter */ - LPARAM lParam; /* LONG message parameter */ -}; - -/* The windows custom window manager information structure */ -typedef struct SDL_SysWMinfo { - SDL_version version; - HWND window; /* The Win32 display window */ - HGLRC hglrc; /* The OpenGL context, if any */ -} SDL_SysWMinfo; - -#elif defined(SDL_VIDEO_DRIVER_RISCOS) - -/* RISC OS custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - int eventCode; /* The window for the message */ - int pollBlock[64]; -}; - -/* The RISC OS custom window manager information structure */ -typedef struct SDL_SysWMinfo { - SDL_version version; - int wimpVersion; /* Wimp version running under */ - int taskHandle; /* The RISC OS task handle */ - int window; /* The RISC OS display window */ -} SDL_SysWMinfo; - -#elif defined(SDL_VIDEO_DRIVER_PHOTON) -#include -#include - -/* The QNX custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - int data; -}; - -/* The QNX custom window manager information structure */ -typedef struct SDL_SysWMinfo { - SDL_version version; - int data; -} SDL_SysWMinfo; - -#elif defined(SDL_VIDEO_DRIVER_QUARTZ) - -struct SDL_SysWMmsg { - SDL_version version; - int data; -}; - -typedef struct SDL_SysWMinfo { - SDL_version version; - void* nsWindowPtr; -} SDL_SysWMinfo; - -#else - -/* The generic custom event structure */ -struct SDL_SysWMmsg { - SDL_version version; - int data; -}; - -/* The generic custom window manager information structure */ -typedef struct SDL_SysWMinfo { - SDL_version version; - int data; -} SDL_SysWMinfo; - -#endif /* video driver type */ - -#endif /* SDL_PROTOTYPES_ONLY */ - -/* Function prototypes */ -/* - * This function gives you custom hooks into the window manager information. - * It fills the structure pointed to by 'info' with custom information and - * returns 1 if the function is implemented. If it's not implemented, or - * the version member of the 'info' structure is invalid, it returns 0. - * - * You typically use this function like this: - * SDL_SysWMInfo info; - * SDL_VERSION(&info.version); - * if ( SDL_GetWMInfo(&info) ) { ... } - */ -extern DECLSPEC int SDLCALL SDL_GetWMInfo(SDL_SysWMinfo *info); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_syswm_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_thread.h b/distrib/sdl-1.2.12/include/SDL_thread.h deleted file mode 100644 index 403ee46..0000000 --- a/distrib/sdl-1.2.12/include/SDL_thread.h +++ /dev/null @@ -1,119 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_thread_h -#define _SDL_thread_h - -/* Header for the SDL thread management routines - - These are independent of the other SDL routines. -*/ - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -/* Thread synchronization primitives */ -#include "SDL_mutex.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* The SDL thread structure, defined in SDL_thread.c */ -struct SDL_Thread; -typedef struct SDL_Thread SDL_Thread; - -/* Create a thread */ -#if ((defined(__WIN32__) && !defined(HAVE_LIBC)) || defined(__OS2__)) && !defined(__SYMBIAN32__) -/* - We compile SDL into a DLL on OS/2. This means, that it's the DLL which - creates a new thread for the calling process with the SDL_CreateThread() - API. There is a problem with this, that only the RTL of the SDL.DLL will - be initialized for those threads, and not the RTL of the calling application! - To solve this, we make a little hack here. - We'll always use the caller's _beginthread() and _endthread() APIs to - start a new thread. This way, if it's the SDL.DLL which uses this API, - then the RTL of SDL.DLL will be used to create the new thread, and if it's - the application, then the RTL of the application will be used. - So, in short: - Always use the _beginthread() and _endthread() of the calling runtime library! -*/ -#define SDL_PASSED_BEGINTHREAD_ENDTHREAD -#ifndef _WIN32_WCE -#include /* This has _beginthread() and _endthread() defined! */ -#endif - -#ifdef __OS2__ -typedef int (*pfnSDL_CurrentBeginThread)(void (*func)(void *), void *, unsigned, void *arg); -typedef void (*pfnSDL_CurrentEndThread)(void); -#elif __GNUC__ -typedef unsigned long (__cdecl *pfnSDL_CurrentBeginThread) (void *, unsigned, - unsigned (__stdcall *func)(void *), void *arg, - unsigned, unsigned *threadID); -typedef void (__cdecl *pfnSDL_CurrentEndThread)(unsigned code); -#else -typedef uintptr_t (__cdecl *pfnSDL_CurrentBeginThread) (void *, unsigned, - unsigned (__stdcall *func)(void *), void *arg, - unsigned, unsigned *threadID); -typedef void (__cdecl *pfnSDL_CurrentEndThread)(unsigned code); -#endif - -extern DECLSPEC SDL_Thread * SDLCALL SDL_CreateThread(int (SDLCALL *fn)(void *), void *data, pfnSDL_CurrentBeginThread pfnBeginThread, pfnSDL_CurrentEndThread pfnEndThread); - -#ifdef __OS2__ -#define SDL_CreateThread(fn, data) SDL_CreateThread(fn, data, _beginthread, _endthread) -#elif defined(_WIN32_WCE) -#define SDL_CreateThread(fn, data) SDL_CreateThread(fn, data, NULL, NULL) -#else -#define SDL_CreateThread(fn, data) SDL_CreateThread(fn, data, _beginthreadex, _endthreadex) -#endif -#else -extern DECLSPEC SDL_Thread * SDLCALL SDL_CreateThread(int (SDLCALL *fn)(void *), void *data); -#endif - -/* Get the 32-bit thread identifier for the current thread */ -extern DECLSPEC Uint32 SDLCALL SDL_ThreadID(void); - -/* Get the 32-bit thread identifier for the specified thread, - equivalent to SDL_ThreadID() if the specified thread is NULL. - */ -extern DECLSPEC Uint32 SDLCALL SDL_GetThreadID(SDL_Thread *thread); - -/* Wait for a thread to finish. - The return code for the thread function is placed in the area - pointed to by 'status', if 'status' is not NULL. - */ -extern DECLSPEC void SDLCALL SDL_WaitThread(SDL_Thread *thread, int *status); - -/* Forcefully kill a thread without worrying about its state */ -extern DECLSPEC void SDLCALL SDL_KillThread(SDL_Thread *thread); - - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_thread_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_timer.h b/distrib/sdl-1.2.12/include/SDL_timer.h deleted file mode 100644 index d21159f..0000000 --- a/distrib/sdl-1.2.12/include/SDL_timer.h +++ /dev/null @@ -1,115 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -#ifndef _SDL_timer_h -#define _SDL_timer_h - -/* Header for the SDL time management routines */ - -#include "SDL_stdinc.h" -#include "SDL_error.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* This is the OS scheduler timeslice, in milliseconds */ -#define SDL_TIMESLICE 10 - -/* This is the maximum resolution of the SDL timer on all platforms */ -#define TIMER_RESOLUTION 10 /* Experimentally determined */ - -/* Get the number of milliseconds since the SDL library initialization. - * Note that this value wraps if the program runs for more than ~49 days. - */ -extern DECLSPEC Uint32 SDLCALL SDL_GetTicks(void); - -/* Wait a specified number of milliseconds before returning */ -extern DECLSPEC void SDLCALL SDL_Delay(Uint32 ms); - -/* Function prototype for the timer callback function */ -typedef Uint32 (SDLCALL *SDL_TimerCallback)(Uint32 interval); - -/* Set a callback to run after the specified number of milliseconds has - * elapsed. The callback function is passed the current timer interval - * and returns the next timer interval. If the returned value is the - * same as the one passed in, the periodic alarm continues, otherwise a - * new alarm is scheduled. If the callback returns 0, the periodic alarm - * is cancelled. - * - * To cancel a currently running timer, call SDL_SetTimer(0, NULL); - * - * The timer callback function may run in a different thread than your - * main code, and so shouldn't call any functions from within itself. - * - * The maximum resolution of this timer is 10 ms, which means that if - * you request a 16 ms timer, your callback will run approximately 20 ms - * later on an unloaded system. If you wanted to set a flag signaling - * a frame update at 30 frames per second (every 33 ms), you might set a - * timer for 30 ms: - * SDL_SetTimer((33/10)*10, flag_update); - * - * If you use this function, you need to pass SDL_INIT_TIMER to SDL_Init(). - * - * Under UNIX, you should not use raise or use SIGALRM and this function - * in the same program, as it is implemented using setitimer(). You also - * should not use this function in multi-threaded applications as signals - * to multi-threaded apps have undefined behavior in some implementations. - * - * This function returns 0 if successful, or -1 if there was an error. - */ -extern DECLSPEC int SDLCALL SDL_SetTimer(Uint32 interval, SDL_TimerCallback callback); - -/* New timer API, supports multiple timers - * Written by Stephane Peter - */ - -/* Function prototype for the new timer callback function. - * The callback function is passed the current timer interval and returns - * the next timer interval. If the returned value is the same as the one - * passed in, the periodic alarm continues, otherwise a new alarm is - * scheduled. If the callback returns 0, the periodic alarm is cancelled. - */ -typedef Uint32 (SDLCALL *SDL_NewTimerCallback)(Uint32 interval, void *param); - -/* Definition of the timer ID type */ -typedef struct _SDL_TimerID *SDL_TimerID; - -/* Add a new timer to the pool of timers already running. - Returns a timer ID, or NULL when an error occurs. - */ -extern DECLSPEC SDL_TimerID SDLCALL SDL_AddTimer(Uint32 interval, SDL_NewTimerCallback callback, void *param); - -/* Remove one of the multiple timers knowing its ID. - * Returns a boolean value indicating success. - */ -extern DECLSPEC SDL_bool SDLCALL SDL_RemoveTimer(SDL_TimerID t); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_timer_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_types.h b/distrib/sdl-1.2.12/include/SDL_types.h deleted file mode 100644 index 853b9ce..0000000 --- a/distrib/sdl-1.2.12/include/SDL_types.h +++ /dev/null @@ -1,24 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* DEPRECATED */ -#include "SDL_stdinc.h" diff --git a/distrib/sdl-1.2.12/include/SDL_version.h b/distrib/sdl-1.2.12/include/SDL_version.h deleted file mode 100644 index 610ffe6..0000000 --- a/distrib/sdl-1.2.12/include/SDL_version.h +++ /dev/null @@ -1,85 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This header defines the current SDL version */ - -#ifndef _SDL_version_h -#define _SDL_version_h - -#include "SDL_stdinc.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL -*/ -#define SDL_MAJOR_VERSION 1 -#define SDL_MINOR_VERSION 2 -#define SDL_PATCHLEVEL 12 - -typedef struct SDL_version { - Uint8 major; - Uint8 minor; - Uint8 patch; -} SDL_version; - -/* This macro can be used to fill a version structure with the compile-time - * version of the SDL library. - */ -#define SDL_VERSION(X) \ -{ \ - (X)->major = SDL_MAJOR_VERSION; \ - (X)->minor = SDL_MINOR_VERSION; \ - (X)->patch = SDL_PATCHLEVEL; \ -} - -/* This macro turns the version numbers into a numeric value: - (1,2,3) -> (1203) - This assumes that there will never be more than 100 patchlevels -*/ -#define SDL_VERSIONNUM(X, Y, Z) \ - ((X)*1000 + (Y)*100 + (Z)) - -/* This is the version number macro for the current SDL version */ -#define SDL_COMPILEDVERSION \ - SDL_VERSIONNUM(SDL_MAJOR_VERSION, SDL_MINOR_VERSION, SDL_PATCHLEVEL) - -/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */ -#define SDL_VERSION_ATLEAST(X, Y, Z) \ - (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z)) - -/* This function gets the version of the dynamically linked SDL library. - it should NOT be used to fill a version structure, instead you should - use the SDL_Version() macro. - */ -extern DECLSPEC const SDL_version * SDLCALL SDL_Linked_Version(void); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_version_h */ diff --git a/distrib/sdl-1.2.12/include/SDL_video.h b/distrib/sdl-1.2.12/include/SDL_video.h deleted file mode 100644 index 64bdc34..0000000 --- a/distrib/sdl-1.2.12/include/SDL_video.h +++ /dev/null @@ -1,922 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* Header file for access to the SDL raw framebuffer window */ - -#ifndef _SDL_video_h -#define _SDL_video_h - -#include "SDL_stdinc.h" -#include "SDL_error.h" -#include "SDL_rwops.h" - -#include "begin_code.h" -/* Set up for C function definitions, even when using C++ */ -#ifdef __cplusplus -extern "C" { -#endif - -/* Transparency definitions: These define alpha as the opacity of a surface */ -#define SDL_ALPHA_OPAQUE 255 -#define SDL_ALPHA_TRANSPARENT 0 - -/* Useful data types */ -typedef struct SDL_Rect { - Sint16 x, y; - Uint16 w, h; -} SDL_Rect; - -typedef struct SDL_Color { - Uint8 r; - Uint8 g; - Uint8 b; - Uint8 unused; -} SDL_Color; -#define SDL_Colour SDL_Color - -typedef struct SDL_Palette { - int ncolors; - SDL_Color *colors; -} SDL_Palette; - -/* Everything in the pixel format structure is read-only */ -typedef struct SDL_PixelFormat { - SDL_Palette *palette; - Uint8 BitsPerPixel; - Uint8 BytesPerPixel; - Uint8 Rloss; - Uint8 Gloss; - Uint8 Bloss; - Uint8 Aloss; - Uint8 Rshift; - Uint8 Gshift; - Uint8 Bshift; - Uint8 Ashift; - Uint32 Rmask; - Uint32 Gmask; - Uint32 Bmask; - Uint32 Amask; - - /* RGB color key information */ - Uint32 colorkey; - /* Alpha value information (per-surface alpha) */ - Uint8 alpha; -} SDL_PixelFormat; - -/* This structure should be treated as read-only, except for 'pixels', - which, if not NULL, contains the raw pixel data for the surface. -*/ -typedef struct SDL_Surface { - Uint32 flags; /* Read-only */ - SDL_PixelFormat *format; /* Read-only */ - int w, h; /* Read-only */ - Uint16 pitch; /* Read-only */ - void *pixels; /* Read-write */ - int offset; /* Private */ - - /* Hardware-specific surface info */ - struct private_hwdata *hwdata; - - /* clipping information */ - SDL_Rect clip_rect; /* Read-only */ - Uint32 unused1; /* for binary compatibility */ - - /* Allow recursive locks */ - Uint32 locked; /* Private */ - - /* info for fast blit mapping to other surfaces */ - struct SDL_BlitMap *map; /* Private */ - - /* format version, bumped at every change to invalidate blit maps */ - unsigned int format_version; /* Private */ - - /* Reference count -- used when freeing surface */ - int refcount; /* Read-mostly */ -} SDL_Surface; - -/* These are the currently supported flags for the SDL_surface */ -/* Available for SDL_CreateRGBSurface() or SDL_SetVideoMode() */ -#define SDL_SWSURFACE 0x00000000 /* Surface is in system memory */ -#define SDL_HWSURFACE 0x00000001 /* Surface is in video memory */ -#define SDL_ASYNCBLIT 0x00000004 /* Use asynchronous blits if possible */ -/* Available for SDL_SetVideoMode() */ -#define SDL_ANYFORMAT 0x10000000 /* Allow any video depth/pixel-format */ -#define SDL_HWPALETTE 0x20000000 /* Surface has exclusive palette */ -#define SDL_DOUBLEBUF 0x40000000 /* Set up double-buffered video mode */ -#define SDL_FULLSCREEN 0x80000000 /* Surface is a full screen display */ -#define SDL_OPENGL 0x00000002 /* Create an OpenGL rendering context */ -#define SDL_OPENGLBLIT 0x0000000A /* Create an OpenGL rendering context and use it for blitting */ -#define SDL_RESIZABLE 0x00000010 /* This video mode may be resized */ -#define SDL_NOFRAME 0x00000020 /* No window caption or edge frame */ -/* Used internally (read-only) */ -#define SDL_HWACCEL 0x00000100 /* Blit uses hardware acceleration */ -#define SDL_SRCCOLORKEY 0x00001000 /* Blit uses a source color key */ -#define SDL_RLEACCELOK 0x00002000 /* Private flag */ -#define SDL_RLEACCEL 0x00004000 /* Surface is RLE encoded */ -#define SDL_SRCALPHA 0x00010000 /* Blit uses source alpha blending */ -#define SDL_PREALLOC 0x01000000 /* Surface uses preallocated memory */ - -/* Evaluates to true if the surface needs to be locked before access */ -#define SDL_MUSTLOCK(surface) \ - (surface->offset || \ - ((surface->flags & (SDL_HWSURFACE|SDL_ASYNCBLIT|SDL_RLEACCEL)) != 0)) - -/* typedef for private surface blitting functions */ -typedef int (*SDL_blit)(struct SDL_Surface *src, SDL_Rect *srcrect, - struct SDL_Surface *dst, SDL_Rect *dstrect); - - -/* Useful for determining the video hardware capabilities */ -typedef struct SDL_VideoInfo { - Uint32 hw_available :1; /* Flag: Can you create hardware surfaces? */ - Uint32 wm_available :1; /* Flag: Can you talk to a window manager? */ - Uint32 UnusedBits1 :6; - Uint32 UnusedBits2 :1; - Uint32 blit_hw :1; /* Flag: Accelerated blits HW --> HW */ - Uint32 blit_hw_CC :1; /* Flag: Accelerated blits with Colorkey */ - Uint32 blit_hw_A :1; /* Flag: Accelerated blits with Alpha */ - Uint32 blit_sw :1; /* Flag: Accelerated blits SW --> HW */ - Uint32 blit_sw_CC :1; /* Flag: Accelerated blits with Colorkey */ - Uint32 blit_sw_A :1; /* Flag: Accelerated blits with Alpha */ - Uint32 blit_fill :1; /* Flag: Accelerated color fill */ - Uint32 UnusedBits3 :16; - Uint32 video_mem; /* The total amount of video memory (in K) */ - SDL_PixelFormat *vfmt; /* Value: The format of the video surface */ - int current_w; /* Value: The current video mode width */ - int current_h; /* Value: The current video mode height */ -} SDL_VideoInfo; - - -/* The most common video overlay formats. - For an explanation of these pixel formats, see: - http://www.webartz.com/fourcc/indexyuv.htm - - For information on the relationship between color spaces, see: - http://www.neuro.sfc.keio.ac.jp/~aly/polygon/info/color-space-faq.html - */ -#define SDL_YV12_OVERLAY 0x32315659 /* Planar mode: Y + V + U (3 planes) */ -#define SDL_IYUV_OVERLAY 0x56555949 /* Planar mode: Y + U + V (3 planes) */ -#define SDL_YUY2_OVERLAY 0x32595559 /* Packed mode: Y0+U0+Y1+V0 (1 plane) */ -#define SDL_UYVY_OVERLAY 0x59565955 /* Packed mode: U0+Y0+V0+Y1 (1 plane) */ -#define SDL_YVYU_OVERLAY 0x55595659 /* Packed mode: Y0+V0+Y1+U0 (1 plane) */ - -/* The YUV hardware video overlay */ -typedef struct SDL_Overlay { - Uint32 format; /* Read-only */ - int w, h; /* Read-only */ - int planes; /* Read-only */ - Uint16 *pitches; /* Read-only */ - Uint8 **pixels; /* Read-write */ - - /* Hardware-specific surface info */ - struct private_yuvhwfuncs *hwfuncs; - struct private_yuvhwdata *hwdata; - - /* Special flags */ - Uint32 hw_overlay :1; /* Flag: This overlay hardware accelerated? */ - Uint32 UnusedBits :31; -} SDL_Overlay; - - -/* Public enumeration for setting the OpenGL window attributes. */ -typedef enum { - SDL_GL_RED_SIZE, - SDL_GL_GREEN_SIZE, - SDL_GL_BLUE_SIZE, - SDL_GL_ALPHA_SIZE, - SDL_GL_BUFFER_SIZE, - SDL_GL_DOUBLEBUFFER, - SDL_GL_DEPTH_SIZE, - SDL_GL_STENCIL_SIZE, - SDL_GL_ACCUM_RED_SIZE, - SDL_GL_ACCUM_GREEN_SIZE, - SDL_GL_ACCUM_BLUE_SIZE, - SDL_GL_ACCUM_ALPHA_SIZE, - SDL_GL_STEREO, - SDL_GL_MULTISAMPLEBUFFERS, - SDL_GL_MULTISAMPLESAMPLES, - SDL_GL_ACCELERATED_VISUAL, - SDL_GL_SWAP_CONTROL -} SDL_GLattr; - -/* flags for SDL_SetPalette() */ -#define SDL_LOGPAL 0x01 -#define SDL_PHYSPAL 0x02 - -/* Function prototypes */ - -/* These functions are used internally, and should not be used unless you - * have a specific need to specify the video driver you want to use. - * You should normally use SDL_Init() or SDL_InitSubSystem(). - * - * SDL_VideoInit() initializes the video subsystem -- sets up a connection - * to the window manager, etc, and determines the current video mode and - * pixel format, but does not initialize a window or graphics mode. - * Note that event handling is activated by this routine. - * - * If you use both sound and video in your application, you need to call - * SDL_Init() before opening the sound device, otherwise under Win32 DirectX, - * you won't be able to set full-screen display modes. - */ -extern DECLSPEC int SDLCALL SDL_VideoInit(const char *driver_name, Uint32 flags); -extern DECLSPEC void SDLCALL SDL_VideoQuit(void); - -/* This function fills the given character buffer with the name of the - * video driver, and returns a pointer to it if the video driver has - * been initialized. It returns NULL if no driver has been initialized. - */ -extern DECLSPEC char * SDLCALL SDL_VideoDriverName(char *namebuf, int maxlen); - -/* - * This function returns a pointer to the current display surface. - * If SDL is doing format conversion on the display surface, this - * function returns the publicly visible surface, not the real video - * surface. - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_GetVideoSurface(void); - -/* - * This function returns a read-only pointer to information about the - * video hardware. If this is called before SDL_SetVideoMode(), the 'vfmt' - * member of the returned structure will contain the pixel format of the - * "best" video mode. - */ -extern DECLSPEC const SDL_VideoInfo * SDLCALL SDL_GetVideoInfo(void); - -/* - * Check to see if a particular video mode is supported. - * It returns 0 if the requested mode is not supported under any bit depth, - * or returns the bits-per-pixel of the closest available mode with the - * given width and height. If this bits-per-pixel is different from the - * one used when setting the video mode, SDL_SetVideoMode() will succeed, - * but will emulate the requested bits-per-pixel with a shadow surface. - * - * The arguments to SDL_VideoModeOK() are the same ones you would pass to - * SDL_SetVideoMode() - */ -extern DECLSPEC int SDLCALL SDL_VideoModeOK(int width, int height, int bpp, Uint32 flags); - -/* - * Return a pointer to an array of available screen dimensions for the - * given format and video flags, sorted largest to smallest. Returns - * NULL if there are no dimensions available for a particular format, - * or (SDL_Rect **)-1 if any dimension is okay for the given format. - * - * If 'format' is NULL, the mode list will be for the format given - * by SDL_GetVideoInfo()->vfmt - */ -extern DECLSPEC SDL_Rect ** SDLCALL SDL_ListModes(SDL_PixelFormat *format, Uint32 flags); - -/* - * Set up a video mode with the specified width, height and bits-per-pixel. - * - * If 'bpp' is 0, it is treated as the current display bits per pixel. - * - * If SDL_ANYFORMAT is set in 'flags', the SDL library will try to set the - * requested bits-per-pixel, but will return whatever video pixel format is - * available. The default is to emulate the requested pixel format if it - * is not natively available. - * - * If SDL_HWSURFACE is set in 'flags', the video surface will be placed in - * video memory, if possible, and you may have to call SDL_LockSurface() - * in order to access the raw framebuffer. Otherwise, the video surface - * will be created in system memory. - * - * If SDL_ASYNCBLIT is set in 'flags', SDL will try to perform rectangle - * updates asynchronously, but you must always lock before accessing pixels. - * SDL will wait for updates to complete before returning from the lock. - * - * If SDL_HWPALETTE is set in 'flags', the SDL library will guarantee - * that the colors set by SDL_SetColors() will be the colors you get. - * Otherwise, in 8-bit mode, SDL_SetColors() may not be able to set all - * of the colors exactly the way they are requested, and you should look - * at the video surface structure to determine the actual palette. - * If SDL cannot guarantee that the colors you request can be set, - * i.e. if the colormap is shared, then the video surface may be created - * under emulation in system memory, overriding the SDL_HWSURFACE flag. - * - * If SDL_FULLSCREEN is set in 'flags', the SDL library will try to set - * a fullscreen video mode. The default is to create a windowed mode - * if the current graphics system has a window manager. - * If the SDL library is able to set a fullscreen video mode, this flag - * will be set in the surface that is returned. - * - * If SDL_DOUBLEBUF is set in 'flags', the SDL library will try to set up - * two surfaces in video memory and swap between them when you call - * SDL_Flip(). This is usually slower than the normal single-buffering - * scheme, but prevents "tearing" artifacts caused by modifying video - * memory while the monitor is refreshing. It should only be used by - * applications that redraw the entire screen on every update. - * - * If SDL_RESIZABLE is set in 'flags', the SDL library will allow the - * window manager, if any, to resize the window at runtime. When this - * occurs, SDL will send a SDL_VIDEORESIZE event to you application, - * and you must respond to the event by re-calling SDL_SetVideoMode() - * with the requested size (or another size that suits the application). - * - * If SDL_NOFRAME is set in 'flags', the SDL library will create a window - * without any title bar or frame decoration. Fullscreen video modes have - * this flag set automatically. - * - * This function returns the video framebuffer surface, or NULL if it fails. - * - * If you rely on functionality provided by certain video flags, check the - * flags of the returned surface to make sure that functionality is available. - * SDL will fall back to reduced functionality if the exact flags you wanted - * are not available. - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_SetVideoMode - (int width, int height, int bpp, Uint32 flags); - -/* - * Makes sure the given list of rectangles is updated on the given screen. - * If 'x', 'y', 'w' and 'h' are all 0, SDL_UpdateRect will update the entire - * screen. - * These functions should not be called while 'screen' is locked. - */ -extern DECLSPEC void SDLCALL SDL_UpdateRects - (SDL_Surface *screen, int numrects, SDL_Rect *rects); -extern DECLSPEC void SDLCALL SDL_UpdateRect - (SDL_Surface *screen, Sint32 x, Sint32 y, Uint32 w, Uint32 h); - -/* - * On hardware that supports double-buffering, this function sets up a flip - * and returns. The hardware will wait for vertical retrace, and then swap - * video buffers before the next video surface blit or lock will return. - * On hardware that doesn not support double-buffering, this is equivalent - * to calling SDL_UpdateRect(screen, 0, 0, 0, 0); - * The SDL_DOUBLEBUF flag must have been passed to SDL_SetVideoMode() when - * setting the video mode for this function to perform hardware flipping. - * This function returns 0 if successful, or -1 if there was an error. - */ -extern DECLSPEC int SDLCALL SDL_Flip(SDL_Surface *screen); - -/* - * Set the gamma correction for each of the color channels. - * The gamma values range (approximately) between 0.1 and 10.0 - * - * If this function isn't supported directly by the hardware, it will - * be emulated using gamma ramps, if available. If successful, this - * function returns 0, otherwise it returns -1. - */ -extern DECLSPEC int SDLCALL SDL_SetGamma(float red, float green, float blue); - -/* - * Set the gamma translation table for the red, green, and blue channels - * of the video hardware. Each table is an array of 256 16-bit quantities, - * representing a mapping between the input and output for that channel. - * The input is the index into the array, and the output is the 16-bit - * gamma value at that index, scaled to the output color precision. - * - * You may pass NULL for any of the channels to leave it unchanged. - * If the call succeeds, it will return 0. If the display driver or - * hardware does not support gamma translation, or otherwise fails, - * this function will return -1. - */ -extern DECLSPEC int SDLCALL SDL_SetGammaRamp(const Uint16 *red, const Uint16 *green, const Uint16 *blue); - -/* - * Retrieve the current values of the gamma translation tables. - * - * You must pass in valid pointers to arrays of 256 16-bit quantities. - * Any of the pointers may be NULL to ignore that channel. - * If the call succeeds, it will return 0. If the display driver or - * hardware does not support gamma translation, or otherwise fails, - * this function will return -1. - */ -extern DECLSPEC int SDLCALL SDL_GetGammaRamp(Uint16 *red, Uint16 *green, Uint16 *blue); - -/* - * Sets a portion of the colormap for the given 8-bit surface. If 'surface' - * is not a palettized surface, this function does nothing, returning 0. - * If all of the colors were set as passed to SDL_SetColors(), it will - * return 1. If not all the color entries were set exactly as given, - * it will return 0, and you should look at the surface palette to - * determine the actual color palette. - * - * When 'surface' is the surface associated with the current display, the - * display colormap will be updated with the requested colors. If - * SDL_HWPALETTE was set in SDL_SetVideoMode() flags, SDL_SetColors() - * will always return 1, and the palette is guaranteed to be set the way - * you desire, even if the window colormap has to be warped or run under - * emulation. - */ -extern DECLSPEC int SDLCALL SDL_SetColors(SDL_Surface *surface, - SDL_Color *colors, int firstcolor, int ncolors); - -/* - * Sets a portion of the colormap for a given 8-bit surface. - * 'flags' is one or both of: - * SDL_LOGPAL -- set logical palette, which controls how blits are mapped - * to/from the surface, - * SDL_PHYSPAL -- set physical palette, which controls how pixels look on - * the screen - * Only screens have physical palettes. Separate change of physical/logical - * palettes is only possible if the screen has SDL_HWPALETTE set. - * - * The return value is 1 if all colours could be set as requested, and 0 - * otherwise. - * - * SDL_SetColors() is equivalent to calling this function with - * flags = (SDL_LOGPAL|SDL_PHYSPAL). - */ -extern DECLSPEC int SDLCALL SDL_SetPalette(SDL_Surface *surface, int flags, - SDL_Color *colors, int firstcolor, - int ncolors); - -/* - * Maps an RGB triple to an opaque pixel value for a given pixel format - */ -extern DECLSPEC Uint32 SDLCALL SDL_MapRGB -(const SDL_PixelFormat * const format, - const Uint8 r, const Uint8 g, const Uint8 b); - -/* - * Maps an RGBA quadruple to a pixel value for a given pixel format - */ -extern DECLSPEC Uint32 SDLCALL SDL_MapRGBA -(const SDL_PixelFormat * const format, - const Uint8 r, const Uint8 g, const Uint8 b, const Uint8 a); - -/* - * Maps a pixel value into the RGB components for a given pixel format - */ -extern DECLSPEC void SDLCALL SDL_GetRGB(Uint32 pixel, SDL_PixelFormat *fmt, - Uint8 *r, Uint8 *g, Uint8 *b); - -/* - * Maps a pixel value into the RGBA components for a given pixel format - */ -extern DECLSPEC void SDLCALL SDL_GetRGBA(Uint32 pixel, SDL_PixelFormat *fmt, - Uint8 *r, Uint8 *g, Uint8 *b, Uint8 *a); - -/* - * Allocate and free an RGB surface (must be called after SDL_SetVideoMode) - * If the depth is 4 or 8 bits, an empty palette is allocated for the surface. - * If the depth is greater than 8 bits, the pixel format is set using the - * flags '[RGB]mask'. - * If the function runs out of memory, it will return NULL. - * - * The 'flags' tell what kind of surface to create. - * SDL_SWSURFACE means that the surface should be created in system memory. - * SDL_HWSURFACE means that the surface should be created in video memory, - * with the same format as the display surface. This is useful for surfaces - * that will not change much, to take advantage of hardware acceleration - * when being blitted to the display surface. - * SDL_ASYNCBLIT means that SDL will try to perform asynchronous blits with - * this surface, but you must always lock it before accessing the pixels. - * SDL will wait for current blits to finish before returning from the lock. - * SDL_SRCCOLORKEY indicates that the surface will be used for colorkey blits. - * If the hardware supports acceleration of colorkey blits between - * two surfaces in video memory, SDL will try to place the surface in - * video memory. If this isn't possible or if there is no hardware - * acceleration available, the surface will be placed in system memory. - * SDL_SRCALPHA means that the surface will be used for alpha blits and - * if the hardware supports hardware acceleration of alpha blits between - * two surfaces in video memory, to place the surface in video memory - * if possible, otherwise it will be placed in system memory. - * If the surface is created in video memory, blits will be _much_ faster, - * but the surface format must be identical to the video surface format, - * and the only way to access the pixels member of the surface is to use - * the SDL_LockSurface() and SDL_UnlockSurface() calls. - * If the requested surface actually resides in video memory, SDL_HWSURFACE - * will be set in the flags member of the returned surface. If for some - * reason the surface could not be placed in video memory, it will not have - * the SDL_HWSURFACE flag set, and will be created in system memory instead. - */ -#define SDL_AllocSurface SDL_CreateRGBSurface -extern DECLSPEC SDL_Surface * SDLCALL SDL_CreateRGBSurface - (Uint32 flags, int width, int height, int depth, - Uint32 Rmask, Uint32 Gmask, Uint32 Bmask, Uint32 Amask); -extern DECLSPEC SDL_Surface * SDLCALL SDL_CreateRGBSurfaceFrom(void *pixels, - int width, int height, int depth, int pitch, - Uint32 Rmask, Uint32 Gmask, Uint32 Bmask, Uint32 Amask); -extern DECLSPEC void SDLCALL SDL_FreeSurface(SDL_Surface *surface); - -/* - * SDL_LockSurface() sets up a surface for directly accessing the pixels. - * Between calls to SDL_LockSurface()/SDL_UnlockSurface(), you can write - * to and read from 'surface->pixels', using the pixel format stored in - * 'surface->format'. Once you are done accessing the surface, you should - * use SDL_UnlockSurface() to release it. - * - * Not all surfaces require locking. If SDL_MUSTLOCK(surface) evaluates - * to 0, then you can read and write to the surface at any time, and the - * pixel format of the surface will not change. In particular, if the - * SDL_HWSURFACE flag is not given when calling SDL_SetVideoMode(), you - * will not need to lock the display surface before accessing it. - * - * No operating system or library calls should be made between lock/unlock - * pairs, as critical system locks may be held during this time. - * - * SDL_LockSurface() returns 0, or -1 if the surface couldn't be locked. - */ -extern DECLSPEC int SDLCALL SDL_LockSurface(SDL_Surface *surface); -extern DECLSPEC void SDLCALL SDL_UnlockSurface(SDL_Surface *surface); - -/* - * Load a surface from a seekable SDL data source (memory or file.) - * If 'freesrc' is non-zero, the source will be closed after being read. - * Returns the new surface, or NULL if there was an error. - * The new surface should be freed with SDL_FreeSurface(). - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_LoadBMP_RW(SDL_RWops *src, int freesrc); - -/* Convenience macro -- load a surface from a file */ -#define SDL_LoadBMP(file) SDL_LoadBMP_RW(SDL_RWFromFile(file, "rb"), 1) - -/* - * Save a surface to a seekable SDL data source (memory or file.) - * If 'freedst' is non-zero, the source will be closed after being written. - * Returns 0 if successful or -1 if there was an error. - */ -extern DECLSPEC int SDLCALL SDL_SaveBMP_RW - (SDL_Surface *surface, SDL_RWops *dst, int freedst); - -/* Convenience macro -- save a surface to a file */ -#define SDL_SaveBMP(surface, file) \ - SDL_SaveBMP_RW(surface, SDL_RWFromFile(file, "wb"), 1) - -/* - * Sets the color key (transparent pixel) in a blittable surface. - * If 'flag' is SDL_SRCCOLORKEY (optionally OR'd with SDL_RLEACCEL), - * 'key' will be the transparent pixel in the source image of a blit. - * SDL_RLEACCEL requests RLE acceleration for the surface if present, - * and removes RLE acceleration if absent. - * If 'flag' is 0, this function clears any current color key. - * This function returns 0, or -1 if there was an error. - */ -extern DECLSPEC int SDLCALL SDL_SetColorKey - (SDL_Surface *surface, Uint32 flag, Uint32 key); - -/* - * This function sets the alpha value for the entire surface, as opposed to - * using the alpha component of each pixel. This value measures the range - * of transparency of the surface, 0 being completely transparent to 255 - * being completely opaque. An 'alpha' value of 255 causes blits to be - * opaque, the source pixels copied to the destination (the default). Note - * that per-surface alpha can be combined with colorkey transparency. - * - * If 'flag' is 0, alpha blending is disabled for the surface. - * If 'flag' is SDL_SRCALPHA, alpha blending is enabled for the surface. - * OR:ing the flag with SDL_RLEACCEL requests RLE acceleration for the - * surface; if SDL_RLEACCEL is not specified, the RLE accel will be removed. - * - * The 'alpha' parameter is ignored for surfaces that have an alpha channel. - */ -extern DECLSPEC int SDLCALL SDL_SetAlpha(SDL_Surface *surface, Uint32 flag, Uint8 alpha); - -/* - * Sets the clipping rectangle for the destination surface in a blit. - * - * If the clip rectangle is NULL, clipping will be disabled. - * If the clip rectangle doesn't intersect the surface, the function will - * return SDL_FALSE and blits will be completely clipped. Otherwise the - * function returns SDL_TRUE and blits to the surface will be clipped to - * the intersection of the surface area and the clipping rectangle. - * - * Note that blits are automatically clipped to the edges of the source - * and destination surfaces. - */ -extern DECLSPEC SDL_bool SDLCALL SDL_SetClipRect(SDL_Surface *surface, const SDL_Rect *rect); - -/* - * Gets the clipping rectangle for the destination surface in a blit. - * 'rect' must be a pointer to a valid rectangle which will be filled - * with the correct values. - */ -extern DECLSPEC void SDLCALL SDL_GetClipRect(SDL_Surface *surface, SDL_Rect *rect); - -/* - * Creates a new surface of the specified format, and then copies and maps - * the given surface to it so the blit of the converted surface will be as - * fast as possible. If this function fails, it returns NULL. - * - * The 'flags' parameter is passed to SDL_CreateRGBSurface() and has those - * semantics. You can also pass SDL_RLEACCEL in the flags parameter and - * SDL will try to RLE accelerate colorkey and alpha blits in the resulting - * surface. - * - * This function is used internally by SDL_DisplayFormat(). - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_ConvertSurface - (SDL_Surface *src, SDL_PixelFormat *fmt, Uint32 flags); - -/* - * This performs a fast blit from the source surface to the destination - * surface. It assumes that the source and destination rectangles are - * the same size. If either 'srcrect' or 'dstrect' are NULL, the entire - * surface (src or dst) is copied. The final blit rectangles are saved - * in 'srcrect' and 'dstrect' after all clipping is performed. - * If the blit is successful, it returns 0, otherwise it returns -1. - * - * The blit function should not be called on a locked surface. - * - * The blit semantics for surfaces with and without alpha and colorkey - * are defined as follows: - * - * RGBA->RGB: - * SDL_SRCALPHA set: - * alpha-blend (using alpha-channel). - * SDL_SRCCOLORKEY ignored. - * SDL_SRCALPHA not set: - * copy RGB. - * if SDL_SRCCOLORKEY set, only copy the pixels matching the - * RGB values of the source colour key, ignoring alpha in the - * comparison. - * - * RGB->RGBA: - * SDL_SRCALPHA set: - * alpha-blend (using the source per-surface alpha value); - * set destination alpha to opaque. - * SDL_SRCALPHA not set: - * copy RGB, set destination alpha to source per-surface alpha value. - * both: - * if SDL_SRCCOLORKEY set, only copy the pixels matching the - * source colour key. - * - * RGBA->RGBA: - * SDL_SRCALPHA set: - * alpha-blend (using the source alpha channel) the RGB values; - * leave destination alpha untouched. [Note: is this correct?] - * SDL_SRCCOLORKEY ignored. - * SDL_SRCALPHA not set: - * copy all of RGBA to the destination. - * if SDL_SRCCOLORKEY set, only copy the pixels matching the - * RGB values of the source colour key, ignoring alpha in the - * comparison. - * - * RGB->RGB: - * SDL_SRCALPHA set: - * alpha-blend (using the source per-surface alpha value). - * SDL_SRCALPHA not set: - * copy RGB. - * both: - * if SDL_SRCCOLORKEY set, only copy the pixels matching the - * source colour key. - * - * If either of the surfaces were in video memory, and the blit returns -2, - * the video memory was lost, so it should be reloaded with artwork and - * re-blitted: - while ( SDL_BlitSurface(image, imgrect, screen, dstrect) == -2 ) { - while ( SDL_LockSurface(image) < 0 ) - Sleep(10); - -- Write image pixels to image->pixels -- - SDL_UnlockSurface(image); - } - * This happens under DirectX 5.0 when the system switches away from your - * fullscreen application. The lock will also fail until you have access - * to the video memory again. - */ -/* You should call SDL_BlitSurface() unless you know exactly how SDL - blitting works internally and how to use the other blit functions. -*/ -#define SDL_BlitSurface SDL_UpperBlit - -/* This is the public blit function, SDL_BlitSurface(), and it performs - rectangle validation and clipping before passing it to SDL_LowerBlit() -*/ -extern DECLSPEC int SDLCALL SDL_UpperBlit - (SDL_Surface *src, SDL_Rect *srcrect, - SDL_Surface *dst, SDL_Rect *dstrect); -/* This is a semi-private blit function and it performs low-level surface - blitting only. -*/ -extern DECLSPEC int SDLCALL SDL_LowerBlit - (SDL_Surface *src, SDL_Rect *srcrect, - SDL_Surface *dst, SDL_Rect *dstrect); - -/* - * This function performs a fast fill of the given rectangle with 'color' - * The given rectangle is clipped to the destination surface clip area - * and the final fill rectangle is saved in the passed in pointer. - * If 'dstrect' is NULL, the whole surface will be filled with 'color' - * The color should be a pixel of the format used by the surface, and - * can be generated by the SDL_MapRGB() function. - * This function returns 0 on success, or -1 on error. - */ -extern DECLSPEC int SDLCALL SDL_FillRect - (SDL_Surface *dst, SDL_Rect *dstrect, Uint32 color); - -/* - * This function takes a surface and copies it to a new surface of the - * pixel format and colors of the video framebuffer, suitable for fast - * blitting onto the display surface. It calls SDL_ConvertSurface() - * - * If you want to take advantage of hardware colorkey or alpha blit - * acceleration, you should set the colorkey and alpha value before - * calling this function. - * - * If the conversion fails or runs out of memory, it returns NULL - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_DisplayFormat(SDL_Surface *surface); - -/* - * This function takes a surface and copies it to a new surface of the - * pixel format and colors of the video framebuffer (if possible), - * suitable for fast alpha blitting onto the display surface. - * The new surface will always have an alpha channel. - * - * If you want to take advantage of hardware colorkey or alpha blit - * acceleration, you should set the colorkey and alpha value before - * calling this function. - * - * If the conversion fails or runs out of memory, it returns NULL - */ -extern DECLSPEC SDL_Surface * SDLCALL SDL_DisplayFormatAlpha(SDL_Surface *surface); - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* YUV video surface overlay functions */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* This function creates a video output overlay - Calling the returned surface an overlay is something of a misnomer because - the contents of the display surface underneath the area where the overlay - is shown is undefined - it may be overwritten with the converted YUV data. -*/ -extern DECLSPEC SDL_Overlay * SDLCALL SDL_CreateYUVOverlay(int width, int height, - Uint32 format, SDL_Surface *display); - -/* Lock an overlay for direct access, and unlock it when you are done */ -extern DECLSPEC int SDLCALL SDL_LockYUVOverlay(SDL_Overlay *overlay); -extern DECLSPEC void SDLCALL SDL_UnlockYUVOverlay(SDL_Overlay *overlay); - -/* Blit a video overlay to the display surface. - The contents of the video surface underneath the blit destination are - not defined. - The width and height of the destination rectangle may be different from - that of the overlay, but currently only 2x scaling is supported. -*/ -extern DECLSPEC int SDLCALL SDL_DisplayYUVOverlay(SDL_Overlay *overlay, SDL_Rect *dstrect); - -/* Free a video overlay */ -extern DECLSPEC void SDLCALL SDL_FreeYUVOverlay(SDL_Overlay *overlay); - - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* OpenGL support functions. */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* - * Dynamically load an OpenGL library, or the default one if path is NULL - * - * If you do this, you need to retrieve all of the GL functions used in - * your program from the dynamic library using SDL_GL_GetProcAddress(). - */ -extern DECLSPEC int SDLCALL SDL_GL_LoadLibrary(const char *path); - -/* - * Get the address of a GL function - */ -extern DECLSPEC void * SDLCALL SDL_GL_GetProcAddress(const char* proc); - -/* - * Set an attribute of the OpenGL subsystem before intialization. - */ -extern DECLSPEC int SDLCALL SDL_GL_SetAttribute(SDL_GLattr attr, int value); - -/* - * Get an attribute of the OpenGL subsystem from the windowing - * interface, such as glX. This is of course different from getting - * the values from SDL's internal OpenGL subsystem, which only - * stores the values you request before initialization. - * - * Developers should track the values they pass into SDL_GL_SetAttribute - * themselves if they want to retrieve these values. - */ -extern DECLSPEC int SDLCALL SDL_GL_GetAttribute(SDL_GLattr attr, int* value); - -/* - * Swap the OpenGL buffers, if double-buffering is supported. - */ -extern DECLSPEC void SDLCALL SDL_GL_SwapBuffers(void); - -/* - * Internal functions that should not be called unless you have read - * and understood the source code for these functions. - */ -extern DECLSPEC void SDLCALL SDL_GL_UpdateRects(int numrects, SDL_Rect* rects); -extern DECLSPEC void SDLCALL SDL_GL_Lock(void); -extern DECLSPEC void SDLCALL SDL_GL_Unlock(void); - -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ -/* These functions allow interaction with the window manager, if any. */ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* - * Sets/Gets the title and icon text of the display window (UTF-8 encoded) - */ -extern DECLSPEC void SDLCALL SDL_WM_SetCaption(const char *title, const char *icon); -extern DECLSPEC void SDLCALL SDL_WM_GetCaption(char **title, char **icon); - -/* - * Sets the icon for the display window. - * This function must be called before the first call to SDL_SetVideoMode(). - * It takes an icon surface, and a mask in MSB format. - * If 'mask' is NULL, the entire icon surface will be used as the icon. - */ -extern DECLSPEC void SDLCALL SDL_WM_SetIcon(SDL_Surface *icon, Uint8 *mask); - -/* - * This function iconifies the window, and returns 1 if it succeeded. - * If the function succeeds, it generates an SDL_APPACTIVE loss event. - * This function is a noop and returns 0 in non-windowed environments. - */ -extern DECLSPEC int SDLCALL SDL_WM_IconifyWindow(void); - -/* - * Toggle fullscreen mode without changing the contents of the screen. - * If the display surface does not require locking before accessing - * the pixel information, then the memory pointers will not change. - * - * If this function was able to toggle fullscreen mode (change from - * running in a window to fullscreen, or vice-versa), it will return 1. - * If it is not implemented, or fails, it returns 0. - * - * The next call to SDL_SetVideoMode() will set the mode fullscreen - * attribute based on the flags parameter - if SDL_FULLSCREEN is not - * set, then the display will be windowed by default where supported. - * - * This is currently only implemented in the X11 video driver. - */ -extern DECLSPEC int SDLCALL SDL_WM_ToggleFullScreen(SDL_Surface *surface); - -/* - * This function allows you to set and query the input grab state of - * the application. It returns the new input grab state. - */ -typedef enum { - SDL_GRAB_QUERY = -1, - SDL_GRAB_OFF = 0, - SDL_GRAB_ON = 1, - SDL_GRAB_FULLSCREEN /* Used internally */ -} SDL_GrabMode; -/* - * Grabbing means that the mouse is confined to the application window, - * and nearly all keyboard input is passed directly to the application, - * and not interpreted by a window manager, if any. - */ -extern DECLSPEC SDL_GrabMode SDLCALL SDL_WM_GrabInput(SDL_GrabMode mode); - -/* - * Move the SDL Window to a specify position. does nothing in fullscreen mode - * - */ -extern DECLSPEC void SDL_WM_SetPos(int x, int y); - -/* - * Get the current SDL window position. returns (0,0) in fullscreen mode - */ -extern DECLSPEC void SDL_WM_GetPos(int *px, int *py); - -/* - * If the window is fully visible, return TRUE; otherwise, recenter the window - * if the 'recenter' parameter is non-0, and return FALSE. - */ -extern DECLSPEC int SDL_WM_IsFullyVisible( int recenter ); - -/* - * Get the resolution of the main monitor in DPIs, if available. - * Return 0 on success, or -1 if the data is not available - */ -extern DECLSPEC int SDL_WM_GetMonitorDPI( int *xDpi, int *yDpi ); - -/* - * Get the coordinates of the monitor in virtual desktop space. - * In the case of multi-monitor systems, returns the rectangle of - * the 'nearest' monitor relative to the main SDL_window. - * Returns 0 on success, or -1 if the data is not available. - */ -extern DECLSPEC int SDL_WM_GetMonitorRect( SDL_Rect *rect ); - -/* Not in public API at the moment - do not use! */ -extern DECLSPEC int SDLCALL SDL_SoftStretch(SDL_Surface *src, SDL_Rect *srcrect, - SDL_Surface *dst, SDL_Rect *dstrect); - -/* Ends C function definitions when using C++ */ -#ifdef __cplusplus -} -#endif -#include "close_code.h" - -#endif /* _SDL_video_h */ diff --git a/distrib/sdl-1.2.12/include/begin_code.h b/distrib/sdl-1.2.12/include/begin_code.h deleted file mode 100644 index b03787f..0000000 --- a/distrib/sdl-1.2.12/include/begin_code.h +++ /dev/null @@ -1,156 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This file sets things up for C dynamic library function definitions, - static inlined functions, and structures aligned at 4-byte alignment. - If you don't like ugly C preprocessor code, don't look at this file. :) -*/ - -/* This shouldn't be nested -- included it around code only. */ -#ifdef _begin_code_h -#error Nested inclusion of begin_code.h -#endif -#define _begin_code_h - -/* Some compilers use a special export keyword */ -#ifndef DECLSPEC -# if defined(__BEOS__) -# if defined(__GNUC__) -# define DECLSPEC __declspec(dllexport) -# else -# define DECLSPEC __declspec(export) -# endif -# elif defined(__WIN32__) -# ifdef __BORLANDC__ -# ifdef BUILD_SDL -# define DECLSPEC -# else -# define DECLSPEC __declspec(dllimport) -# endif -# else -# define DECLSPEC __declspec(dllexport) -# endif -# elif defined(__OS2__) -# ifdef __WATCOMC__ -# ifdef BUILD_SDL -# define DECLSPEC __declspec(dllexport) -# else -# define DECLSPEC -# endif -# else -# define DECLSPEC -# endif -# else -# if defined(__GNUC__) && __GNUC__ >= 4 -# define DECLSPEC __attribute__ ((visibility("default"))) -# else -# define DECLSPEC -# endif -# endif -#endif - -/* By default SDL uses the C calling convention */ -#ifndef SDLCALL -#if defined(__WIN32__) && !defined(__GNUC__) -#define SDLCALL __cdecl -#else -#ifdef __OS2__ -/* But on OS/2, we use the _System calling convention */ -/* to be compatible with every compiler */ -#define SDLCALL _System -#else -#define SDLCALL -#endif -#endif -#endif /* SDLCALL */ - -#ifdef __SYMBIAN32__ -#ifndef EKA2 -#undef DECLSPEC -#define DECLSPEC -#elif !defined(__WINS__) -#undef DECLSPEC -#define DECLSPEC __declspec(dllexport) -#endif //EKA2 -#endif //__SYMBIAN32__ - -/* Force structure packing at 4 byte alignment. - This is necessary if the header is included in code which has structure - packing set to an alternate value, say for loading structures from disk. - The packing is reset to the previous value in close_code.h - */ -#if defined(_MSC_VER) || defined(__MWERKS__) || defined(__BORLANDC__) -#ifdef _MSC_VER -#pragma warning(disable: 4103) -#endif -#ifdef __BORLANDC__ -#pragma nopackwarning -#endif -#pragma pack(push,4) -#elif (defined(__MWERKS__) && defined(__MACOS__)) -#pragma options align=mac68k4byte -#pragma enumsalwaysint on -#endif /* Compiler needs structure packing set */ - -/* Set up compiler-specific options for inlining functions */ -#ifndef SDL_INLINE_OKAY -#ifdef __GNUC__ -#define SDL_INLINE_OKAY -#else -/* Add any special compiler-specific cases here */ -#if defined(_MSC_VER) || defined(__BORLANDC__) || \ - defined(__DMC__) || defined(__SC__) || \ - defined(__WATCOMC__) || defined(__LCC__) || \ - defined(__DECC) || defined(__EABI__) -#ifndef __inline__ -#define __inline__ __inline -#endif -#define SDL_INLINE_OKAY -#else -#if !defined(__MRC__) && !defined(_SGI_SOURCE) -#ifndef __inline__ -#define __inline__ inline -#endif -#define SDL_INLINE_OKAY -#endif /* Not a funky compiler */ -#endif /* Visual C++ */ -#endif /* GNU C */ -#endif /* SDL_INLINE_OKAY */ - -/* If inlining isn't supported, remove "__inline__", turning static - inlined functions into static functions (resulting in code bloat - in all files which include the offending header files) -*/ -#ifndef SDL_INLINE_OKAY -#define __inline__ -#endif - -/* Apparently this is needed by several Windows compilers */ -#if !defined(__MACH__) -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif /* NULL */ -#endif /* ! Mac OS X - breaks precompiled headers */ diff --git a/distrib/sdl-1.2.12/include/close_code.h b/distrib/sdl-1.2.12/include/close_code.h deleted file mode 100644 index afbb650..0000000 --- a/distrib/sdl-1.2.12/include/close_code.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* This file reverses the effects of begin_code.h and should be included - after you finish any function and structure declarations in your headers -*/ - -#undef _begin_code_h - -/* Reset structure packing at previous byte alignment */ -#if defined(_MSC_VER) || defined(__MWERKS__) || defined(__WATCOMC__) || defined(__BORLANDC__) -#ifdef __BORLANDC__ -#pragma nopackwarning -#endif -#if (defined(__MWERKS__) && defined(__MACOS__)) -#pragma options align=reset -#pragma enumsalwaysint reset -#else -#pragma pack(pop) -#endif -#endif /* Compiler needs structure packing set */ - diff --git a/distrib/sdl-1.2.12/sdl-config.in b/distrib/sdl-1.2.12/sdl-config.in deleted file mode 100644 index 843c1a6..0000000 --- a/distrib/sdl-1.2.12/sdl-config.in +++ /dev/null @@ -1,61 +0,0 @@ -#!/bin/sh - -curdir=`dirname $0` -prefix=`dirname $curdir` -exec_prefix=@exec_prefix@ -exec_prefix_set=no -libdir=@libdir@ - -@ENABLE_STATIC_FALSE@usage="\ -@ENABLE_STATIC_FALSE@Usage: sdl-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]" -@ENABLE_STATIC_TRUE@usage="\ -@ENABLE_STATIC_TRUE@Usage: sdl-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs] [--static-libs]" - -if test $# -eq 0; then - echo "${usage}" 1>&2 - exit 1 -fi - -while test $# -gt 0; do - case "$1" in - -*=*) optarg=`echo "$1" | LC_ALL="C" sed 's/[-_a-zA-Z0-9]*=//'` ;; - *) optarg= ;; - esac - - case $1 in - --prefix=*) - prefix=$optarg - if test $exec_prefix_set = no ; then - exec_prefix=$optarg - fi - ;; - --prefix) - echo $prefix - ;; - --exec-prefix=*) - exec_prefix=$optarg - exec_prefix_set=yes - ;; - --exec-prefix) - echo $exec_prefix - ;; - --version) - echo @SDL_VERSION@ - ;; - --cflags) - echo -I@includedir@/SDL @SDL_CFLAGS@ - ;; -@ENABLE_SHARED_TRUE@ --libs) -@ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@ -@ENABLE_SHARED_TRUE@ ;; -@ENABLE_STATIC_TRUE@@ENABLE_SHARED_TRUE@ --static-libs) -@ENABLE_STATIC_TRUE@@ENABLE_SHARED_FALSE@ --libs|--static-libs) -@ENABLE_STATIC_TRUE@ echo @SDL_STATIC_LIBS@ -@ENABLE_STATIC_TRUE@ ;; - *) - echo "${usage}" 1>&2 - exit 1 - ;; - esac - shift -done diff --git a/distrib/sdl-1.2.12/sources.make b/distrib/sdl-1.2.12/sources.make deleted file mode 100644 index dadcb3f..0000000 --- a/distrib/sdl-1.2.12/sources.make +++ /dev/null @@ -1,244 +0,0 @@ -# This is included from the main Android emulator build script -# to declare the SDL-related sources, compiler flags and libraries -# - -SDL_CFLAGS := -SDL_LDLIBS := -SDL_STATIC_LIBRARIES := - -SDL_SOURCES := - -ifeq ($(HOST_OS),linux) - SDL_CONFIG_LOADSO_DLOPEN := yes - SDL_CONFIG_THREAD_PTHREAD := yes - SDL_CONFIG_THREAD_PTHREAD_RECURSIVE_MUTEX_NP := yes - SDL_CONFIG_TIMER_UNIX := yes - SDL_CONFIG_VIDEO_X11 := yes - SDL_CONFIG_VIDEO_X11_DPMS := yes - SDL_CONFIG_VIDEO_X11_XINERAMA := yes - SDL_CONFIG_VIDEO_X11_XME := yes - SDL_CONFIG_MAIN_DUMMY := yes - - SDL_CFLAGS += -D_GNU_SOURCE=1 -D_REENTRANT - SDL_LDLIBS += -lm -ldl -lpthread -lrt -endif - -ifeq ($(HOST_OS),freebsd) - SDL_CONFIG_LOADSO_DLOPEN := yes - SDL_CONFIG_THREAD_PTHREAD := yes - SDL_CONFIG_THREAD_PTHREAD_RECURSIVE_MUTEX := yes - SDL_CONFIG_TIMER_UNIX := yes - SDL_CONFIG_VIDEO_X11 := yes - SDL_CONFIG_VIDEO_X11_DPMS := yes - SDL_CONFIG_VIDEO_X11_XINERAMA := yes - SDL_CONFIG_VIDEO_X11_XME := yes - SDL_CONFIG_MAIN_DUMMY := yes - - SDL_CFLAGS += -D_GNU_SOURCE=1 -D_REENTRANT - SDL_LDLIBS += -lm -ldl -lpthread -endif - -ifeq ($(HOST_OS),darwin) - SDL_CONFIG_LOADSO_DLCOMPAT := yes - SDL_CONFIG_THREAD_PTHREAD := yes - SDL_CONFIG_THREAD_PTHREAD_RECURSIVE_MUTEX := yes - SDL_CONFIG_TIMER_UNIX := yes - SDL_CONFIG_VIDEO_QUARTZ := yes - SDL_CONFIG_MAIN_MACOSX := yes - - SDL_CFLAGS += -D_GNU_SOURCE=1 -DTHREAD_SAFE - FRAMEWORKS := OpenGL Cocoa QuickTime ApplicationServices Carbon IOKit - SDL_LDLIBS += $(FRAMEWORKS:%=-Wl,-framework,%) -endif - -ifeq ($(HOST_OS),windows) - SDL_CONFIG_LOADSO_WIN32 := yes - SDL_CONFIG_THREAD_WIN32 := yes - SDL_CONFIG_TIMER_WIN32 := yes - SDL_CONFIG_VIDEO_WINDIB := yes - SDL_CONFIG_MAIN_WIN32 := yes - - SDL_CFLAGS += -D_GNU_SOURCE=1 -Dmain=SDL_main -DNO_STDIO_REDIRECT=1 - SDL_LDLIBS += -luser32 -lgdi32 -lwinmm -endif - - -# the main src/ sources -# -SRCS := SDL.c \ - SDL_error.c \ - SDL_fatal.c \ - -SRCS += events/SDL_active.c \ - events/SDL_events.c \ - events/SDL_expose.c \ - events/SDL_keyboard.c \ - events/SDL_mouse.c \ - events/SDL_quit.c \ - events/SDL_resize.c \ - -SRCS += file/SDL_rwops.c - -SRCS += stdlib/SDL_getenv.c \ - stdlib/SDL_iconv.c \ - stdlib/SDL_malloc.c \ - stdlib/SDL_qsort.c \ - stdlib/SDL_stdlib.c \ - stdlib/SDL_string.c - -SRCS += cpuinfo/SDL_cpuinfo.c - -SDL_SOURCES += $(SRCS:%=$(SDL_DIR)/src/%) - -# the LoadSO sources -# - -SRCS := - -ifeq ($(SDL_CONFIG_LOADSO_DLOPEN),yes) - SRCS += dlopen/SDL_sysloadso.c - SDL_LDLIBS += -ldl -endif - -ifeq ($(SDL_CONFIG_LOADSO_DLCOMPAT),yes) - SRCS += macosx/SDL_dlcompat.c -endif - -ifeq ($(SDL_CONFIG_LOADSO_WIN32),yes) - SRCS += win32/SDL_sysloadso.c -endif - -SDL_SOURCES += $(SRCS:%=$(SDL_DIR)/src/loadso/%) - -# the Thread sources -# - -SRCS := SDL_thread.c - -ifeq ($(SDL_CONFIG_THREAD_PTHREAD),yes) - SRCS += pthread/SDL_syscond.c \ - pthread/SDL_sysmutex.c \ - pthread/SDL_syssem.c \ - pthread/SDL_systhread.c -endif - -ifeq ($(SDL_CONFIG_THREAD_WIN32),yes) - SRCS += win32/SDL_sysmutex.c \ - win32/SDL_syssem.c \ - win32/SDL_systhread.c -endif - -SDL_SOURCES += $(SRCS:%=$(SDL_DIR)/src/thread/%) - -# the Timer sources -# - -SRCS := SDL_timer.c - -ifeq ($(SDL_CONFIG_TIMER_UNIX),yes) - SRCS += unix/SDL_systimer.c -endif - -ifeq ($(SDL_CONFIG_TIMER_WIN32),yes) - SRCS += win32/SDL_systimer.c -endif - -SDL_SOURCES += $(SRCS:%=$(SDL_DIR)/src/timer/%) - -# the Video sources -# - -SRCS := SDL_RLEaccel.c \ - SDL_blit.c \ - SDL_blit_0.c \ - SDL_blit_1.c \ - SDL_blit_A.c \ - SDL_blit_N.c \ - SDL_bmp.c \ - SDL_cursor.c \ - SDL_gamma.c \ - SDL_pixels.c \ - SDL_stretch.c \ - SDL_surface.c \ - SDL_video.c \ - SDL_yuv.c \ - SDL_yuv_mmx.c \ - SDL_yuv_sw.c \ - -SRCS += dummy/SDL_nullevents.c \ - dummy/SDL_nullmouse.c \ - dummy/SDL_nullvideo.c - -ifeq ($(SDL_CONFIG_VIDEO_WINDIB),yes) - SRCS += windib/SDL_dibevents.c \ - windib/SDL_dibvideo.c \ - wincommon/SDL_sysevents.c \ - wincommon/SDL_sysmouse.c \ - wincommon/SDL_syswm.c \ - wincommon/SDL_wingl.c -endif - -ifeq ($(SDL_CONFIG_VIDEO_QUARTZ),yes) - SRCS += quartz/SDL_QuartzGL.m \ - quartz/SDL_QuartzVideo.m \ - quartz/SDL_QuartzWM.m \ - quartz/SDL_QuartzWindow.m \ - quartz/SDL_QuartzYUV.m \ - quartz/SDL_QuartzEvents.m \ - maccommon/SDL_macevents.c \ - maccommon/SDL_macgl.c \ - maccommon/SDL_macmouse.c \ - maccommon/SDL_macwm.c - -endif - -ifeq ($(SDL_CONFIG_VIDEO_X11),yes) - SRCS += x11/SDL_x11dyn.c \ - x11/SDL_x11dga.c \ - x11/SDL_x11events.c \ - x11/SDL_x11gamma.c \ - x11/SDL_x11gl.c \ - x11/SDL_x11image.c \ - x11/SDL_x11modes.c \ - x11/SDL_x11mouse.c \ - x11/SDL_x11video.c \ - x11/SDL_x11wm.c \ - x11/SDL_x11yuv.c -endif - -ifeq ($(SDL_CONFIG_VIDEO_X11_DGAMOUSE),yes) - SRCS += x11/SDL_x11dga.c -endif - -ifeq ($(SDL_CONFIG_VIDEO_X11_XME),yes) - SRCS += Xext/XME/xme.c -endif - -ifeq ($(SDL_CONFIG_VIDEO_X11_XINERAMA),yes) - SRCS += Xext/Xinerama/Xinerama.c -endif - -ifeq ($(SDL_CONFIG_VIDEO_X11_XV),yes) - SRCS += Xext/Xv/Xv.c -endif - -SDL_SOURCES += $(SRCS:%=$(SDL_DIR)/src/video/%) - -## Build libSDLmain -## - -SRCS := - -ifeq ($(SDL_CONFIG_MAIN_DUMMY),yes) - SRCS += dummy/SDL_dummy_main.c -endif - -ifeq ($(SDL_CONFIG_MAIN_MACOSX),yes) - SRCS += macosx/SDLMain.m -endif - -ifeq ($(SDL_CONFIG_MAIN_WIN32),yes) - SRCS += win32/SDL_win32_main.c -endif - -SDLMAIN_SOURCES := $(SRCS:%=$(SDL_DIR)/src/main/%) diff --git a/distrib/sdl-1.2.12/src/SDL.c b/distrib/sdl-1.2.12/src/SDL.c deleted file mode 100644 index eec4e7e..0000000 --- a/distrib/sdl-1.2.12/src/SDL.c +++ /dev/null @@ -1,350 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Initialization code for SDL */ - -#include "SDL.h" -#include "SDL_fatal.h" -#if !SDL_VIDEO_DISABLED -#include "video/SDL_leaks.h" -#endif - -#if SDL_THREAD_PTH -#include -#endif - -/* Initialization/Cleanup routines */ -#if !SDL_JOYSTICK_DISABLED -extern int SDL_JoystickInit(void); -extern void SDL_JoystickQuit(void); -#endif -#if !SDL_CDROM_DISABLED -extern int SDL_CDROMInit(void); -extern void SDL_CDROMQuit(void); -#endif -#if !SDL_TIMERS_DISABLED -extern void SDL_StartTicks(void); -extern int SDL_TimerInit(void); -extern void SDL_TimerQuit(void); -#endif - -/* The current SDL version */ -static SDL_version version = - { SDL_MAJOR_VERSION, SDL_MINOR_VERSION, SDL_PATCHLEVEL }; - -/* The initialized subsystems */ -static Uint32 SDL_initialized = 0; -#if !SDL_TIMERS_DISABLED -static Uint32 ticks_started = 0; -#endif - -#ifdef CHECK_LEAKS -int surfaces_allocated = 0; -#endif - -int SDL_InitSubSystem(Uint32 flags) -{ -#if !SDL_VIDEO_DISABLED - /* Initialize the video/event subsystem */ - if ( (flags & SDL_INIT_VIDEO) && !(SDL_initialized & SDL_INIT_VIDEO) ) { - if ( SDL_VideoInit(SDL_getenv("SDL_VIDEODRIVER"), - (flags&SDL_INIT_EVENTTHREAD)) < 0 ) { - return(-1); - } - SDL_initialized |= SDL_INIT_VIDEO; - } -#else - if ( flags & SDL_INIT_VIDEO ) { - SDL_SetError("SDL not built with video support"); - return(-1); - } -#endif - -#if !SDL_AUDIO_DISABLED - /* Initialize the audio subsystem */ - if ( (flags & SDL_INIT_AUDIO) && !(SDL_initialized & SDL_INIT_AUDIO) ) { - if ( SDL_AudioInit(SDL_getenv("SDL_AUDIODRIVER")) < 0 ) { - return(-1); - } - SDL_initialized |= SDL_INIT_AUDIO; - } -#else - if ( flags & SDL_INIT_AUDIO ) { - SDL_SetError("SDL not built with audio support"); - return(-1); - } -#endif - -#if !SDL_TIMERS_DISABLED - /* Initialize the timer subsystem */ - if ( ! ticks_started ) { - SDL_StartTicks(); - ticks_started = 1; - } - if ( (flags & SDL_INIT_TIMER) && !(SDL_initialized & SDL_INIT_TIMER) ) { - if ( SDL_TimerInit() < 0 ) { - return(-1); - } - SDL_initialized |= SDL_INIT_TIMER; - } -#else - if ( flags & SDL_INIT_TIMER ) { - SDL_SetError("SDL not built with timer support"); - return(-1); - } -#endif - -#if !SDL_JOYSTICK_DISABLED - /* Initialize the joystick subsystem */ - if ( (flags & SDL_INIT_JOYSTICK) && - !(SDL_initialized & SDL_INIT_JOYSTICK) ) { - if ( SDL_JoystickInit() < 0 ) { - return(-1); - } - SDL_initialized |= SDL_INIT_JOYSTICK; - } -#else - if ( flags & SDL_INIT_JOYSTICK ) { - SDL_SetError("SDL not built with joystick support"); - return(-1); - } -#endif - -#if !SDL_CDROM_DISABLED - /* Initialize the CD-ROM subsystem */ - if ( (flags & SDL_INIT_CDROM) && !(SDL_initialized & SDL_INIT_CDROM) ) { - if ( SDL_CDROMInit() < 0 ) { - return(-1); - } - SDL_initialized |= SDL_INIT_CDROM; - } -#else - if ( flags & SDL_INIT_CDROM ) { - SDL_SetError("SDL not built with cdrom support"); - return(-1); - } -#endif - return(0); -} - -int SDL_Init(Uint32 flags) -{ -#if !SDL_THREADS_DISABLED && SDL_THREAD_PTH - if (!pth_init()) { - return -1; - } -#endif - - /* Clear the error message */ - SDL_ClearError(); - - /* Initialize the desired subsystems */ - if ( SDL_InitSubSystem(flags) < 0 ) { - return(-1); - } - - /* Everything is initialized */ - if ( !(flags & SDL_INIT_NOPARACHUTE) ) { - SDL_InstallParachute(); - } - return(0); -} - -void SDL_QuitSubSystem(Uint32 flags) -{ - /* Shut down requested initialized subsystems */ -#if !SDL_CDROM_DISABLED - if ( (flags & SDL_initialized & SDL_INIT_CDROM) ) { - SDL_CDROMQuit(); - SDL_initialized &= ~SDL_INIT_CDROM; - } -#endif -#if !SDL_JOYSTICK_DISABLED - if ( (flags & SDL_initialized & SDL_INIT_JOYSTICK) ) { - SDL_JoystickQuit(); - SDL_initialized &= ~SDL_INIT_JOYSTICK; - } -#endif -#if !SDL_TIMERS_DISABLED - if ( (flags & SDL_initialized & SDL_INIT_TIMER) ) { - SDL_TimerQuit(); - SDL_initialized &= ~SDL_INIT_TIMER; - } -#endif -#if !SDL_AUDIO_DISABLED - if ( (flags & SDL_initialized & SDL_INIT_AUDIO) ) { - SDL_AudioQuit(); - SDL_initialized &= ~SDL_INIT_AUDIO; - } -#endif -#if !SDL_VIDEO_DISABLED - if ( (flags & SDL_initialized & SDL_INIT_VIDEO) ) { - SDL_VideoQuit(); - SDL_initialized &= ~SDL_INIT_VIDEO; - } -#endif -} - -Uint32 SDL_WasInit(Uint32 flags) -{ - if ( ! flags ) { - flags = SDL_INIT_EVERYTHING; - } - return (SDL_initialized&flags); -} - -void SDL_Quit(void) -{ - /* Quit all subsystems */ -#ifdef DEBUG_BUILD - printf("[SDL_Quit] : Enter! Calling QuitSubSystem()\n"); fflush(stdout); -#endif - SDL_QuitSubSystem(SDL_INIT_EVERYTHING); - -#ifdef CHECK_LEAKS -#ifdef DEBUG_BUILD - printf("[SDL_Quit] : CHECK_LEAKS\n"); fflush(stdout); -#endif - - /* Print the number of surfaces not freed */ - if ( surfaces_allocated != 0 ) { - fprintf(stderr, "SDL Warning: %d SDL surfaces extant\n", - surfaces_allocated); - } -#endif -#ifdef DEBUG_BUILD - printf("[SDL_Quit] : SDL_UninstallParachute()\n"); fflush(stdout); -#endif - - /* Uninstall any parachute signal handlers */ - SDL_UninstallParachute(); - -#if !SDL_THREADS_DISABLED && SDL_THREAD_PTH - pth_kill(); -#endif -#ifdef DEBUG_BUILD - printf("[SDL_Quit] : Returning!\n"); fflush(stdout); -#endif - -} - -/* Return the library version number */ -const SDL_version * SDL_Linked_Version(void) -{ - return(&version); -} - -#if defined(__OS2__) -/* Building for OS/2 */ -#ifdef __WATCOMC__ - -#define INCL_DOSERRORS -#define INCL_DOSEXCEPTIONS -#include - -/* Exception handler to prevent the Audio thread hanging, making a zombie process! */ -ULONG _System SDL_Main_ExceptionHandler(PEXCEPTIONREPORTRECORD pERepRec, - PEXCEPTIONREGISTRATIONRECORD pERegRec, - PCONTEXTRECORD pCtxRec, - PVOID p) -{ - if (pERepRec->fHandlerFlags & EH_EXIT_UNWIND) - return XCPT_CONTINUE_SEARCH; - if (pERepRec->fHandlerFlags & EH_UNWINDING) - return XCPT_CONTINUE_SEARCH; - if (pERepRec->fHandlerFlags & EH_NESTED_CALL) - return XCPT_CONTINUE_SEARCH; - - /* Do cleanup at every fatal exception! */ - if (((pERepRec->ExceptionNum & XCPT_SEVERITY_CODE) == XCPT_FATAL_EXCEPTION) && - (pERepRec->ExceptionNum != XCPT_BREAKPOINT) && - (pERepRec->ExceptionNum != XCPT_SINGLE_STEP) - ) - { - if (SDL_initialized & SDL_INIT_AUDIO) - { - /* This removes the zombie audio thread in case of emergency. */ -#ifdef DEBUG_BUILD - printf("[SDL_Main_ExceptionHandler] : Calling SDL_CloseAudio()!\n"); -#endif - SDL_CloseAudio(); - } - } - return (XCPT_CONTINUE_SEARCH); -} - - -EXCEPTIONREGISTRATIONRECORD SDL_Main_xcpthand = {0, SDL_Main_ExceptionHandler}; - -/* The main DLL entry for DLL Initialization and Uninitialization: */ -unsigned _System LibMain(unsigned hmod, unsigned termination) -{ - if (termination) - { -#ifdef DEBUG_BUILD -/* printf("[SDL DLL Unintialization] : Removing exception handler\n"); */ -#endif - DosUnsetExceptionHandler(&SDL_Main_xcpthand); - return 1; - } else - { -#ifdef DEBUG_BUILD - /* Make stdout and stderr unbuffered! */ - setbuf(stdout, NULL); - setbuf(stderr, NULL); -#endif - /* Fire up exception handler */ -#ifdef DEBUG_BUILD -/* printf("[SDL DLL Initialization] : Setting exception handler\n"); */ -#endif - /* Set exception handler */ - DosSetExceptionHandler(&SDL_Main_xcpthand); - - return 1; - } -} -#endif /* __WATCOMC__ */ - -#elif defined(__WIN32__) && !defined(__SYMBIAN32__) - -#if !defined(HAVE_LIBC) || (defined(__WATCOMC__) && defined(BUILD_DLL)) -/* Need to include DllMain() on Watcom C for some reason.. */ -#define WIN32_LEAN_AND_MEAN -#include - -BOOL APIENTRY _DllMainCRTStartup( HANDLE hModule, - DWORD ul_reason_for_call, - LPVOID lpReserved ) -{ - switch (ul_reason_for_call) { - case DLL_PROCESS_ATTACH: - case DLL_THREAD_ATTACH: - case DLL_THREAD_DETACH: - case DLL_PROCESS_DETACH: - break; - } - return TRUE; -} -#endif /* building DLL with Watcom C */ - -#endif /* OS/2 elif __WIN32__ */ diff --git a/distrib/sdl-1.2.12/src/SDL_error.c b/distrib/sdl-1.2.12/src/SDL_error.c deleted file mode 100644 index 11632f2..0000000 --- a/distrib/sdl-1.2.12/src/SDL_error.c +++ /dev/null @@ -1,238 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Simple error handling in SDL */ - -#include "SDL_error.h" -#include "SDL_error_c.h" - -/* Routine to get the thread-specific error variable */ -#if SDL_THREADS_DISABLED -/* The SDL_arraysize(The ),default (non-thread-safe) global error variable */ -static SDL_error SDL_global_error; -#define SDL_GetErrBuf() (&SDL_global_error) -#else -extern SDL_error *SDL_GetErrBuf(void); -#endif /* SDL_THREADS_DISABLED */ - -#define SDL_ERRBUFIZE 1024 - -/* Private functions */ - -static const char *SDL_LookupString(const char *key) -{ - /* FIXME: Add code to lookup key in language string hash-table */ - return key; -} - -/* Public functions */ - -void SDL_SetError (const char *fmt, ...) -{ - va_list ap; - SDL_error *error; - - /* Copy in the key, mark error as valid */ - error = SDL_GetErrBuf(); - error->error = 1; - SDL_strlcpy((char *)error->key, fmt, sizeof(error->key)); - - va_start(ap, fmt); - error->argc = 0; - while ( *fmt ) { - if ( *fmt++ == '%' ) { - while ( *fmt == '.' || (*fmt >= '0' && *fmt <= '9') ) { - ++fmt; - } - switch (*fmt++) { - case 0: /* Malformed format string.. */ - --fmt; - break; - case 'c': - case 'i': - case 'd': - case 'u': - case 'o': - case 'x': - case 'X': - error->args[error->argc++].value_i = - va_arg(ap, int); - break; - case 'f': - error->args[error->argc++].value_f = - va_arg(ap, double); - break; - case 'p': - error->args[error->argc++].value_ptr = - va_arg(ap, void *); - break; - case 's': - { - int i = error->argc; - const char *str = va_arg(ap, const char *); - if (str == NULL) - str = "(null)"; - SDL_strlcpy((char *)error->args[i].buf, str, ERR_MAX_STRLEN); - error->argc++; - } - break; - default: - break; - } - if ( error->argc >= ERR_MAX_ARGS ) { - break; - } - } - } - va_end(ap); - - /* If we are in debug mode, print out an error message */ -#ifdef DEBUG_ERROR - fprintf(stderr, "SDL_SetError: %s\n", SDL_GetError()); -#endif -} - -/* This function has a bit more overhead than most error functions - so that it supports internationalization and thread-safe errors. -*/ -char *SDL_GetErrorMsg(char *errstr, unsigned int maxlen) -{ - SDL_error *error; - - /* Clear the error string */ - *errstr = '\0'; --maxlen; - - /* Get the thread-safe error, and print it out */ - error = SDL_GetErrBuf(); - if ( error->error ) { - const char *fmt; - char *msg = errstr; - int len; - int argi; - - fmt = SDL_LookupString(error->key); - argi = 0; - while ( *fmt && (maxlen > 0) ) { - if ( *fmt == '%' ) { - char tmp[32], *spot = tmp; - *spot++ = *fmt++; - while ( (*fmt == '.' || (*fmt >= '0' && *fmt <= '9')) && spot < (tmp+SDL_arraysize(tmp)-2) ) { - *spot++ = *fmt++; - } - *spot++ = *fmt++; - *spot++ = '\0'; - switch (spot[-2]) { - case '%': - *msg++ = '%'; - maxlen -= 1; - break; - case 'c': - case 'i': - case 'd': - case 'u': - case 'o': - case 'x': - case 'X': - len = SDL_snprintf(msg, maxlen, tmp, error->args[argi++].value_i); - msg += len; - maxlen -= len; - break; - case 'f': - len = SDL_snprintf(msg, maxlen, tmp, error->args[argi++].value_f); - msg += len; - maxlen -= len; - break; - case 'p': - len = SDL_snprintf(msg, maxlen, tmp, error->args[argi++].value_ptr); - msg += len; - maxlen -= len; - break; - case 's': - len = SDL_snprintf(msg, maxlen, tmp, SDL_LookupString(error->args[argi++].buf)); - msg += len; - maxlen -= len; - break; - } - } else { - *msg++ = *fmt++; - maxlen -= 1; - } - } - *msg = 0; /* NULL terminate the string */ - } - return(errstr); -} - -/* Available for backwards compatibility */ -char *SDL_GetError (void) -{ - static char errmsg[SDL_ERRBUFIZE]; - - return((char *)SDL_GetErrorMsg(errmsg, SDL_ERRBUFIZE)); -} - -void SDL_ClearError(void) -{ - SDL_error *error; - - error = SDL_GetErrBuf(); - error->error = 0; -} - -/* Very common errors go here */ -void SDL_Error(SDL_errorcode code) -{ - switch (code) { - case SDL_ENOMEM: - SDL_SetError("Out of memory"); - break; - case SDL_EFREAD: - SDL_SetError("Error reading from datastream"); - break; - case SDL_EFWRITE: - SDL_SetError("Error writing to datastream"); - break; - case SDL_EFSEEK: - SDL_SetError("Error seeking in datastream"); - break; - default: - SDL_SetError("Unknown SDL error"); - break; - } -} - -#ifdef TEST_ERROR -int main(int argc, char *argv[]) -{ - char buffer[BUFSIZ+1]; - - SDL_SetError("Hi there!"); - printf("Error 1: %s\n", SDL_GetError()); - SDL_ClearError(); - SDL_memset(buffer, '1', BUFSIZ); - buffer[BUFSIZ] = 0; - SDL_SetError("This is the error: %s (%f)", buffer, 1.0); - printf("Error 2: %s\n", SDL_GetError()); - exit(0); -} -#endif diff --git a/distrib/sdl-1.2.12/src/SDL_error_c.h b/distrib/sdl-1.2.12/src/SDL_error_c.h deleted file mode 100644 index 990acb5..0000000 --- a/distrib/sdl-1.2.12/src/SDL_error_c.h +++ /dev/null @@ -1,58 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* This file defines a structure that carries language-independent - error messages -*/ - -#ifndef _SDL_error_c_h -#define _SDL_error_c_h - -#define ERR_MAX_STRLEN 128 -#define ERR_MAX_ARGS 5 - -typedef struct SDL_error { - /* This is a numeric value corresponding to the current error */ - int error; - - /* This is a key used to index into a language hashtable containing - internationalized versions of the SDL error messages. If the key - is not in the hashtable, or no hashtable is available, the key is - used directly as an error message format string. - */ - char key[ERR_MAX_STRLEN]; - - /* These are the arguments for the error functions */ - int argc; - union { - void *value_ptr; -#if 0 /* What is a character anyway? (UNICODE issues) */ - unsigned char value_c; -#endif - int value_i; - double value_f; - char buf[ERR_MAX_STRLEN]; - } args[ERR_MAX_ARGS]; -} SDL_error; - -#endif /* _SDL_error_c_h */ diff --git a/distrib/sdl-1.2.12/src/SDL_fatal.c b/distrib/sdl-1.2.12/src/SDL_fatal.c deleted file mode 100644 index 784836b..0000000 --- a/distrib/sdl-1.2.12/src/SDL_fatal.c +++ /dev/null @@ -1,134 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* General fatal signal handling code for SDL */ - -#ifdef HAVE_SIGNAL_H - -#include - -#include "SDL.h" -#include "SDL_fatal.h" - -/* This installs some signal handlers for the more common fatal signals, - so that if the programmer is lazy, the app doesn't die so horribly if - the program crashes. -*/ - -static void SDL_Parachute(int sig) -{ - signal(sig, SIG_DFL); - SDL_Quit(); - raise(sig); -} - -static int SDL_fatal_signals[] = { - SIGSEGV, -#ifdef SIGBUS - SIGBUS, -#endif -#ifdef SIGFPE - SIGFPE, -#endif -#ifdef SIGQUIT - SIGQUIT, -#endif - 0 -}; - -void SDL_InstallParachute(void) -{ - /* Set a handler for any fatal signal not already handled */ - int i; -#ifdef HAVE_SIGACTION - struct sigaction action; - - for ( i=0; SDL_fatal_signals[i]; ++i ) { - sigaction(SDL_fatal_signals[i], NULL, &action); - if ( action.sa_handler == SIG_DFL ) { - action.sa_handler = SDL_Parachute; - sigaction(SDL_fatal_signals[i], &action, NULL); - } - } -#ifdef SIGALRM - /* Set SIGALRM to be ignored -- necessary on Solaris */ - sigaction(SIGALRM, NULL, &action); - if ( action.sa_handler == SIG_DFL ) { - action.sa_handler = SIG_IGN; - sigaction(SIGALRM, &action, NULL); - } -#endif -#else - void (*ohandler)(int); - - for ( i=0; SDL_fatal_signals[i]; ++i ) { - ohandler = signal(SDL_fatal_signals[i], SDL_Parachute); - if ( ohandler != SIG_DFL ) { - signal(SDL_fatal_signals[i], ohandler); - } - } -#endif /* HAVE_SIGACTION */ - return; -} - -void SDL_UninstallParachute(void) -{ - /* Remove a handler for any fatal signal handled */ - int i; -#ifdef HAVE_SIGACTION - struct sigaction action; - - for ( i=0; SDL_fatal_signals[i]; ++i ) { - sigaction(SDL_fatal_signals[i], NULL, &action); - if ( action.sa_handler == SDL_Parachute ) { - action.sa_handler = SIG_DFL; - sigaction(SDL_fatal_signals[i], &action, NULL); - } - } -#else - void (*ohandler)(int); - - for ( i=0; SDL_fatal_signals[i]; ++i ) { - ohandler = signal(SDL_fatal_signals[i], SIG_DFL); - if ( ohandler != SDL_Parachute ) { - signal(SDL_fatal_signals[i], ohandler); - } - } -#endif /* HAVE_SIGACTION */ -} - -#else - -/* No signals on this platform, nothing to do.. */ - -void SDL_InstallParachute(void) -{ - return; -} - -void SDL_UninstallParachute(void) -{ - return; -} - -#endif /* HAVE_SIGNAL_H */ diff --git a/distrib/sdl-1.2.12/src/SDL_fatal.h b/distrib/sdl-1.2.12/src/SDL_fatal.h deleted file mode 100644 index 34b6069..0000000 --- a/distrib/sdl-1.2.12/src/SDL_fatal.h +++ /dev/null @@ -1,28 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* General fatal signal handling code for SDL */ - -extern void SDL_InstallParachute(void); -extern void SDL_UninstallParachute(void); - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audio.c b/distrib/sdl-1.2.12/src/audio/SDL_audio.c deleted file mode 100644 index 3e2316d..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audio.c +++ /dev/null @@ -1,695 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include "SDL.h" -#include "SDL_audio_c.h" -#include "SDL_audiomem.h" -#include "SDL_sysaudio.h" - -#ifdef __OS2__ -/* We'll need the DosSetPriority() API! */ -#define INCL_DOSPROCESS -#include -#endif - -/* Available audio drivers */ -static AudioBootStrap *bootstrap[] = { -#if SDL_AUDIO_DRIVER_BSD - &BSD_AUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_OSS - &DSP_bootstrap, - &DMA_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_ALSA - &ALSA_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_PULSE - &PULSE_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_QNXNTO - &QNXNTOAUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_SUNAUDIO - &SUNAUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DMEDIA - &DMEDIA_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_ARTS - &ARTS_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_ESD - &ESD_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_NAS - &NAS_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DSOUND - &DSOUND_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_WAVEOUT - &WAVEOUT_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_PAUD - &Paud_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_BAUDIO - &BAUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_COREAUDIO - &COREAUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_SNDMGR - &SNDMGR_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_MINT - &MINTAUDIO_GSXB_bootstrap, - &MINTAUDIO_MCSN_bootstrap, - &MINTAUDIO_STFA_bootstrap, - &MINTAUDIO_XBIOS_bootstrap, - &MINTAUDIO_DMA8_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DISK - &DISKAUD_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DUMMY - &DUMMYAUD_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DC - &DCAUD_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_NDS - &NDSAUD_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_MMEAUDIO - &MMEAUDIO_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_DART - &DART_bootstrap, -#endif -#if SDL_AUDIO_DRIVER_EPOCAUDIO - &EPOCAudio_bootstrap, -#endif - NULL -}; -SDL_AudioDevice *current_audio = NULL; - -/* Various local functions */ -int SDL_AudioInit(const char *driver_name); -void SDL_AudioQuit(void); - -/* The general mixing thread function */ -int SDLCALL SDL_RunAudio(void *audiop) -{ - SDL_AudioDevice *audio = (SDL_AudioDevice *)audiop; - Uint8 *stream; - int stream_len; - void *udata; - void (SDLCALL *fill)(void *userdata,Uint8 *stream, int len); - int silence; - - /* Perform any thread setup */ - if ( audio->ThreadInit ) { - audio->ThreadInit(audio); - } - audio->threadid = SDL_ThreadID(); - - /* Set up the mixing function */ - fill = audio->spec.callback; - udata = audio->spec.userdata; - - if ( audio->convert.needed ) { - if ( audio->convert.src_format == AUDIO_U8 ) { - silence = 0x80; - } else { - silence = 0; - } - stream_len = audio->convert.len; - } else { - silence = audio->spec.silence; - stream_len = audio->spec.size; - } - -#ifdef __OS2__ - /* Increase the priority of this thread to make sure that - the audio will be continuous all the time! */ -#ifdef USE_DOSSETPRIORITY - if (SDL_getenv("SDL_USE_TIMECRITICAL_AUDIO")) - { -#ifdef DEBUG_BUILD - printf("[SDL_RunAudio] : Setting priority to TimeCritical+0! (TID%d)\n", SDL_ThreadID()); -#endif - DosSetPriority(PRTYS_THREAD, PRTYC_TIMECRITICAL, 0, 0); - } - else - { -#ifdef DEBUG_BUILD - printf("[SDL_RunAudio] : Setting priority to ForegroundServer+0! (TID%d)\n", SDL_ThreadID()); -#endif - DosSetPriority(PRTYS_THREAD, PRTYC_FOREGROUNDSERVER, 0, 0); - } -#endif -#endif - - /* Loop, filling the audio buffers */ - while ( audio->enabled ) { - - /* Fill the current buffer with sound */ - if ( audio->convert.needed ) { - if ( audio->convert.buf ) { - stream = audio->convert.buf; - } else { - continue; - } - } else { - stream = audio->GetAudioBuf(audio); - if ( stream == NULL ) { - stream = audio->fake_stream; - } - } - - SDL_memset(stream, silence, stream_len); - - if ( ! audio->paused ) { - SDL_mutexP(audio->mixer_lock); - (*fill)(udata, stream, stream_len); - SDL_mutexV(audio->mixer_lock); - } - - /* Convert the audio if necessary */ - if ( audio->convert.needed ) { - SDL_ConvertAudio(&audio->convert); - stream = audio->GetAudioBuf(audio); - if ( stream == NULL ) { - stream = audio->fake_stream; - } - SDL_memcpy(stream, audio->convert.buf, - audio->convert.len_cvt); - } - - /* Ready current buffer for play and change current buffer */ - if ( stream != audio->fake_stream ) { - audio->PlayAudio(audio); - } - - /* Wait for an audio buffer to become available */ - if ( stream == audio->fake_stream ) { - SDL_Delay((audio->spec.samples*1000)/audio->spec.freq); - } else { - audio->WaitAudio(audio); - } - } - - /* Wait for the audio to drain.. */ - if ( audio->WaitDone ) { - audio->WaitDone(audio); - } - -#ifdef __OS2__ -#ifdef DEBUG_BUILD - printf("[SDL_RunAudio] : Task exiting. (TID%d)\n", SDL_ThreadID()); -#endif -#endif - return(0); -} - -static void SDL_LockAudio_Default(SDL_AudioDevice *audio) -{ - if ( audio->thread && (SDL_ThreadID() == audio->threadid) ) { - return; - } - SDL_mutexP(audio->mixer_lock); -} - -static void SDL_UnlockAudio_Default(SDL_AudioDevice *audio) -{ - if ( audio->thread && (SDL_ThreadID() == audio->threadid) ) { - return; - } - SDL_mutexV(audio->mixer_lock); -} - -static Uint16 SDL_ParseAudioFormat(const char *string) -{ - Uint16 format = 0; - - switch (*string) { - case 'U': - ++string; - format |= 0x0000; - break; - case 'S': - ++string; - format |= 0x8000; - break; - default: - return 0; - } - switch (SDL_atoi(string)) { - case 8: - string += 1; - format |= 8; - break; - case 16: - string += 2; - format |= 16; - if ( SDL_strcmp(string, "LSB") == 0 -#if SDL_BYTEORDER == SDL_LIL_ENDIAN - || SDL_strcmp(string, "SYS") == 0 -#endif - ) { - format |= 0x0000; - } - if ( SDL_strcmp(string, "MSB") == 0 -#if SDL_BYTEORDER == SDL_BIG_ENDIAN - || SDL_strcmp(string, "SYS") == 0 -#endif - ) { - format |= 0x1000; - } - break; - default: - return 0; - } - return format; -} - -int SDL_AudioInit(const char *driver_name) -{ - SDL_AudioDevice *audio; - int i = 0, idx; - - /* Check to make sure we don't overwrite 'current_audio' */ - if ( current_audio != NULL ) { - SDL_AudioQuit(); - } - - /* Select the proper audio driver */ - audio = NULL; - idx = 0; -#if SDL_AUDIO_DRIVER_ESD - if ( (driver_name == NULL) && (SDL_getenv("ESPEAKER") != NULL) ) { - /* Ahem, we know that if ESPEAKER is set, user probably wants - to use ESD, but don't start it if it's not already running. - This probably isn't the place to do this, but... Shh! :) - */ - for ( i=0; bootstrap[i]; ++i ) { - if ( SDL_strcasecmp(bootstrap[i]->name, "esd") == 0 ) { -#ifdef HAVE_PUTENV - const char *esd_no_spawn; - - /* Don't start ESD if it's not running */ - esd_no_spawn = getenv("ESD_NO_SPAWN"); - if ( esd_no_spawn == NULL ) { - putenv("ESD_NO_SPAWN=1"); - } -#endif - if ( bootstrap[i]->available() ) { - audio = bootstrap[i]->create(0); - break; - } -#ifdef HAVE_UNSETENV - if ( esd_no_spawn == NULL ) { - unsetenv("ESD_NO_SPAWN"); - } -#endif - } - } - } -#endif /* SDL_AUDIO_DRIVER_ESD */ - if ( audio == NULL ) { - if ( driver_name != NULL ) { -#if 0 /* This will be replaced with a better driver selection API */ - if ( SDL_strrchr(driver_name, ':') != NULL ) { - idx = atoi(SDL_strrchr(driver_name, ':')+1); - } -#endif - for ( i=0; bootstrap[i]; ++i ) { - if (SDL_strcasecmp(bootstrap[i]->name, driver_name) == 0) { - if ( bootstrap[i]->available() ) { - audio=bootstrap[i]->create(idx); - break; - } - } - } - } else { - for ( i=0; bootstrap[i]; ++i ) { - if ( bootstrap[i]->available() ) { - audio = bootstrap[i]->create(idx); - if ( audio != NULL ) { - break; - } - } - } - } - if ( audio == NULL ) { - SDL_SetError("No available audio device"); -#if 0 /* Don't fail SDL_Init() if audio isn't available. - SDL_OpenAudio() will handle it at that point. *sigh* - */ - return(-1); -#endif - } - } - current_audio = audio; - if ( current_audio ) { - current_audio->name = bootstrap[i]->name; - if ( !current_audio->LockAudio && !current_audio->UnlockAudio ) { - current_audio->LockAudio = SDL_LockAudio_Default; - current_audio->UnlockAudio = SDL_UnlockAudio_Default; - } - } - return(0); -} - -char *SDL_AudioDriverName(char *namebuf, int maxlen) -{ - if ( current_audio != NULL ) { - SDL_strlcpy(namebuf, current_audio->name, maxlen); - return(namebuf); - } - return(NULL); -} - -int SDL_OpenAudio(SDL_AudioSpec *desired, SDL_AudioSpec *obtained) -{ - SDL_AudioDevice *audio; - const char *env; - - /* Start up the audio driver, if necessary */ - if ( ! current_audio ) { - if ( (SDL_InitSubSystem(SDL_INIT_AUDIO) < 0) || - (current_audio == NULL) ) { - return(-1); - } - } - audio = current_audio; - - if (audio->opened) { - SDL_SetError("Audio device is already opened"); - return(-1); - } - - /* Verify some parameters */ - if ( desired->freq == 0 ) { - env = SDL_getenv("SDL_AUDIO_FREQUENCY"); - if ( env ) { - desired->freq = SDL_atoi(env); - } - } - if ( desired->freq == 0 ) { - /* Pick some default audio frequency */ - desired->freq = 22050; - } - if ( desired->format == 0 ) { - env = SDL_getenv("SDL_AUDIO_FORMAT"); - if ( env ) { - desired->format = SDL_ParseAudioFormat(env); - } - } - if ( desired->format == 0 ) { - /* Pick some default audio format */ - desired->format = AUDIO_S16; - } - if ( desired->channels == 0 ) { - env = SDL_getenv("SDL_AUDIO_CHANNELS"); - if ( env ) { - desired->channels = (Uint8)SDL_atoi(env); - } - } - if ( desired->channels == 0 ) { - /* Pick a default number of channels */ - desired->channels = 2; - } - switch ( desired->channels ) { - case 1: /* Mono */ - case 2: /* Stereo */ - case 4: /* surround */ - case 6: /* surround with center and lfe */ - break; - default: - SDL_SetError("1 (mono) and 2 (stereo) channels supported"); - return(-1); - } - if ( desired->samples == 0 ) { - env = SDL_getenv("SDL_AUDIO_SAMPLES"); - if ( env ) { - desired->samples = (Uint16)SDL_atoi(env); - } - } - if ( desired->samples == 0 ) { - /* Pick a default of ~46 ms at desired frequency */ - int samples = (desired->freq / 1000) * 46; - int power2 = 1; - while ( power2 < samples ) { - power2 *= 2; - } - desired->samples = power2; - } - if ( desired->callback == NULL ) { - SDL_SetError("SDL_OpenAudio() passed a NULL callback"); - return(-1); - } - -#if SDL_THREADS_DISABLED - /* Uses interrupt driven audio, without thread */ -#else - /* Create a semaphore for locking the sound buffers */ - audio->mixer_lock = SDL_CreateMutex(); - if ( audio->mixer_lock == NULL ) { - SDL_SetError("Couldn't create mixer lock"); - SDL_CloseAudio(); - return(-1); - } -#endif /* SDL_THREADS_DISABLED */ - - /* Calculate the silence and size of the audio specification */ - SDL_CalculateAudioSpec(desired); - - /* Open the audio subsystem */ - SDL_memcpy(&audio->spec, desired, sizeof(audio->spec)); - audio->convert.needed = 0; - audio->enabled = 1; - audio->paused = 1; - - audio->opened = audio->OpenAudio(audio, &audio->spec)+1; - - if ( ! audio->opened ) { - SDL_CloseAudio(); - return(-1); - } - - /* If the audio driver changes the buffer size, accept it */ - if ( audio->spec.samples != desired->samples ) { - desired->samples = audio->spec.samples; - SDL_CalculateAudioSpec(desired); - } - - /* Allocate a fake audio memory buffer */ - audio->fake_stream = SDL_AllocAudioMem(audio->spec.size); - if ( audio->fake_stream == NULL ) { - SDL_CloseAudio(); - SDL_OutOfMemory(); - return(-1); - } - - /* See if we need to do any conversion */ - if ( obtained != NULL ) { - SDL_memcpy(obtained, &audio->spec, sizeof(audio->spec)); - } else if ( desired->freq != audio->spec.freq || - desired->format != audio->spec.format || - desired->channels != audio->spec.channels ) { - /* Build an audio conversion block */ - if ( SDL_BuildAudioCVT(&audio->convert, - desired->format, desired->channels, - desired->freq, - audio->spec.format, audio->spec.channels, - audio->spec.freq) < 0 ) { - SDL_CloseAudio(); - return(-1); - } - if ( audio->convert.needed ) { - audio->convert.len = (int) ( ((double) desired->size) / - audio->convert.len_ratio ); - audio->convert.buf =(Uint8 *)SDL_AllocAudioMem( - audio->convert.len*audio->convert.len_mult); - if ( audio->convert.buf == NULL ) { - SDL_CloseAudio(); - SDL_OutOfMemory(); - return(-1); - } - } - } - - /* Start the audio thread if necessary */ - switch (audio->opened) { - case 1: - /* Start the audio thread */ -#if (defined(__WIN32__) && !defined(_WIN32_WCE)) && !defined(HAVE_LIBC) && !defined(__SYMBIAN32__) -#undef SDL_CreateThread - audio->thread = SDL_CreateThread(SDL_RunAudio, audio, NULL, NULL); -#else - audio->thread = SDL_CreateThread(SDL_RunAudio, audio); -#endif - if ( audio->thread == NULL ) { - SDL_CloseAudio(); - SDL_SetError("Couldn't create audio thread"); - return(-1); - } - break; - - default: - /* The audio is now playing */ - break; - } - - return(0); -} - -SDL_audiostatus SDL_GetAudioStatus(void) -{ - SDL_AudioDevice *audio = current_audio; - SDL_audiostatus status; - - status = SDL_AUDIO_STOPPED; - if ( audio && audio->enabled ) { - if ( audio->paused ) { - status = SDL_AUDIO_PAUSED; - } else { - status = SDL_AUDIO_PLAYING; - } - } - return(status); -} - -void SDL_PauseAudio (int pause_on) -{ - SDL_AudioDevice *audio = current_audio; - - if ( audio ) { - audio->paused = pause_on; - } -} - -void SDL_LockAudio (void) -{ - SDL_AudioDevice *audio = current_audio; - - /* Obtain a lock on the mixing buffers */ - if ( audio && audio->LockAudio ) { - audio->LockAudio(audio); - } -} - -void SDL_UnlockAudio (void) -{ - SDL_AudioDevice *audio = current_audio; - - /* Release lock on the mixing buffers */ - if ( audio && audio->UnlockAudio ) { - audio->UnlockAudio(audio); - } -} - -void SDL_CloseAudio (void) -{ - SDL_QuitSubSystem(SDL_INIT_AUDIO); -} - -void SDL_AudioQuit(void) -{ - SDL_AudioDevice *audio = current_audio; - - if ( audio ) { - audio->enabled = 0; - if ( audio->thread != NULL ) { - SDL_WaitThread(audio->thread, NULL); - } - if ( audio->mixer_lock != NULL ) { - SDL_DestroyMutex(audio->mixer_lock); - } - if ( audio->fake_stream != NULL ) { - SDL_FreeAudioMem(audio->fake_stream); - } - if ( audio->convert.needed ) { - SDL_FreeAudioMem(audio->convert.buf); - - } - if ( audio->opened ) { - audio->CloseAudio(audio); - audio->opened = 0; - } - /* Free the driver data */ - audio->free(audio); - current_audio = NULL; - } -} - -#define NUM_FORMATS 6 -static int format_idx; -static int format_idx_sub; -static Uint16 format_list[NUM_FORMATS][NUM_FORMATS] = { - { AUDIO_U8, AUDIO_S8, AUDIO_S16LSB, AUDIO_S16MSB, AUDIO_U16LSB, AUDIO_U16MSB }, - { AUDIO_S8, AUDIO_U8, AUDIO_S16LSB, AUDIO_S16MSB, AUDIO_U16LSB, AUDIO_U16MSB }, - { AUDIO_S16LSB, AUDIO_S16MSB, AUDIO_U16LSB, AUDIO_U16MSB, AUDIO_U8, AUDIO_S8 }, - { AUDIO_S16MSB, AUDIO_S16LSB, AUDIO_U16MSB, AUDIO_U16LSB, AUDIO_U8, AUDIO_S8 }, - { AUDIO_U16LSB, AUDIO_U16MSB, AUDIO_S16LSB, AUDIO_S16MSB, AUDIO_U8, AUDIO_S8 }, - { AUDIO_U16MSB, AUDIO_U16LSB, AUDIO_S16MSB, AUDIO_S16LSB, AUDIO_U8, AUDIO_S8 }, -}; - -Uint16 SDL_FirstAudioFormat(Uint16 format) -{ - for ( format_idx=0; format_idx < NUM_FORMATS; ++format_idx ) { - if ( format_list[format_idx][0] == format ) { - break; - } - } - format_idx_sub = 0; - return(SDL_NextAudioFormat()); -} - -Uint16 SDL_NextAudioFormat(void) -{ - if ( (format_idx == NUM_FORMATS) || (format_idx_sub == NUM_FORMATS) ) { - return(0); - } - return(format_list[format_idx][format_idx_sub++]); -} - -void SDL_CalculateAudioSpec(SDL_AudioSpec *spec) -{ - switch (spec->format) { - case AUDIO_U8: - spec->silence = 0x80; - break; - default: - spec->silence = 0x00; - break; - } - spec->size = (spec->format&0xFF)/8; - spec->size *= spec->channels; - spec->size *= spec->samples; -} diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audio_c.h b/distrib/sdl-1.2.12/src/audio/SDL_audio_c.h deleted file mode 100644 index f584895..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audio_c.h +++ /dev/null @@ -1,34 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Functions and variables exported from SDL_audio.c for SDL_sysaudio.c */ - -/* Functions to get a list of "close" audio formats */ -extern Uint16 SDL_FirstAudioFormat(Uint16 format); -extern Uint16 SDL_NextAudioFormat(void); - -/* Function to calculate the size and silence for a SDL_AudioSpec */ -extern void SDL_CalculateAudioSpec(SDL_AudioSpec *spec); - -/* The actual mixing thread function */ -extern int SDLCALL SDL_RunAudio(void *audiop); diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audiocvt.c b/distrib/sdl-1.2.12/src/audio/SDL_audiocvt.c deleted file mode 100644 index 68c99e1..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audiocvt.c +++ /dev/null @@ -1,1510 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Functions for audio drivers to perform runtime conversion of audio format */ - -#include "SDL_audio.h" - - -/* Effectively mix right and left channels into a single channel */ -void SDLCALL SDL_ConvertMono(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Sint32 sample; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting to mono\n"); -#endif - switch (format&0x8018) { - - case AUDIO_U8: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - for ( i=cvt->len_cvt/2; i; --i ) { - sample = src[0] + src[1]; - *dst = (Uint8)(sample / 2); - src += 2; - dst += 1; - } - } - break; - - case AUDIO_S8: { - Sint8 *src, *dst; - - src = (Sint8 *)cvt->buf; - dst = (Sint8 *)cvt->buf; - for ( i=cvt->len_cvt/2; i; --i ) { - sample = src[0] + src[1]; - *dst = (Sint8)(sample / 2); - src += 2; - dst += 1; - } - } - break; - - case AUDIO_U16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - sample = (Uint16)((src[0]<<8)|src[1])+ - (Uint16)((src[2]<<8)|src[3]); - sample /= 2; - dst[1] = (sample&0xFF); - sample >>= 8; - dst[0] = (sample&0xFF); - src += 4; - dst += 2; - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - sample = (Uint16)((src[1]<<8)|src[0])+ - (Uint16)((src[3]<<8)|src[2]); - sample /= 2; - dst[0] = (sample&0xFF); - sample >>= 8; - dst[1] = (sample&0xFF); - src += 4; - dst += 2; - } - } - } - break; - - case AUDIO_S16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - sample = (Sint16)((src[0]<<8)|src[1])+ - (Sint16)((src[2]<<8)|src[3]); - sample /= 2; - dst[1] = (sample&0xFF); - sample >>= 8; - dst[0] = (sample&0xFF); - src += 4; - dst += 2; - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - sample = (Sint16)((src[1]<<8)|src[0])+ - (Sint16)((src[3]<<8)|src[2]); - sample /= 2; - dst[0] = (sample&0xFF); - sample >>= 8; - dst[1] = (sample&0xFF); - src += 4; - dst += 2; - } - } - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Discard top 4 channels */ -void SDLCALL SDL_ConvertStrip(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Sint32 lsample, rsample; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting down to stereo\n"); -#endif - switch (format&0x8018) { - - case AUDIO_U8: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - for ( i=cvt->len_cvt/6; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 6; - dst += 2; - } - } - break; - - case AUDIO_S8: { - Sint8 *src, *dst; - - src = (Sint8 *)cvt->buf; - dst = (Sint8 *)cvt->buf; - for ( i=cvt->len_cvt/6; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 6; - dst += 2; - } - } - break; - - case AUDIO_U16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/12; i; --i ) { - lsample = (Uint16)((src[0]<<8)|src[1]); - rsample = (Uint16)((src[2]<<8)|src[3]); - dst[1] = (lsample&0xFF); - lsample >>= 8; - dst[0] = (lsample&0xFF); - dst[3] = (rsample&0xFF); - rsample >>= 8; - dst[2] = (rsample&0xFF); - src += 12; - dst += 4; - } - } else { - for ( i=cvt->len_cvt/12; i; --i ) { - lsample = (Uint16)((src[1]<<8)|src[0]); - rsample = (Uint16)((src[3]<<8)|src[2]); - dst[0] = (lsample&0xFF); - lsample >>= 8; - dst[1] = (lsample&0xFF); - dst[2] = (rsample&0xFF); - rsample >>= 8; - dst[3] = (rsample&0xFF); - src += 12; - dst += 4; - } - } - } - break; - - case AUDIO_S16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/12; i; --i ) { - lsample = (Sint16)((src[0]<<8)|src[1]); - rsample = (Sint16)((src[2]<<8)|src[3]); - dst[1] = (lsample&0xFF); - lsample >>= 8; - dst[0] = (lsample&0xFF); - dst[3] = (rsample&0xFF); - rsample >>= 8; - dst[2] = (rsample&0xFF); - src += 12; - dst += 4; - } - } else { - for ( i=cvt->len_cvt/12; i; --i ) { - lsample = (Sint16)((src[1]<<8)|src[0]); - rsample = (Sint16)((src[3]<<8)|src[2]); - dst[0] = (lsample&0xFF); - lsample >>= 8; - dst[1] = (lsample&0xFF); - dst[2] = (rsample&0xFF); - rsample >>= 8; - dst[3] = (rsample&0xFF); - src += 12; - dst += 4; - } - } - } - break; - } - cvt->len_cvt /= 3; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Discard top 2 channels of 6 */ -void SDLCALL SDL_ConvertStrip_2(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Sint32 lsample, rsample; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting 6 down to quad\n"); -#endif - switch (format&0x8018) { - - case AUDIO_U8: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - for ( i=cvt->len_cvt/4; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 4; - dst += 2; - } - } - break; - - case AUDIO_S8: { - Sint8 *src, *dst; - - src = (Sint8 *)cvt->buf; - dst = (Sint8 *)cvt->buf; - for ( i=cvt->len_cvt/4; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 4; - dst += 2; - } - } - break; - - case AUDIO_U16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/8; i; --i ) { - lsample = (Uint16)((src[0]<<8)|src[1]); - rsample = (Uint16)((src[2]<<8)|src[3]); - dst[1] = (lsample&0xFF); - lsample >>= 8; - dst[0] = (lsample&0xFF); - dst[3] = (rsample&0xFF); - rsample >>= 8; - dst[2] = (rsample&0xFF); - src += 8; - dst += 4; - } - } else { - for ( i=cvt->len_cvt/8; i; --i ) { - lsample = (Uint16)((src[1]<<8)|src[0]); - rsample = (Uint16)((src[3]<<8)|src[2]); - dst[0] = (lsample&0xFF); - lsample >>= 8; - dst[1] = (lsample&0xFF); - dst[2] = (rsample&0xFF); - rsample >>= 8; - dst[3] = (rsample&0xFF); - src += 8; - dst += 4; - } - } - } - break; - - case AUDIO_S16: { - Uint8 *src, *dst; - - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/8; i; --i ) { - lsample = (Sint16)((src[0]<<8)|src[1]); - rsample = (Sint16)((src[2]<<8)|src[3]); - dst[1] = (lsample&0xFF); - lsample >>= 8; - dst[0] = (lsample&0xFF); - dst[3] = (rsample&0xFF); - rsample >>= 8; - dst[2] = (rsample&0xFF); - src += 8; - dst += 4; - } - } else { - for ( i=cvt->len_cvt/8; i; --i ) { - lsample = (Sint16)((src[1]<<8)|src[0]); - rsample = (Sint16)((src[3]<<8)|src[2]); - dst[0] = (lsample&0xFF); - lsample >>= 8; - dst[1] = (lsample&0xFF); - dst[2] = (rsample&0xFF); - rsample >>= 8; - dst[3] = (rsample&0xFF); - src += 8; - dst += 4; - } - } - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Duplicate a mono channel to both stereo channels */ -void SDLCALL SDL_ConvertStereo(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting to stereo\n"); -#endif - if ( (format & 0xFF) == 16 ) { - Uint16 *src, *dst; - - src = (Uint16 *)(cvt->buf+cvt->len_cvt); - dst = (Uint16 *)(cvt->buf+cvt->len_cvt*2); - for ( i=cvt->len_cvt/2; i; --i ) { - dst -= 2; - src -= 1; - dst[0] = src[0]; - dst[1] = src[0]; - } - } else { - Uint8 *src, *dst; - - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - for ( i=cvt->len_cvt; i; --i ) { - dst -= 2; - src -= 1; - dst[0] = src[0]; - dst[1] = src[0]; - } - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Duplicate a stereo channel to a pseudo-5.1 stream */ -void SDLCALL SDL_ConvertSurround(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting stereo to surround\n"); -#endif - switch (format&0x8018) { - - case AUDIO_U8: { - Uint8 *src, *dst, lf, rf, ce; - - src = (Uint8 *)(cvt->buf+cvt->len_cvt); - dst = (Uint8 *)(cvt->buf+cvt->len_cvt*3); - for ( i=cvt->len_cvt; i; --i ) { - dst -= 6; - src -= 2; - lf = src[0]; - rf = src[1]; - ce = (lf/2) + (rf/2); - dst[0] = lf; - dst[1] = rf; - dst[2] = lf - ce; - dst[3] = rf - ce; - dst[4] = ce; - dst[5] = ce; - } - } - break; - - case AUDIO_S8: { - Sint8 *src, *dst, lf, rf, ce; - - src = (Sint8 *)cvt->buf+cvt->len_cvt; - dst = (Sint8 *)cvt->buf+cvt->len_cvt*3; - for ( i=cvt->len_cvt; i; --i ) { - dst -= 6; - src -= 2; - lf = src[0]; - rf = src[1]; - ce = (lf/2) + (rf/2); - dst[0] = lf; - dst[1] = rf; - dst[2] = lf - ce; - dst[3] = rf - ce; - dst[4] = ce; - dst[5] = ce; - } - } - break; - - case AUDIO_U16: { - Uint8 *src, *dst; - Uint16 lf, rf, ce, lr, rr; - - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*3; - - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 12; - src -= 4; - lf = (Uint16)((src[0]<<8)|src[1]); - rf = (Uint16)((src[2]<<8)|src[3]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[1] = (lf&0xFF); - dst[0] = ((lf>>8)&0xFF); - dst[3] = (rf&0xFF); - dst[2] = ((rf>>8)&0xFF); - - dst[1+4] = (lr&0xFF); - dst[0+4] = ((lr>>8)&0xFF); - dst[3+4] = (rr&0xFF); - dst[2+4] = ((rr>>8)&0xFF); - - dst[1+8] = (ce&0xFF); - dst[0+8] = ((ce>>8)&0xFF); - dst[3+8] = (ce&0xFF); - dst[2+8] = ((ce>>8)&0xFF); - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 12; - src -= 4; - lf = (Uint16)((src[1]<<8)|src[0]); - rf = (Uint16)((src[3]<<8)|src[2]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[0] = (lf&0xFF); - dst[1] = ((lf>>8)&0xFF); - dst[2] = (rf&0xFF); - dst[3] = ((rf>>8)&0xFF); - - dst[0+4] = (lr&0xFF); - dst[1+4] = ((lr>>8)&0xFF); - dst[2+4] = (rr&0xFF); - dst[3+4] = ((rr>>8)&0xFF); - - dst[0+8] = (ce&0xFF); - dst[1+8] = ((ce>>8)&0xFF); - dst[2+8] = (ce&0xFF); - dst[3+8] = ((ce>>8)&0xFF); - } - } - } - break; - - case AUDIO_S16: { - Uint8 *src, *dst; - Sint16 lf, rf, ce, lr, rr; - - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*3; - - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 12; - src -= 4; - lf = (Sint16)((src[0]<<8)|src[1]); - rf = (Sint16)((src[2]<<8)|src[3]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[1] = (lf&0xFF); - dst[0] = ((lf>>8)&0xFF); - dst[3] = (rf&0xFF); - dst[2] = ((rf>>8)&0xFF); - - dst[1+4] = (lr&0xFF); - dst[0+4] = ((lr>>8)&0xFF); - dst[3+4] = (rr&0xFF); - dst[2+4] = ((rr>>8)&0xFF); - - dst[1+8] = (ce&0xFF); - dst[0+8] = ((ce>>8)&0xFF); - dst[3+8] = (ce&0xFF); - dst[2+8] = ((ce>>8)&0xFF); - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 12; - src -= 4; - lf = (Sint16)((src[1]<<8)|src[0]); - rf = (Sint16)((src[3]<<8)|src[2]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[0] = (lf&0xFF); - dst[1] = ((lf>>8)&0xFF); - dst[2] = (rf&0xFF); - dst[3] = ((rf>>8)&0xFF); - - dst[0+4] = (lr&0xFF); - dst[1+4] = ((lr>>8)&0xFF); - dst[2+4] = (rr&0xFF); - dst[3+4] = ((rr>>8)&0xFF); - - dst[0+8] = (ce&0xFF); - dst[1+8] = ((ce>>8)&0xFF); - dst[2+8] = (ce&0xFF); - dst[3+8] = ((ce>>8)&0xFF); - } - } - } - break; - } - cvt->len_cvt *= 3; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Duplicate a stereo channel to a pseudo-4.0 stream */ -void SDLCALL SDL_ConvertSurround_4(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting stereo to quad\n"); -#endif - switch (format&0x8018) { - - case AUDIO_U8: { - Uint8 *src, *dst, lf, rf, ce; - - src = (Uint8 *)(cvt->buf+cvt->len_cvt); - dst = (Uint8 *)(cvt->buf+cvt->len_cvt*2); - for ( i=cvt->len_cvt; i; --i ) { - dst -= 4; - src -= 2; - lf = src[0]; - rf = src[1]; - ce = (lf/2) + (rf/2); - dst[0] = lf; - dst[1] = rf; - dst[2] = lf - ce; - dst[3] = rf - ce; - } - } - break; - - case AUDIO_S8: { - Sint8 *src, *dst, lf, rf, ce; - - src = (Sint8 *)cvt->buf+cvt->len_cvt; - dst = (Sint8 *)cvt->buf+cvt->len_cvt*2; - for ( i=cvt->len_cvt; i; --i ) { - dst -= 4; - src -= 2; - lf = src[0]; - rf = src[1]; - ce = (lf/2) + (rf/2); - dst[0] = lf; - dst[1] = rf; - dst[2] = lf - ce; - dst[3] = rf - ce; - } - } - break; - - case AUDIO_U16: { - Uint8 *src, *dst; - Uint16 lf, rf, ce, lr, rr; - - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 8; - src -= 4; - lf = (Uint16)((src[0]<<8)|src[1]); - rf = (Uint16)((src[2]<<8)|src[3]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[1] = (lf&0xFF); - dst[0] = ((lf>>8)&0xFF); - dst[3] = (rf&0xFF); - dst[2] = ((rf>>8)&0xFF); - - dst[1+4] = (lr&0xFF); - dst[0+4] = ((lr>>8)&0xFF); - dst[3+4] = (rr&0xFF); - dst[2+4] = ((rr>>8)&0xFF); - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 8; - src -= 4; - lf = (Uint16)((src[1]<<8)|src[0]); - rf = (Uint16)((src[3]<<8)|src[2]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[0] = (lf&0xFF); - dst[1] = ((lf>>8)&0xFF); - dst[2] = (rf&0xFF); - dst[3] = ((rf>>8)&0xFF); - - dst[0+4] = (lr&0xFF); - dst[1+4] = ((lr>>8)&0xFF); - dst[2+4] = (rr&0xFF); - dst[3+4] = ((rr>>8)&0xFF); - } - } - } - break; - - case AUDIO_S16: { - Uint8 *src, *dst; - Sint16 lf, rf, ce, lr, rr; - - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - - if ( (format & 0x1000) == 0x1000 ) { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 8; - src -= 4; - lf = (Sint16)((src[0]<<8)|src[1]); - rf = (Sint16)((src[2]<<8)|src[3]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[1] = (lf&0xFF); - dst[0] = ((lf>>8)&0xFF); - dst[3] = (rf&0xFF); - dst[2] = ((rf>>8)&0xFF); - - dst[1+4] = (lr&0xFF); - dst[0+4] = ((lr>>8)&0xFF); - dst[3+4] = (rr&0xFF); - dst[2+4] = ((rr>>8)&0xFF); - } - } else { - for ( i=cvt->len_cvt/4; i; --i ) { - dst -= 8; - src -= 4; - lf = (Sint16)((src[1]<<8)|src[0]); - rf = (Sint16)((src[3]<<8)|src[2]); - ce = (lf/2) + (rf/2); - rr = lf - ce; - lr = rf - ce; - dst[0] = (lf&0xFF); - dst[1] = ((lf>>8)&0xFF); - dst[2] = (rf&0xFF); - dst[3] = ((rf>>8)&0xFF); - - dst[0+4] = (lr&0xFF); - dst[1+4] = ((lr>>8)&0xFF); - dst[2+4] = (rr&0xFF); - dst[3+4] = ((rr>>8)&0xFF); - } - } - } - break; - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Convert 8-bit to 16-bit - LSB */ -void SDLCALL SDL_Convert16LSB(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting to 16-bit LSB\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - for ( i=cvt->len_cvt; i; --i ) { - src -= 1; - dst -= 2; - dst[1] = *src; - dst[0] = 0; - } - format = ((format & ~0x0008) | AUDIO_U16LSB); - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} -/* Convert 8-bit to 16-bit - MSB */ -void SDLCALL SDL_Convert16MSB(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting to 16-bit MSB\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - for ( i=cvt->len_cvt; i; --i ) { - src -= 1; - dst -= 2; - dst[0] = *src; - dst[1] = 0; - } - format = ((format & ~0x0008) | AUDIO_U16MSB); - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Convert 16-bit to 8-bit */ -void SDLCALL SDL_Convert8(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting to 8-bit\n"); -#endif - src = cvt->buf; - dst = cvt->buf; - if ( (format & 0x1000) != 0x1000 ) { /* Little endian */ - ++src; - } - for ( i=cvt->len_cvt/2; i; --i ) { - *dst = *src; - src += 2; - dst += 1; - } - format = ((format & ~0x9010) | AUDIO_U8); - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Toggle signed/unsigned */ -void SDLCALL SDL_ConvertSign(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *data; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio signedness\n"); -#endif - data = cvt->buf; - if ( (format & 0xFF) == 16 ) { - if ( (format & 0x1000) != 0x1000 ) { /* Little endian */ - ++data; - } - for ( i=cvt->len_cvt/2; i; --i ) { - *data ^= 0x80; - data += 2; - } - } else { - for ( i=cvt->len_cvt; i; --i ) { - *data++ ^= 0x80; - } - } - format = (format ^ 0x8000); - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Toggle endianness */ -void SDLCALL SDL_ConvertEndian(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *data, tmp; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio endianness\n"); -#endif - data = cvt->buf; - for ( i=cvt->len_cvt/2; i; --i ) { - tmp = data[0]; - data[0] = data[1]; - data[1] = tmp; - data += 2; - } - format = (format ^ 0x1000); - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Convert rate up by multiple of 2 */ -void SDLCALL SDL_RateMUL2(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate * 2\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt; i; --i ) { - src -= 1; - dst -= 2; - dst[0] = src[0]; - dst[1] = src[0]; - } - break; - case 16: - for ( i=cvt->len_cvt/2; i; --i ) { - src -= 2; - dst -= 4; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[0]; - dst[3] = src[1]; - } - break; - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Convert rate up by multiple of 2, for stereo */ -void SDLCALL SDL_RateMUL2_c2(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate * 2\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/2; i; --i ) { - src -= 2; - dst -= 4; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[0]; - dst[3] = src[1]; - } - break; - case 16: - for ( i=cvt->len_cvt/4; i; --i ) { - src -= 4; - dst -= 8; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[0]; - dst[5] = src[1]; - dst[6] = src[2]; - dst[7] = src[3]; - } - break; - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Convert rate up by multiple of 2, for quad */ -void SDLCALL SDL_RateMUL2_c4(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate * 2\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/4; i; --i ) { - src -= 4; - dst -= 8; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[0]; - dst[5] = src[1]; - dst[6] = src[2]; - dst[7] = src[3]; - } - break; - case 16: - for ( i=cvt->len_cvt/8; i; --i ) { - src -= 8; - dst -= 16; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - dst[6] = src[6]; - dst[7] = src[7]; - dst[8] = src[0]; - dst[9] = src[1]; - dst[10] = src[2]; - dst[11] = src[3]; - dst[12] = src[4]; - dst[13] = src[5]; - dst[14] = src[6]; - dst[15] = src[7]; - } - break; - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Convert rate up by multiple of 2, for 5.1 */ -void SDLCALL SDL_RateMUL2_c6(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate * 2\n"); -#endif - src = cvt->buf+cvt->len_cvt; - dst = cvt->buf+cvt->len_cvt*2; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/6; i; --i ) { - src -= 6; - dst -= 12; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - dst[6] = src[0]; - dst[7] = src[1]; - dst[8] = src[2]; - dst[9] = src[3]; - dst[10] = src[4]; - dst[11] = src[5]; - } - break; - case 16: - for ( i=cvt->len_cvt/12; i; --i ) { - src -= 12; - dst -= 24; - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - dst[6] = src[6]; - dst[7] = src[7]; - dst[8] = src[8]; - dst[9] = src[9]; - dst[10] = src[10]; - dst[11] = src[11]; - dst[12] = src[0]; - dst[13] = src[1]; - dst[14] = src[2]; - dst[15] = src[3]; - dst[16] = src[4]; - dst[17] = src[5]; - dst[18] = src[6]; - dst[19] = src[7]; - dst[20] = src[8]; - dst[21] = src[9]; - dst[22] = src[10]; - dst[23] = src[11]; - } - break; - } - cvt->len_cvt *= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Convert rate down by multiple of 2 */ -void SDLCALL SDL_RateDIV2(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate / 2\n"); -#endif - src = cvt->buf; - dst = cvt->buf; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/2; i; --i ) { - dst[0] = src[0]; - src += 2; - dst += 1; - } - break; - case 16: - for ( i=cvt->len_cvt/4; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 4; - dst += 2; - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Convert rate down by multiple of 2, for stereo */ -void SDLCALL SDL_RateDIV2_c2(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate / 2\n"); -#endif - src = cvt->buf; - dst = cvt->buf; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/4; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - src += 4; - dst += 2; - } - break; - case 16: - for ( i=cvt->len_cvt/8; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - src += 8; - dst += 4; - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - - -/* Convert rate down by multiple of 2, for quad */ -void SDLCALL SDL_RateDIV2_c4(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate / 2\n"); -#endif - src = cvt->buf; - dst = cvt->buf; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/8; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - src += 8; - dst += 4; - } - break; - case 16: - for ( i=cvt->len_cvt/16; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - dst[6] = src[6]; - dst[7] = src[7]; - src += 16; - dst += 8; - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Convert rate down by multiple of 2, for 5.1 */ -void SDLCALL SDL_RateDIV2_c6(SDL_AudioCVT *cvt, Uint16 format) -{ - int i; - Uint8 *src, *dst; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate / 2\n"); -#endif - src = cvt->buf; - dst = cvt->buf; - switch (format & 0xFF) { - case 8: - for ( i=cvt->len_cvt/12; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - src += 12; - dst += 6; - } - break; - case 16: - for ( i=cvt->len_cvt/24; i; --i ) { - dst[0] = src[0]; - dst[1] = src[1]; - dst[2] = src[2]; - dst[3] = src[3]; - dst[4] = src[4]; - dst[5] = src[5]; - dst[6] = src[6]; - dst[7] = src[7]; - dst[8] = src[8]; - dst[9] = src[9]; - dst[10] = src[10]; - dst[11] = src[11]; - src += 24; - dst += 12; - } - break; - } - cvt->len_cvt /= 2; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -/* Very slow rate conversion routine */ -void SDLCALL SDL_RateSLOW(SDL_AudioCVT *cvt, Uint16 format) -{ - double ipos; - int i, clen; - -#ifdef DEBUG_CONVERT - fprintf(stderr, "Converting audio rate * %4.4f\n", 1.0/cvt->rate_incr); -#endif - clen = (int)((double)cvt->len_cvt / cvt->rate_incr); - if ( cvt->rate_incr > 1.0 ) { - switch (format & 0xFF) { - case 8: { - Uint8 *output; - - output = cvt->buf; - ipos = 0.0; - for ( i=clen; i; --i ) { - *output = cvt->buf[(int)ipos]; - ipos += cvt->rate_incr; - output += 1; - } - } - break; - - case 16: { - Uint16 *output; - - clen &= ~1; - output = (Uint16 *)cvt->buf; - ipos = 0.0; - for ( i=clen/2; i; --i ) { - *output=((Uint16 *)cvt->buf)[(int)ipos]; - ipos += cvt->rate_incr; - output += 1; - } - } - break; - } - } else { - switch (format & 0xFF) { - case 8: { - Uint8 *output; - - output = cvt->buf+clen; - ipos = (double)cvt->len_cvt; - for ( i=clen; i; --i ) { - ipos -= cvt->rate_incr; - output -= 1; - *output = cvt->buf[(int)ipos]; - } - } - break; - - case 16: { - Uint16 *output; - - clen &= ~1; - output = (Uint16 *)(cvt->buf+clen); - ipos = (double)cvt->len_cvt/2; - for ( i=clen/2; i; --i ) { - ipos -= cvt->rate_incr; - output -= 1; - *output=((Uint16 *)cvt->buf)[(int)ipos]; - } - } - break; - } - } - cvt->len_cvt = clen; - if ( cvt->filters[++cvt->filter_index] ) { - cvt->filters[cvt->filter_index](cvt, format); - } -} - -int SDL_ConvertAudio(SDL_AudioCVT *cvt) -{ - /* Make sure there's data to convert */ - if ( cvt->buf == NULL ) { - SDL_SetError("No buffer allocated for conversion"); - return(-1); - } - /* Return okay if no conversion is necessary */ - cvt->len_cvt = cvt->len; - if ( cvt->filters[0] == NULL ) { - return(0); - } - - /* Set up the conversion and go! */ - cvt->filter_index = 0; - cvt->filters[0](cvt, cvt->src_format); - return(0); -} - -/* Creates a set of audio filters to convert from one format to another. - Returns -1 if the format conversion is not supported, or 1 if the - audio filter is set up. -*/ - -int SDL_BuildAudioCVT(SDL_AudioCVT *cvt, - Uint16 src_format, Uint8 src_channels, int src_rate, - Uint16 dst_format, Uint8 dst_channels, int dst_rate) -{ -/*printf("Build format %04x->%04x, channels %u->%u, rate %d->%d\n", - src_format, dst_format, src_channels, dst_channels, src_rate, dst_rate);*/ - /* Start off with no conversion necessary */ - cvt->needed = 0; - cvt->filter_index = 0; - cvt->filters[0] = NULL; - cvt->len_mult = 1; - cvt->len_ratio = 1.0; - - /* First filter: Endian conversion from src to dst */ - if ( (src_format & 0x1000) != (dst_format & 0x1000) - && ((src_format & 0xff) == 16) && ((dst_format & 0xff) == 16)) { - cvt->filters[cvt->filter_index++] = SDL_ConvertEndian; - } - - /* Second filter: Sign conversion -- signed/unsigned */ - if ( (src_format & 0x8000) != (dst_format & 0x8000) ) { - cvt->filters[cvt->filter_index++] = SDL_ConvertSign; - } - - /* Next filter: Convert 16 bit <--> 8 bit PCM */ - if ( (src_format & 0xFF) != (dst_format & 0xFF) ) { - switch (dst_format&0x10FF) { - case AUDIO_U8: - cvt->filters[cvt->filter_index++] = - SDL_Convert8; - cvt->len_ratio /= 2; - break; - case AUDIO_U16LSB: - cvt->filters[cvt->filter_index++] = - SDL_Convert16LSB; - cvt->len_mult *= 2; - cvt->len_ratio *= 2; - break; - case AUDIO_U16MSB: - cvt->filters[cvt->filter_index++] = - SDL_Convert16MSB; - cvt->len_mult *= 2; - cvt->len_ratio *= 2; - break; - } - } - - /* Last filter: Mono/Stereo conversion */ - if ( src_channels != dst_channels ) { - if ( (src_channels == 1) && (dst_channels > 1) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertStereo; - cvt->len_mult *= 2; - src_channels = 2; - cvt->len_ratio *= 2; - } - if ( (src_channels == 2) && - (dst_channels == 6) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertSurround; - src_channels = 6; - cvt->len_mult *= 3; - cvt->len_ratio *= 3; - } - if ( (src_channels == 2) && - (dst_channels == 4) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertSurround_4; - src_channels = 4; - cvt->len_mult *= 2; - cvt->len_ratio *= 2; - } - while ( (src_channels*2) <= dst_channels ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertStereo; - cvt->len_mult *= 2; - src_channels *= 2; - cvt->len_ratio *= 2; - } - if ( (src_channels == 6) && - (dst_channels <= 2) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertStrip; - src_channels = 2; - cvt->len_ratio /= 3; - } - if ( (src_channels == 6) && - (dst_channels == 4) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertStrip_2; - src_channels = 4; - cvt->len_ratio /= 2; - } - /* This assumes that 4 channel audio is in the format: - Left {front/back} + Right {front/back} - so converting to L/R stereo works properly. - */ - while ( ((src_channels%2) == 0) && - ((src_channels/2) >= dst_channels) ) { - cvt->filters[cvt->filter_index++] = - SDL_ConvertMono; - src_channels /= 2; - cvt->len_ratio /= 2; - } - if ( src_channels != dst_channels ) { - /* Uh oh.. */; - } - } - - /* Do rate conversion */ - cvt->rate_incr = 0.0; - if ( (src_rate/100) != (dst_rate/100) ) { - Uint32 hi_rate, lo_rate; - int len_mult; - double len_ratio; - void (SDLCALL *rate_cvt)(SDL_AudioCVT *cvt, Uint16 format); - - if ( src_rate > dst_rate ) { - hi_rate = src_rate; - lo_rate = dst_rate; - switch (src_channels) { - case 1: rate_cvt = SDL_RateDIV2; break; - case 2: rate_cvt = SDL_RateDIV2_c2; break; - case 4: rate_cvt = SDL_RateDIV2_c4; break; - case 6: rate_cvt = SDL_RateDIV2_c6; break; - default: return -1; - } - len_mult = 1; - len_ratio = 0.5; - } else { - hi_rate = dst_rate; - lo_rate = src_rate; - switch (src_channels) { - case 1: rate_cvt = SDL_RateMUL2; break; - case 2: rate_cvt = SDL_RateMUL2_c2; break; - case 4: rate_cvt = SDL_RateMUL2_c4; break; - case 6: rate_cvt = SDL_RateMUL2_c6; break; - default: return -1; - } - len_mult = 2; - len_ratio = 2.0; - } - /* If hi_rate = lo_rate*2^x then conversion is easy */ - while ( ((lo_rate*2)/100) <= (hi_rate/100) ) { - cvt->filters[cvt->filter_index++] = rate_cvt; - cvt->len_mult *= len_mult; - lo_rate *= 2; - cvt->len_ratio *= len_ratio; - } - /* We may need a slow conversion here to finish up */ - if ( (lo_rate/100) != (hi_rate/100) ) { -#if 1 - /* The problem with this is that if the input buffer is - say 1K, and the conversion rate is say 1.1, then the - output buffer is 1.1K, which may not be an acceptable - buffer size for the audio driver (not a power of 2) - */ - /* For now, punt and hope the rate distortion isn't great. - */ -#else - if ( src_rate < dst_rate ) { - cvt->rate_incr = (double)lo_rate/hi_rate; - cvt->len_mult *= 2; - cvt->len_ratio /= cvt->rate_incr; - } else { - cvt->rate_incr = (double)hi_rate/lo_rate; - cvt->len_ratio *= cvt->rate_incr; - } - cvt->filters[cvt->filter_index++] = SDL_RateSLOW; -#endif - } - } - - /* Set up the filter information */ - if ( cvt->filter_index != 0 ) { - cvt->needed = 1; - cvt->src_format = src_format; - cvt->dst_format = dst_format; - cvt->len = 0; - cvt->buf = NULL; - cvt->filters[cvt->filter_index] = NULL; - } - return(cvt->needed); -} diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audiodev.c b/distrib/sdl-1.2.12/src/audio/SDL_audiodev.c deleted file mode 100644 index 90671f9..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audiodev.c +++ /dev/null @@ -1,179 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Get the name of the audio device we use for output */ - -#if SDL_AUDIO_DRIVER_BSD || SDL_AUDIO_DRIVER_OSS || SDL_AUDIO_DRIVER_SUNAUDIO - -#include -#include -#include - -#include "SDL_stdinc.h" -#include "SDL_audiodev_c.h" - -#ifndef _PATH_DEV_DSP -#if defined(__NETBSD__) || defined(__OPENBSD__) -#define _PATH_DEV_DSP "/dev/audio" -#else -#define _PATH_DEV_DSP "/dev/dsp" -#endif -#endif -#ifndef _PATH_DEV_DSP24 -#define _PATH_DEV_DSP24 "/dev/sound/dsp" -#endif -#ifndef _PATH_DEV_AUDIO -#define _PATH_DEV_AUDIO "/dev/audio" -#endif - - -int SDL_OpenAudioPath(char *path, int maxlen, int flags, int classic) -{ - const char *audiodev; - int audio_fd; - char audiopath[1024]; - - /* Figure out what our audio device is */ - if ( ((audiodev=SDL_getenv("SDL_PATH_DSP")) == NULL) && - ((audiodev=SDL_getenv("AUDIODEV")) == NULL) ) { - if ( classic ) { - audiodev = _PATH_DEV_AUDIO; - } else { - struct stat sb; - - /* Added support for /dev/sound/\* in Linux 2.4 */ - if ( ((stat("/dev/sound", &sb) == 0) && S_ISDIR(sb.st_mode)) && - ((stat(_PATH_DEV_DSP24, &sb) == 0) && S_ISCHR(sb.st_mode)) ) { - audiodev = _PATH_DEV_DSP24; - } else { - audiodev = _PATH_DEV_DSP; - } - } - } - audio_fd = open(audiodev, flags, 0); - - /* If the first open fails, look for other devices */ - if ( (audio_fd < 0) && (SDL_strlen(audiodev) < (sizeof(audiopath)-3)) ) { - int exists, instance; - struct stat sb; - - instance = 1; - do { /* Don't use errno ENOENT - it may not be thread-safe */ - SDL_snprintf(audiopath, SDL_arraysize(audiopath), - "%s%d", audiodev, instance++); - exists = 0; - if ( stat(audiopath, &sb) == 0 ) { - exists = 1; - audio_fd = open(audiopath, flags, 0); - } - } while ( exists && (audio_fd < 0) ); - audiodev = audiopath; - } - if ( path != NULL ) { - SDL_strlcpy(path, audiodev, maxlen); - path[maxlen-1] = '\0'; - } - return(audio_fd); -} - -#elif SDL_AUDIO_DRIVER_PAUD - -/* Get the name of the audio device we use for output */ - -#include -#include - -#include "SDL_stdinc.h" -#include "SDL_audiodev_c.h" - -#ifndef _PATH_DEV_DSP -#define _PATH_DEV_DSP "/dev/%caud%c/%c" -#endif - -char devsettings[][3] = -{ - { 'p', '0', '1' }, { 'p', '0', '2' }, { 'p', '0', '3' }, { 'p', '0', '4' }, - { 'p', '1', '1' }, { 'p', '1', '2' }, { 'p', '1', '3' }, { 'p', '1', '4' }, - { 'p', '2', '1' }, { 'p', '2', '2' }, { 'p', '2', '3' }, { 'p', '2', '4' }, - { 'p', '3', '1' }, { 'p', '3', '2' }, { 'p', '3', '3' }, { 'p', '3', '4' }, - { 'b', '0', '1' }, { 'b', '0', '2' }, { 'b', '0', '3' }, { 'b', '0', '4' }, - { 'b', '1', '1' }, { 'b', '1', '2' }, { 'b', '1', '3' }, { 'b', '1', '4' }, - { 'b', '2', '1' }, { 'b', '2', '2' }, { 'b', '2', '3' }, { 'b', '2', '4' }, - { 'b', '3', '1' }, { 'b', '3', '2' }, { 'b', '3', '3' }, { 'b', '3', '4' }, - { '\0', '\0', '\0' } -}; - -static int OpenUserDefinedDevice(char *path, int maxlen, int flags) -{ - const char *audiodev; - int audio_fd; - - /* Figure out what our audio device is */ - if ((audiodev=SDL_getenv("SDL_PATH_DSP")) == NULL) { - audiodev=SDL_getenv("AUDIODEV"); - } - if ( audiodev == NULL ) { - return -1; - } - audio_fd = open(audiodev, flags, 0); - if ( path != NULL ) { - SDL_strlcpy(path, audiodev, maxlen); - path[maxlen-1] = '\0'; - } - return audio_fd; -} - -int SDL_OpenAudioPath(char *path, int maxlen, int flags, int classic) -{ - struct stat sb; - int audio_fd; - char audiopath[1024]; - int cycle; - - audio_fd = OpenUserDefinedDevice(path,maxlen,flags); - if ( audio_fd != -1 ) { - return audio_fd; - } - - cycle = 0; - while( devsettings[cycle][0] != '\0' ) { - SDL_snprintf( audiopath, SDL_arraysize(audiopath), - _PATH_DEV_DSP, - devsettings[cycle][0], - devsettings[cycle][1], - devsettings[cycle][2]); - - if ( stat(audiopath, &sb) == 0 ) { - audio_fd = open(audiopath, flags, 0); - if ( audio_fd > 0 ) { - if ( path != NULL ) { - SDL_strlcpy( path, audiopath, maxlen ); - } - return audio_fd; - } - } - } - return -1; -} - -#endif /* Audio driver selection */ diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audiodev_c.h b/distrib/sdl-1.2.12/src/audio/SDL_audiodev_c.h deleted file mode 100644 index 055fd65..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audiodev_c.h +++ /dev/null @@ -1,26 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Open the audio device, storing the pathname in 'path' */ -extern int SDL_OpenAudioPath(char *path, int maxlen, int flags, int classic); - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_audiomem.h b/distrib/sdl-1.2.12/src/audio/SDL_audiomem.h deleted file mode 100644 index 3d759eb..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_audiomem.h +++ /dev/null @@ -1,25 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#define SDL_AllocAudioMem SDL_malloc -#define SDL_FreeAudioMem SDL_free diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer.c b/distrib/sdl-1.2.12/src/audio/SDL_mixer.c deleted file mode 100644 index 5e07a07..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer.c +++ /dev/null @@ -1,258 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* This provides the default mixing callback for the SDL audio routines */ - -#include "SDL_cpuinfo.h" -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "SDL_sysaudio.h" -#include "SDL_mixer_MMX.h" -#include "SDL_mixer_MMX_VC.h" -#include "SDL_mixer_m68k.h" - -/* This table is used to add two sound values together and pin - * the value to avoid overflow. (used with permission from ARDI) - * Changed to use 0xFE instead of 0xFF for better sound quality. - */ -static const Uint8 mix8[] = -{ - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x03, - 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, - 0x0F, 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19, - 0x1A, 0x1B, 0x1C, 0x1D, 0x1E, 0x1F, 0x20, 0x21, 0x22, 0x23, 0x24, - 0x25, 0x26, 0x27, 0x28, 0x29, 0x2A, 0x2B, 0x2C, 0x2D, 0x2E, 0x2F, - 0x30, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x3A, - 0x3B, 0x3C, 0x3D, 0x3E, 0x3F, 0x40, 0x41, 0x42, 0x43, 0x44, 0x45, - 0x46, 0x47, 0x48, 0x49, 0x4A, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, - 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, 0x59, 0x5A, 0x5B, - 0x5C, 0x5D, 0x5E, 0x5F, 0x60, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, - 0x67, 0x68, 0x69, 0x6A, 0x6B, 0x6C, 0x6D, 0x6E, 0x6F, 0x70, 0x71, - 0x72, 0x73, 0x74, 0x75, 0x76, 0x77, 0x78, 0x79, 0x7A, 0x7B, 0x7C, - 0x7D, 0x7E, 0x7F, 0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, - 0x88, 0x89, 0x8A, 0x8B, 0x8C, 0x8D, 0x8E, 0x8F, 0x90, 0x91, 0x92, - 0x93, 0x94, 0x95, 0x96, 0x97, 0x98, 0x99, 0x9A, 0x9B, 0x9C, 0x9D, - 0x9E, 0x9F, 0xA0, 0xA1, 0xA2, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7, 0xA8, - 0xA9, 0xAA, 0xAB, 0xAC, 0xAD, 0xAE, 0xAF, 0xB0, 0xB1, 0xB2, 0xB3, - 0xB4, 0xB5, 0xB6, 0xB7, 0xB8, 0xB9, 0xBA, 0xBB, 0xBC, 0xBD, 0xBE, - 0xBF, 0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, 0xC8, 0xC9, - 0xCA, 0xCB, 0xCC, 0xCD, 0xCE, 0xCF, 0xD0, 0xD1, 0xD2, 0xD3, 0xD4, - 0xD5, 0xD6, 0xD7, 0xD8, 0xD9, 0xDA, 0xDB, 0xDC, 0xDD, 0xDE, 0xDF, - 0xE0, 0xE1, 0xE2, 0xE3, 0xE4, 0xE5, 0xE6, 0xE7, 0xE8, 0xE9, 0xEA, - 0xEB, 0xEC, 0xED, 0xEE, 0xEF, 0xF0, 0xF1, 0xF2, 0xF3, 0xF4, 0xF5, - 0xF6, 0xF7, 0xF8, 0xF9, 0xFA, 0xFB, 0xFC, 0xFD, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, - 0xFE, 0xFE, 0xFE, 0xFE, 0xFE, 0xFE -}; - -/* The volume ranges from 0 - 128 */ -#define ADJUST_VOLUME(s, v) (s = (s*v)/SDL_MIX_MAXVOLUME) -#define ADJUST_VOLUME_U8(s, v) (s = (((s-128)*v)/SDL_MIX_MAXVOLUME)+128) - -void SDL_MixAudio (Uint8 *dst, const Uint8 *src, Uint32 len, int volume) -{ - Uint16 format; - - if ( volume == 0 ) { - return; - } - /* Mix the user-level audio format */ - if ( current_audio ) { - if ( current_audio->convert.needed ) { - format = current_audio->convert.src_format; - } else { - format = current_audio->spec.format; - } - } else { - /* HACK HACK HACK */ - format = AUDIO_S16; - } - switch (format) { - - case AUDIO_U8: { -#if defined(__GNUC__) && defined(__M68000__) && defined(SDL_ASSEMBLY_ROUTINES) - SDL_MixAudio_m68k_U8((char*)dst,(char*)src,(unsigned long)len,(long)volume,(char *)mix8); -#else - Uint8 src_sample; - - while ( len-- ) { - src_sample = *src; - ADJUST_VOLUME_U8(src_sample, volume); - *dst = mix8[*dst+src_sample]; - ++dst; - ++src; - } -#endif - } - break; - - case AUDIO_S8: { -#if defined(__GNUC__) && defined(__i386__) && defined(SDL_ASSEMBLY_ROUTINES) - if (SDL_HasMMX()) - { - SDL_MixAudio_MMX_S8((char*)dst,(char*)src,(unsigned int)len,(int)volume); - } - else -#elif ((defined(_MSC_VER) && defined(_M_IX86)) || defined(__WATCOMC__)) && defined(SDL_ASSEMBLY_ROUTINES) - if (SDL_HasMMX()) - { - SDL_MixAudio_MMX_S8_VC((char*)dst,(char*)src,(unsigned int)len,(int)volume); - } - else -#endif -#if defined(__GNUC__) && defined(__M68000__) && defined(SDL_ASSEMBLY_ROUTINES) - SDL_MixAudio_m68k_S8((char*)dst,(char*)src,(unsigned long)len,(long)volume); -#else - { - Sint8 *dst8, *src8; - Sint8 src_sample; - int dst_sample; - const int max_audioval = ((1<<(8-1))-1); - const int min_audioval = -(1<<(8-1)); - - src8 = (Sint8 *)src; - dst8 = (Sint8 *)dst; - while ( len-- ) { - src_sample = *src8; - ADJUST_VOLUME(src_sample, volume); - dst_sample = *dst8 + src_sample; - if ( dst_sample > max_audioval ) { - *dst8 = max_audioval; - } else - if ( dst_sample < min_audioval ) { - *dst8 = min_audioval; - } else { - *dst8 = dst_sample; - } - ++dst8; - ++src8; - } - } -#endif - } - break; - - case AUDIO_S16LSB: { -#if defined(__GNUC__) && defined(__i386__) && defined(SDL_ASSEMBLY_ROUTINES) - if (SDL_HasMMX()) - { - SDL_MixAudio_MMX_S16((char*)dst,(char*)src,(unsigned int)len,(int)volume); - } - else -#elif ((defined(_MSC_VER) && defined(_M_IX86)) || defined(__WATCOMC__)) && defined(SDL_ASSEMBLY_ROUTINES) - if (SDL_HasMMX()) - { - SDL_MixAudio_MMX_S16_VC((char*)dst,(char*)src,(unsigned int)len,(int)volume); - } - else -#endif -#if defined(__GNUC__) && defined(__M68000__) && defined(SDL_ASSEMBLY_ROUTINES) - SDL_MixAudio_m68k_S16LSB((short*)dst,(short*)src,(unsigned long)len,(long)volume); -#else - { - Sint16 src1, src2; - int dst_sample; - const int max_audioval = ((1<<(16-1))-1); - const int min_audioval = -(1<<(16-1)); - - len /= 2; - while ( len-- ) { - src1 = ((src[1])<<8|src[0]); - ADJUST_VOLUME(src1, volume); - src2 = ((dst[1])<<8|dst[0]); - src += 2; - dst_sample = src1+src2; - if ( dst_sample > max_audioval ) { - dst_sample = max_audioval; - } else - if ( dst_sample < min_audioval ) { - dst_sample = min_audioval; - } - dst[0] = dst_sample&0xFF; - dst_sample >>= 8; - dst[1] = dst_sample&0xFF; - dst += 2; - } - } -#endif - } - break; - - case AUDIO_S16MSB: { -#if defined(__GNUC__) && defined(__M68000__) && defined(SDL_ASSEMBLY_ROUTINES) - SDL_MixAudio_m68k_S16MSB((short*)dst,(short*)src,(unsigned long)len,(long)volume); -#else - Sint16 src1, src2; - int dst_sample; - const int max_audioval = ((1<<(16-1))-1); - const int min_audioval = -(1<<(16-1)); - - len /= 2; - while ( len-- ) { - src1 = ((src[0])<<8|src[1]); - ADJUST_VOLUME(src1, volume); - src2 = ((dst[0])<<8|dst[1]); - src += 2; - dst_sample = src1+src2; - if ( dst_sample > max_audioval ) { - dst_sample = max_audioval; - } else - if ( dst_sample < min_audioval ) { - dst_sample = min_audioval; - } - dst[1] = dst_sample&0xFF; - dst_sample >>= 8; - dst[0] = dst_sample&0xFF; - dst += 2; - } -#endif - } - break; - - default: /* If this happens... FIXME! */ - SDL_SetError("SDL_MixAudio(): unknown audio format"); - return; - } -} - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.c b/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.c deleted file mode 100644 index 9d24ba0..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.c +++ /dev/null @@ -1,206 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MMX assembler version of SDL_MixAudio for signed little endian 16 bit samples and signed 8 bit samples - Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) - This code is licensed under the LGPL (see COPYING for details) - - Assumes buffer size in bytes is a multiple of 16 - Assumes SDL_MIX_MAXVOLUME = 128 -*/ - - -/*********************************************** -* Mixing for 16 bit signed buffers -***********************************************/ - -#if defined(__GNUC__) && defined(__i386__) && defined(SDL_ASSEMBLY_ROUTINES) -void SDL_MixAudio_MMX_S16(char* dst,char* src,unsigned int size,int volume) -{ - __asm__ __volatile__ ( - -" movl %3,%%eax\n" /* eax = volume */ - -" movl %2,%%edx\n" /* edx = size */ - -" shrl $4,%%edx\n" /* process 16 bytes per iteration = 8 samples */ - -" jz .endS16\n" - -" pxor %%mm0,%%mm0\n" - -" movd %%eax,%%mm0\n" -" movq %%mm0,%%mm1\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" /* mm0 = vol|vol|vol|vol */ - -".align 8\n" -" .mixloopS16:\n" - -" movq (%1),%%mm1\n" /* mm1 = a|b|c|d */ - -" movq %%mm1,%%mm2\n" /* mm2 = a|b|c|d */ - -" movq 8(%1),%%mm4\n" /* mm4 = e|f|g|h */ - - /* pré charger le buffer dst dans mm7 */ -" movq (%0),%%mm7\n" /* mm7 = dst[0] */ - - /* multiplier par le volume */ -" pmullw %%mm0,%%mm1\n" /* mm1 = l(a*v)|l(b*v)|l(c*v)|l(d*v) */ - -" pmulhw %%mm0,%%mm2\n" /* mm2 = h(a*v)|h(b*v)|h(c*v)|h(d*v) */ -" movq %%mm4,%%mm5\n" /* mm5 = e|f|g|h */ - -" pmullw %%mm0,%%mm4\n" /* mm4 = l(e*v)|l(f*v)|l(g*v)|l(h*v) */ - -" pmulhw %%mm0,%%mm5\n" /* mm5 = h(e*v)|h(f*v)|h(g*v)|h(h*v) */ -" movq %%mm1,%%mm3\n" /* mm3 = l(a*v)|l(b*v)|l(c*v)|l(d*v) */ - -" punpckhwd %%mm2,%%mm1\n" /* mm1 = a*v|b*v */ - -" movq %%mm4,%%mm6\n" /* mm6 = l(e*v)|l(f*v)|l(g*v)|l(h*v) */ -" punpcklwd %%mm2,%%mm3\n" /* mm3 = c*v|d*v */ - -" punpckhwd %%mm5,%%mm4\n" /* mm4 = e*f|f*v */ - -" punpcklwd %%mm5,%%mm6\n" /* mm6 = g*v|h*v */ - - /* pré charger le buffer dst dans mm5 */ -" movq 8(%0),%%mm5\n" /* mm5 = dst[1] */ - - /* diviser par 128 */ -" psrad $7,%%mm1\n" /* mm1 = a*v/128|b*v/128 , 128 = SDL_MIX_MAXVOLUME */ -" add $16,%1\n" - -" psrad $7,%%mm3\n" /* mm3 = c*v/128|d*v/128 */ - -" psrad $7,%%mm4\n" /* mm4 = e*v/128|f*v/128 */ - - /* mm1 = le sample avec le volume modifié */ -" packssdw %%mm1,%%mm3\n" /* mm3 = s(a*v|b*v|c*v|d*v) */ - -" psrad $7,%%mm6\n" /* mm6= g*v/128|h*v/128 */ -" paddsw %%mm7,%%mm3\n" /* mm3 = adjust_volume(src)+dst */ - - /* mm4 = le sample avec le volume modifié */ -" packssdw %%mm4,%%mm6\n" /* mm6 = s(e*v|f*v|g*v|h*v) */ -" movq %%mm3,(%0)\n" - -" paddsw %%mm5,%%mm6\n" /* mm6 = adjust_volume(src)+dst */ - -" movq %%mm6,8(%0)\n" - -" add $16,%0\n" - -" dec %%edx\n" - -" jnz .mixloopS16\n" - -" emms\n" - -".endS16:\n" - : - : "r" (dst), "r"(src),"m"(size), - "m"(volume) - : "eax","edx","memory" - ); -} - - - -/*////////////////////////////////////////////// */ -/* Mixing for 8 bit signed buffers */ -/*////////////////////////////////////////////// */ - -void SDL_MixAudio_MMX_S8(char* dst,char* src,unsigned int size,int volume) -{ - __asm__ __volatile__ ( - -" movl %3,%%eax\n" /* eax = volume */ - -" movd %%eax,%%mm0\n" -" movq %%mm0,%%mm1\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" -" psllq $16,%%mm0\n" -" por %%mm1,%%mm0\n" - -" movl %2,%%edx\n" /* edx = size */ -" shr $3,%%edx\n" /* process 8 bytes per iteration = 8 samples */ - -" cmp $0,%%edx\n" -" je .endS8\n" - -".align 8\n" -" .mixloopS8:\n" - -" pxor %%mm2,%%mm2\n" /* mm2 = 0 */ -" movq (%1),%%mm1\n" /* mm1 = a|b|c|d|e|f|g|h */ - -" movq %%mm1,%%mm3\n" /* mm3 = a|b|c|d|e|f|g|h */ - - /* on va faire le "sign extension" en faisant un cmp avec 0 qui retourne 1 si <0, 0 si >0 */ -" pcmpgtb %%mm1,%%mm2\n" /* mm2 = 11111111|00000000|00000000.... */ - -" punpckhbw %%mm2,%%mm1\n" /* mm1 = 0|a|0|b|0|c|0|d */ - -" punpcklbw %%mm2,%%mm3\n" /* mm3 = 0|e|0|f|0|g|0|h */ -" movq (%0),%%mm2\n" /* mm2 = destination */ - -" pmullw %%mm0,%%mm1\n" /* mm1 = v*a|v*b|v*c|v*d */ -" add $8,%1\n" - -" pmullw %%mm0,%%mm3\n" /* mm3 = v*e|v*f|v*g|v*h */ -" psraw $7,%%mm1\n" /* mm1 = v*a/128|v*b/128|v*c/128|v*d/128 */ - -" psraw $7,%%mm3\n" /* mm3 = v*e/128|v*f/128|v*g/128|v*h/128 */ - -" packsswb %%mm1,%%mm3\n" /* mm1 = v*a/128|v*b/128|v*c/128|v*d/128|v*e/128|v*f/128|v*g/128|v*h/128 */ - -" paddsb %%mm2,%%mm3\n" /* add to destination buffer */ - -" movq %%mm3,(%0)\n" /* store back to ram */ -" add $8,%0\n" - -" dec %%edx\n" - -" jnz .mixloopS8\n" - -".endS8:\n" -" emms\n" - : - : "r" (dst), "r"(src),"m"(size), - "m"(volume) - : "eax","edx","memory" - ); -} -#endif - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.h b/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.h deleted file mode 100644 index 5a62683..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX.h +++ /dev/null @@ -1,15 +0,0 @@ -/* - headers for MMX assembler version of SDL_MixAudio - Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) - This code is licensed under the LGPL (see COPYING for details) - - Assumes buffer size in bytes is a multiple of 16 - Assumes SDL_MIX_MAXVOLUME = 128 -*/ -#include "SDL_config.h" - -#if defined(__GNUC__) && defined(__i386__) && defined(SDL_ASSEMBLY_ROUTINES) -void SDL_MixAudio_MMX_S16(char* ,char* ,unsigned int ,int ); -void SDL_MixAudio_MMX_S8(char* ,char* ,unsigned int ,int ); -#endif - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.c b/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.c deleted file mode 100644 index 89b646a..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.c +++ /dev/null @@ -1,181 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#include "SDL_mixer_MMX_VC.h" - -#if ((defined(_MSC_VER) && defined(_M_IX86)) || defined(__WATCOMC__)) && defined(SDL_ASSEMBLY_ROUTINES) -// MMX assembler version of SDL_MixAudio for signed little endian 16 bit samples and signed 8 bit samples -// Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) -// Converted to Intel ASM notation by Cth -// This code is licensed under the LGPL (see COPYING for details) -// -// Assumes buffer size in bytes is a multiple of 16 -// Assumes SDL_MIX_MAXVOLUME = 128 - - -//////////////////////////////////////////////// -// Mixing for 16 bit signed buffers -//////////////////////////////////////////////// - -void SDL_MixAudio_MMX_S16_VC(char* dst,char* src,unsigned int nSize,int volume) -{ - __asm - { - - push edi - push esi - push ebx - - mov edi, dst // edi = dst - mov esi, src // esi = src - mov eax, volume // eax = volume - mov ebx, nSize // ebx = size - shr ebx, 4 // process 16 bytes per iteration = 8 samples - jz endS16 - - pxor mm0, mm0 - movd mm0, eax //%%eax,%%mm0 - movq mm1, mm0 //%%mm0,%%mm1 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 // mm0 = vol|vol|vol|vol - - #ifndef __WATCOMC__ - align 16 - #endif -mixloopS16: - movq mm1, [esi] //(%%esi),%%mm1\n" // mm1 = a|b|c|d - movq mm2, mm1 //%%mm1,%%mm2\n" // mm2 = a|b|c|d - movq mm4, [esi + 8] //8(%%esi),%%mm4\n" // mm4 = e|f|g|h - // pre charger le buffer dst dans mm7 - movq mm7, [edi] //(%%edi),%%mm7\n" // mm7 = dst[0]" - // multiplier par le volume - pmullw mm1, mm0 //%%mm0,%%mm1\n" // mm1 = l(a*v)|l(b*v)|l(c*v)|l(d*v) - pmulhw mm2, mm0 //%%mm0,%%mm2\n" // mm2 = h(a*v)|h(b*v)|h(c*v)|h(d*v) - movq mm5, mm4 //%%mm4,%%mm5\n" // mm5 = e|f|g|h - pmullw mm4, mm0 //%%mm0,%%mm4\n" // mm4 = l(e*v)|l(f*v)|l(g*v)|l(h*v) - pmulhw mm5, mm0 //%%mm0,%%mm5\n" // mm5 = h(e*v)|h(f*v)|h(g*v)|h(h*v) - movq mm3, mm1 //%%mm1,%%mm3\n" // mm3 = l(a*v)|l(b*v)|l(c*v)|l(d*v) - punpckhwd mm1, mm2 //%%mm2,%%mm1\n" // mm1 = a*v|b*v - movq mm6, mm4 //%%mm4,%%mm6\n" // mm6 = l(e*v)|l(f*v)|l(g*v)|l(h*v) - punpcklwd mm3, mm2 //%%mm2,%%mm3\n" // mm3 = c*v|d*v - punpckhwd mm4, mm5 //%%mm5,%%mm4\n" // mm4 = e*f|f*v - punpcklwd mm6, mm5 //%%mm5,%%mm6\n" // mm6 = g*v|h*v - // pre charger le buffer dst dans mm5 - movq mm5, [edi + 8] //8(%%edi),%%mm5\n" // mm5 = dst[1] - // diviser par 128 - psrad mm1, 7 //$7,%%mm1\n" // mm1 = a*v/128|b*v/128 , 128 = SDL_MIX_MAXVOLUME - add esi, 16 //$16,%%esi\n" - psrad mm3, 7 //$7,%%mm3\n" // mm3 = c*v/128|d*v/128 - psrad mm4, 7 //$7,%%mm4\n" // mm4 = e*v/128|f*v/128 - // mm1 = le sample avec le volume modifie - packssdw mm3, mm1 //%%mm1,%%mm3\n" // mm3 = s(a*v|b*v|c*v|d*v) - psrad mm6, 7 //$7,%%mm6\n" // mm6= g*v/128|h*v/128 - paddsw mm3, mm7 //%%mm7,%%mm3\n" // mm3 = adjust_volume(src)+dst - // mm4 = le sample avec le volume modifie - packssdw mm6, mm4 //%%mm4,%%mm6\n" // mm6 = s(e*v|f*v|g*v|h*v) - movq [edi], mm3 //%%mm3,(%%edi)\n" - paddsw mm6, mm5 //%%mm5,%%mm6\n" // mm6 = adjust_volume(src)+dst - movq [edi + 8], mm6 //%%mm6,8(%%edi)\n" - add edi, 16 //$16,%%edi\n" - dec ebx //%%ebx\n" - jnz mixloopS16 - -ends16: - emms - - pop ebx - pop esi - pop edi - } - -} - -//////////////////////////////////////////////// -// Mixing for 8 bit signed buffers -//////////////////////////////////////////////// - -void SDL_MixAudio_MMX_S8_VC(char* dst,char* src,unsigned int nSize,int volume) -{ - _asm - { - - push edi - push esi - push ebx - - mov edi, dst //movl %0,%%edi // edi = dst - mov esi, src //%1,%%esi // esi = src - mov eax, volume //%3,%%eax // eax = volume - - movd mm0, eax //%%eax,%%mm0 - movq mm1, mm0 //%%mm0,%%mm1 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 - psllq mm0, 16 //$16,%%mm0 - por mm0, mm1 //%%mm1,%%mm0 - - mov ebx, nSize //%2,%%ebx // ebx = size - shr ebx, 3 //$3,%%ebx // process 8 bytes per iteration = 8 samples - cmp ebx, 0 //$0,%%ebx - je endS8 - - #ifndef __WATCOMC__ - align 16 - #endif -mixloopS8: - pxor mm2, mm2 //%%mm2,%%mm2 // mm2 = 0 - movq mm1, [esi] //(%%esi),%%mm1 // mm1 = a|b|c|d|e|f|g|h - movq mm3, mm1 //%%mm1,%%mm3 // mm3 = a|b|c|d|e|f|g|h - // on va faire le "sign extension" en faisant un cmp avec 0 qui retourne 1 si <0, 0 si >0 - pcmpgtb mm2, mm1 //%%mm1,%%mm2 // mm2 = 11111111|00000000|00000000.... - punpckhbw mm1, mm2 //%%mm2,%%mm1 // mm1 = 0|a|0|b|0|c|0|d - punpcklbw mm3, mm2 //%%mm2,%%mm3 // mm3 = 0|e|0|f|0|g|0|h - movq mm2, [edi] //(%%edi),%%mm2 // mm2 = destination - pmullw mm1, mm0 //%%mm0,%%mm1 // mm1 = v*a|v*b|v*c|v*d - add esi, 8 //$8,%%esi - pmullw mm3, mm0 //%%mm0,%%mm3 // mm3 = v*e|v*f|v*g|v*h - psraw mm1, 7 //$7,%%mm1 // mm1 = v*a/128|v*b/128|v*c/128|v*d/128 - psraw mm3, 7 //$7,%%mm3 // mm3 = v*e/128|v*f/128|v*g/128|v*h/128 - packsswb mm3, mm1 //%%mm1,%%mm3 // mm1 = v*a/128|v*b/128|v*c/128|v*d/128|v*e/128|v*f/128|v*g/128|v*h/128 - paddsb mm3, mm2 //%%mm2,%%mm3 // add to destination buffer - movq [edi], mm3 //%%mm3,(%%edi) // store back to ram - add edi, 8 //$8,%%edi - dec ebx //%%ebx - jnz mixloopS8 - -endS8: - emms - - pop ebx - pop esi - pop edi - } -} - -#endif /* SDL_ASSEMBLY_ROUTINES */ diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.h b/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.h deleted file mode 100644 index bfe02a9..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_MMX_VC.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - - -#if ((defined(_MSC_VER) && defined(_M_IX86)) || defined(__WATCOMC__)) && defined(SDL_ASSEMBLY_ROUTINES) -/* headers for MMX assembler version of SDL_MixAudio - Copyright 2002 Stephane Marchesin (stephane.marchesin@wanadoo.fr) - Converted to Intel ASM notation by Cth - This code is licensed under the LGPL (see COPYING for details) - - Assumes buffer size in bytes is a multiple of 16 - Assumes SDL_MIX_MAXVOLUME = 128 -*/ -void SDL_MixAudio_MMX_S16_VC(char* ,char* ,unsigned int ,int ); -void SDL_MixAudio_MMX_S8_VC(char* ,char* ,unsigned int ,int ); -#endif diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.c b/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.c deleted file mode 100644 index f8786da..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.c +++ /dev/null @@ -1,211 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - m68k assembly mix routines - - Patrice Mandin -*/ - -#if defined(__M68000__) && defined(__GNUC__) -void SDL_MixAudio_m68k_U8(char* dst, char* src, long len, long volume, char* mix8) -{ - __asm__ __volatile__ ( - - "tstl %2\n" -" beqs stoploop_u8\n" -"mixloop_u8:\n" - - /* Mix a sample */ - -" moveq #0,%%d0\n" -" moveq #0,%%d1\n" - -" moveb %1@+,%%d0\n" /* d0 = *src++ */ -" sub #128,%%d0\n" /* d0 -= 128 */ -" muls %3,%%d0\n" /* d0 *= volume (0<=volume<=128) */ -" moveb %0@,%%d1\n" /* d1 = *dst */ -" asr #7,%%d0\n" /* d0 /= 128 (SDL_MIX_MAXVOLUME) */ -" add #128,%%d0\n" /* d0 += 128 */ - -" add %%d1,%%d0\n" - -" moveb %4@(%%d0:w),%0@+\n" - - /* Loop till done */ - -" subql #1,%2\n" -" bhis mixloop_u8\n" -"stoploop_u8:\n" - - : /* no return value */ - : /* input */ - "a"(dst), "a"(src), "d"(len), "d"(volume), "a"(mix8) - : /* clobbered registers */ - "d0", "d1", "cc", "memory" - ); -} - -void SDL_MixAudio_m68k_S8(char* dst, char* src, long len, long volume) -{ - __asm__ __volatile__ ( - - "tstl %2\n" -" beqs stoploop_s8\n" -" moveq #-128,%%d2\n" -" moveq #127,%%d3\n" -"mixloop_s8:\n" - - /* Mix a sample */ - -" moveq #0,%%d0\n" -" moveq #0,%%d1\n" - -" moveb %1@+,%%d0\n" /* d0 = *src++ */ -" muls %3,%%d0\n" /* d0 *= volume (0<=volume<=128) */ -" moveb %0@,%%d1\n" /* d1 = *dst */ -" asr #7,%%d0\n" /* d0 /= 128 (SDL_MIX_MAXVOLUME) */ - -" add %%d1,%%d0\n" - -" cmp %%d2,%%d0\n" -" bges lower_limit_s8\n" -" move %%d2,%%d0\n" -"lower_limit_s8:\n" - -" cmp %%d3,%%d0\n" -" bles upper_limit_s8\n" -" move %%d3,%%d0\n" -"upper_limit_s8:\n" -" moveb %%d0,%0@+\n" - - /* Loop till done */ - -" subql #1,%2\n" -" bhis mixloop_s8\n" -"stoploop_s8:\n" - - : /* no return value */ - : /* input */ - "a"(dst), "a"(src), "d"(len), "d"(volume) - : /* clobbered registers */ - "d0", "d1", "d2", "d3", "cc", "memory" - ); -} - -void SDL_MixAudio_m68k_S16MSB(short* dst, short* src, long len, long volume) -{ - __asm__ __volatile__ ( - - "tstl %2\n" -" beqs stoploop_s16msb\n" -" movel #-32768,%%d2\n" -" movel #32767,%%d3\n" -" lsrl #1,%2\n" -"mixloop_s16msb:\n" - - /* Mix a sample */ - -" move %1@+,%%d0\n" /* d0 = *src++ */ -" muls %3,%%d0\n" /* d0 *= volume (0<=volume<=128) */ -" move %0@,%%d1\n" /* d1 = *dst */ -" extl %%d1\n" /* extend d1 to 32 bits */ -" asrl #7,%%d0\n" /* d0 /= 128 (SDL_MIX_MAXVOLUME) */ - -" addl %%d1,%%d0\n" - -" cmpl %%d2,%%d0\n" -" bges lower_limit_s16msb\n" -" move %%d2,%%d0\n" -"lower_limit_s16msb:\n" - -" cmpl %%d3,%%d0\n" -" bles upper_limit_s16msb\n" -" move %%d3,%%d0\n" -"upper_limit_s16msb:\n" -" move %%d0,%0@+\n" - - /* Loop till done */ - -" subql #1,%2\n" -" bhis mixloop_s16msb\n" -"stoploop_s16msb:\n" - - : /* no return value */ - : /* input */ - "a"(dst), "a"(src), "d"(len), "d"(volume) - : /* clobbered registers */ - "d0", "d1", "d2", "d3", "cc", "memory" - ); -} - -void SDL_MixAudio_m68k_S16LSB(short* dst, short* src, long len, long volume) -{ - __asm__ __volatile__ ( - - "tstl %2\n" -" beqs stoploop_s16lsb\n" -" movel #-32768,%%d2\n" -" movel #32767,%%d3\n" -" lsrl #1,%2\n" -"mixloop_s16lsb:\n" - - /* Mix a sample */ - -" move %1@+,%%d0\n" /* d0 = *src++ */ -" rorw #8,%%d0\n" -" muls %3,%%d0\n" /* d0 *= volume (0<=volume<=128) */ -" move %0@,%%d1\n" /* d1 = *dst */ -" rorw #8,%%d1\n" -" extl %%d1\n" /* extend d1 to 32 bits */ -" asrl #7,%%d0\n" /* d0 /= 128 (SDL_MIX_MAXVOLUME) */ - -" addl %%d1,%%d0\n" - -" cmpl %%d2,%%d0\n" -" bges lower_limit_s16lsb\n" -" move %%d2,%%d0\n" -"lower_limit_s16lsb:\n" - -" cmpl %%d3,%%d0\n" -" bles upper_limit_s16lsb\n" -" move %%d3,%%d0\n" -"upper_limit_s16lsb:\n" -" rorw #8,%%d0\n" -" move %%d0,%0@+\n" - - /* Loop till done */ - -" subql #1,%2\n" -" bhis mixloop_s16lsb\n" -"stoploop_s16lsb:\n" - - : /* no return value */ - : /* input */ - "a"(dst), "a"(src), "d"(len), "d"(volume) - : /* clobbered registers */ - "d0", "d1", "d2", "d3", "cc", "memory" - ); -} -#endif - diff --git a/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.h b/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.h deleted file mode 100644 index d451dc4..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_mixer_m68k.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - m68k assembly mix routines - - Patrice Mandin -*/ - -#if defined(__M68000__) && defined(__GNUC__) -void SDL_MixAudio_m68k_U8(char* dst,char* src, long len, long volume, char* mix8); -void SDL_MixAudio_m68k_S8(char* dst,char* src, long len, long volume); - -void SDL_MixAudio_m68k_S16MSB(short* dst,short* src, long len, long volume); -void SDL_MixAudio_m68k_S16LSB(short* dst,short* src, long len, long volume); -#endif diff --git a/distrib/sdl-1.2.12/src/audio/SDL_sysaudio.h b/distrib/sdl-1.2.12/src/audio/SDL_sysaudio.h deleted file mode 100644 index 1fc920a..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_sysaudio.h +++ /dev/null @@ -1,184 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is SDL_free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_sysaudio_h -#define _SDL_sysaudio_h - -#include "SDL_mutex.h" -#include "SDL_thread.h" - -/* The SDL audio driver */ -typedef struct SDL_AudioDevice SDL_AudioDevice; - -/* Define the SDL audio driver structure */ -#define _THIS SDL_AudioDevice *_this -#ifndef _STATUS -#define _STATUS SDL_status *status -#endif -struct SDL_AudioDevice { - /* * * */ - /* The name of this audio driver */ - const char *name; - - /* * * */ - /* The description of this audio driver */ - const char *desc; - - /* * * */ - /* Public driver functions */ - int (*OpenAudio)(_THIS, SDL_AudioSpec *spec); - void (*ThreadInit)(_THIS); /* Called by audio thread at start */ - void (*WaitAudio)(_THIS); - void (*PlayAudio)(_THIS); - Uint8 *(*GetAudioBuf)(_THIS); - void (*WaitDone)(_THIS); - void (*CloseAudio)(_THIS); - - /* * * */ - /* Lock / Unlock functions added for the Mac port */ - void (*LockAudio)(_THIS); - void (*UnlockAudio)(_THIS); - - /* * * */ - /* Data common to all devices */ - - /* The current audio specification (shared with audio thread) */ - SDL_AudioSpec spec; - - /* An audio conversion block for audio format emulation */ - SDL_AudioCVT convert; - - /* Current state flags */ - int enabled; - int paused; - int opened; - - /* Fake audio buffer for when the audio hardware is busy */ - Uint8 *fake_stream; - - /* A semaphore for locking the mixing buffers */ - SDL_mutex *mixer_lock; - - /* A thread to feed the audio device */ - SDL_Thread *thread; - Uint32 threadid; - - /* * * */ - /* Data private to this driver */ - struct SDL_PrivateAudioData *hidden; - - /* * * */ - /* The function used to dispose of this structure */ - void (*free)(_THIS); -}; -#undef _THIS - -typedef struct AudioBootStrap { - const char *name; - const char *desc; - int (*available)(void); - SDL_AudioDevice *(*create)(int devindex); -} AudioBootStrap; - -#if SDL_AUDIO_DRIVER_BSD -extern AudioBootStrap BSD_AUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_PULSE -extern AudioBootStrap PULSE_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_OSS -extern AudioBootStrap DSP_bootstrap; -extern AudioBootStrap DMA_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_ALSA -extern AudioBootStrap ALSA_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_QNXNTO -extern AudioBootStrap QNXNTOAUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_SUNAUDIO -extern AudioBootStrap SUNAUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DMEDIA -extern AudioBootStrap DMEDIA_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_ARTS -extern AudioBootStrap ARTS_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_ESD -extern AudioBootStrap ESD_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_NAS -extern AudioBootStrap NAS_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DSOUND -extern AudioBootStrap DSOUND_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_WAVEOUT -extern AudioBootStrap WAVEOUT_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_PAUD -extern AudioBootStrap Paud_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_BAUDIO -extern AudioBootStrap BAUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_COREAUDIO -extern AudioBootStrap COREAUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_SNDMGR -extern AudioBootStrap SNDMGR_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_MINT -extern AudioBootStrap MINTAUDIO_GSXB_bootstrap; -extern AudioBootStrap MINTAUDIO_MCSN_bootstrap; -extern AudioBootStrap MINTAUDIO_STFA_bootstrap; -extern AudioBootStrap MINTAUDIO_XBIOS_bootstrap; -extern AudioBootStrap MINTAUDIO_DMA8_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DISK -extern AudioBootStrap DISKAUD_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DUMMY -extern AudioBootStrap DUMMYAUD_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DC -extern AudioBootStrap DCAUD_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_NDS -extern AudioBootStrap NDSAUD_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_MMEAUDIO -extern AudioBootStrap MMEAUDIO_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_DART -extern AudioBootStrap DART_bootstrap; -#endif -#if SDL_AUDIO_DRIVER_EPOCAUDIO -extern AudioBootStrap EPOCAudio_bootstrap; -#endif - -/* This is the current audio device */ -extern SDL_AudioDevice *current_audio; - -#endif /* _SDL_sysaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/SDL_wave.c b/distrib/sdl-1.2.12/src/audio/SDL_wave.c deleted file mode 100644 index 465195e..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_wave.c +++ /dev/null @@ -1,597 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Microsoft WAVE file loading routines */ - -#include "SDL_audio.h" -#include "SDL_wave.h" - - -static int ReadChunk(SDL_RWops *src, Chunk *chunk); - -struct MS_ADPCM_decodestate { - Uint8 hPredictor; - Uint16 iDelta; - Sint16 iSamp1; - Sint16 iSamp2; -}; -static struct MS_ADPCM_decoder { - WaveFMT wavefmt; - Uint16 wSamplesPerBlock; - Uint16 wNumCoef; - Sint16 aCoeff[7][2]; - /* * * */ - struct MS_ADPCM_decodestate state[2]; -} MS_ADPCM_state; - -static int InitMS_ADPCM(WaveFMT *format) -{ - Uint8 *rogue_feel; - Uint16 extra_info; - int i; - - /* Set the rogue pointer to the MS_ADPCM specific data */ - MS_ADPCM_state.wavefmt.encoding = SDL_SwapLE16(format->encoding); - MS_ADPCM_state.wavefmt.channels = SDL_SwapLE16(format->channels); - MS_ADPCM_state.wavefmt.frequency = SDL_SwapLE32(format->frequency); - MS_ADPCM_state.wavefmt.byterate = SDL_SwapLE32(format->byterate); - MS_ADPCM_state.wavefmt.blockalign = SDL_SwapLE16(format->blockalign); - MS_ADPCM_state.wavefmt.bitspersample = - SDL_SwapLE16(format->bitspersample); - rogue_feel = (Uint8 *)format+sizeof(*format); - if ( sizeof(*format) == 16 ) { - extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]); - rogue_feel += sizeof(Uint16); - } - MS_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]); - rogue_feel += sizeof(Uint16); - MS_ADPCM_state.wNumCoef = ((rogue_feel[1]<<8)|rogue_feel[0]); - rogue_feel += sizeof(Uint16); - if ( MS_ADPCM_state.wNumCoef != 7 ) { - SDL_SetError("Unknown set of MS_ADPCM coefficients"); - return(-1); - } - for ( i=0; iiSamp1 * coeff[0]) + - (state->iSamp2 * coeff[1]))/256; - if ( nybble & 0x08 ) { - new_sample += state->iDelta * (nybble-0x10); - } else { - new_sample += state->iDelta * nybble; - } - if ( new_sample < min_audioval ) { - new_sample = min_audioval; - } else - if ( new_sample > max_audioval ) { - new_sample = max_audioval; - } - delta = ((Sint32)state->iDelta * adaptive[nybble])/256; - if ( delta < 16 ) { - delta = 16; - } - state->iDelta = (Uint16)delta; - state->iSamp2 = state->iSamp1; - state->iSamp1 = (Sint16)new_sample; - return(new_sample); -} - -static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 *audio_len) -{ - struct MS_ADPCM_decodestate *state[2]; - Uint8 *freeable, *encoded, *decoded; - Sint32 encoded_len, samplesleft; - Sint8 nybble, stereo; - Sint16 *coeff[2]; - Sint32 new_sample; - - /* Allocate the proper sized output buffer */ - encoded_len = *audio_len; - encoded = *audio_buf; - freeable = *audio_buf; - *audio_len = (encoded_len/MS_ADPCM_state.wavefmt.blockalign) * - MS_ADPCM_state.wSamplesPerBlock* - MS_ADPCM_state.wavefmt.channels*sizeof(Sint16); - *audio_buf = (Uint8 *)SDL_malloc(*audio_len); - if ( *audio_buf == NULL ) { - SDL_Error(SDL_ENOMEM); - return(-1); - } - decoded = *audio_buf; - - /* Get ready... Go! */ - stereo = (MS_ADPCM_state.wavefmt.channels == 2); - state[0] = &MS_ADPCM_state.state[0]; - state[1] = &MS_ADPCM_state.state[stereo]; - while ( encoded_len >= MS_ADPCM_state.wavefmt.blockalign ) { - /* Grab the initial information for this block */ - state[0]->hPredictor = *encoded++; - if ( stereo ) { - state[1]->hPredictor = *encoded++; - } - state[0]->iDelta = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - if ( stereo ) { - state[1]->iDelta = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - } - state[0]->iSamp1 = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - if ( stereo ) { - state[1]->iSamp1 = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - } - state[0]->iSamp2 = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - if ( stereo ) { - state[1]->iSamp2 = ((encoded[1]<<8)|encoded[0]); - encoded += sizeof(Sint16); - } - coeff[0] = MS_ADPCM_state.aCoeff[state[0]->hPredictor]; - coeff[1] = MS_ADPCM_state.aCoeff[state[1]->hPredictor]; - - /* Store the two initial samples we start with */ - decoded[0] = state[0]->iSamp2&0xFF; - decoded[1] = state[0]->iSamp2>>8; - decoded += 2; - if ( stereo ) { - decoded[0] = state[1]->iSamp2&0xFF; - decoded[1] = state[1]->iSamp2>>8; - decoded += 2; - } - decoded[0] = state[0]->iSamp1&0xFF; - decoded[1] = state[0]->iSamp1>>8; - decoded += 2; - if ( stereo ) { - decoded[0] = state[1]->iSamp1&0xFF; - decoded[1] = state[1]->iSamp1>>8; - decoded += 2; - } - - /* Decode and store the other samples in this block */ - samplesleft = (MS_ADPCM_state.wSamplesPerBlock-2)* - MS_ADPCM_state.wavefmt.channels; - while ( samplesleft > 0 ) { - nybble = (*encoded)>>4; - new_sample = MS_ADPCM_nibble(state[0],nybble,coeff[0]); - decoded[0] = new_sample&0xFF; - new_sample >>= 8; - decoded[1] = new_sample&0xFF; - decoded += 2; - - nybble = (*encoded)&0x0F; - new_sample = MS_ADPCM_nibble(state[1],nybble,coeff[1]); - decoded[0] = new_sample&0xFF; - new_sample >>= 8; - decoded[1] = new_sample&0xFF; - decoded += 2; - - ++encoded; - samplesleft -= 2; - } - encoded_len -= MS_ADPCM_state.wavefmt.blockalign; - } - SDL_free(freeable); - return(0); -} - -struct IMA_ADPCM_decodestate { - Sint32 sample; - Sint8 index; -}; -static struct IMA_ADPCM_decoder { - WaveFMT wavefmt; - Uint16 wSamplesPerBlock; - /* * * */ - struct IMA_ADPCM_decodestate state[2]; -} IMA_ADPCM_state; - -static int InitIMA_ADPCM(WaveFMT *format) -{ - Uint8 *rogue_feel; - Uint16 extra_info; - - /* Set the rogue pointer to the IMA_ADPCM specific data */ - IMA_ADPCM_state.wavefmt.encoding = SDL_SwapLE16(format->encoding); - IMA_ADPCM_state.wavefmt.channels = SDL_SwapLE16(format->channels); - IMA_ADPCM_state.wavefmt.frequency = SDL_SwapLE32(format->frequency); - IMA_ADPCM_state.wavefmt.byterate = SDL_SwapLE32(format->byterate); - IMA_ADPCM_state.wavefmt.blockalign = SDL_SwapLE16(format->blockalign); - IMA_ADPCM_state.wavefmt.bitspersample = - SDL_SwapLE16(format->bitspersample); - rogue_feel = (Uint8 *)format+sizeof(*format); - if ( sizeof(*format) == 16 ) { - extra_info = ((rogue_feel[1]<<8)|rogue_feel[0]); - rogue_feel += sizeof(Uint16); - } - IMA_ADPCM_state.wSamplesPerBlock = ((rogue_feel[1]<<8)|rogue_feel[0]); - return(0); -} - -static Sint32 IMA_ADPCM_nibble(struct IMA_ADPCM_decodestate *state,Uint8 nybble) -{ - const Sint32 max_audioval = ((1<<(16-1))-1); - const Sint32 min_audioval = -(1<<(16-1)); - const int index_table[16] = { - -1, -1, -1, -1, - 2, 4, 6, 8, - -1, -1, -1, -1, - 2, 4, 6, 8 - }; - const Sint32 step_table[89] = { - 7, 8, 9, 10, 11, 12, 13, 14, 16, 17, 19, 21, 23, 25, 28, 31, - 34, 37, 41, 45, 50, 55, 60, 66, 73, 80, 88, 97, 107, 118, 130, - 143, 157, 173, 190, 209, 230, 253, 279, 307, 337, 371, 408, - 449, 494, 544, 598, 658, 724, 796, 876, 963, 1060, 1166, 1282, - 1411, 1552, 1707, 1878, 2066, 2272, 2499, 2749, 3024, 3327, - 3660, 4026, 4428, 4871, 5358, 5894, 6484, 7132, 7845, 8630, - 9493, 10442, 11487, 12635, 13899, 15289, 16818, 18500, 20350, - 22385, 24623, 27086, 29794, 32767 - }; - Sint32 delta, step; - - /* Compute difference and new sample value */ - step = step_table[state->index]; - delta = step >> 3; - if ( nybble & 0x04 ) delta += step; - if ( nybble & 0x02 ) delta += (step >> 1); - if ( nybble & 0x01 ) delta += (step >> 2); - if ( nybble & 0x08 ) delta = -delta; - state->sample += delta; - - /* Update index value */ - state->index += index_table[nybble]; - if ( state->index > 88 ) { - state->index = 88; - } else - if ( state->index < 0 ) { - state->index = 0; - } - - /* Clamp output sample */ - if ( state->sample > max_audioval ) { - state->sample = max_audioval; - } else - if ( state->sample < min_audioval ) { - state->sample = min_audioval; - } - return(state->sample); -} - -/* Fill the decode buffer with a channel block of data (8 samples) */ -static void Fill_IMA_ADPCM_block(Uint8 *decoded, Uint8 *encoded, - int channel, int numchannels, struct IMA_ADPCM_decodestate *state) -{ - int i; - Sint8 nybble; - Sint32 new_sample; - - decoded += (channel * 2); - for ( i=0; i<4; ++i ) { - nybble = (*encoded)&0x0F; - new_sample = IMA_ADPCM_nibble(state, nybble); - decoded[0] = new_sample&0xFF; - new_sample >>= 8; - decoded[1] = new_sample&0xFF; - decoded += 2 * numchannels; - - nybble = (*encoded)>>4; - new_sample = IMA_ADPCM_nibble(state, nybble); - decoded[0] = new_sample&0xFF; - new_sample >>= 8; - decoded[1] = new_sample&0xFF; - decoded += 2 * numchannels; - - ++encoded; - } -} - -static int IMA_ADPCM_decode(Uint8 **audio_buf, Uint32 *audio_len) -{ - struct IMA_ADPCM_decodestate *state; - Uint8 *freeable, *encoded, *decoded; - Sint32 encoded_len, samplesleft; - unsigned int c, channels; - - /* Check to make sure we have enough variables in the state array */ - channels = IMA_ADPCM_state.wavefmt.channels; - if ( channels > SDL_arraysize(IMA_ADPCM_state.state) ) { - SDL_SetError("IMA ADPCM decoder can only handle %d channels", - SDL_arraysize(IMA_ADPCM_state.state)); - return(-1); - } - state = IMA_ADPCM_state.state; - - /* Allocate the proper sized output buffer */ - encoded_len = *audio_len; - encoded = *audio_buf; - freeable = *audio_buf; - *audio_len = (encoded_len/IMA_ADPCM_state.wavefmt.blockalign) * - IMA_ADPCM_state.wSamplesPerBlock* - IMA_ADPCM_state.wavefmt.channels*sizeof(Sint16); - *audio_buf = (Uint8 *)SDL_malloc(*audio_len); - if ( *audio_buf == NULL ) { - SDL_Error(SDL_ENOMEM); - return(-1); - } - decoded = *audio_buf; - - /* Get ready... Go! */ - while ( encoded_len >= IMA_ADPCM_state.wavefmt.blockalign ) { - /* Grab the initial information for this block */ - for ( c=0; c>8); - decoded += 2; - } - - /* Decode and store the other samples in this block */ - samplesleft = (IMA_ADPCM_state.wSamplesPerBlock-1)*channels; - while ( samplesleft > 0 ) { - for ( c=0; cencoding)) { - case PCM_CODE: - /* We can understand this */ - break; - case MS_ADPCM_CODE: - /* Try to understand this */ - if ( InitMS_ADPCM(format) < 0 ) { - was_error = 1; - goto done; - } - MS_ADPCM_encoded = 1; - break; - case IMA_ADPCM_CODE: - /* Try to understand this */ - if ( InitIMA_ADPCM(format) < 0 ) { - was_error = 1; - goto done; - } - IMA_ADPCM_encoded = 1; - break; - case MP3_CODE: - SDL_SetError("MPEG Layer 3 data not supported", - SDL_SwapLE16(format->encoding)); - was_error = 1; - goto done; - default: - SDL_SetError("Unknown WAVE data format: 0x%.4x", - SDL_SwapLE16(format->encoding)); - was_error = 1; - goto done; - } - SDL_memset(spec, 0, (sizeof *spec)); - spec->freq = SDL_SwapLE32(format->frequency); - switch (SDL_SwapLE16(format->bitspersample)) { - case 4: - if ( MS_ADPCM_encoded || IMA_ADPCM_encoded ) { - spec->format = AUDIO_S16; - } else { - was_error = 1; - } - break; - case 8: - spec->format = AUDIO_U8; - break; - case 16: - spec->format = AUDIO_S16; - break; - default: - was_error = 1; - break; - } - if ( was_error ) { - SDL_SetError("Unknown %d-bit PCM data format", - SDL_SwapLE16(format->bitspersample)); - goto done; - } - spec->channels = (Uint8)SDL_SwapLE16(format->channels); - spec->samples = 4096; /* Good default buffer size */ - - /* Read the audio data chunk */ - *audio_buf = NULL; - do { - if ( *audio_buf != NULL ) { - SDL_free(*audio_buf); - } - lenread = ReadChunk(src, &chunk); - if ( lenread < 0 ) { - was_error = 1; - goto done; - } - *audio_len = lenread; - *audio_buf = chunk.data; - if(chunk.magic != DATA) headerDiff += lenread + 2 * sizeof(Uint32); - } while ( chunk.magic != DATA ); - headerDiff += 2 * sizeof(Uint32); /* for the data chunk and len */ - - if ( MS_ADPCM_encoded ) { - if ( MS_ADPCM_decode(audio_buf, audio_len) < 0 ) { - was_error = 1; - goto done; - } - } - if ( IMA_ADPCM_encoded ) { - if ( IMA_ADPCM_decode(audio_buf, audio_len) < 0 ) { - was_error = 1; - goto done; - } - } - - /* Don't return a buffer that isn't a multiple of samplesize */ - samplesize = ((spec->format & 0xFF)/8)*spec->channels; - *audio_len &= ~(samplesize-1); - -done: - if ( format != NULL ) { - SDL_free(format); - } - if ( src ) { - if ( freesrc ) { - SDL_RWclose(src); - } else { - /* seek to the end of the file (given by the RIFF chunk) */ - SDL_RWseek(src, wavelen - chunk.length - headerDiff, RW_SEEK_CUR); - } - } - if ( was_error ) { - spec = NULL; - } - return(spec); -} - -/* Since the WAV memory is allocated in the shared library, it must also - be freed here. (Necessary under Win32, VC++) - */ -void SDL_FreeWAV(Uint8 *audio_buf) -{ - if ( audio_buf != NULL ) { - SDL_free(audio_buf); - } -} - -static int ReadChunk(SDL_RWops *src, Chunk *chunk) -{ - chunk->magic = SDL_ReadLE32(src); - chunk->length = SDL_ReadLE32(src); - chunk->data = (Uint8 *)SDL_malloc(chunk->length); - if ( chunk->data == NULL ) { - SDL_Error(SDL_ENOMEM); - return(-1); - } - if ( SDL_RWread(src, chunk->data, chunk->length, 1) != 1 ) { - SDL_Error(SDL_EFREAD); - SDL_free(chunk->data); - return(-1); - } - return(chunk->length); -} diff --git a/distrib/sdl-1.2.12/src/audio/SDL_wave.h b/distrib/sdl-1.2.12/src/audio/SDL_wave.h deleted file mode 100644 index a0af6eb..0000000 --- a/distrib/sdl-1.2.12/src/audio/SDL_wave.h +++ /dev/null @@ -1,62 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is SDL_free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* WAVE files are little-endian */ - -/*******************************************/ -/* Define values for Microsoft WAVE format */ -/*******************************************/ -#define RIFF 0x46464952 /* "RIFF" */ -#define WAVE 0x45564157 /* "WAVE" */ -#define FACT 0x74636166 /* "fact" */ -#define LIST 0x5453494c /* "LIST" */ -#define FMT 0x20746D66 /* "fmt " */ -#define DATA 0x61746164 /* "data" */ -#define PCM_CODE 0x0001 -#define MS_ADPCM_CODE 0x0002 -#define IMA_ADPCM_CODE 0x0011 -#define MP3_CODE 0x0055 -#define WAVE_MONO 1 -#define WAVE_STEREO 2 - -/* Normally, these three chunks come consecutively in a WAVE file */ -typedef struct WaveFMT { -/* Not saved in the chunk we read: - Uint32 FMTchunk; - Uint32 fmtlen; -*/ - Uint16 encoding; - Uint16 channels; /* 1 = mono, 2 = stereo */ - Uint32 frequency; /* One of 11025, 22050, or 44100 Hz */ - Uint32 byterate; /* Average bytes per second */ - Uint16 blockalign; /* Bytes per sample block */ - Uint16 bitspersample; /* One of 8, 12, 16, or 4 for ADPCM */ -} WaveFMT; - -/* The general chunk found in the WAVE file */ -typedef struct Chunk { - Uint32 magic; - Uint32 length; - Uint8 *data; -} Chunk; - diff --git a/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.c b/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.c deleted file mode 100644 index a5138d1..0000000 --- a/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.c +++ /dev/null @@ -1,538 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include -#include /* For kill() */ - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "SDL_alsa_audio.h" - -#ifdef SDL_AUDIO_DRIVER_ALSA_DYNAMIC -#include -#include "SDL_name.h" -#include "SDL_loadso.h" -#else -#define SDL_NAME(X) X -#endif - - -/* The tag name used by ALSA audio */ -#define DRIVER_NAME "alsa" - -/* The default ALSA audio driver */ -#define DEFAULT_DEVICE "default" - -/* Audio driver functions */ -static int ALSA_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void ALSA_WaitAudio(_THIS); -static void ALSA_PlayAudio(_THIS); -static Uint8 *ALSA_GetAudioBuf(_THIS); -static void ALSA_CloseAudio(_THIS); - -#ifdef SDL_AUDIO_DRIVER_ALSA_DYNAMIC - -static const char *alsa_library = SDL_AUDIO_DRIVER_ALSA_DYNAMIC; -static void *alsa_handle = NULL; -static int alsa_loaded = 0; - -static int (*SDL_snd_pcm_open)(snd_pcm_t **pcm, const char *name, snd_pcm_stream_t stream, int mode); -static int (*SDL_NAME(snd_pcm_open))(snd_pcm_t **pcm, const char *name, snd_pcm_stream_t stream, int mode); -static int (*SDL_NAME(snd_pcm_close))(snd_pcm_t *pcm); -static snd_pcm_sframes_t (*SDL_NAME(snd_pcm_writei))(snd_pcm_t *pcm, const void *buffer, snd_pcm_uframes_t size); -static int (*SDL_NAME(snd_pcm_resume))(snd_pcm_t *pcm); -static int (*SDL_NAME(snd_pcm_prepare))(snd_pcm_t *pcm); -static int (*SDL_NAME(snd_pcm_drain))(snd_pcm_t *pcm); -static const char *(*SDL_NAME(snd_strerror))(int errnum); -static size_t (*SDL_NAME(snd_pcm_hw_params_sizeof))(void); -static size_t (*SDL_NAME(snd_pcm_sw_params_sizeof))(void); -static int (*SDL_NAME(snd_pcm_hw_params_any))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params); -static int (*SDL_NAME(snd_pcm_hw_params_set_access))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t access); -static int (*SDL_NAME(snd_pcm_hw_params_set_format))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t val); -static int (*SDL_NAME(snd_pcm_hw_params_set_channels))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val); -static int (*SDL_NAME(snd_pcm_hw_params_get_channels))(const snd_pcm_hw_params_t *params); -static unsigned int (*SDL_NAME(snd_pcm_hw_params_set_rate_near))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir); -static snd_pcm_uframes_t (*SDL_NAME(snd_pcm_hw_params_set_period_size_near))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int *dir); -static snd_pcm_sframes_t (*SDL_NAME(snd_pcm_hw_params_get_period_size))(const snd_pcm_hw_params_t *params); -static unsigned int (*SDL_NAME(snd_pcm_hw_params_set_periods_near))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir); -static int (*SDL_NAME(snd_pcm_hw_params_get_periods))(snd_pcm_hw_params_t *params); -static int (*SDL_NAME(snd_pcm_hw_params))(snd_pcm_t *pcm, snd_pcm_hw_params_t *params); -/* -*/ -static int (*SDL_NAME(snd_pcm_sw_params_current))(snd_pcm_t *pcm, snd_pcm_sw_params_t *swparams); -static int (*SDL_NAME(snd_pcm_sw_params_set_start_threshold))(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val); -static int (*SDL_NAME(snd_pcm_sw_params_set_avail_min))(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val); -static int (*SDL_NAME(snd_pcm_sw_params))(snd_pcm_t *pcm, snd_pcm_sw_params_t *params); -static int (*SDL_NAME(snd_pcm_nonblock))(snd_pcm_t *pcm, int nonblock); -#define snd_pcm_hw_params_sizeof SDL_NAME(snd_pcm_hw_params_sizeof) -#define snd_pcm_sw_params_sizeof SDL_NAME(snd_pcm_sw_params_sizeof) - -/* cast funcs to char* first, to please GCC's strict aliasing rules. */ -static struct { - const char *name; - void **func; -} alsa_functions[] = { - { "snd_pcm_open", (void**)(char*)&SDL_NAME(snd_pcm_open) }, - { "snd_pcm_close", (void**)(char*)&SDL_NAME(snd_pcm_close) }, - { "snd_pcm_writei", (void**)(char*)&SDL_NAME(snd_pcm_writei) }, - { "snd_pcm_resume", (void**)(char*)&SDL_NAME(snd_pcm_resume) }, - { "snd_pcm_prepare", (void**)(char*)&SDL_NAME(snd_pcm_prepare) }, - { "snd_pcm_drain", (void**)(char*)&SDL_NAME(snd_pcm_drain) }, - { "snd_strerror", (void**)(char*)&SDL_NAME(snd_strerror) }, - { "snd_pcm_hw_params_sizeof", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_sizeof) }, - { "snd_pcm_sw_params_sizeof", (void**)(char*)&SDL_NAME(snd_pcm_sw_params_sizeof) }, - { "snd_pcm_hw_params_any", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_any) }, - { "snd_pcm_hw_params_set_access", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_access) }, - { "snd_pcm_hw_params_set_format", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_format) }, - { "snd_pcm_hw_params_set_channels", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_channels) }, - { "snd_pcm_hw_params_get_channels", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_get_channels) }, - { "snd_pcm_hw_params_set_rate_near", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_rate_near) }, - { "snd_pcm_hw_params_set_period_size_near", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_period_size_near) }, - { "snd_pcm_hw_params_get_period_size", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_get_period_size) }, - { "snd_pcm_hw_params_set_periods_near", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_set_periods_near) }, - { "snd_pcm_hw_params_get_periods", (void**)(char*)&SDL_NAME(snd_pcm_hw_params_get_periods) }, - { "snd_pcm_hw_params", (void**)(char*)&SDL_NAME(snd_pcm_hw_params) }, - { "snd_pcm_sw_params_current", (void**)(char*)&SDL_NAME(snd_pcm_sw_params_current) }, - { "snd_pcm_sw_params_set_start_threshold", (void**)(char*)&SDL_NAME(snd_pcm_sw_params_set_start_threshold) }, - { "snd_pcm_sw_params_set_avail_min", (void**)(char*)&SDL_NAME(snd_pcm_sw_params_set_avail_min) }, - { "snd_pcm_sw_params", (void**)(char*)&SDL_NAME(snd_pcm_sw_params) }, - { "snd_pcm_nonblock", (void**)(char*)&SDL_NAME(snd_pcm_nonblock) }, -}; - -static void UnloadALSALibrary(void) { - if (alsa_loaded) { -/* SDL_UnloadObject(alsa_handle);*/ - dlclose(alsa_handle); - alsa_handle = NULL; - alsa_loaded = 0; - } -} - -static int LoadALSALibrary(void) { - int i, retval = -1; - -/* alsa_handle = SDL_LoadObject(alsa_library);*/ - alsa_handle = dlopen(alsa_library,RTLD_NOW); - if (alsa_handle) { - alsa_loaded = 1; - retval = 0; - for (i = 0; i < SDL_arraysize(alsa_functions); i++) { -/* *alsa_functions[i].func = SDL_LoadFunction(alsa_handle,alsa_functions[i].name);*/ -#if HAVE_DLVSYM - *alsa_functions[i].func = dlvsym(alsa_handle,alsa_functions[i].name,"ALSA_0.9"); - if (!*alsa_functions[i].func) -#endif - *alsa_functions[i].func = dlsym(alsa_handle,alsa_functions[i].name); - if (!*alsa_functions[i].func) { - retval = -1; - UnloadALSALibrary(); - break; - } - } - } - return retval; -} - -#else - -static void UnloadALSALibrary(void) { - return; -} - -static int LoadALSALibrary(void) { - return 0; -} - -#endif /* SDL_AUDIO_DRIVER_ALSA_DYNAMIC */ - -static const char *get_audio_device(int channels) -{ - const char *device; - - device = SDL_getenv("AUDIODEV"); /* Is there a standard variable name? */ - if ( device == NULL ) { - if (channels == 6) device = "surround51"; - else if (channels == 4) device = "surround40"; - else device = DEFAULT_DEVICE; - } - return device; -} - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - int available; - int status; - snd_pcm_t *handle; - - available = 0; - if (LoadALSALibrary() < 0) { - return available; - } - status = SDL_NAME(snd_pcm_open)(&handle, get_audio_device(2), SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK); - if ( status >= 0 ) { - available = 1; - SDL_NAME(snd_pcm_close)(handle); - } - UnloadALSALibrary(); - return(available); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); - UnloadALSALibrary(); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - LoadALSALibrary(); - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = ALSA_OpenAudio; - this->WaitAudio = ALSA_WaitAudio; - this->PlayAudio = ALSA_PlayAudio; - this->GetAudioBuf = ALSA_GetAudioBuf; - this->CloseAudio = ALSA_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap ALSA_bootstrap = { - DRIVER_NAME, "ALSA 0.9 PCM audio", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void ALSA_WaitAudio(_THIS) -{ - /* Check to see if the thread-parent process is still alive */ - { static int cnt = 0; - /* Note that this only works with thread implementations - that use a different process id for each thread. - */ - if (parent && (((++cnt)%10) == 0)) { /* Check every 10 loops */ - if ( kill(parent, 0) < 0 ) { - this->enabled = 0; - } - } - } -} - - -/* - * http://bugzilla.libsdl.org/show_bug.cgi?id=110 - * "For Linux ALSA, this is FL-FR-RL-RR-C-LFE - * and for Windows DirectX [and CoreAudio], this is FL-FR-C-LFE-RL-RR" - */ -#define SWIZ6(T) \ - T *ptr = (T *) mixbuf; \ - const Uint32 count = (this->spec.samples / 6); \ - Uint32 i; \ - for (i = 0; i < count; i++, ptr += 6) { \ - T tmp; \ - tmp = ptr[2]; ptr[2] = ptr[4]; ptr[4] = tmp; \ - tmp = ptr[3]; ptr[3] = ptr[5]; ptr[5] = tmp; \ - } - -static __inline__ void swizzle_alsa_channels_6_64bit(_THIS) { SWIZ6(Uint64); } -static __inline__ void swizzle_alsa_channels_6_32bit(_THIS) { SWIZ6(Uint32); } -static __inline__ void swizzle_alsa_channels_6_16bit(_THIS) { SWIZ6(Uint16); } -static __inline__ void swizzle_alsa_channels_6_8bit(_THIS) { SWIZ6(Uint8); } - -#undef SWIZ6 - - -/* - * Called right before feeding this->mixbuf to the hardware. Swizzle channels - * from Windows/Mac order to the format alsalib will want. - */ -static __inline__ void swizzle_alsa_channels(_THIS) -{ - if (this->spec.channels == 6) { - const Uint16 fmtsize = (this->spec.format & 0xFF); /* bits/channel. */ - if (fmtsize == 16) - swizzle_alsa_channels_6_16bit(this); - else if (fmtsize == 8) - swizzle_alsa_channels_6_8bit(this); - else if (fmtsize == 32) - swizzle_alsa_channels_6_32bit(this); - else if (fmtsize == 64) - swizzle_alsa_channels_6_64bit(this); - } - - /* !!! FIXME: update this for 7.1 if needed, later. */ -} - - -static void ALSA_PlayAudio(_THIS) -{ - int status; - int sample_len; - signed short *sample_buf; - - swizzle_alsa_channels(this); - - sample_len = this->spec.samples; - sample_buf = (signed short *)mixbuf; - - while ( sample_len > 0 ) { - status = SDL_NAME(snd_pcm_writei)(pcm_handle, sample_buf, sample_len); - if ( status < 0 ) { - if ( status == -EAGAIN ) { - SDL_Delay(1); - continue; - } - if ( status == -ESTRPIPE ) { - do { - SDL_Delay(1); - status = SDL_NAME(snd_pcm_resume)(pcm_handle); - } while ( status == -EAGAIN ); - } - if ( status < 0 ) { - status = SDL_NAME(snd_pcm_prepare)(pcm_handle); - } - if ( status < 0 ) { - /* Hmm, not much we can do - abort */ - this->enabled = 0; - return; - } - continue; - } - sample_buf += status * this->spec.channels; - sample_len -= status; - } -} - -static Uint8 *ALSA_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void ALSA_CloseAudio(_THIS) -{ - if ( mixbuf != NULL ) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if ( pcm_handle ) { - SDL_NAME(snd_pcm_drain)(pcm_handle); - SDL_NAME(snd_pcm_close)(pcm_handle); - pcm_handle = NULL; - } -} - -static int ALSA_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - int status; - snd_pcm_hw_params_t *hwparams; - snd_pcm_sw_params_t *swparams; - snd_pcm_format_t format; - snd_pcm_uframes_t frames; - Uint16 test_format; - - /* Open the audio device */ - /* Name of device should depend on # channels in spec */ - status = SDL_NAME(snd_pcm_open)(&pcm_handle, get_audio_device(spec->channels), SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK); - - if ( status < 0 ) { - SDL_SetError("Couldn't open audio device: %s", SDL_NAME(snd_strerror)(status)); - return(-1); - } - - /* Figure out what the hardware is capable of */ - snd_pcm_hw_params_alloca(&hwparams); - status = SDL_NAME(snd_pcm_hw_params_any)(pcm_handle, hwparams); - if ( status < 0 ) { - SDL_SetError("Couldn't get hardware config: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - - /* SDL only uses interleaved sample output */ - status = SDL_NAME(snd_pcm_hw_params_set_access)(pcm_handle, hwparams, SND_PCM_ACCESS_RW_INTERLEAVED); - if ( status < 0 ) { - SDL_SetError("Couldn't set interleaved access: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - - /* Try for a closest match on audio format */ - status = -1; - for ( test_format = SDL_FirstAudioFormat(spec->format); - test_format && (status < 0); ) { - switch ( test_format ) { - case AUDIO_U8: - format = SND_PCM_FORMAT_U8; - break; - case AUDIO_S8: - format = SND_PCM_FORMAT_S8; - break; - case AUDIO_S16LSB: - format = SND_PCM_FORMAT_S16_LE; - break; - case AUDIO_S16MSB: - format = SND_PCM_FORMAT_S16_BE; - break; - case AUDIO_U16LSB: - format = SND_PCM_FORMAT_U16_LE; - break; - case AUDIO_U16MSB: - format = SND_PCM_FORMAT_U16_BE; - break; - default: - format = 0; - break; - } - if ( format != 0 ) { - status = SDL_NAME(snd_pcm_hw_params_set_format)(pcm_handle, hwparams, format); - } - if ( status < 0 ) { - test_format = SDL_NextAudioFormat(); - } - } - if ( status < 0 ) { - SDL_SetError("Couldn't find any hardware audio formats"); - ALSA_CloseAudio(this); - return(-1); - } - spec->format = test_format; - - /* Set the number of channels */ - status = SDL_NAME(snd_pcm_hw_params_set_channels)(pcm_handle, hwparams, spec->channels); - if ( status < 0 ) { - status = SDL_NAME(snd_pcm_hw_params_get_channels)(hwparams); - if ( (status <= 0) || (status > 2) ) { - SDL_SetError("Couldn't set audio channels"); - ALSA_CloseAudio(this); - return(-1); - } - spec->channels = status; - } - - /* Set the audio rate */ - status = SDL_NAME(snd_pcm_hw_params_set_rate_near)(pcm_handle, hwparams, spec->freq, NULL); - if ( status < 0 ) { - SDL_SetError("Couldn't set audio frequency: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - spec->freq = status; - - /* Set the buffer size, in samples */ - frames = spec->samples; - frames = SDL_NAME(snd_pcm_hw_params_set_period_size_near)(pcm_handle, hwparams, frames, NULL); - spec->samples = frames; - SDL_NAME(snd_pcm_hw_params_set_periods_near)(pcm_handle, hwparams, 2, NULL); - - /* "set" the hardware with the desired parameters */ - status = SDL_NAME(snd_pcm_hw_params)(pcm_handle, hwparams); - if ( status < 0 ) { - SDL_SetError("Couldn't set hardware audio parameters: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - -/* This is useful for debugging... */ -/* -{ snd_pcm_sframes_t bufsize; int fragments; - bufsize = SDL_NAME(snd_pcm_hw_params_get_period_size)(hwparams); - fragments = SDL_NAME(snd_pcm_hw_params_get_periods)(hwparams); - - fprintf(stderr, "ALSA: bufsize = %ld, fragments = %d\n", bufsize, fragments); -} -*/ - - /* Set the software parameters */ - snd_pcm_sw_params_alloca(&swparams); - status = SDL_NAME(snd_pcm_sw_params_current)(pcm_handle, swparams); - if ( status < 0 ) { - SDL_SetError("Couldn't get software config: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - status = SDL_NAME(snd_pcm_sw_params_set_start_threshold)(pcm_handle, swparams, 0); - if ( status < 0 ) { - SDL_SetError("Couldn't set start threshold: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - status = SDL_NAME(snd_pcm_sw_params_set_avail_min)(pcm_handle, swparams, frames); - if ( status < 0 ) { - SDL_SetError("Couldn't set avail min: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - status = SDL_NAME(snd_pcm_sw_params)(pcm_handle, swparams); - if ( status < 0 ) { - SDL_SetError("Couldn't set software audio parameters: %s", SDL_NAME(snd_strerror)(status)); - ALSA_CloseAudio(this); - return(-1); - } - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Allocate mixing buffer */ - mixlen = spec->size; - mixbuf = (Uint8 *)SDL_AllocAudioMem(mixlen); - if ( mixbuf == NULL ) { - ALSA_CloseAudio(this); - return(-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - - /* Switch to blocking mode for playback */ - SDL_NAME(snd_pcm_nonblock)(pcm_handle, 0); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.h b/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.h deleted file mode 100644 index fd9ac03..0000000 --- a/distrib/sdl-1.2.12/src/audio/alsa/SDL_alsa_audio.h +++ /dev/null @@ -1,54 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _ALSA_PCM_audio_h -#define _ALSA_PCM_audio_h - -#define ALSA_PCM_OLD_HW_PARAMS_API -#define ALSA_PCM_OLD_SW_PARAMS_API -#include - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The audio device handle */ - snd_pcm_t *pcm_handle; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *mixbuf; - int mixlen; -}; - -/* Old variable names */ -#define pcm_handle (this->hidden->pcm_handle) -#define parent (this->hidden->parent) -#define mixbuf (this->hidden->mixbuf) -#define mixlen (this->hidden->mixlen) - -#endif /* _ALSA_PCM_audio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.c b/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.c deleted file mode 100644 index c9a4c1a..0000000 --- a/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.c +++ /dev/null @@ -1,337 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer (for AmigaOS) */ - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "SDL_ahiaudio.h" - -/* Audio driver functions */ -static int AHI_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void AHI_WaitAudio(_THIS); -static void AHI_PlayAudio(_THIS); -static Uint8 *AHI_GetAudioBuf(_THIS); -static void AHI_CloseAudio(_THIS); - -#ifndef __SASC - #define mymalloc(x) AllocVec(x,MEMF_PUBLIC) - #define myfree FreeVec -#else - #define mymalloc malloc - #define myfree free -#endif - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - int ok=0; - struct MsgPort *p; - struct AHIRequest *req; - - if(p=CreateMsgPort()) - { - if(req=(struct AHIRequest *)CreateIORequest(p,sizeof(struct AHIRequest))) - { - req->ahir_Version=4; - - if(!OpenDevice(AHINAME,0,(struct IORequest *)req,NULL)) - { - D(bug("AHI available.\n")); - ok=1; - CloseDevice((struct IORequest *)req); - } - DeleteIORequest((struct IORequest *)req); - } - DeleteMsgPort(p); - } - - D(if(!ok) bug("AHI not available\n")); - return ok; -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - -#ifndef NO_AMIGADEBUG - D(bug("AHI created...\n")); -#endif - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = AHI_OpenAudio; - this->WaitAudio = AHI_WaitAudio; - this->PlayAudio = AHI_PlayAudio; - this->GetAudioBuf = AHI_GetAudioBuf; - this->CloseAudio = AHI_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap AHI_bootstrap = { - "AHI", Audio_Available, Audio_CreateDevice -}; - - -void static AHI_WaitAudio(_THIS) -{ - if(!CheckIO((struct IORequest *)audio_req[current_buffer])) - { - WaitIO((struct IORequest *)audio_req[current_buffer]); -// AbortIO((struct IORequest *)audio_req[current_buffer]); - } -} - -static void AHI_PlayAudio(_THIS) -{ - if(playing>1) - WaitIO((struct IORequest *)audio_req[current_buffer]); - - /* Write the audio data out */ - audio_req[current_buffer] -> ahir_Std. io_Message.mn_Node.ln_Pri = 60; - audio_req[current_buffer] -> ahir_Std. io_Data = mixbuf[current_buffer]; - audio_req[current_buffer] -> ahir_Std. io_Length = this->hidden->size; - audio_req[current_buffer] -> ahir_Std. io_Offset = 0; - audio_req[current_buffer] -> ahir_Std . io_Command = CMD_WRITE; - audio_req[current_buffer] -> ahir_Frequency = this->hidden->freq; - audio_req[current_buffer] -> ahir_Volume = 0x10000; - audio_req[current_buffer] -> ahir_Type = this->hidden->type; - audio_req[current_buffer] -> ahir_Position = 0x8000; - audio_req[current_buffer] -> ahir_Link = (playing>0 ? audio_req[current_buffer^1] : NULL); - - SendIO((struct IORequest *)audio_req[current_buffer]); - current_buffer^=1; - - playing++; -} - -static Uint8 *AHI_GetAudioBuf(_THIS) -{ - return(mixbuf[current_buffer]); -} - -static void AHI_CloseAudio(_THIS) -{ - D(bug("Closing audio...\n")); - - playing=0; - - if(audio_req[0]) - { - if(audio_req[1]) - { - D(bug("Break req[1]...\n")); - - AbortIO((struct IORequest *)audio_req[1]); - WaitIO((struct IORequest *)audio_req[1]); - } - - D(bug("Break req[0]...\n")); - - AbortIO((struct IORequest *)audio_req[0]); - WaitIO((struct IORequest *)audio_req[0]); - - if(audio_req[1]) - { - D(bug("Break AGAIN req[1]...\n")); - AbortIO((struct IORequest *)audio_req[1]); - WaitIO((struct IORequest *)audio_req[1]); - } -// Double abort to be sure to break the dbuffering process. - - SDL_Delay(200); - - D(bug("Reqs breaked, closing device...\n")); - CloseDevice((struct IORequest *)audio_req[0]); - D(bug("Device closed, freeing memory...\n")); - myfree(audio_req[1]); - D(bug("Memory freed, deleting IOReq...\n")); - DeleteIORequest((struct IORequest *)audio_req[0]); - audio_req[0]=audio_req[1]=NULL; - } - - D(bug("Freeing mixbuf[0]...\n")); - if ( mixbuf[0] != NULL ) { - myfree(mixbuf[0]); -// SDL_FreeAudioMem(mixbuf[0]); - mixbuf[0] = NULL; - } - - D(bug("Freeing mixbuf[1]...\n")); - if ( mixbuf[1] != NULL ) { - myfree(mixbuf[1]); -// SDL_FreeAudioMem(mixbuf[1]); - mixbuf[1] = NULL; - } - - D(bug("Freeing audio_port...\n")); - - if ( audio_port != NULL ) { - DeleteMsgPort(audio_port); - audio_port = NULL; - } - D(bug("...done!\n")); -} - -static int AHI_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ -// int width; - - D(bug("AHI opening...\n")); - - /* Determine the audio parameters from the AudioSpec */ - switch ( spec->format & 0xFF ) { - - case 8: { /* Signed 8 bit audio data */ - D(bug("Samples a 8 bit...\n")); - spec->format = AUDIO_S8; - this->hidden->bytespersample=1; - if(spec->channels<2) - this->hidden->type = AHIST_M8S; - else - this->hidden->type = AHIST_S8S; - } - break; - - case 16: { /* Signed 16 bit audio data */ - D(bug("Samples a 16 bit...\n")); - spec->format = AUDIO_S16MSB; - this->hidden->bytespersample=2; - if(spec->channels<2) - this->hidden->type = AHIST_M16S; - else - this->hidden->type = AHIST_S16S; - } - break; - - default: { - SDL_SetError("Unsupported audio format"); - return(-1); - } - } - - if(spec->channels!=1 && spec->channels!=2) - { - D(bug("Wrong channel number!\n")); - SDL_SetError("Channel number non supported"); - return -1; - } - - D(bug("Before CalculateAudioSpec\n")); - /* Update the fragment size as size in bytes */ - SDL_CalculateAudioSpec(spec); - - D(bug("Before CreateMsgPort\n")); - - if(!(audio_port=CreateMsgPort())) - { - SDL_SetError("Unable to create a MsgPort"); - return -1; - } - - D(bug("Before CreateIORequest\n")); - - if(!(audio_req[0]=(struct AHIRequest *)CreateIORequest(audio_port,sizeof(struct AHIRequest)))) - { - SDL_SetError("Unable to create an AHIRequest"); - DeleteMsgPort(audio_port); - return -1; - } - - audio_req[0]->ahir_Version = 4; - - if(OpenDevice(AHINAME,0,(struct IORequest *)audio_req[0],NULL)) - { - SDL_SetError("Unable to open AHI device!\n"); - DeleteIORequest((struct IORequest *)audio_req[0]); - DeleteMsgPort(audio_port); - return -1; - } - - D(bug("AFTER opendevice\n")); - - /* Set output frequency and size */ - this->hidden->freq = spec->freq; - this->hidden->size = spec->size; - - D(bug("Before buffer allocation\n")); - - /* Allocate mixing buffer */ - mixbuf[0] = (Uint8 *)mymalloc(spec->size); - mixbuf[1] = (Uint8 *)mymalloc(spec->size); - - D(bug("Before audio_req allocation\n")); - - if(!(audio_req[1]=mymalloc(sizeof(struct AHIRequest)))) - { - SDL_OutOfMemory(); - return(-1); - } - - D(bug("Before audio_req memcpy\n")); - - SDL_memcpy(audio_req[1],audio_req[0],sizeof(struct AHIRequest)); - - if ( mixbuf[0] == NULL || mixbuf[1] == NULL ) { - SDL_OutOfMemory(); - return(-1); - } - - D(bug("Before mixbuf memset\n")); - - SDL_memset(mixbuf[0], spec->silence, spec->size); - SDL_memset(mixbuf[1], spec->silence, spec->size); - - current_buffer=0; - playing=0; - - D(bug("AHI opened: freq:%ld mixbuf:%lx/%lx buflen:%ld bits:%ld channels:%ld\n",spec->freq,mixbuf[0],mixbuf[1],spec->size,this->hidden->bytespersample*8,spec->channels)); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.h b/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.h deleted file mode 100644 index b9ef339..0000000 --- a/distrib/sdl-1.2.12/src/audio/amigaos/SDL_ahiaudio.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_ahiaudio_h -#define _SDL_ahiaudio_h - -#include -#include -#ifdef __SASC -#include -#else -#include -#endif - -#include -#include "mydebug.h" - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the audio functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The handle for the audio device */ - struct AHIRequest *audio_req[2]; - struct MsgPort *audio_port; - Sint32 freq,type,bytespersample,size; - Uint8 *mixbuf[2]; /* The app mixing buffer */ - int current_buffer; - Uint32 playing; -}; - -/* Old variable names */ -#define audio_port (this->hidden->audio_port) -#define audio_req (this->hidden->audio_req) -#define mixbuf (this->hidden->mixbuf) -#define current_buffer (this->hidden->current_buffer) -#define playing (this->hidden->playing) - -#endif /* _SDL_ahiaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.c b/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.c deleted file mode 100644 index 204e582..0000000 --- a/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.c +++ /dev/null @@ -1,348 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#ifdef HAVE_SIGNAL_H -#include -#endif -#include - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_artsaudio.h" - -#ifdef SDL_AUDIO_DRIVER_ARTS_DYNAMIC -#include "SDL_name.h" -#include "SDL_loadso.h" -#else -#define SDL_NAME(X) X -#endif - -/* The tag name used by artsc audio */ -#define ARTS_DRIVER_NAME "arts" - -/* Audio driver functions */ -static int ARTS_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void ARTS_WaitAudio(_THIS); -static void ARTS_PlayAudio(_THIS); -static Uint8 *ARTS_GetAudioBuf(_THIS); -static void ARTS_CloseAudio(_THIS); - -#ifdef SDL_AUDIO_DRIVER_ARTS_DYNAMIC - -static const char *arts_library = SDL_AUDIO_DRIVER_ARTS_DYNAMIC; -static void *arts_handle = NULL; -static int arts_loaded = 0; - -static int (*SDL_NAME(arts_init))(void); -static void (*SDL_NAME(arts_free))(void); -static arts_stream_t (*SDL_NAME(arts_play_stream))(int rate, int bits, int channels, const char *name); -static int (*SDL_NAME(arts_stream_set))(arts_stream_t s, arts_parameter_t param, int value); -static int (*SDL_NAME(arts_stream_get))(arts_stream_t s, arts_parameter_t param); -static int (*SDL_NAME(arts_write))(arts_stream_t s, const void *buffer, int count); -static void (*SDL_NAME(arts_close_stream))(arts_stream_t s); -static int (*SDL_NAME(arts_suspended))(void); -static const char *(*SDL_NAME(arts_error_text))(int errorcode); - -static struct { - const char *name; - void **func; -} arts_functions[] = { - { "arts_init", (void **)&SDL_NAME(arts_init) }, - { "arts_free", (void **)&SDL_NAME(arts_free) }, - { "arts_play_stream", (void **)&SDL_NAME(arts_play_stream) }, - { "arts_stream_set", (void **)&SDL_NAME(arts_stream_set) }, - { "arts_stream_get", (void **)&SDL_NAME(arts_stream_get) }, - { "arts_write", (void **)&SDL_NAME(arts_write) }, - { "arts_close_stream", (void **)&SDL_NAME(arts_close_stream) }, - { "arts_suspended", (void **)&SDL_NAME(arts_suspended) }, - { "arts_error_text", (void **)&SDL_NAME(arts_error_text) }, -}; - -static void UnloadARTSLibrary() -{ - if ( arts_loaded ) { - SDL_UnloadObject(arts_handle); - arts_handle = NULL; - arts_loaded = 0; - } -} - -static int LoadARTSLibrary(void) -{ - int i, retval = -1; - - arts_handle = SDL_LoadObject(arts_library); - if ( arts_handle ) { - arts_loaded = 1; - retval = 0; - for ( i=0; ihidden); - SDL_free(device); - UnloadARTSLibrary(); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - LoadARTSLibrary(); - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - stream = 0; - - /* Set the function pointers */ - this->OpenAudio = ARTS_OpenAudio; - this->WaitAudio = ARTS_WaitAudio; - this->PlayAudio = ARTS_PlayAudio; - this->GetAudioBuf = ARTS_GetAudioBuf; - this->CloseAudio = ARTS_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap ARTS_bootstrap = { - ARTS_DRIVER_NAME, "Analog Realtime Synthesizer", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void ARTS_WaitAudio(_THIS) -{ - Sint32 ticks; - - /* Check to see if the thread-parent process is still alive */ - { static int cnt = 0; - /* Note that this only works with thread implementations - that use a different process id for each thread. - */ - if (parent && (((++cnt)%10) == 0)) { /* Check every 10 loops */ - if ( kill(parent, 0) < 0 ) { - this->enabled = 0; - } - } - } - - /* Use timer for general audio synchronization */ - ticks = ((Sint32)(next_frame - SDL_GetTicks()))-FUDGE_TICKS; - if ( ticks > 0 ) { - SDL_Delay(ticks); - } -} - -static void ARTS_PlayAudio(_THIS) -{ - int written; - - /* Write the audio data */ - written = SDL_NAME(arts_write)(stream, mixbuf, mixlen); - - /* If timer synchronization is enabled, set the next write frame */ - if ( frame_ticks ) { - next_frame += frame_ticks; - } - - /* If we couldn't write, assume fatal error for now */ - if ( written < 0 ) { - this->enabled = 0; - } -#ifdef DEBUG_AUDIO - fprintf(stderr, "Wrote %d bytes of audio data\n", written); -#endif -} - -static Uint8 *ARTS_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void ARTS_CloseAudio(_THIS) -{ - if ( mixbuf != NULL ) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if ( stream ) { - SDL_NAME(arts_close_stream)(stream); - stream = 0; - } - SDL_NAME(arts_free)(); -} - -static int ARTS_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - int bits, frag_spec; - Uint16 test_format, format; - int error_code; - - /* Reset the timer synchronization flag */ - frame_ticks = 0.0; - - mixbuf = NULL; - - /* Try for a closest match on audio format */ - format = 0; - bits = 0; - for ( test_format = SDL_FirstAudioFormat(spec->format); - ! format && test_format; ) { -#ifdef DEBUG_AUDIO - fprintf(stderr, "Trying format 0x%4.4x\n", test_format); -#endif - switch ( test_format ) { - case AUDIO_U8: - bits = 8; - format = 1; - break; - case AUDIO_S16LSB: - bits = 16; - format = 1; - break; - default: - format = 0; - break; - } - if ( ! format ) { - test_format = SDL_NextAudioFormat(); - } - } - if ( format == 0 ) { - SDL_SetError("Couldn't find any hardware audio formats"); - return(-1); - } - spec->format = test_format; - - error_code = SDL_NAME(arts_init)(); - if ( error_code != 0 ) { - SDL_SetError("Unable to initialize ARTS: %s", SDL_NAME(arts_error_text)(error_code)); - return(-1); - } - if ( ! SDL_NAME(arts_suspended)() ) { - SDL_SetError("ARTS can not open audio device"); - return(-1); - } - stream = SDL_NAME(arts_play_stream)(spec->freq, bits, spec->channels, "SDL"); - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Determine the power of two of the fragment size */ - for ( frag_spec = 0; (0x01<size; ++frag_spec ); - if ( (0x01<size ) { - SDL_SetError("Fragment size must be a power of two"); - return(-1); - } - frag_spec |= 0x00020000; /* two fragments, for low latency */ - -#ifdef ARTS_P_PACKET_SETTINGS - SDL_NAME(arts_stream_set)(stream, ARTS_P_PACKET_SETTINGS, frag_spec); -#else - SDL_NAME(arts_stream_set)(stream, ARTS_P_PACKET_SIZE, frag_spec&0xffff); - SDL_NAME(arts_stream_set)(stream, ARTS_P_PACKET_COUNT, frag_spec>>16); -#endif - spec->size = SDL_NAME(arts_stream_get)(stream, ARTS_P_PACKET_SIZE); - - /* Allocate mixing buffer */ - mixlen = spec->size; - mixbuf = (Uint8 *)SDL_AllocAudioMem(mixlen); - if ( mixbuf == NULL ) { - return(-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.h b/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.h deleted file mode 100644 index 5569a3d..0000000 --- a/distrib/sdl-1.2.12/src/audio/arts/SDL_artsaudio.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_artscaudio_h -#define _SDL_artscaudio_h - -#include - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The stream descriptor for the audio device */ - arts_stream_t stream; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *mixbuf; - int mixlen; - - /* Support for audio timing using a timer, in addition to select() */ - float frame_ticks; - float next_frame; -}; -#define FUDGE_TICKS 10 /* The scheduler overhead ticks per frame */ - -/* Old variable names */ -#define stream (this->hidden->stream) -#define parent (this->hidden->parent) -#define mixbuf (this->hidden->mixbuf) -#define mixlen (this->hidden->mixlen) -#define frame_ticks (this->hidden->frame_ticks) -#define next_frame (this->hidden->next_frame) - -#endif /* _SDL_artscaudio_h */ - diff --git a/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.cc b/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.cc deleted file mode 100644 index fce0ecb..0000000 --- a/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.cc +++ /dev/null @@ -1,225 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to the audio stream on BeOS */ - -#include - -#include "../../main/beos/SDL_BeApp.h" - -extern "C" { - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" -#include "../../thread/beos/SDL_systhread_c.h" -#include "SDL_beaudio.h" - - -/* Audio driver functions */ -static int BE_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void BE_WaitAudio(_THIS); -static void BE_PlayAudio(_THIS); -static Uint8 *BE_GetAudioBuf(_THIS); -static void BE_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *device; - - /* Initialize all variables that we clean on shutdown */ - device = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( device ) { - SDL_memset(device, 0, (sizeof *device)); - device->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *device->hidden)); - } - if ( (device == NULL) || (device->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( device ) { - SDL_free(device); - } - return(0); - } - SDL_memset(device->hidden, 0, (sizeof *device->hidden)); - - /* Set the function pointers */ - device->OpenAudio = BE_OpenAudio; - device->WaitAudio = BE_WaitAudio; - device->PlayAudio = BE_PlayAudio; - device->GetAudioBuf = BE_GetAudioBuf; - device->CloseAudio = BE_CloseAudio; - - device->free = Audio_DeleteDevice; - - return device; -} - -AudioBootStrap BAUDIO_bootstrap = { - "baudio", "BeOS BSoundPlayer", - Audio_Available, Audio_CreateDevice -}; - -/* The BeOS callback for handling the audio buffer */ -static void FillSound(void *device, void *stream, size_t len, - const media_raw_audio_format &format) -{ - SDL_AudioDevice *audio = (SDL_AudioDevice *)device; - - /* Silence the buffer, since it's ours */ - SDL_memset(stream, audio->spec.silence, len); - - /* Only do soemthing if audio is enabled */ - if ( ! audio->enabled ) - return; - - if ( ! audio->paused ) { - if ( audio->convert.needed ) { - SDL_mutexP(audio->mixer_lock); - (*audio->spec.callback)(audio->spec.userdata, - (Uint8 *)audio->convert.buf,audio->convert.len); - SDL_mutexV(audio->mixer_lock); - SDL_ConvertAudio(&audio->convert); - SDL_memcpy(stream,audio->convert.buf,audio->convert.len_cvt); - } else { - SDL_mutexP(audio->mixer_lock); - (*audio->spec.callback)(audio->spec.userdata, - (Uint8 *)stream, len); - SDL_mutexV(audio->mixer_lock); - } - } - return; -} - -/* Dummy functions -- we don't use thread-based audio */ -void BE_WaitAudio(_THIS) -{ - return; -} -void BE_PlayAudio(_THIS) -{ - return; -} -Uint8 *BE_GetAudioBuf(_THIS) -{ - return(NULL); -} - -void BE_CloseAudio(_THIS) -{ - if ( audio_obj ) { - audio_obj->Stop(); - delete audio_obj; - audio_obj = NULL; - } - - /* Quit the Be Application, if there's nothing left to do */ - SDL_QuitBeApp(); -} - -int BE_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - int valid_datatype = 0; - media_raw_audio_format format; - Uint16 test_format = SDL_FirstAudioFormat(spec->format); - - /* Parse the audio format and fill the Be raw audio format */ - memset(&format, '\0', sizeof (media_raw_audio_format)); - format.byte_order = B_MEDIA_LITTLE_ENDIAN; - format.frame_rate = (float) spec->freq; - format.channel_count = spec->channels; /* !!! FIXME: support > 2? */ - while ((!valid_datatype) && (test_format)) { - valid_datatype = 1; - spec->format = test_format; - switch (test_format) { - case AUDIO_S8: - format.format = media_raw_audio_format::B_AUDIO_CHAR; - break; - - case AUDIO_U8: - format.format = media_raw_audio_format::B_AUDIO_UCHAR; - break; - - case AUDIO_S16LSB: - format.format = media_raw_audio_format::B_AUDIO_SHORT; - break; - - case AUDIO_S16MSB: - format.format = media_raw_audio_format::B_AUDIO_SHORT; - format.byte_order = B_MEDIA_BIG_ENDIAN; - break; - - default: - valid_datatype = 0; - test_format = SDL_NextAudioFormat(); - break; - } - } - - if (!valid_datatype) { /* shouldn't happen, but just in case... */ - SDL_SetError("Unsupported audio format"); - return (-1); - } - - /* Initialize the Be Application, if it's not already started */ - if (SDL_InitBeApp() < 0) { - return (-1); - } - - format.buffer_size = spec->samples; - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Subscribe to the audio stream (creates a new thread) */ - { sigset_t omask; - SDL_MaskSignals(&omask); - audio_obj = new BSoundPlayer(&format, "SDL Audio", FillSound, - NULL, _this); - SDL_UnmaskSignals(&omask); - } - if ( audio_obj->Start() == B_NO_ERROR ) { - audio_obj->SetHasData(true); - } else { - SDL_SetError("Unable to start Be audio"); - return(-1); - } - - /* We're running! */ - return(1); -} - -}; /* Extern C */ diff --git a/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.h b/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.h deleted file mode 100644 index 942c60e..0000000 --- a/distrib/sdl-1.2.12/src/audio/baudio/SDL_beaudio.h +++ /dev/null @@ -1,39 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_lowaudio_h -#define _SDL_lowaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *_this - -struct SDL_PrivateAudioData { - BSoundPlayer *audio_obj; -}; - -/* Old variable names */ -#define audio_obj (_this->hidden->audio_obj) - -#endif /* _SDL_lowaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.c b/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.c deleted file mode 100644 index f1946c0..0000000 --- a/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.c +++ /dev/null @@ -1,404 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - * Driver for native OpenBSD/NetBSD audio(4). - * vedge@vedge.com.ar. - */ - -#include -#include -#include -#include -#include -#include -#include -#include - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_bsdaudio.h" - -/* The tag name used by NetBSD/OpenBSD audio */ -#ifdef __NetBSD__ -#define BSD_AUDIO_DRIVER_NAME "netbsd" -#define BSD_AUDIO_DRIVER_DESC "Native NetBSD audio" -#else -#define BSD_AUDIO_DRIVER_NAME "openbsd" -#define BSD_AUDIO_DRIVER_DESC "Native OpenBSD audio" -#endif - -/* Open the audio device for playback, and don't block if busy */ -/* #define USE_BLOCKING_WRITES */ - -/* Use timer for synchronization */ -/* #define USE_TIMER_SYNC */ - -/* #define DEBUG_AUDIO */ -/* #define DEBUG_AUDIO_STREAM */ - -#ifdef USE_BLOCKING_WRITES -#define OPEN_FLAGS O_WRONLY -#else -#define OPEN_FLAGS (O_WRONLY|O_NONBLOCK) -#endif - -/* Audio driver functions */ -static void OBSD_WaitAudio(_THIS); -static int OBSD_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void OBSD_PlayAudio(_THIS); -static Uint8 *OBSD_GetAudioBuf(_THIS); -static void OBSD_CloseAudio(_THIS); - -#ifdef DEBUG_AUDIO -static void OBSD_Status(_THIS); -#endif - -/* Audio driver bootstrap functions */ - -static int -Audio_Available(void) -{ - int fd; - int available; - - available = 0; - fd = SDL_OpenAudioPath(NULL, 0, OPEN_FLAGS, 0); - if(fd >= 0) { - available = 1; - close(fd); - } - return(available); -} - -static void -Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice -*Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice*)SDL_malloc(sizeof(SDL_AudioDevice)); - if(this) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = - (struct SDL_PrivateAudioData*)SDL_malloc((sizeof *this->hidden)); - } - if((this == NULL) || (this->hidden == NULL)) { - SDL_OutOfMemory(); - if(this) SDL_free(this); - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - audio_fd = -1; - - /* Set the function pointers */ - this->OpenAudio = OBSD_OpenAudio; - this->WaitAudio = OBSD_WaitAudio; - this->PlayAudio = OBSD_PlayAudio; - this->GetAudioBuf = OBSD_GetAudioBuf; - this->CloseAudio = OBSD_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap BSD_AUDIO_bootstrap = { - BSD_AUDIO_DRIVER_NAME, BSD_AUDIO_DRIVER_DESC, - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void -OBSD_WaitAudio(_THIS) -{ -#ifndef USE_BLOCKING_WRITES /* Not necessary when using blocking writes */ - /* See if we need to use timed audio synchronization */ - if ( frame_ticks ) { - /* Use timer for general audio synchronization */ - Sint32 ticks; - - ticks = ((Sint32)(next_frame - SDL_GetTicks()))-FUDGE_TICKS; - if ( ticks > 0 ) { - SDL_Delay(ticks); - } - } else { - /* Use select() for audio synchronization */ - fd_set fdset; - struct timeval timeout; - - FD_ZERO(&fdset); - FD_SET(audio_fd, &fdset); - timeout.tv_sec = 10; - timeout.tv_usec = 0; -#ifdef DEBUG_AUDIO - fprintf(stderr, "Waiting for audio to get ready\n"); -#endif - if ( select(audio_fd+1, NULL, &fdset, NULL, &timeout) <= 0 ) { - const char *message = - "Audio timeout - buggy audio driver? (disabled)"; - /* In general we should never print to the screen, - but in this case we have no other way of letting - the user know what happened. - */ - fprintf(stderr, "SDL: %s\n", message); - this->enabled = 0; - /* Don't try to close - may hang */ - audio_fd = -1; -#ifdef DEBUG_AUDIO - fprintf(stderr, "Done disabling audio\n"); -#endif - } -#ifdef DEBUG_AUDIO - fprintf(stderr, "Ready!\n"); -#endif - } -#endif /* !USE_BLOCKING_WRITES */ -} - -static void -OBSD_PlayAudio(_THIS) -{ - int written, p=0; - - /* Write the audio data, checking for EAGAIN on broken audio drivers */ - do { - written = write(audio_fd, &mixbuf[p], mixlen-p); - if (written>0) - p += written; - if (written == -1 && errno != 0 && errno != EAGAIN && errno != EINTR) - { - /* Non recoverable error has occurred. It should be reported!!! */ - perror("audio"); - break; - } - - if ( p < written || ((written < 0) && ((errno == 0) || (errno == EAGAIN))) ) { - SDL_Delay(1); /* Let a little CPU time go by */ - } - } while ( p < written ); - - /* If timer synchronization is enabled, set the next write frame */ - if ( frame_ticks ) { - next_frame += frame_ticks; - } - - /* If we couldn't write, assume fatal error for now */ - if ( written < 0 ) { - this->enabled = 0; - } -#ifdef DEBUG_AUDIO - fprintf(stderr, "Wrote %d bytes of audio data\n", written); -#endif -} - -static Uint8 -*OBSD_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void -OBSD_CloseAudio(_THIS) -{ - if(mixbuf != NULL) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if(audio_fd >= 0) { - close(audio_fd); - audio_fd = -1; - } -} - -#ifdef DEBUG_AUDIO -void -OBSD_Status(_THIS) -{ - audio_info_t info; - - if(ioctl(audio_fd, AUDIO_GETINFO, &info) < 0) { - fprintf(stderr,"AUDIO_GETINFO failed.\n"); - return; - } - - fprintf(stderr,"\n" -"[play/record info]\n" -"buffer size : %d bytes\n" -"sample rate : %i Hz\n" -"channels : %i\n" -"precision : %i-bit\n" -"encoding : 0x%x\n" -"seek : %i\n" -"sample count : %i\n" -"EOF count : %i\n" -"paused : %s\n" -"error occured : %s\n" -"waiting : %s\n" -"active : %s\n" -"", - info.play.buffer_size, - info.play.sample_rate, - info.play.channels, - info.play.precision, - info.play.encoding, - info.play.seek, - info.play.samples, - info.play.eof, - info.play.pause ? "yes" : "no", - info.play.error ? "yes" : "no", - info.play.waiting ? "yes" : "no", - info.play.active ? "yes": "no"); - - fprintf(stderr,"\n" -"[audio info]\n" -"monitor_gain : %i\n" -"hw block size : %d bytes\n" -"hi watermark : %i\n" -"lo watermark : %i\n" -"audio mode : %s\n" -"", - info.monitor_gain, - info.blocksize, - info.hiwat, info.lowat, - (info.mode == AUMODE_PLAY) ? "PLAY" - : (info.mode = AUMODE_RECORD) ? "RECORD" - : (info.mode == AUMODE_PLAY_ALL ? "PLAY_ALL" - : "?")); -} -#endif /* DEBUG_AUDIO */ - -static int -OBSD_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - char audiodev[64]; - Uint16 format; - audio_info_t info; - - AUDIO_INITINFO(&info); - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - -#ifdef USE_TIMER_SYNC - frame_ticks = 0.0; -#endif - - /* Open the audio device */ - audio_fd = SDL_OpenAudioPath(audiodev, sizeof(audiodev), OPEN_FLAGS, 0); - if(audio_fd < 0) { - SDL_SetError("Couldn't open %s: %s", audiodev, strerror(errno)); - return(-1); - } - - /* Set to play mode */ - info.mode = AUMODE_PLAY; - if(ioctl(audio_fd, AUDIO_SETINFO, &info) < 0) { - SDL_SetError("Couldn't put device into play mode"); - return(-1); - } - - mixbuf = NULL; - AUDIO_INITINFO(&info); - for (format = SDL_FirstAudioFormat(spec->format); - format; format = SDL_NextAudioFormat()) - { - switch(format) { - case AUDIO_U8: - info.play.encoding = AUDIO_ENCODING_ULINEAR; - info.play.precision = 8; - break; - case AUDIO_S8: - info.play.encoding = AUDIO_ENCODING_SLINEAR; - info.play.precision = 8; - break; - case AUDIO_S16LSB: - info.play.encoding = AUDIO_ENCODING_SLINEAR_LE; - info.play.precision = 16; - break; - case AUDIO_S16MSB: - info.play.encoding = AUDIO_ENCODING_SLINEAR_BE; - info.play.precision = 16; - break; - case AUDIO_U16LSB: - info.play.encoding = AUDIO_ENCODING_ULINEAR_LE; - info.play.precision = 16; - break; - case AUDIO_U16MSB: - info.play.encoding = AUDIO_ENCODING_ULINEAR_BE; - info.play.precision = 16; - break; - default: - continue; - } - if (ioctl(audio_fd, AUDIO_SETINFO, &info) == 0) - break; - } - - if(!format) { - SDL_SetError("No supported encoding for 0x%x", spec->format); - return(-1); - } - - spec->format = format; - - AUDIO_INITINFO(&info); - info.play.channels = spec->channels; - if (ioctl(audio_fd, AUDIO_SETINFO, &info) == -1) - spec->channels = 1; - AUDIO_INITINFO(&info); - info.play.sample_rate = spec->freq; - info.blocksize = spec->size; - info.hiwat = 5; - info.lowat = 3; - (void)ioctl(audio_fd, AUDIO_SETINFO, &info); - (void)ioctl(audio_fd, AUDIO_GETINFO, &info); - spec->freq = info.play.sample_rate; - /* Allocate mixing buffer */ - mixlen = spec->size; - mixbuf = (Uint8*)SDL_AllocAudioMem(mixlen); - if(mixbuf == NULL) { - return(-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - -#ifdef DEBUG_AUDIO - OBSD_Status(this); -#endif - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.h b/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.h deleted file mode 100644 index 8e8db89..0000000 --- a/distrib/sdl-1.2.12/src/audio/bsd/SDL_bsdaudio.h +++ /dev/null @@ -1,58 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_openbsdaudio_h -#define _SDL_openbsdaudio_h - -#include "../SDL_sysaudio.h" - -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData -{ - /* The file descriptor for the audio device */ - int audio_fd; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *mixbuf; - int mixlen; - - /* Support for audio timing using a timer, in addition to select() */ - float frame_ticks; - float next_frame; -}; - -#define FUDGE_TICKS 10 /* The scheduler overhead ticks per frame */ - -/* Old variable names */ -#define audio_fd (this->hidden->audio_fd) -#define parent (this->hidden->parent) -#define mixbuf (this->hidden->mixbuf) -#define mixlen (this->hidden->mixlen) -#define frame_ticks (this->hidden->frame_ticks) -#define next_frame (this->hidden->next_frame) - -#endif /* _SDL_openbsdaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.c b/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.c deleted file mode 100644 index a37a5e2..0000000 --- a/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.c +++ /dev/null @@ -1,441 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "SDL_dart.h" - -// Buffer states: -#define BUFFER_EMPTY 0 -#define BUFFER_USED 1 - -typedef struct _tMixBufferDesc { - int iBufferUsage; // BUFFER_EMPTY or BUFFER_USED - SDL_AudioDevice *pSDLAudioDevice; -} tMixBufferDesc, *pMixBufferDesc; - - -//--------------------------------------------------------------------- -// DARTEventFunc -// -// This function is called by DART, when an event occures, like end of -// playback of a buffer, etc... -//--------------------------------------------------------------------- -LONG APIENTRY DARTEventFunc(ULONG ulStatus, - PMCI_MIX_BUFFER pBuffer, - ULONG ulFlags) -{ - if (ulFlags && MIX_WRITE_COMPLETE) - { // Playback of buffer completed! - - // Get pointer to buffer description - pMixBufferDesc pBufDesc; - - if (pBuffer) - { - pBufDesc = (pMixBufferDesc) (*pBuffer).ulUserParm; - - if (pBufDesc) - { - SDL_AudioDevice *pSDLAudioDevice = pBufDesc->pSDLAudioDevice; - // Set the buffer to be empty - pBufDesc->iBufferUsage = BUFFER_EMPTY; - // And notify DART feeder thread that it will have to work a bit. - if (pSDLAudioDevice) - DosPostEventSem(pSDLAudioDevice->hidden->hevAudioBufferPlayed); - } - } - } - return TRUE; -} - - -int DART_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - Uint16 test_format = SDL_FirstAudioFormat(spec->format); - int valid_datatype = 0; - MCI_AMP_OPEN_PARMS AmpOpenParms; - MCI_GENERIC_PARMS GenericParms; - int iDeviceOrd = 0; // Default device to be used - int bOpenShared = 1; // Try opening it shared - int iBits = 16; // Default is 16 bits signed - int iFreq = 44100; // Default is 44KHz - int iChannels = 2; // Default is 2 channels (Stereo) - int iNumBufs = 2; // Number of audio buffers: 2 - int iBufSize; - int iOpenMode; - int iSilence; - int rc; - - // First thing is to try to open a given DART device! - SDL_memset(&AmpOpenParms, 0, sizeof(MCI_AMP_OPEN_PARMS)); - // pszDeviceType should contain the device type in low word, and device ordinal in high word! - AmpOpenParms.pszDeviceType = (PSZ) (MCI_DEVTYPE_AUDIO_AMPMIX | (iDeviceOrd << 16)); - - iOpenMode = MCI_WAIT | MCI_OPEN_TYPE_ID; - if (bOpenShared) iOpenMode |= MCI_OPEN_SHAREABLE; - - rc = mciSendCommand( 0, MCI_OPEN, - iOpenMode, - (PVOID) &AmpOpenParms, 0); - if (rc!=MCIERR_SUCCESS) // No audio available?? - return (-1); - // Save the device ID we got from DART! - // We will use this in the next calls! - iDeviceOrd = AmpOpenParms.usDeviceID; - - // Determine the audio parameters from the AudioSpec - if (spec->channels > 2) - spec->channels = 2; // !!! FIXME: more than stereo support in OS/2? - - while ((!valid_datatype) && (test_format)) { - spec->format = test_format; - valid_datatype = 1; - switch (test_format) { - case AUDIO_U8: - // Unsigned 8 bit audio data - iSilence = 0x80; - iBits = 8; - break; - - case AUDIO_S16LSB: - // Signed 16 bit audio data - iSilence = 0x00; - iBits = 16; - break; - - default: - valid_datatype = 0; - test_format = SDL_NextAudioFormat(); - break; - } - } - - if (!valid_datatype) { // shouldn't happen, but just in case... - // Close DART, and exit with error code! - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Unsupported audio format"); - return (-1); - } - - iFreq = spec->freq; - iChannels = spec->channels; - /* Update the fragment size as size in bytes */ - SDL_CalculateAudioSpec(spec); - iBufSize = spec->size; - - // Now query this device if it supports the given freq/bits/channels! - SDL_memset(&(_this->hidden->MixSetupParms), 0, sizeof(MCI_MIXSETUP_PARMS)); - _this->hidden->MixSetupParms.ulBitsPerSample = iBits; - _this->hidden->MixSetupParms.ulFormatTag = MCI_WAVE_FORMAT_PCM; - _this->hidden->MixSetupParms.ulSamplesPerSec = iFreq; - _this->hidden->MixSetupParms.ulChannels = iChannels; - _this->hidden->MixSetupParms.ulFormatMode = MCI_PLAY; - _this->hidden->MixSetupParms.ulDeviceType = MCI_DEVTYPE_WAVEFORM_AUDIO; - _this->hidden->MixSetupParms.pmixEvent = DARTEventFunc; - rc = mciSendCommand (iDeviceOrd, MCI_MIXSETUP, - MCI_WAIT | MCI_MIXSETUP_QUERYMODE, - &(_this->hidden->MixSetupParms), 0); - if (rc!=MCIERR_SUCCESS) - { // The device cannot handle this format! - // Close DART, and exit with error code! - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Audio device doesn't support requested audio format"); - return(-1); - } - // The device can handle this format, so initialize! - rc = mciSendCommand(iDeviceOrd, MCI_MIXSETUP, - MCI_WAIT | MCI_MIXSETUP_INIT, - &(_this->hidden->MixSetupParms), 0); - if (rc!=MCIERR_SUCCESS) - { // The device could not be opened! - // Close DART, and exit with error code! - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Audio device could not be set up"); - return(-1); - } - // Ok, the device is initialized. - // Now we should allocate buffers. For this, we need a place where - // the buffer descriptors will be: - _this->hidden->pMixBuffers = (MCI_MIX_BUFFER *) SDL_malloc(sizeof(MCI_MIX_BUFFER)*iNumBufs); - if (!(_this->hidden->pMixBuffers)) - { // Not enough memory! - // Close DART, and exit with error code! - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Not enough memory for audio buffer descriptors"); - return(-1); - } - // Now that we have the place for buffer list, we can ask DART for the - // buffers! - _this->hidden->BufferParms.ulNumBuffers = iNumBufs; // Number of buffers - _this->hidden->BufferParms.ulBufferSize = iBufSize; // each with this size - _this->hidden->BufferParms.pBufList = _this->hidden->pMixBuffers; // getting descriptorts into this list - // Allocate buffers! - rc = mciSendCommand(iDeviceOrd, MCI_BUFFER, - MCI_WAIT | MCI_ALLOCATE_MEMORY, - &(_this->hidden->BufferParms), 0); - if ((rc!=MCIERR_SUCCESS) || (iNumBufs != _this->hidden->BufferParms.ulNumBuffers) || (_this->hidden->BufferParms.ulBufferSize==0)) - { // Could not allocate memory! - // Close DART, and exit with error code! - SDL_free(_this->hidden->pMixBuffers); _this->hidden->pMixBuffers = NULL; - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("DART could not allocate buffers"); - return(-1); - } - // Ok, we have all the buffers allocated, let's mark them! - { - int i; - for (i=0; ihidden->pMixBuffers[i].pBuffer)) || (!pBufferDesc)) - { // Wrong buffer! - // Close DART, and exit with error code! - // Free buffer descriptions - { int j; - for (j=0; jhidden->pMixBuffers[j].ulUserParm)); - } - // and cleanup - mciSendCommand(iDeviceOrd, MCI_BUFFER, MCI_WAIT | MCI_DEALLOCATE_MEMORY, &(_this->hidden->BufferParms), 0); - SDL_free(_this->hidden->pMixBuffers); _this->hidden->pMixBuffers = NULL; - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Error at internal buffer check"); - return(-1); - } - pBufferDesc->iBufferUsage = BUFFER_EMPTY; - pBufferDesc->pSDLAudioDevice = _this; - - _this->hidden->pMixBuffers[i].ulBufferLength = _this->hidden->BufferParms.ulBufferSize; - _this->hidden->pMixBuffers[i].ulUserParm = (ULONG) pBufferDesc; // User parameter: Description of buffer - _this->hidden->pMixBuffers[i].ulFlags = 0; // Some stuff should be flagged here for DART, like end of - // audio data, but as we will continously send - // audio data, there will be no end.:) - SDL_memset(_this->hidden->pMixBuffers[i].pBuffer, iSilence, iBufSize); - } - } - _this->hidden->iNextFreeBuffer = 0; - _this->hidden->iLastPlayedBuf = -1; - // Create event semaphore - if (DosCreateEventSem(NULL, &(_this->hidden->hevAudioBufferPlayed), 0, FALSE)!=NO_ERROR) - { - // Could not create event semaphore! - { - int i; - for (i=0; ihidden->pMixBuffers[i].ulUserParm)); - } - mciSendCommand(iDeviceOrd, MCI_BUFFER, MCI_WAIT | MCI_DEALLOCATE_MEMORY, &(_this->hidden->BufferParms), 0); - SDL_free(_this->hidden->pMixBuffers); _this->hidden->pMixBuffers = NULL; - mciSendCommand(iDeviceOrd, MCI_CLOSE, MCI_WAIT, &GenericParms, 0); - SDL_SetError("Could not create event semaphore"); - return(-1); - } - - // Store the new settings in global variables - _this->hidden->iCurrDeviceOrd = iDeviceOrd; - _this->hidden->iCurrFreq = iFreq; - _this->hidden->iCurrBits = iBits; - _this->hidden->iCurrChannels = iChannels; - _this->hidden->iCurrNumBufs = iNumBufs; - _this->hidden->iCurrBufSize = iBufSize; - - return (0); -} - - - -void DART_ThreadInit(_THIS) -{ - return; -} - -/* This function waits until it is possible to write a full sound buffer */ -void DART_WaitAudio(_THIS) -{ - int i; - pMixBufferDesc pBufDesc; - ULONG ulPostCount; - - DosResetEventSem(_this->hidden->hevAudioBufferPlayed, &ulPostCount); - // If there is already an empty buffer, then return now! - for (i=0; i<_this->hidden->iCurrNumBufs; i++) - { - pBufDesc = (pMixBufferDesc) _this->hidden->pMixBuffers[i].ulUserParm; - if (pBufDesc->iBufferUsage == BUFFER_EMPTY) - return; - } - // If there is no empty buffer, wait for one to be empty! - DosWaitEventSem(_this->hidden->hevAudioBufferPlayed, 1000); // Wait max 1 sec!!! Important! - return; -} - -void DART_PlayAudio(_THIS) -{ - int iFreeBuf = _this->hidden->iNextFreeBuffer; - pMixBufferDesc pBufDesc; - - pBufDesc = (pMixBufferDesc) _this->hidden->pMixBuffers[iFreeBuf].ulUserParm; - pBufDesc->iBufferUsage = BUFFER_USED; - // Send it to DART to be queued - _this->hidden->MixSetupParms.pmixWrite(_this->hidden->MixSetupParms.ulMixHandle, - &(_this->hidden->pMixBuffers[iFreeBuf]), 1); - - _this->hidden->iLastPlayedBuf = iFreeBuf; - iFreeBuf = (iFreeBuf+1) % _this->hidden->iCurrNumBufs; - _this->hidden->iNextFreeBuffer = iFreeBuf; -} - -Uint8 *DART_GetAudioBuf(_THIS) -{ - int iFreeBuf; - Uint8 *pResult; - pMixBufferDesc pBufDesc; - - if (_this) - { - if (_this->hidden) - { - iFreeBuf = _this->hidden->iNextFreeBuffer; - pBufDesc = (pMixBufferDesc) _this->hidden->pMixBuffers[iFreeBuf].ulUserParm; - - if (pBufDesc) - { - if (pBufDesc->iBufferUsage == BUFFER_EMPTY) - { - pResult = _this->hidden->pMixBuffers[iFreeBuf].pBuffer; - return pResult; - } - } else - printf("[DART_GetAudioBuf] : ERROR! pBufDesc = %p\n", pBufDesc); - } else - printf("[DART_GetAudioBuf] : ERROR! _this->hidden = %p\n", _this->hidden); - } else - printf("[DART_GetAudioBuf] : ERROR! _this = %p\n", _this); - return NULL; -} - -void DART_WaitDone(_THIS) -{ - pMixBufferDesc pBufDesc; - ULONG ulPostCount; - APIRET rc; - - pBufDesc = (pMixBufferDesc) _this->hidden->pMixBuffers[_this->hidden->iLastPlayedBuf].ulUserParm; - rc = NO_ERROR; - while ((pBufDesc->iBufferUsage != BUFFER_EMPTY) && (rc==NO_ERROR)) - { - DosResetEventSem(_this->hidden->hevAudioBufferPlayed, &ulPostCount); - rc = DosWaitEventSem(_this->hidden->hevAudioBufferPlayed, 1000); // 1 sec timeout! Important! - } -} - -void DART_CloseAudio(_THIS) -{ - MCI_GENERIC_PARMS GenericParms; - int rc; - - // Stop DART playback - rc = mciSendCommand(_this->hidden->iCurrDeviceOrd, MCI_STOP, MCI_WAIT, &GenericParms, 0); - if (rc!=MCIERR_SUCCESS) - { -#ifdef SFX_DEBUG_BUILD - printf("Could not stop DART playback!\n"); - fflush(stdout); -#endif - } - - // Close event semaphore - DosCloseEventSem(_this->hidden->hevAudioBufferPlayed); - - // Free memory of buffer descriptions - { - int i; - for (i=0; i<_this->hidden->iCurrNumBufs; i++) SDL_free((void *)(_this->hidden->pMixBuffers[i].ulUserParm)); - } - - // Deallocate buffers - rc = mciSendCommand(_this->hidden->iCurrDeviceOrd, MCI_BUFFER, MCI_WAIT | MCI_DEALLOCATE_MEMORY, &(_this->hidden->BufferParms), 0); - - // Free bufferlist - SDL_free(_this->hidden->pMixBuffers); _this->hidden->pMixBuffers = NULL; - - // Close dart - rc = mciSendCommand(_this->hidden->iCurrDeviceOrd, MCI_CLOSE, MCI_WAIT, &(GenericParms), 0); -} - -/* Audio driver bootstrap functions */ - -int Audio_Available(void) -{ - return(1); -} - -void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) - { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) - { - SDL_OutOfMemory(); - if ( this ) - SDL_free(this); - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = DART_OpenAudio; - this->ThreadInit = DART_ThreadInit; - this->WaitAudio = DART_WaitAudio; - this->PlayAudio = DART_PlayAudio; - this->GetAudioBuf = DART_GetAudioBuf; - this->WaitDone = DART_WaitDone; - this->CloseAudio = DART_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap DART_bootstrap = { - "dart", "OS/2 Direct Audio RouTines (DART)", - Audio_Available, Audio_CreateDevice -}; - diff --git a/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.h b/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.h deleted file mode 100644 index 895da00..0000000 --- a/distrib/sdl-1.2.12/src/audio/dart/SDL_dart.h +++ /dev/null @@ -1,63 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_lowaudio_h -#define _SDL_lowaudio_h - -#define INCL_TYPES -#define INCL_DOSSEMAPHORES -#define INCL_DOSRESOURCES -#define INCL_DOSMISC -#define INCL_DOSERRORS - -#define INCL_OS2MM -#define INCL_MMIOOS2 -#define INCL_MCIOS2 -#include -#include // DART stuff and MMIO stuff - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the audio functions */ -#define _THIS SDL_AudioDevice *_this - -/* The DirectSound objects */ -struct SDL_PrivateAudioData -{ - int iCurrDeviceOrd; - int iCurrFreq; - int iCurrBits; - int iCurrChannels; - int iCurrNumBufs; - int iCurrBufSize; - - int iLastPlayedBuf; - int iNextFreeBuffer; - - MCI_BUFFER_PARMS BufferParms; // Sound buffer parameters - MCI_MIX_BUFFER *pMixBuffers; // Sound buffers - MCI_MIXSETUP_PARMS MixSetupParms; // Mixer setup parameters - HEV hevAudioBufferPlayed; // Event semaphore to indicate that an audio buffer has been played by DART -}; - -#endif /* _SDL_lowaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.c b/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.c deleted file mode 100644 index a28ea5a..0000000 --- a/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.c +++ /dev/null @@ -1,246 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - -*/ -#include "SDL_config.h" - -/* Output dreamcast aica */ - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_dcaudio.h" - -#include "aica.h" -#include - -/* Audio driver functions */ -static int DCAUD_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void DCAUD_WaitAudio(_THIS); -static void DCAUD_PlayAudio(_THIS); -static Uint8 *DCAUD_GetAudioBuf(_THIS); -static void DCAUD_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ -static int DCAUD_Available(void) -{ - return 1; -} - -static void DCAUD_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *DCAUD_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = DCAUD_OpenAudio; - this->WaitAudio = DCAUD_WaitAudio; - this->PlayAudio = DCAUD_PlayAudio; - this->GetAudioBuf = DCAUD_GetAudioBuf; - this->CloseAudio = DCAUD_CloseAudio; - - this->free = DCAUD_DeleteDevice; - - spu_init(); - - return this; -} - -AudioBootStrap DCAUD_bootstrap = { - "dcaudio", "Dreamcast AICA audio", - DCAUD_Available, DCAUD_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void DCAUD_WaitAudio(_THIS) -{ - if (this->hidden->playing) { - /* wait */ - while(aica_get_pos(0)/this->spec.samples == this->hidden->nextbuf) { - thd_pass(); - } - } -} - -#define SPU_RAM_BASE 0xa0800000 - -static void spu_memload_stereo8(int leftpos,int rightpos,void *src0,size_t size) -{ - uint8 *src = src0; - uint32 *left = (uint32*)(leftpos +SPU_RAM_BASE); - uint32 *right = (uint32*)(rightpos+SPU_RAM_BASE); - size = (size+7)/8; - while(size--) { - unsigned lval,rval; - lval = *src++; - rval = *src++; - lval|= (*src++)<<8; - rval|= (*src++)<<8; - lval|= (*src++)<<16; - rval|= (*src++)<<16; - lval|= (*src++)<<24; - rval|= (*src++)<<24; - g2_write_32(left++,lval); - g2_write_32(right++,rval); - g2_fifo_wait(); - } -} - -static void spu_memload_stereo16(int leftpos,int rightpos,void *src0,size_t size) -{ - uint16 *src = src0; - uint32 *left = (uint32*)(leftpos +SPU_RAM_BASE); - uint32 *right = (uint32*)(rightpos+SPU_RAM_BASE); - size = (size+7)/8; - while(size--) { - unsigned lval,rval; - lval = *src++; - rval = *src++; - lval|= (*src++)<<16; - rval|= (*src++)<<16; - g2_write_32(left++,lval); - g2_write_32(right++,rval); - g2_fifo_wait(); - } -} - -static void DCAUD_PlayAudio(_THIS) -{ - SDL_AudioSpec *spec = &this->spec; - unsigned int offset; - - if (this->hidden->playing) { - /* wait */ - while(aica_get_pos(0)/spec->samples == this->hidden->nextbuf) { - thd_pass(); - } - } - - offset = this->hidden->nextbuf*spec->size; - this->hidden->nextbuf^=1; - /* Write the audio data, checking for EAGAIN on broken audio drivers */ - if (spec->channels==1) { - spu_memload(this->hidden->leftpos+offset,this->hidden->mixbuf,this->hidden->mixlen); - } else { - offset/=2; - if ((this->spec.format&255)==8) { - spu_memload_stereo8(this->hidden->leftpos+offset,this->hidden->rightpos+offset,this->hidden->mixbuf,this->hidden->mixlen); - } else { - spu_memload_stereo16(this->hidden->leftpos+offset,this->hidden->rightpos+offset,this->hidden->mixbuf,this->hidden->mixlen); - } - } - - if (!this->hidden->playing) { - int mode; - this->hidden->playing = 1; - mode = (spec->format==AUDIO_S8)?SM_8BIT:SM_16BIT; - if (spec->channels==1) { - aica_play(0,mode,this->hidden->leftpos,0,spec->samples*2,spec->freq,255,128,1); - } else { - aica_play(0,mode,this->hidden->leftpos ,0,spec->samples*2,spec->freq,255,0,1); - aica_play(1,mode,this->hidden->rightpos,0,spec->samples*2,spec->freq,255,255,1); - } - } -} - -static Uint8 *DCAUD_GetAudioBuf(_THIS) -{ - return(this->hidden->mixbuf); -} - -static void DCAUD_CloseAudio(_THIS) -{ - aica_stop(0); - if (this->spec.channels==2) aica_stop(1); - if ( this->hidden->mixbuf != NULL ) { - SDL_FreeAudioMem(this->hidden->mixbuf); - this->hidden->mixbuf = NULL; - } -} - -static int DCAUD_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - Uint16 test_format = SDL_FirstAudioFormat(spec->format); - int valid_datatype = 0; - while ((!valid_datatype) && (test_format)) { - spec->format = test_format; - switch (test_format) { - /* only formats Dreamcast accepts... */ - case AUDIO_S8: - case AUDIO_S16LSB: - valid_datatype = 1; - break; - - default: - test_format = SDL_NextAudioFormat(); - break; - } - } - - if (!valid_datatype) { /* shouldn't happen, but just in case... */ - SDL_SetError("Unsupported audio format"); - return (-1); - } - - if (spec->channels > 2) - spec->channels = 2; /* no more than stereo on the Dreamcast. */ - - /* Update the fragment size as size in bytes */ - SDL_CalculateAudioSpec(spec); - - /* Allocate mixing buffer */ - this->hidden->mixlen = spec->size; - this->hidden->mixbuf = (Uint8 *) SDL_AllocAudioMem(this->hidden->mixlen); - if ( this->hidden->mixbuf == NULL ) { - return(-1); - } - SDL_memset(this->hidden->mixbuf, spec->silence, spec->size); - this->hidden->leftpos = 0x11000; - this->hidden->rightpos = 0x11000+spec->size; - this->hidden->playing = 0; - this->hidden->nextbuf = 0; - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.h b/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.h deleted file mode 100644 index a5b01d3..0000000 --- a/distrib/sdl-1.2.12/src/audio/dc/SDL_dcaudio.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_dcaudio_h -#define _SDL_dcaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - Uint8 *mixbuf; - Uint32 mixlen; - int playing; - int leftpos,rightpos; - int nextbuf; -}; - -#endif /* _SDL_dcaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dc/aica.c b/distrib/sdl-1.2.12/src/audio/dc/aica.c deleted file mode 100644 index b6a1c93..0000000 --- a/distrib/sdl-1.2.12/src/audio/dc/aica.c +++ /dev/null @@ -1,271 +0,0 @@ -/* This file is part of the Dreamcast function library. - * Please see libdream.c for further details. - * - * (c)2000 Dan Potter - * modify BERO - */ -#include "aica.h" - -#include -#include - -/* #define dc_snd_base ((volatile unsigned char *)0x00800000) */ /* arm side */ -#define dc_snd_base ((volatile unsigned char *)0xa0700000) /* dc side */ - -/* Some convienence macros */ -#define SNDREGADDR(x) (0xa0700000 + (x)) -#define CHNREGADDR(ch,x) SNDREGADDR(0x80*(ch)+(x)) - - -#define SNDREG32(x) (*(volatile unsigned long *)SNDREGADDR(x)) -#define SNDREG8(x) (*(volatile unsigned char *)SNDREGADDR(x)) -#define CHNREG32(ch, x) (*(volatile unsigned long *)CHNREGADDR(ch,x)) -#define CHNREG8(ch, x) (*(volatile unsigned long *)CHNREGADDR(ch,x)) - -#define G2_LOCK(OLD) \ - do { \ - if (!irq_inside_int()) \ - OLD = irq_disable(); \ - /* suspend any G2 DMA here... */ \ - while((*(volatile unsigned int *)0xa05f688c) & 0x20) \ - ; \ - } while(0) - -#define G2_UNLOCK(OLD) \ - do { \ - /* resume any G2 DMA here... */ \ - if (!irq_inside_int()) \ - irq_restore(OLD); \ - } while(0) - - -void aica_init() { - int i, j, old = 0; - - /* Initialize AICA channels */ - G2_LOCK(old); - SNDREG32(0x2800) = 0x0000; - - for (i=0; i<64; i++) { - for (j=0; j<0x80; j+=4) { - if ((j&31)==0) g2_fifo_wait(); - CHNREG32(i, j) = 0; - } - g2_fifo_wait(); - CHNREG32(i,0) = 0x8000; - CHNREG32(i,20) = 0x1f; - } - - SNDREG32(0x2800) = 0x000f; - g2_fifo_wait(); - G2_UNLOCK(old); -} - -/* Translates a volume from linear form to logarithmic form (required by - the AICA chip */ -/* int logs[] = { - -0, 40, 50, 58, 63, 68, 73, 77, 80, 83, 86, 89, 92, 94, 97, 99, 101, 103, -105, 107, 109, 111, 112, 114, 116, 117, 119, 120, 122, 123, 125, 126, 127, -129, 130, 131, 133, 134, 135, 136, 137, 139, 140, 141, 142, 143, 144, 145, -146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 156, 157, 158, 159, -160, 161, 162, 162, 163, 164, 165, 166, 166, 167, 168, 169, 170, 170, 171, -172, 172, 173, 174, 175, 175, 176, 177, 177, 178, 179, 180, 180, 181, 182, -182, 183, 183, 184, 185, 185, 186, 187, 187, 188, 188, 189, 190, 190, 191, -191, 192, 193, 193, 194, 194, 195, 196, 196, 197, 197, 198, 198, 199, 199, -200, 201, 201, 202, 202, 203, 203, 204, 204, 205, 205, 206, 206, 207, 207, -208, 208, 209, 209, 210, 210, 211, 211, 212, 212, 213, 213, 214, 214, 215, -215, 216, 216, 217, 217, 217, 218, 218, 219, 219, 220, 220, 221, 221, 222, -222, 222, 223, 223, 224, 224, 225, 225, 225, 226, 226, 227, 227, 228, 228, -228, 229, 229, 230, 230, 230, 231, 231, 232, 232, 232, 233, 233, 234, 234, -234, 235, 235, 236, 236, 236, 237, 237, 238, 238, 238, 239, 239, 240, 240, -240, 241, 241, 241, 242, 242, 243, 243, 243, 244, 244, 244, 245, 245, 245, -246, 246, 247, 247, 247, 248, 248, 248, 249, 249, 249, 250, 250, 250, 251, -251, 251, 252, 252, 252, 253, 253, 253, 254, 254, 254, 255 - -}; */ - -const static unsigned char logs[] = { - 0, 15, 22, 27, 31, 35, 39, 42, 45, 47, 50, 52, 55, 57, 59, 61, - 63, 65, 67, 69, 71, 73, 74, 76, 78, 79, 81, 82, 84, 85, 87, 88, - 90, 91, 92, 94, 95, 96, 98, 99, 100, 102, 103, 104, 105, 106, - 108, 109, 110, 111, 112, 113, 114, 116, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, - 135, 136, 137, 138, 138, 139, 140, 141, 142, 143, 144, 145, 146, - 146, 147, 148, 149, 150, 151, 152, 152, 153, 154, 155, 156, 156, - 157, 158, 159, 160, 160, 161, 162, 163, 164, 164, 165, 166, 167, - 167, 168, 169, 170, 170, 171, 172, 173, 173, 174, 175, 176, 176, - 177, 178, 178, 179, 180, 181, 181, 182, 183, 183, 184, 185, 185, - 186, 187, 187, 188, 189, 189, 190, 191, 191, 192, 193, 193, 194, - 195, 195, 196, 197, 197, 198, 199, 199, 200, 200, 201, 202, 202, - 203, 204, 204, 205, 205, 206, 207, 207, 208, 209, 209, 210, 210, - 211, 212, 212, 213, 213, 214, 215, 215, 216, 216, 217, 217, 218, - 219, 219, 220, 220, 221, 221, 222, 223, 223, 224, 224, 225, 225, - 226, 227, 227, 228, 228, 229, 229, 230, 230, 231, 232, 232, 233, - 233, 234, 234, 235, 235, 236, 236, 237, 237, 238, 239, 239, 240, - 240, 241, 241, 242, 242, 243, 243, 244, 244, 245, 245, 246, 246, - 247, 247, 248, 248, 249, 249, 250, 250, 251, 251, 252, 252, 253, 254, 255 -}; - -/* For the moment this is going to have to suffice, until we really - figure out what these mean. */ -#define AICA_PAN(x) ((x)==0x80?(0):((x)<0x80?(0x1f):(0x0f))) -#define AICA_VOL(x) (0xff - logs[128 + (((x) & 0xff) / 2)]) -//#define AICA_VOL(x) (0xff - logs[x&255]) - -static inline unsigned AICA_FREQ(unsigned freq) { - unsigned long freq_lo, freq_base = 5644800; - int freq_hi = 7; - - /* Need to convert frequency to floating point format - (freq_hi is exponent, freq_lo is mantissa) - Formula is ferq = 44100*2^freq_hi*(1+freq_lo/1024) */ - while (freq < freq_base && freq_hi > -8) { - freq_base >>= 1; - --freq_hi; - } - while (freq < freq_base && freq_hi > -8) { - freq_base >>= 1; - freq_hi--; - } - freq_lo = (freq<<10) / freq_base; - return (freq_hi << 11) | (freq_lo & 1023); -} - -/* Sets up a sound channel completely. This is generally good if you want - a quick and dirty way to play notes. If you want a more comprehensive - set of routines (more like PC wavetable cards) see below. - - ch is the channel to play on (0 - 63) - smpptr is the pointer to the sound data; if you're running off the - SH4, then this ought to be (ptr - 0xa0800000); otherwise it's just - ptr. Basically, it's an offset into sound ram. - mode is one of the mode constants (16 bit, 8 bit, ADPCM) - nsamp is the number of samples to play (not number of bytes!) - freq is the sampling rate of the sound - vol is the volume, 0 to 0xff (0xff is louder) - pan is a panning constant -- 0 is left, 128 is center, 255 is right. - - This routine (and the similar ones) owe a lot to Marcus' sound example -- - I hadn't gotten quite this far into dissecting the individual regs yet. */ -void aica_play(int ch,int mode,unsigned long smpptr,int loopst,int loopend,int freq,int vol,int pan,int loopflag) { -/* int i; -*/ - int val; - int old = 0; - - /* Stop the channel (if it's already playing) */ - aica_stop(ch); - /* doesn't seem to be needed, but it's here just in case */ -/* - for (i=0; i<256; i++) { - asm("nop"); - asm("nop"); - asm("nop"); - asm("nop"); - } -*/ - G2_LOCK(old); - /* Envelope setup. The first of these is the loop point, - e.g., where the sample starts over when it loops. The second - is the loop end. This is the full length of the sample when - you are not looping, or the loop end point when you are (though - storing more than that is a waste of memory if you're not doing - volume enveloping). */ - CHNREG32(ch, 8) = loopst & 0xffff; - CHNREG32(ch, 12) = loopend & 0xffff; - - /* Write resulting values */ - CHNREG32(ch, 24) = AICA_FREQ(freq); - - /* Set volume, pan, and some other things that we don't know what - they do =) */ - CHNREG32(ch, 36) = AICA_PAN(pan) | (0xf<<8); - /* Convert the incoming volume and pan into hardware values */ - /* Vol starts at zero so we can ramp */ - vol = AICA_VOL(vol); - CHNREG32(ch, 40) = 0x24 | (vol<<8); - /* Convert the incoming volume and pan into hardware values */ - /* Vol starts at zero so we can ramp */ - - /* If we supported volume envelopes (which we don't yet) then - this value would set that up. The top 4 bits determine the - envelope speed. f is the fastest, 1 is the slowest, and 0 - seems to be an invalid value and does weird things). The - default (below) sets it into normal mode (play and terminate/loop). - CHNREG32(ch, 16) = 0xf010; - */ - CHNREG32(ch, 16) = 0x1f; /* No volume envelope */ - - - /* Set sample format, buffer address, and looping control. If - 0x0200 mask is set on reg 0, the sample loops infinitely. If - it's not set, the sample plays once and terminates. We'll - also set the bits to start playback here. */ - CHNREG32(ch, 4) = smpptr & 0xffff; - val = 0xc000 | 0x0000 | (mode<<7) | (smpptr >> 16); - if (loopflag) val|=0x200; - - CHNREG32(ch, 0) = val; - - G2_UNLOCK(old); - - /* Enable playback */ - /* CHNREG32(ch, 0) |= 0xc000; */ - g2_fifo_wait(); - -#if 0 - for (i=0xff; i>=vol; i--) { - if ((i&7)==0) g2_fifo_wait(); - CHNREG32(ch, 40) = 0x24 | (i<<8);; - } - - g2_fifo_wait(); -#endif -} - -/* Stop the sound on a given channel */ -void aica_stop(int ch) { - g2_write_32(CHNREGADDR(ch, 0),(g2_read_32(CHNREGADDR(ch, 0)) & ~0x4000) | 0x8000); - g2_fifo_wait(); -} - - -/* The rest of these routines can change the channel in mid-stride so you - can do things like vibrato and panning effects. */ - -/* Set channel volume */ -void aica_vol(int ch,int vol) { -// g2_write_8(CHNREGADDR(ch, 41),AICA_VOL(vol)); - g2_write_32(CHNREGADDR(ch, 40),(g2_read_32(CHNREGADDR(ch, 40))&0xffff00ff)|(AICA_VOL(vol)<<8) ); - g2_fifo_wait(); -} - -/* Set channel pan */ -void aica_pan(int ch,int pan) { -// g2_write_8(CHNREGADDR(ch, 36),AICA_PAN(pan)); - g2_write_32(CHNREGADDR(ch, 36),(g2_read_32(CHNREGADDR(ch, 36))&0xffffff00)|(AICA_PAN(pan)) ); - g2_fifo_wait(); -} - -/* Set channel frequency */ -void aica_freq(int ch,int freq) { - g2_write_32(CHNREGADDR(ch, 24),AICA_FREQ(freq)); - g2_fifo_wait(); -} - -/* Get channel position */ -int aica_get_pos(int ch) { -#if 1 - /* Observe channel ch */ - g2_write_32(SNDREGADDR(0x280c),(g2_read_32(SNDREGADDR(0x280c))&0xffff00ff) | (ch<<8)); - g2_fifo_wait(); - /* Update position counters */ - return g2_read_32(SNDREGADDR(0x2814)) & 0xffff; -#else - /* Observe channel ch */ - g2_write_8(SNDREGADDR(0x280d),ch); - /* Update position counters */ - return g2_read_32(SNDREGADDR(0x2814)) & 0xffff; -#endif -} diff --git a/distrib/sdl-1.2.12/src/audio/dc/aica.h b/distrib/sdl-1.2.12/src/audio/dc/aica.h deleted file mode 100644 index 93155d2..0000000 --- a/distrib/sdl-1.2.12/src/audio/dc/aica.h +++ /dev/null @@ -1,40 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _AICA_H_ -#define _AICA_H_ - -#define AICA_MEM 0xa0800000 - -#define SM_8BIT 1 -#define SM_16BIT 0 -#define SM_ADPCM 2 - -void aica_play(int ch,int mode,unsigned long smpptr,int looptst,int loopend,int freq,int vol,int pan,int loopflag); -void aica_stop(int ch); -void aica_vol(int ch,int vol); -void aica_pan(int ch,int pan); -void aica_freq(int ch,int freq); -int aica_get_pos(int ch); - -#endif diff --git a/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.c b/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.c deleted file mode 100644 index d896d9d..0000000 --- a/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.c +++ /dev/null @@ -1,186 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - - This file written by Ryan C. Gordon (icculus@icculus.org) -*/ -#include "SDL_config.h" - -/* Output raw audio data to a file. */ - -#if HAVE_STDIO_H -#include -#endif - -#include "SDL_rwops.h" -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_diskaudio.h" - -/* The tag name used by DISK audio */ -#define DISKAUD_DRIVER_NAME "disk" - -/* environment variables and defaults. */ -#define DISKENVR_OUTFILE "SDL_DISKAUDIOFILE" -#define DISKDEFAULT_OUTFILE "sdlaudio.raw" -#define DISKENVR_WRITEDELAY "SDL_DISKAUDIODELAY" -#define DISKDEFAULT_WRITEDELAY 150 - -/* Audio driver functions */ -static int DISKAUD_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void DISKAUD_WaitAudio(_THIS); -static void DISKAUD_PlayAudio(_THIS); -static Uint8 *DISKAUD_GetAudioBuf(_THIS); -static void DISKAUD_CloseAudio(_THIS); - -static const char *DISKAUD_GetOutputFilename(void) -{ - const char *envr = SDL_getenv(DISKENVR_OUTFILE); - return((envr != NULL) ? envr : DISKDEFAULT_OUTFILE); -} - -/* Audio driver bootstrap functions */ -static int DISKAUD_Available(void) -{ - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - if (envr && (SDL_strcmp(envr, DISKAUD_DRIVER_NAME) == 0)) { - return(1); - } - return(0); -} - -static void DISKAUD_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *DISKAUD_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - const char *envr; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - envr = SDL_getenv(DISKENVR_WRITEDELAY); - this->hidden->write_delay = (envr) ? SDL_atoi(envr) : DISKDEFAULT_WRITEDELAY; - - /* Set the function pointers */ - this->OpenAudio = DISKAUD_OpenAudio; - this->WaitAudio = DISKAUD_WaitAudio; - this->PlayAudio = DISKAUD_PlayAudio; - this->GetAudioBuf = DISKAUD_GetAudioBuf; - this->CloseAudio = DISKAUD_CloseAudio; - - this->free = DISKAUD_DeleteDevice; - - return this; -} - -AudioBootStrap DISKAUD_bootstrap = { - DISKAUD_DRIVER_NAME, "direct-to-disk audio", - DISKAUD_Available, DISKAUD_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void DISKAUD_WaitAudio(_THIS) -{ - SDL_Delay(this->hidden->write_delay); -} - -static void DISKAUD_PlayAudio(_THIS) -{ - int written; - - /* Write the audio data */ - written = SDL_RWwrite(this->hidden->output, - this->hidden->mixbuf, 1, - this->hidden->mixlen); - - /* If we couldn't write, assume fatal error for now */ - if ( (Uint32)written != this->hidden->mixlen ) { - this->enabled = 0; - } -#ifdef DEBUG_AUDIO - fprintf(stderr, "Wrote %d bytes of audio data\n", written); -#endif -} - -static Uint8 *DISKAUD_GetAudioBuf(_THIS) -{ - return(this->hidden->mixbuf); -} - -static void DISKAUD_CloseAudio(_THIS) -{ - if ( this->hidden->mixbuf != NULL ) { - SDL_FreeAudioMem(this->hidden->mixbuf); - this->hidden->mixbuf = NULL; - } - if ( this->hidden->output != NULL ) { - SDL_RWclose(this->hidden->output); - this->hidden->output = NULL; - } -} - -static int DISKAUD_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - const char *fname = DISKAUD_GetOutputFilename(); - - /* Open the audio device */ - this->hidden->output = SDL_RWFromFile(fname, "wb"); - if ( this->hidden->output == NULL ) { - return(-1); - } - -#if HAVE_STDIO_H - fprintf(stderr, "WARNING: You are using the SDL disk writer" - " audio driver!\n Writing to file [%s].\n", fname); -#endif - - /* Allocate mixing buffer */ - this->hidden->mixlen = spec->size; - this->hidden->mixbuf = (Uint8 *) SDL_AllocAudioMem(this->hidden->mixlen); - if ( this->hidden->mixbuf == NULL ) { - return(-1); - } - SDL_memset(this->hidden->mixbuf, spec->silence, spec->size); - - /* We're ready to rock and roll. :-) */ - return(0); -} - diff --git a/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.h b/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.h deleted file mode 100644 index 2ddd68f..0000000 --- a/distrib/sdl-1.2.12/src/audio/disk/SDL_diskaudio.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_diskaudio_h -#define _SDL_diskaudio_h - -#include "SDL_rwops.h" -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - SDL_RWops *output; - Uint8 *mixbuf; - Uint32 mixlen; - Uint32 write_delay; -}; - -#endif /* _SDL_diskaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.c b/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.c deleted file mode 100644 index 84734a3..0000000 --- a/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.c +++ /dev/null @@ -1,455 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include -#include /* For strerror() */ -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#if SDL_AUDIO_DRIVER_OSS_SOUNDCARD_H -/* This is installed on some systems */ -#include -#else -/* This is recommended by OSS */ -#include -#endif - -#ifndef MAP_FAILED -#define MAP_FAILED ((Uint8 *)-1) -#endif - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_dmaaudio.h" - -/* The tag name used by DMA audio */ -#define DMA_DRIVER_NAME "dma" - -/* Open the audio device for playback, and don't block if busy */ -#define OPEN_FLAGS (O_RDWR|O_NONBLOCK) - -/* Audio driver functions */ -static int DMA_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void DMA_WaitAudio(_THIS); -static void DMA_PlayAudio(_THIS); -static Uint8 *DMA_GetAudioBuf(_THIS); -static void DMA_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - int available; - int fd; - - available = 0; - - fd = SDL_OpenAudioPath(NULL, 0, OPEN_FLAGS, 0); - if ( fd >= 0 ) { - int caps; - struct audio_buf_info info; - - if ( (ioctl(fd, SNDCTL_DSP_GETCAPS, &caps) == 0) && - (caps & DSP_CAP_TRIGGER) && (caps & DSP_CAP_MMAP) && - (ioctl(fd, SNDCTL_DSP_GETOSPACE, &info) == 0) ) { - available = 1; - } - close(fd); - } - return(available); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - audio_fd = -1; - - /* Set the function pointers */ - this->OpenAudio = DMA_OpenAudio; - this->WaitAudio = DMA_WaitAudio; - this->PlayAudio = DMA_PlayAudio; - this->GetAudioBuf = DMA_GetAudioBuf; - this->CloseAudio = DMA_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap DMA_bootstrap = { - DMA_DRIVER_NAME, "OSS /dev/dsp DMA audio", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void DMA_WaitAudio(_THIS) -{ - fd_set fdset; - - /* Check to see if the thread-parent process is still alive */ - { static int cnt = 0; - /* Note that this only works with thread implementations - that use a different process id for each thread. - */ - if (parent && (((++cnt)%10) == 0)) { /* Check every 10 loops */ - if ( kill(parent, 0) < 0 ) { - this->enabled = 0; - } - } - } - - /* See if we need to use timed audio synchronization */ - if ( frame_ticks ) { - /* Use timer for general audio synchronization */ - Sint32 ticks; - - ticks = ((Sint32)(next_frame - SDL_GetTicks()))-FUDGE_TICKS; - if ( ticks > 0 ) { - SDL_Delay(ticks); - } - } else { - /* Use select() for audio synchronization */ - struct timeval timeout; - FD_ZERO(&fdset); - FD_SET(audio_fd, &fdset); - timeout.tv_sec = 10; - timeout.tv_usec = 0; -#ifdef DEBUG_AUDIO - fprintf(stderr, "Waiting for audio to get ready\n"); -#endif - if ( select(audio_fd+1, NULL, &fdset, NULL, &timeout) <= 0 ) { - const char *message = -#ifdef AUDIO_OSPACE_HACK - "Audio timeout - buggy audio driver? (trying ospace)"; -#else - "Audio timeout - buggy audio driver? (disabled)"; -#endif - /* In general we should never print to the screen, - but in this case we have no other way of letting - the user know what happened. - */ - fprintf(stderr, "SDL: %s\n", message); -#ifdef AUDIO_OSPACE_HACK - /* We may be able to use GET_OSPACE trick */ - frame_ticks = (float)(this->spec->samples*1000) / - this->spec->freq; - next_frame = SDL_GetTicks()+frame_ticks; -#else - this->enabled = 0; - /* Don't try to close - may hang */ - audio_fd = -1; -#ifdef DEBUG_AUDIO - fprintf(stderr, "Done disabling audio\n"); -#endif -#endif /* AUDIO_OSPACE_HACK */ - } -#ifdef DEBUG_AUDIO - fprintf(stderr, "Ready!\n"); -#endif - } -} - -static void DMA_PlayAudio(_THIS) -{ - /* If timer synchronization is enabled, set the next write frame */ - if ( frame_ticks ) { - next_frame += frame_ticks; - } - return; -} - -static Uint8 *DMA_GetAudioBuf(_THIS) -{ - count_info info; - int playing; - int filling; - - /* Get number of blocks, looping if we're not using select() */ - do { - if ( ioctl(audio_fd, SNDCTL_DSP_GETOPTR, &info) < 0 ) { - /* Uh oh... */ - this->enabled = 0; - return(NULL); - } - } while ( frame_ticks && (info.blocks < 1) ); -#ifdef DEBUG_AUDIO - if ( info.blocks > 1 ) { - printf("Warning: audio underflow (%d frags)\n", info.blocks-1); - } -#endif - playing = info.ptr / this->spec.size; - filling = (playing + 1)%num_buffers; - return (dma_buf + (filling * this->spec.size)); -} - -static void DMA_CloseAudio(_THIS) -{ - if ( dma_buf != NULL ) { - munmap(dma_buf, dma_len); - dma_buf = NULL; - } - if ( audio_fd >= 0 ) { - close(audio_fd); - audio_fd = -1; - } -} - -static int DMA_ReopenAudio(_THIS, const char *audiodev, int format, int stereo, - SDL_AudioSpec *spec) -{ - int frag_spec; - int value; - - /* Close and then reopen the audio device */ - close(audio_fd); - audio_fd = open(audiodev, O_RDWR, 0); - if ( audio_fd < 0 ) { - SDL_SetError("Couldn't open %s: %s", audiodev, strerror(errno)); - return(-1); - } - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Determine the power of two of the fragment size */ - for ( frag_spec = 0; (0x01<size; ++frag_spec ); - if ( (0x01<size ) { - SDL_SetError("Fragment size must be a power of two"); - return(-1); - } - - /* Set the audio buffering parameters */ - if ( ioctl(audio_fd, SNDCTL_DSP_SETFRAGMENT, &frag_spec) < 0 ) { - SDL_SetError("Couldn't set audio fragment spec"); - return(-1); - } - - /* Set the audio format */ - value = format; - if ( (ioctl(audio_fd, SNDCTL_DSP_SETFMT, &value) < 0) || - (value != format) ) { - SDL_SetError("Couldn't set audio format"); - return(-1); - } - - /* Set mono or stereo audio */ - value = (spec->channels > 1); - if ( (ioctl(audio_fd, SNDCTL_DSP_STEREO, &stereo) < 0) || - (value != stereo) ) { - SDL_SetError("Couldn't set audio channels"); - return(-1); - } - - /* Set the DSP frequency */ - value = spec->freq; - if ( ioctl(audio_fd, SNDCTL_DSP_SPEED, &value) < 0 ) { - SDL_SetError("Couldn't set audio frequency"); - return(-1); - } - spec->freq = value; - - /* We successfully re-opened the audio */ - return(0); -} - -static int DMA_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - char audiodev[1024]; - int format; - int stereo; - int value; - Uint16 test_format; - struct audio_buf_info info; - - /* Reset the timer synchronization flag */ - frame_ticks = 0.0; - - /* Open the audio device */ - audio_fd = SDL_OpenAudioPath(audiodev, sizeof(audiodev), OPEN_FLAGS, 0); - if ( audio_fd < 0 ) { - SDL_SetError("Couldn't open %s: %s", audiodev, strerror(errno)); - return(-1); - } - dma_buf = NULL; - ioctl(audio_fd, SNDCTL_DSP_RESET, 0); - - /* Get a list of supported hardware formats */ - if ( ioctl(audio_fd, SNDCTL_DSP_GETFMTS, &value) < 0 ) { - SDL_SetError("Couldn't get audio format list"); - return(-1); - } - - /* Try for a closest match on audio format */ - format = 0; - for ( test_format = SDL_FirstAudioFormat(spec->format); - ! format && test_format; ) { -#ifdef DEBUG_AUDIO - fprintf(stderr, "Trying format 0x%4.4x\n", test_format); -#endif - switch ( test_format ) { - case AUDIO_U8: - if ( value & AFMT_U8 ) { - format = AFMT_U8; - } - break; - case AUDIO_S8: - if ( value & AFMT_S8 ) { - format = AFMT_S8; - } - break; - case AUDIO_S16LSB: - if ( value & AFMT_S16_LE ) { - format = AFMT_S16_LE; - } - break; - case AUDIO_S16MSB: - if ( value & AFMT_S16_BE ) { - format = AFMT_S16_BE; - } - break; - case AUDIO_U16LSB: - if ( value & AFMT_U16_LE ) { - format = AFMT_U16_LE; - } - break; - case AUDIO_U16MSB: - if ( value & AFMT_U16_BE ) { - format = AFMT_U16_BE; - } - break; - default: - format = 0; - break; - } - if ( ! format ) { - test_format = SDL_NextAudioFormat(); - } - } - if ( format == 0 ) { - SDL_SetError("Couldn't find any hardware audio formats"); - return(-1); - } - spec->format = test_format; - - /* Set the audio format */ - value = format; - if ( (ioctl(audio_fd, SNDCTL_DSP_SETFMT, &value) < 0) || - (value != format) ) { - SDL_SetError("Couldn't set audio format"); - return(-1); - } - - /* Set mono or stereo audio (currently only two channels supported) */ - stereo = (spec->channels > 1); - ioctl(audio_fd, SNDCTL_DSP_STEREO, &stereo); - if ( stereo ) { - spec->channels = 2; - } else { - spec->channels = 1; - } - - /* Because some drivers don't allow setting the buffer size - after setting the format, we must re-open the audio device - once we know what format and channels are supported - */ - if ( DMA_ReopenAudio(this, audiodev, format, stereo, spec) < 0 ) { - /* Error is set by DMA_ReopenAudio() */ - return(-1); - } - - /* Memory map the audio buffer */ - if ( ioctl(audio_fd, SNDCTL_DSP_GETOSPACE, &info) < 0 ) { - SDL_SetError("Couldn't get OSPACE parameters"); - return(-1); - } - spec->size = info.fragsize; - spec->samples = spec->size / ((spec->format & 0xFF) / 8); - spec->samples /= spec->channels; - num_buffers = info.fragstotal; - dma_len = num_buffers*spec->size; - dma_buf = (Uint8 *)mmap(NULL, dma_len, PROT_WRITE, MAP_SHARED, - audio_fd, 0); - if ( dma_buf == MAP_FAILED ) { - SDL_SetError("DMA memory map failed"); - dma_buf = NULL; - return(-1); - } - SDL_memset(dma_buf, spec->silence, dma_len); - - /* Check to see if we need to use select() workaround */ - { char *workaround; - workaround = SDL_getenv("SDL_DSP_NOSELECT"); - if ( workaround ) { - frame_ticks = (float)(spec->samples*1000)/spec->freq; - next_frame = SDL_GetTicks()+frame_ticks; - } - } - - /* Trigger audio playback */ - value = 0; - ioctl(audio_fd, SNDCTL_DSP_SETTRIGGER, &value); - value = PCM_ENABLE_OUTPUT; - if ( ioctl(audio_fd, SNDCTL_DSP_SETTRIGGER, &value) < 0 ) { - SDL_SetError("Couldn't trigger audio output"); - return(-1); - } - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.h b/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.h deleted file mode 100644 index ca8c05a..0000000 --- a/distrib/sdl-1.2.12/src/audio/dma/SDL_dmaaudio.h +++ /dev/null @@ -1,59 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_dspaudio_h -#define _SDL_dspaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - int audio_fd; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *dma_buf; - int dma_len; - int num_buffers; - - /* Support for audio timing using a timer, in addition to select() */ - float frame_ticks; - float next_frame; -}; -#define FUDGE_TICKS 10 /* The scheduler overhead ticks per frame */ - -/* Old variable names */ -#define audio_fd (this->hidden->audio_fd) -#define parent (this->hidden->parent) -#define dma_buf (this->hidden->dma_buf) -#define dma_len (this->hidden->dma_len) -#define num_buffers (this->hidden->num_buffers) -#define frame_ticks (this->hidden->frame_ticks) -#define next_frame (this->hidden->next_frame) - -#endif /* _SDL_dspaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.c b/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.c deleted file mode 100644 index f9bd310..0000000 --- a/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.c +++ /dev/null @@ -1,242 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer (For IRIX 6.5 and higher) */ -/* patch for IRIX 5 by Georg Schwarz 18/07/2004 */ - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "SDL_irixaudio.h" - - -#ifndef AL_RESOURCE /* as a test whether we use the old IRIX audio libraries */ -#define OLD_IRIX_AUDIO -#define alClosePort(x) ALcloseport(x) -#define alFreeConfig(x) ALfreeconfig(x) -#define alGetFillable(x) ALgetfillable(x) -#define alNewConfig() ALnewconfig() -#define alOpenPort(x,y,z) ALopenport(x,y,z) -#define alSetChannels(x,y) ALsetchannels(x,y) -#define alSetQueueSize(x,y) ALsetqueuesize(x,y) -#define alSetSampFmt(x,y) ALsetsampfmt(x,y) -#define alSetWidth(x,y) ALsetwidth(x,y) -#endif - -/* Audio driver functions */ -static int AL_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void AL_WaitAudio(_THIS); -static void AL_PlayAudio(_THIS); -static Uint8 *AL_GetAudioBuf(_THIS); -static void AL_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - return 1; -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = AL_OpenAudio; - this->WaitAudio = AL_WaitAudio; - this->PlayAudio = AL_PlayAudio; - this->GetAudioBuf = AL_GetAudioBuf; - this->CloseAudio = AL_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap DMEDIA_bootstrap = { - "AL", "IRIX DMedia audio", - Audio_Available, Audio_CreateDevice -}; - - -void static AL_WaitAudio(_THIS) -{ - Sint32 timeleft; - - timeleft = this->spec.samples - alGetFillable(audio_port); - if ( timeleft > 0 ) { - timeleft /= (this->spec.freq/1000); - SDL_Delay((Uint32)timeleft); - } -} - -static void AL_PlayAudio(_THIS) -{ - /* Write the audio data out */ - if ( alWriteFrames(audio_port, mixbuf, this->spec.samples) < 0 ) { - /* Assume fatal error, for now */ - this->enabled = 0; - } -} - -static Uint8 *AL_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void AL_CloseAudio(_THIS) -{ - if ( mixbuf != NULL ) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if ( audio_port != NULL ) { - alClosePort(audio_port); - audio_port = NULL; - } -} - -static int AL_OpenAudio(_THIS, SDL_AudioSpec * spec) -{ - Uint16 test_format = SDL_FirstAudioFormat(spec->format); - long width = 0; - long fmt = 0; - int valid = 0; - -#ifdef OLD_IRIX_AUDIO - { - long audio_param[2]; - audio_param[0] = AL_OUTPUT_RATE; - audio_param[1] = spec->freq; - valid = (ALsetparams(AL_DEFAULT_DEVICE, audio_param, 2) < 0); - } -#else - { - ALpv audio_param; - audio_param.param = AL_RATE; - audio_param.value.i = spec->freq; - valid = (alSetParams(AL_DEFAULT_OUTPUT, &audio_param, 1) < 0); - } -#endif - - while ((!valid) && (test_format)) { - valid = 1; - spec->format = test_format; - - switch (test_format) { - case AUDIO_S8: - width = AL_SAMPLE_8; - fmt = AL_SAMPFMT_TWOSCOMP; - break; - - case AUDIO_S16SYS: - width = AL_SAMPLE_16; - fmt = AL_SAMPFMT_TWOSCOMP; - break; - - default: - valid = 0; - test_format = SDL_NextAudioFormat(); - break; - } - - if (valid) { - ALconfig audio_config = alNewConfig(); - valid = 0; - if (audio_config) { - if (alSetChannels(audio_config, spec->channels) < 0) { - if (spec->channels > 2) { /* can't handle > stereo? */ - spec->channels = 2; /* try again below. */ - } - } - - if ((alSetSampFmt(audio_config, fmt) >= 0) && - ((!width) || (alSetWidth(audio_config, width) >= 0)) && - (alSetQueueSize(audio_config, spec->samples * 2) >= 0) && - (alSetChannels(audio_config, spec->channels) >= 0)) { - - audio_port = alOpenPort("SDL audio", "w", audio_config); - if (audio_port == NULL) { - /* docs say AL_BAD_CHANNELS happens here, too. */ - int err = oserror(); - if (err == AL_BAD_CHANNELS) { - spec->channels = 2; - alSetChannels(audio_config, spec->channels); - audio_port = alOpenPort("SDL audio", "w", - audio_config); - } - } - - if (audio_port != NULL) { - valid = 1; - } - } - - alFreeConfig(audio_config); - } - } - } - - if (!valid) { - SDL_SetError("Unsupported audio format"); - return (-1); - } - - /* Update the fragment size as size in bytes */ - SDL_CalculateAudioSpec(spec); - - /* Allocate mixing buffer */ - mixbuf = (Uint8 *) SDL_AllocAudioMem(spec->size); - if (mixbuf == NULL) { - SDL_OutOfMemory(); - return (-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* We're ready to rock and roll. :-) */ - return (0); -} - diff --git a/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.h b/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.h deleted file mode 100644 index 751de41..0000000 --- a/distrib/sdl-1.2.12/src/audio/dmedia/SDL_irixaudio.h +++ /dev/null @@ -1,45 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_lowaudio_h -#define _SDL_lowaudio_h - -#include - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the audio functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The handle for the audio device */ - ALport audio_port; - - Uint8 *mixbuf; /* The app mixing buffer */ -}; - -/* Old variable names */ -#define audio_port (this->hidden->audio_port) -#define mixbuf (this->hidden->mixbuf) - -#endif /* _SDL_lowaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.c b/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.c deleted file mode 100644 index 95617e3..0000000 --- a/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.c +++ /dev/null @@ -1,340 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - - Modified in Oct 2004 by Hannu Savolainen - hannu@opensound.com -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include /* For perror() */ -#include /* For strerror() */ -#include -#include -#include -#include -#include -#include -#include - -#if SDL_AUDIO_DRIVER_OSS_SOUNDCARD_H -/* This is installed on some systems */ -#include -#else -/* This is recommended by OSS */ -#include -#endif - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_dspaudio.h" - -/* The tag name used by DSP audio */ -#define DSP_DRIVER_NAME "dsp" - -/* Open the audio device for playback, and don't block if busy */ -#define OPEN_FLAGS (O_WRONLY|O_NONBLOCK) - -/* Audio driver functions */ -static int DSP_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void DSP_WaitAudio(_THIS); -static void DSP_PlayAudio(_THIS); -static Uint8 *DSP_GetAudioBuf(_THIS); -static void DSP_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - int fd; - int available; - - available = 0; - fd = SDL_OpenAudioPath(NULL, 0, OPEN_FLAGS, 0); - if ( fd >= 0 ) { - available = 1; - close(fd); - } - return(available); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - audio_fd = -1; - - /* Set the function pointers */ - this->OpenAudio = DSP_OpenAudio; - this->WaitAudio = DSP_WaitAudio; - this->PlayAudio = DSP_PlayAudio; - this->GetAudioBuf = DSP_GetAudioBuf; - this->CloseAudio = DSP_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap DSP_bootstrap = { - DSP_DRIVER_NAME, "OSS /dev/dsp standard audio", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void DSP_WaitAudio(_THIS) -{ - /* Not needed at all since OSS handles waiting automagically */ -} - -static void DSP_PlayAudio(_THIS) -{ - if (write(audio_fd, mixbuf, mixlen)==-1) - { - perror("Audio write"); - this->enabled = 0; - } - -#ifdef DEBUG_AUDIO - fprintf(stderr, "Wrote %d bytes of audio data\n", mixlen); -#endif -} - -static Uint8 *DSP_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void DSP_CloseAudio(_THIS) -{ - if ( mixbuf != NULL ) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if ( audio_fd >= 0 ) { - close(audio_fd); - audio_fd = -1; - } -} - -static int DSP_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - char audiodev[1024]; - int format; - int value; - int frag_spec; - Uint16 test_format; - - /* Make sure fragment size stays a power of 2, or OSS fails. */ - /* I don't know which of these are actually legal values, though... */ - if (spec->channels > 8) - spec->channels = 8; - else if (spec->channels > 4) - spec->channels = 4; - else if (spec->channels > 2) - spec->channels = 2; - - /* Open the audio device */ - audio_fd = SDL_OpenAudioPath(audiodev, sizeof(audiodev), OPEN_FLAGS, 0); - if ( audio_fd < 0 ) { - SDL_SetError("Couldn't open %s: %s", audiodev, strerror(errno)); - return(-1); - } - mixbuf = NULL; - - /* Make the file descriptor use blocking writes with fcntl() */ - { long flags; - flags = fcntl(audio_fd, F_GETFL); - flags &= ~O_NONBLOCK; - if ( fcntl(audio_fd, F_SETFL, flags) < 0 ) { - SDL_SetError("Couldn't set audio blocking mode"); - DSP_CloseAudio(this); - return(-1); - } - } - - /* Get a list of supported hardware formats */ - if ( ioctl(audio_fd, SNDCTL_DSP_GETFMTS, &value) < 0 ) { - perror("SNDCTL_DSP_GETFMTS"); - SDL_SetError("Couldn't get audio format list"); - DSP_CloseAudio(this); - return(-1); - } - - /* Try for a closest match on audio format */ - format = 0; - for ( test_format = SDL_FirstAudioFormat(spec->format); - ! format && test_format; ) { -#ifdef DEBUG_AUDIO - fprintf(stderr, "Trying format 0x%4.4x\n", test_format); -#endif - switch ( test_format ) { - case AUDIO_U8: - if ( value & AFMT_U8 ) { - format = AFMT_U8; - } - break; - case AUDIO_S16LSB: - if ( value & AFMT_S16_LE ) { - format = AFMT_S16_LE; - } - break; - case AUDIO_S16MSB: - if ( value & AFMT_S16_BE ) { - format = AFMT_S16_BE; - } - break; -#if 0 -/* - * These formats are not used by any real life systems so they are not - * needed here. - */ - case AUDIO_S8: - if ( value & AFMT_S8 ) { - format = AFMT_S8; - } - break; - case AUDIO_U16LSB: - if ( value & AFMT_U16_LE ) { - format = AFMT_U16_LE; - } - break; - case AUDIO_U16MSB: - if ( value & AFMT_U16_BE ) { - format = AFMT_U16_BE; - } - break; -#endif - default: - format = 0; - break; - } - if ( ! format ) { - test_format = SDL_NextAudioFormat(); - } - } - if ( format == 0 ) { - SDL_SetError("Couldn't find any hardware audio formats"); - DSP_CloseAudio(this); - return(-1); - } - spec->format = test_format; - - /* Set the audio format */ - value = format; - if ( (ioctl(audio_fd, SNDCTL_DSP_SETFMT, &value) < 0) || - (value != format) ) { - perror("SNDCTL_DSP_SETFMT"); - SDL_SetError("Couldn't set audio format"); - DSP_CloseAudio(this); - return(-1); - } - - /* Set the number of channels of output */ - value = spec->channels; - if ( ioctl(audio_fd, SNDCTL_DSP_CHANNELS, &value) < 0 ) { - perror("SNDCTL_DSP_CHANNELS"); - SDL_SetError("Cannot set the number of channels"); - DSP_CloseAudio(this); - return(-1); - } - spec->channels = value; - - /* Set the DSP frequency */ - value = spec->freq; - if ( ioctl(audio_fd, SNDCTL_DSP_SPEED, &value) < 0 ) { - perror("SNDCTL_DSP_SPEED"); - SDL_SetError("Couldn't set audio frequency"); - DSP_CloseAudio(this); - return(-1); - } - spec->freq = value; - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Determine the power of two of the fragment size */ - for ( frag_spec = 0; (0x01U<size; ++frag_spec ); - if ( (0x01U<size ) { - SDL_SetError("Fragment size must be a power of two"); - DSP_CloseAudio(this); - return(-1); - } - frag_spec |= 0x00020000; /* two fragments, for low latency */ - - /* Set the audio buffering parameters */ -#ifdef DEBUG_AUDIO - fprintf(stderr, "Requesting %d fragments of size %d\n", - (frag_spec >> 16), 1<<(frag_spec&0xFFFF)); -#endif - if ( ioctl(audio_fd, SNDCTL_DSP_SETFRAGMENT, &frag_spec) < 0 ) { - perror("SNDCTL_DSP_SETFRAGMENT"); - } -#ifdef DEBUG_AUDIO - { audio_buf_info info; - ioctl(audio_fd, SNDCTL_DSP_GETOSPACE, &info); - fprintf(stderr, "fragments = %d\n", info.fragments); - fprintf(stderr, "fragstotal = %d\n", info.fragstotal); - fprintf(stderr, "fragsize = %d\n", info.fragsize); - fprintf(stderr, "bytes = %d\n", info.bytes); - } -#endif - - /* Allocate mixing buffer */ - mixlen = spec->size; - mixbuf = (Uint8 *)SDL_AllocAudioMem(mixlen); - if ( mixbuf == NULL ) { - DSP_CloseAudio(this); - return(-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.h b/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.h deleted file mode 100644 index 0bf803f..0000000 --- a/distrib/sdl-1.2.12/src/audio/dsp/SDL_dspaudio.h +++ /dev/null @@ -1,53 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_dspaudio_h -#define _SDL_dspaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - int audio_fd; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *mixbuf; - int mixlen; -}; -#define FUDGE_TICKS 10 /* The scheduler overhead ticks per frame */ - -/* Old variable names */ -#define audio_fd (this->hidden->audio_fd) -#define parent (this->hidden->parent) -#define mixbuf (this->hidden->mixbuf) -#define mixlen (this->hidden->mixlen) -#define frame_ticks (this->hidden->frame_ticks) -#define next_frame (this->hidden->next_frame) - -#endif /* _SDL_dspaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.c b/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.c deleted file mode 100644 index 6e9a3f0..0000000 --- a/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.c +++ /dev/null @@ -1,156 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - - This file written by Ryan C. Gordon (icculus@icculus.org) -*/ -#include "SDL_config.h" - -/* Output audio to nowhere... */ - -#include "SDL_rwops.h" -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_dummyaudio.h" - -/* The tag name used by DUMMY audio */ -#define DUMMYAUD_DRIVER_NAME "dummy" - -/* Audio driver functions */ -static int DUMMYAUD_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void DUMMYAUD_WaitAudio(_THIS); -static void DUMMYAUD_PlayAudio(_THIS); -static Uint8 *DUMMYAUD_GetAudioBuf(_THIS); -static void DUMMYAUD_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ -static int DUMMYAUD_Available(void) -{ - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - if (envr && (SDL_strcmp(envr, DUMMYAUD_DRIVER_NAME) == 0)) { - return(1); - } - return(0); -} - -static void DUMMYAUD_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *DUMMYAUD_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = DUMMYAUD_OpenAudio; - this->WaitAudio = DUMMYAUD_WaitAudio; - this->PlayAudio = DUMMYAUD_PlayAudio; - this->GetAudioBuf = DUMMYAUD_GetAudioBuf; - this->CloseAudio = DUMMYAUD_CloseAudio; - - this->free = DUMMYAUD_DeleteDevice; - - return this; -} - -AudioBootStrap DUMMYAUD_bootstrap = { - DUMMYAUD_DRIVER_NAME, "SDL dummy audio driver", - DUMMYAUD_Available, DUMMYAUD_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void DUMMYAUD_WaitAudio(_THIS) -{ - /* Don't block on first calls to simulate initial fragment filling. */ - if (this->hidden->initial_calls) - this->hidden->initial_calls--; - else - SDL_Delay(this->hidden->write_delay); -} - -static void DUMMYAUD_PlayAudio(_THIS) -{ - /* no-op...this is a null driver. */ -} - -static Uint8 *DUMMYAUD_GetAudioBuf(_THIS) -{ - return(this->hidden->mixbuf); -} - -static void DUMMYAUD_CloseAudio(_THIS) -{ - if ( this->hidden->mixbuf != NULL ) { - SDL_FreeAudioMem(this->hidden->mixbuf); - this->hidden->mixbuf = NULL; - } -} - -static int DUMMYAUD_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - float bytes_per_sec = 0.0f; - - /* Allocate mixing buffer */ - this->hidden->mixlen = spec->size; - this->hidden->mixbuf = (Uint8 *) SDL_AllocAudioMem(this->hidden->mixlen); - if ( this->hidden->mixbuf == NULL ) { - return(-1); - } - SDL_memset(this->hidden->mixbuf, spec->silence, spec->size); - - bytes_per_sec = (float) (((spec->format & 0xFF) / 8) * - spec->channels * spec->freq); - - /* - * We try to make this request more audio at the correct rate for - * a given audio spec, so timing stays fairly faithful. - * Also, we have it not block at all for the first two calls, so - * it seems like we're filling two audio fragments right out of the - * gate, like other SDL drivers tend to do. - */ - this->hidden->initial_calls = 2; - this->hidden->write_delay = - (Uint32) ((((float) spec->size) / bytes_per_sec) * 1000.0f); - - /* We're ready to rock and roll. :-) */ - return(0); -} - diff --git a/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.h b/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.h deleted file mode 100644 index ff16cc7..0000000 --- a/distrib/sdl-1.2.12/src/audio/dummy/SDL_dummyaudio.h +++ /dev/null @@ -1,40 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_dummyaudio_h -#define _SDL_dummyaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - Uint8 *mixbuf; - Uint32 mixlen; - Uint32 write_delay; - Uint32 initial_calls; -}; - -#endif /* _SDL_dummyaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.c b/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.c deleted file mode 100644 index d35e89a..0000000 --- a/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.c +++ /dev/null @@ -1,323 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to an ESD network stream mixing buffer */ - -#include -#include -#include -#include -#include - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_esdaudio.h" - -#ifdef SDL_AUDIO_DRIVER_ESD_DYNAMIC -#include "SDL_name.h" -#include "SDL_loadso.h" -#else -#define SDL_NAME(X) X -#endif - -/* The tag name used by ESD audio */ -#define ESD_DRIVER_NAME "esd" - -/* Audio driver functions */ -static int ESD_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void ESD_WaitAudio(_THIS); -static void ESD_PlayAudio(_THIS); -static Uint8 *ESD_GetAudioBuf(_THIS); -static void ESD_CloseAudio(_THIS); - -#ifdef SDL_AUDIO_DRIVER_ESD_DYNAMIC - -static const char *esd_library = SDL_AUDIO_DRIVER_ESD_DYNAMIC; -static void *esd_handle = NULL; -static int esd_loaded = 0; - -static int (*SDL_NAME(esd_open_sound))( const char *host ); -static int (*SDL_NAME(esd_close))( int esd ); -static int (*SDL_NAME(esd_play_stream))( esd_format_t format, int rate, - const char *host, const char *name ); -static struct { - const char *name; - void **func; -} esd_functions[] = { - { "esd_open_sound", (void **)&SDL_NAME(esd_open_sound) }, - { "esd_close", (void **)&SDL_NAME(esd_close) }, - { "esd_play_stream", (void **)&SDL_NAME(esd_play_stream) }, -}; - -static void UnloadESDLibrary() -{ - if ( esd_loaded ) { - SDL_UnloadObject(esd_handle); - esd_handle = NULL; - esd_loaded = 0; - } -} - -static int LoadESDLibrary(void) -{ - int i, retval = -1; - - esd_handle = SDL_LoadObject(esd_library); - if ( esd_handle ) { - esd_loaded = 1; - retval = 0; - for ( i=0; i= 0 ) { - available = 1; - SDL_NAME(esd_close)(connection); - } - UnloadESDLibrary(); - return(available); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); - UnloadESDLibrary(); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - LoadESDLibrary(); - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - audio_fd = -1; - - /* Set the function pointers */ - this->OpenAudio = ESD_OpenAudio; - this->WaitAudio = ESD_WaitAudio; - this->PlayAudio = ESD_PlayAudio; - this->GetAudioBuf = ESD_GetAudioBuf; - this->CloseAudio = ESD_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap ESD_bootstrap = { - ESD_DRIVER_NAME, "Enlightened Sound Daemon", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void ESD_WaitAudio(_THIS) -{ - Sint32 ticks; - - /* Check to see if the thread-parent process is still alive */ - { static int cnt = 0; - /* Note that this only works with thread implementations - that use a different process id for each thread. - */ - if (parent && (((++cnt)%10) == 0)) { /* Check every 10 loops */ - if ( kill(parent, 0) < 0 ) { - this->enabled = 0; - } - } - } - - /* Use timer for general audio synchronization */ - ticks = ((Sint32)(next_frame - SDL_GetTicks()))-FUDGE_TICKS; - if ( ticks > 0 ) { - SDL_Delay(ticks); - } -} - -static void ESD_PlayAudio(_THIS) -{ - int written; - - /* Write the audio data, checking for EAGAIN on broken audio drivers */ - do { - written = write(audio_fd, mixbuf, mixlen); - if ( (written < 0) && ((errno == 0) || (errno == EAGAIN)) ) { - SDL_Delay(1); /* Let a little CPU time go by */ - } - } while ( (written < 0) && - ((errno == 0) || (errno == EAGAIN) || (errno == EINTR)) ); - - /* Set the next write frame */ - next_frame += frame_ticks; - - /* If we couldn't write, assume fatal error for now */ - if ( written < 0 ) { - this->enabled = 0; - } -} - -static Uint8 *ESD_GetAudioBuf(_THIS) -{ - return(mixbuf); -} - -static void ESD_CloseAudio(_THIS) -{ - if ( mixbuf != NULL ) { - SDL_FreeAudioMem(mixbuf); - mixbuf = NULL; - } - if ( audio_fd >= 0 ) { - SDL_NAME(esd_close)(audio_fd); - audio_fd = -1; - } -} - -/* Try to get the name of the program */ -static char *get_progname(void) -{ - char *progname = NULL; -#ifdef __LINUX__ - FILE *fp; - static char temp[BUFSIZ]; - - SDL_snprintf(temp, SDL_arraysize(temp), "/proc/%d/cmdline", getpid()); - fp = fopen(temp, "r"); - if ( fp != NULL ) { - if ( fgets(temp, sizeof(temp)-1, fp) ) { - progname = SDL_strrchr(temp, '/'); - if ( progname == NULL ) { - progname = temp; - } else { - progname = progname+1; - } - } - fclose(fp); - } -#endif - return(progname); -} - -static int ESD_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - esd_format_t format; - - /* Convert audio spec to the ESD audio format */ - format = (ESD_STREAM | ESD_PLAY); - switch ( spec->format & 0xFF ) { - case 8: - format |= ESD_BITS8; - break; - case 16: - format |= ESD_BITS16; - break; - default: - SDL_SetError("Unsupported ESD audio format"); - return(-1); - } - if ( spec->channels == 1 ) { - format |= ESD_MONO; - } else { - format |= ESD_STEREO; - } -#if 0 - spec->samples = ESD_BUF_SIZE; /* Darn, no way to change this yet */ -#endif - - /* Open a connection to the ESD audio server */ - audio_fd = SDL_NAME(esd_play_stream)(format, spec->freq, NULL, get_progname()); - if ( audio_fd < 0 ) { - SDL_SetError("Couldn't open ESD connection"); - return(-1); - } - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - frame_ticks = (float)(spec->samples*1000)/spec->freq; - next_frame = SDL_GetTicks()+frame_ticks; - - /* Allocate mixing buffer */ - mixlen = spec->size; - mixbuf = (Uint8 *)SDL_AllocAudioMem(mixlen); - if ( mixbuf == NULL ) { - return(-1); - } - SDL_memset(mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - parent = getpid(); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.h b/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.h deleted file mode 100644 index cffb276..0000000 --- a/distrib/sdl-1.2.12/src/audio/esd/SDL_esdaudio.h +++ /dev/null @@ -1,57 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_esdaudio_h -#define _SDL_esdaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* The file descriptor for the audio device */ - int audio_fd; - - /* The parent process id, to detect when application quits */ - pid_t parent; - - /* Raw mixing buffer */ - Uint8 *mixbuf; - int mixlen; - - /* Support for audio timing using a timer */ - float frame_ticks; - float next_frame; -}; -#define FUDGE_TICKS 10 /* The scheduler overhead ticks per frame */ - -/* Old variable names */ -#define audio_fd (this->hidden->audio_fd) -#define parent (this->hidden->parent) -#define mixbuf (this->hidden->mixbuf) -#define mixlen (this->hidden->mixlen) -#define frame_ticks (this->hidden->frame_ticks) -#define next_frame (this->hidden->next_frame) - -#endif /* _SDL_esdaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.c b/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.c deleted file mode 100644 index 2cae958..0000000 --- a/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.c +++ /dev/null @@ -1,277 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" -#include "SDL_coreaudio.h" - - -/* Audio driver functions */ - -static int Core_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Core_WaitAudio(_THIS); -static void Core_PlayAudio(_THIS); -static Uint8 *Core_GetAudioBuf(_THIS); -static void Core_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Core_OpenAudio; - this->WaitAudio = Core_WaitAudio; - this->PlayAudio = Core_PlayAudio; - this->GetAudioBuf = Core_GetAudioBuf; - this->CloseAudio = Core_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap COREAUDIO_bootstrap = { - "coreaudio", "Mac OS X CoreAudio", - Audio_Available, Audio_CreateDevice -}; - -/* The CoreAudio callback */ -static OSStatus audioCallback (void *inRefCon, - AudioUnitRenderActionFlags inActionFlags, - const AudioTimeStamp *inTimeStamp, - UInt32 inBusNumber, - AudioBuffer *ioData) -{ - SDL_AudioDevice *this = (SDL_AudioDevice *)inRefCon; - UInt32 remaining, len; - void *ptr; - - /* Only do anything if audio is enabled and not paused */ - if ( ! this->enabled || this->paused ) { - SDL_memset(ioData->mData, this->spec.silence, ioData->mDataByteSize); - return 0; - } - - /* No SDL conversion should be needed here, ever, since we accept - any input format in OpenAudio, and leave the conversion to CoreAudio. - */ - /* - assert(!this->convert.needed); - assert(this->spec.channels == ioData->mNumberChannels); - */ - - remaining = ioData->mDataByteSize; - ptr = ioData->mData; - while (remaining > 0) { - if (bufferOffset >= bufferSize) { - /* Generate the data */ - SDL_memset(buffer, this->spec.silence, bufferSize); - SDL_mutexP(this->mixer_lock); - (*this->spec.callback)(this->spec.userdata, - buffer, bufferSize); - SDL_mutexV(this->mixer_lock); - bufferOffset = 0; - } - - len = bufferSize - bufferOffset; - if (len > remaining) - len = remaining; - SDL_memcpy(ptr, (char *)buffer + bufferOffset, len); - ptr = (char *)ptr + len; - remaining -= len; - bufferOffset += len; - } - - return 0; -} - -/* Dummy functions -- we don't use thread-based audio */ -void Core_WaitAudio(_THIS) -{ - return; -} - -void Core_PlayAudio(_THIS) -{ - return; -} - -Uint8 *Core_GetAudioBuf(_THIS) -{ - return(NULL); -} - -void Core_CloseAudio(_THIS) -{ - OSStatus result; - struct AudioUnitInputCallback callback; - - /* stop processing the audio unit */ - result = AudioOutputUnitStop (outputAudioUnit); - if (result != noErr) { - SDL_SetError("Core_CloseAudio: AudioOutputUnitStop"); - return; - } - - /* Remove the input callback */ - callback.inputProc = 0; - callback.inputProcRefCon = 0; - result = AudioUnitSetProperty (outputAudioUnit, - kAudioUnitProperty_SetInputCallback, - kAudioUnitScope_Input, - 0, - &callback, - sizeof(callback)); - if (result != noErr) { - SDL_SetError("Core_CloseAudio: AudioUnitSetProperty (kAudioUnitProperty_SetInputCallback)"); - return; - } - - result = CloseComponent(outputAudioUnit); - if (result != noErr) { - SDL_SetError("Core_CloseAudio: CloseComponent"); - return; - } - - SDL_free(buffer); -} - -#define CHECK_RESULT(msg) \ - if (result != noErr) { \ - SDL_SetError("Failed to start CoreAudio: " msg); \ - return -1; \ - } - - -int Core_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - OSStatus result = noErr; - Component comp; - ComponentDescription desc; - struct AudioUnitInputCallback callback; - AudioStreamBasicDescription requestedDesc; - - /* Setup a AudioStreamBasicDescription with the requested format */ - requestedDesc.mFormatID = kAudioFormatLinearPCM; - requestedDesc.mFormatFlags = kLinearPCMFormatFlagIsPacked; - requestedDesc.mChannelsPerFrame = spec->channels; - requestedDesc.mSampleRate = spec->freq; - - requestedDesc.mBitsPerChannel = spec->format & 0xFF; - if (spec->format & 0x8000) - requestedDesc.mFormatFlags |= kLinearPCMFormatFlagIsSignedInteger; - if (spec->format & 0x1000) - requestedDesc.mFormatFlags |= kLinearPCMFormatFlagIsBigEndian; - - requestedDesc.mFramesPerPacket = 1; - requestedDesc.mBytesPerFrame = requestedDesc.mBitsPerChannel * requestedDesc.mChannelsPerFrame / 8; - requestedDesc.mBytesPerPacket = requestedDesc.mBytesPerFrame * requestedDesc.mFramesPerPacket; - - - /* Locate the default output audio unit */ - desc.componentType = kAudioUnitComponentType; - desc.componentSubType = kAudioUnitSubType_Output; - desc.componentManufacturer = kAudioUnitID_DefaultOutput; - desc.componentFlags = 0; - desc.componentFlagsMask = 0; - - comp = FindNextComponent (NULL, &desc); - if (comp == NULL) { - SDL_SetError ("Failed to start CoreAudio: FindNextComponent returned NULL"); - return -1; - } - - /* Open & initialize the default output audio unit */ - result = OpenAComponent (comp, &outputAudioUnit); - CHECK_RESULT("OpenAComponent") - - result = AudioUnitInitialize (outputAudioUnit); - CHECK_RESULT("AudioUnitInitialize") - - /* Set the input format of the audio unit. */ - result = AudioUnitSetProperty (outputAudioUnit, - kAudioUnitProperty_StreamFormat, - kAudioUnitScope_Input, - 0, - &requestedDesc, - sizeof (requestedDesc)); - CHECK_RESULT("AudioUnitSetProperty (kAudioUnitProperty_StreamFormat)") - - /* Set the audio callback */ - callback.inputProc = audioCallback; - callback.inputProcRefCon = this; - result = AudioUnitSetProperty (outputAudioUnit, - kAudioUnitProperty_SetInputCallback, - kAudioUnitScope_Input, - 0, - &callback, - sizeof(callback)); - CHECK_RESULT("AudioUnitSetProperty (kAudioUnitProperty_SetInputCallback)") - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - /* Allocate a sample buffer */ - bufferOffset = bufferSize = this->spec.size; - buffer = SDL_malloc(bufferSize); - - /* Finally, start processing of the audio unit */ - result = AudioOutputUnitStart (outputAudioUnit); - CHECK_RESULT("AudioOutputUnitStart") - - - /* We're running! */ - return(1); -} diff --git a/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.h b/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.h deleted file mode 100644 index de2490c..0000000 --- a/distrib/sdl-1.2.12/src/audio/macosx/SDL_coreaudio.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_coreaudio_h -#define _SDL_coreaudio_h - -#include "../SDL_sysaudio.h" -#include - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - AudioUnit outputAudioUnit; - void *buffer; - UInt32 bufferOffset; - UInt32 bufferSize; -}; - -/* Old variable names */ -#define outputAudioUnit (this->hidden->outputAudioUnit) -#define buffer (this->hidden->buffer) -#define bufferOffset (this->hidden->bufferOffset) -#define bufferSize (this->hidden->bufferSize) - -#endif /* _SDL_coreaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.c b/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.c deleted file mode 100644 index 140c033..0000000 --- a/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.c +++ /dev/null @@ -1,496 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#if defined(__APPLE__) && defined(__MACH__) -# include -#elif TARGET_API_MAC_CARBON && (UNIVERSAL_INTERFACES_VERSION > 0x0335) -# include -#else -# include /* SoundManager interface */ -# include -# include -#endif - -#if !defined(NewSndCallBackUPP) && (UNIVERSAL_INTERFACES_VERSION < 0x0335) -#if !defined(NewSndCallBackProc) /* avoid circular redefinition... */ -#define NewSndCallBackUPP NewSndCallBackProc -#endif -#if !defined(NewSndCallBackUPP) -#define NewSndCallBackUPP NewSndCallBackProc -#endif -#endif - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" -#include "SDL_romaudio.h" - -/* Audio driver functions */ - -static void Mac_CloseAudio(_THIS); -static int Mac_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mac_LockAudio(_THIS); -static void Mac_UnlockAudio(_THIS); - -/* Audio driver bootstrap functions */ - - -static int Audio_Available(void) -{ - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mac_OpenAudio; - this->CloseAudio = Mac_CloseAudio; - this->LockAudio = Mac_LockAudio; - this->UnlockAudio = Mac_UnlockAudio; - this->free = Audio_DeleteDevice; - -#ifdef __MACOSX__ /* Mac OS X uses threaded audio, so normal thread code is okay */ - this->LockAudio = NULL; - this->UnlockAudio = NULL; -#endif - return this; -} - -AudioBootStrap SNDMGR_bootstrap = { - "sndmgr", "MacOS SoundManager 3.0", - Audio_Available, Audio_CreateDevice -}; - -#if defined(TARGET_API_MAC_CARBON) || defined(USE_RYANS_SOUNDCODE) -/* This works correctly on Mac OS X */ - -#pragma options align=power - -static volatile SInt32 audio_is_locked = 0; -static volatile SInt32 need_to_mix = 0; - -static UInt8 *buffer[2]; -static volatile UInt32 running = 0; -static CmpSoundHeader header; -static volatile Uint32 fill_me = 0; - -static void mix_buffer(SDL_AudioDevice *audio, UInt8 *buffer) -{ - if ( ! audio->paused ) { -#ifdef __MACOSX__ - SDL_mutexP(audio->mixer_lock); -#endif - if ( audio->convert.needed ) { - audio->spec.callback(audio->spec.userdata, - (Uint8 *)audio->convert.buf,audio->convert.len); - SDL_ConvertAudio(&audio->convert); - if ( audio->convert.len_cvt != audio->spec.size ) { - /* Uh oh... probably crashes here */; - } - SDL_memcpy(buffer, audio->convert.buf, audio->convert.len_cvt); - } else { - audio->spec.callback(audio->spec.userdata, buffer, audio->spec.size); - } -#ifdef __MACOSX__ - SDL_mutexV(audio->mixer_lock); -#endif - } - - DecrementAtomic((SInt32 *) &need_to_mix); -} - -static void Mac_LockAudio(_THIS) -{ - IncrementAtomic((SInt32 *) &audio_is_locked); -} - -static void Mac_UnlockAudio(_THIS) -{ - SInt32 oldval; - - oldval = DecrementAtomic((SInt32 *) &audio_is_locked); - if ( oldval != 1 ) /* != 1 means audio is still locked. */ - return; - - /* Did we miss the chance to mix in an interrupt? Do it now. */ - if ( BitAndAtomic (0xFFFFFFFF, (UInt32 *) &need_to_mix) ) { - /* - * Note that this could be a problem if you missed an interrupt - * while the audio was locked, and get preempted by a second - * interrupt here, but that means you locked for way too long anyhow. - */ - mix_buffer (this, buffer[fill_me]); - } -} - -static void callBackProc (SndChannel *chan, SndCommand *cmd_passed ) { - UInt32 play_me; - SndCommand cmd; - SDL_AudioDevice *audio = (SDL_AudioDevice *)chan->userInfo; - - IncrementAtomic((SInt32 *) &need_to_mix); - - fill_me = cmd_passed->param2; /* buffer that has just finished playing, so fill it */ - play_me = ! fill_me; /* filled buffer to play _now_ */ - - if ( ! audio->enabled ) { - return; - } - - /* queue previously mixed buffer for playback. */ - header.samplePtr = (Ptr)buffer[play_me]; - cmd.cmd = bufferCmd; - cmd.param1 = 0; - cmd.param2 = (long)&header; - SndDoCommand (chan, &cmd, 0); - - memset (buffer[fill_me], 0, audio->spec.size); - - /* - * if audio device isn't locked, mix the next buffer to be queued in - * the memory block that just finished playing. - */ - if ( ! BitAndAtomic(0xFFFFFFFF, (UInt32 *) &audio_is_locked) ) { - mix_buffer (audio, buffer[fill_me]); - } - - /* set this callback to run again when current buffer drains. */ - if ( running ) { - cmd.cmd = callBackCmd; - cmd.param1 = 0; - cmd.param2 = play_me; - - SndDoCommand (chan, &cmd, 0); - } -} - -static int Mac_OpenAudio(_THIS, SDL_AudioSpec *spec) { - - SndCallBackUPP callback; - int sample_bits; - int i; - long initOptions; - - /* Very few conversions are required, but... */ - switch (spec->format) { - case AUDIO_S8: - spec->format = AUDIO_U8; - break; - case AUDIO_U16LSB: - spec->format = AUDIO_S16LSB; - break; - case AUDIO_U16MSB: - spec->format = AUDIO_S16MSB; - break; - } - SDL_CalculateAudioSpec(spec); - - /* initialize bufferCmd header */ - memset (&header, 0, sizeof(header)); - callback = (SndCallBackUPP) NewSndCallBackUPP (callBackProc); - sample_bits = spec->size / spec->samples / spec->channels * 8; - -#ifdef DEBUG_AUDIO - fprintf(stderr, - "Audio format 0x%x, channels = %d, sample_bits = %d, frequency = %d\n", - spec->format, spec->channels, sample_bits, spec->freq); -#endif /* DEBUG_AUDIO */ - - header.numChannels = spec->channels; - header.sampleSize = sample_bits; - header.sampleRate = spec->freq << 16; - header.numFrames = spec->samples; - header.encode = cmpSH; - - /* Note that we install the 16bitLittleEndian Converter if needed. */ - if ( spec->format == 0x8010 ) { - header.compressionID = fixedCompression; - header.format = k16BitLittleEndianFormat; - } - - /* allocate 2 buffers */ - for (i=0; i<2; i++) { - buffer[i] = (UInt8*)malloc (sizeof(UInt8) * spec->size); - if (buffer[i] == NULL) { - SDL_OutOfMemory(); - return (-1); - } - memset (buffer[i], 0, spec->size); - } - - /* Create the sound manager channel */ - channel = (SndChannelPtr)SDL_malloc(sizeof(*channel)); - if ( channel == NULL ) { - SDL_OutOfMemory(); - return(-1); - } - if ( spec->channels >= 2 ) { - initOptions = initStereo; - } else { - initOptions = initMono; - } - channel->userInfo = (long)this; - channel->qLength = 128; - if ( SndNewChannel(&channel, sampledSynth, initOptions, callback) != noErr ) { - SDL_SetError("Unable to create audio channel"); - SDL_free(channel); - channel = NULL; - return(-1); - } - - /* start playback */ - { - SndCommand cmd; - cmd.cmd = callBackCmd; - cmd.param2 = 0; - running = 1; - SndDoCommand (channel, &cmd, 0); - } - - return 1; -} - -static void Mac_CloseAudio(_THIS) { - - int i; - - running = 0; - - if (channel) { - SndDisposeChannel (channel, true); - channel = NULL; - } - - for ( i=0; i<2; ++i ) { - if ( buffer[i] ) { - SDL_free(buffer[i]); - buffer[i] = NULL; - } - } -} - -#else /* !TARGET_API_MAC_CARBON && !USE_RYANS_SOUNDCODE */ - -static void Mac_LockAudio(_THIS) -{ - /* no-op. */ -} - -static void Mac_UnlockAudio(_THIS) -{ - /* no-op. */ -} - - -/* This function is called by Sound Manager when it has exhausted one of - the buffers, so we'll zero it to silence and fill it with audio if - we're not paused. -*/ -static pascal -void sndDoubleBackProc (SndChannelPtr chan, SndDoubleBufferPtr newbuf) -{ - SDL_AudioDevice *audio = (SDL_AudioDevice *)newbuf->dbUserInfo[0]; - - /* If audio is quitting, don't do anything */ - if ( ! audio->enabled ) { - return; - } - memset (newbuf->dbSoundData, 0, audio->spec.size); - newbuf->dbNumFrames = audio->spec.samples; - if ( ! audio->paused ) { - if ( audio->convert.needed ) { - audio->spec.callback(audio->spec.userdata, - (Uint8 *)audio->convert.buf,audio->convert.len); - SDL_ConvertAudio(&audio->convert); -#if 0 - if ( audio->convert.len_cvt != audio->spec.size ) { - /* Uh oh... probably crashes here */; - } -#endif - SDL_memcpy(newbuf->dbSoundData, audio->convert.buf, - audio->convert.len_cvt); - } else { - audio->spec.callback(audio->spec.userdata, - (Uint8 *)newbuf->dbSoundData, audio->spec.size); - } - } - newbuf->dbFlags |= dbBufferReady; -} - -static int DoubleBufferAudio_Available(void) -{ - int available; - NumVersion sndversion; - long response; - - available = 0; - sndversion = SndSoundManagerVersion(); - if ( sndversion.majorRev >= 3 ) { - if ( Gestalt(gestaltSoundAttr, &response) == noErr ) { - if ( (response & (1 << gestaltSndPlayDoubleBuffer)) ) { - available = 1; - } - } - } else { - if ( Gestalt(gestaltSoundAttr, &response) == noErr ) { - if ( (response & (1 << gestaltHasASC)) ) { - available = 1; - } - } - } - return(available); -} - -static void Mac_CloseAudio(_THIS) -{ - int i; - - if ( channel != NULL ) { - /* Clean up the audio channel */ - SndDisposeChannel(channel, true); - channel = NULL; - } - for ( i=0; i<2; ++i ) { - if ( audio_buf[i] ) { - SDL_free(audio_buf[i]); - audio_buf[i] = NULL; - } - } -} - -static int Mac_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - SndDoubleBufferHeader2 audio_dbh; - int i; - long initOptions; - int sample_bits; - SndDoubleBackUPP doubleBackProc; - - /* Check to make sure double-buffered audio is available */ - if ( ! DoubleBufferAudio_Available() ) { - SDL_SetError("Sound manager doesn't support double-buffering"); - return(-1); - } - - /* Very few conversions are required, but... */ - switch (spec->format) { - case AUDIO_S8: - spec->format = AUDIO_U8; - break; - case AUDIO_U16LSB: - spec->format = AUDIO_S16LSB; - break; - case AUDIO_U16MSB: - spec->format = AUDIO_S16MSB; - break; - } - SDL_CalculateAudioSpec(spec); - - /* initialize the double-back header */ - SDL_memset(&audio_dbh, 0, sizeof(audio_dbh)); - doubleBackProc = NewSndDoubleBackProc (sndDoubleBackProc); - sample_bits = spec->size / spec->samples / spec->channels * 8; - - audio_dbh.dbhNumChannels = spec->channels; - audio_dbh.dbhSampleSize = sample_bits; - audio_dbh.dbhCompressionID = 0; - audio_dbh.dbhPacketSize = 0; - audio_dbh.dbhSampleRate = spec->freq << 16; - audio_dbh.dbhDoubleBack = doubleBackProc; - audio_dbh.dbhFormat = 0; - - /* Note that we install the 16bitLittleEndian Converter if needed. */ - if ( spec->format == 0x8010 ) { - audio_dbh.dbhCompressionID = fixedCompression; - audio_dbh.dbhFormat = k16BitLittleEndianFormat; - } - - /* allocate the 2 double-back buffers */ - for ( i=0; i<2; ++i ) { - audio_buf[i] = SDL_calloc(1, sizeof(SndDoubleBuffer)+spec->size); - if ( audio_buf[i] == NULL ) { - SDL_OutOfMemory(); - return(-1); - } - audio_buf[i]->dbNumFrames = spec->samples; - audio_buf[i]->dbFlags = dbBufferReady; - audio_buf[i]->dbUserInfo[0] = (long)this; - audio_dbh.dbhBufferPtr[i] = audio_buf[i]; - } - - /* Create the sound manager channel */ - channel = (SndChannelPtr)SDL_malloc(sizeof(*channel)); - if ( channel == NULL ) { - SDL_OutOfMemory(); - return(-1); - } - if ( spec->channels >= 2 ) { - initOptions = initStereo; - } else { - initOptions = initMono; - } - channel->userInfo = 0; - channel->qLength = 128; - if ( SndNewChannel(&channel, sampledSynth, initOptions, 0L) != noErr ) { - SDL_SetError("Unable to create audio channel"); - SDL_free(channel); - channel = NULL; - return(-1); - } - - /* Start playback */ - if ( SndPlayDoubleBuffer(channel, (SndDoubleBufferHeaderPtr)&audio_dbh) - != noErr ) { - SDL_SetError("Unable to play double buffered audio"); - return(-1); - } - - return 1; -} - -#endif /* TARGET_API_MAC_CARBON || USE_RYANS_SOUNDCODE */ - diff --git a/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.h b/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.h deleted file mode 100644 index be5dc69..0000000 --- a/distrib/sdl-1.2.12/src/audio/macrom/SDL_romaudio.h +++ /dev/null @@ -1,50 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -#ifndef _SDL_romaudio_h -#define _SDL_romaudio_h - -#include "../SDL_sysaudio.h" - -/* This is Ryan's improved MacOS sound code, with locking support */ -#define USE_RYANS_SOUNDCODE - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this - -struct SDL_PrivateAudioData { - /* Sound manager audio channel */ - SndChannelPtr channel; -#if defined(TARGET_API_MAC_CARBON) || defined(USE_RYANS_SOUNDCODE) - /* FIXME: Add Ryan's static data here */ -#else - /* Double buffering variables */ - SndDoubleBufferPtr audio_buf[2]; -#endif -}; - -/* Old variable names */ -#define channel (this->hidden->channel) -#define audio_buf (this->hidden->audio_buf) - -#endif /* _SDL_romaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.c deleted file mode 100644 index afdec64..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.c +++ /dev/null @@ -1,215 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - Audio interrupt variables and callback function - - Patrice Mandin -*/ - -#include - -#include -#include -#include -#include - -#include "SDL_audio.h" -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_stfa.h" - -/* The audio device */ - -SDL_AudioDevice *SDL_MintAudio_device; -Uint8 *SDL_MintAudio_audiobuf[2]; /* Pointers to buffers */ -unsigned long SDL_MintAudio_audiosize; /* Length of audio buffer=spec->size */ -volatile unsigned short SDL_MintAudio_numbuf; /* Buffer to play */ -volatile unsigned short SDL_MintAudio_mutex; -volatile unsigned long SDL_MintAudio_clocktics; -cookie_stfa_t *SDL_MintAudio_stfa; -unsigned short SDL_MintAudio_hasfpu; - -/* MiNT thread variables */ -SDL_bool SDL_MintAudio_mint_present; -SDL_bool SDL_MintAudio_quit_thread; -SDL_bool SDL_MintAudio_thread_finished; -long SDL_MintAudio_thread_pid; - -/* The callback function, called by each driver whenever needed */ - -void SDL_MintAudio_Callback(void) -{ - Uint8 *buffer; - SDL_AudioDevice *audio = SDL_MintAudio_device; - - buffer = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - SDL_memset(buffer, audio->spec.silence, audio->spec.size); - - if (audio->paused) - return; - - if (audio->convert.needed) { - int silence; - - if ( audio->convert.src_format == AUDIO_U8 ) { - silence = 0x80; - } else { - silence = 0; - } - SDL_memset(audio->convert.buf, silence, audio->convert.len); - audio->spec.callback(audio->spec.userdata, - (Uint8 *)audio->convert.buf,audio->convert.len); - SDL_ConvertAudio(&audio->convert); - SDL_memcpy(buffer, audio->convert.buf, audio->convert.len_cvt); - } else { - audio->spec.callback(audio->spec.userdata, buffer, audio->spec.size); - } -} - -/* Add a new frequency/clock/predivisor to the current list */ -void SDL_MintAudio_AddFrequency(_THIS, Uint32 frequency, Uint32 clock, - Uint32 prediv, int gpio_bits) -{ - int i, p; - - if (MINTAUDIO_freqcount==MINTAUDIO_maxfreqs) { - return; - } - - /* Search where to insert the frequency (highest first) */ - for (p=0; p MINTAUDIO_frequencies[p].frequency) { - break; - } - } - - /* Put all following ones farer */ - if (MINTAUDIO_freqcount>0) { - for (i=MINTAUDIO_freqcount; i>p; i--) { - SDL_memcpy(&MINTAUDIO_frequencies[i], &MINTAUDIO_frequencies[i-1], sizeof(mint_frequency_t)); - } - } - - /* And insert new one */ - MINTAUDIO_frequencies[p].frequency = frequency; - MINTAUDIO_frequencies[p].masterclock = clock; - MINTAUDIO_frequencies[p].predivisor = prediv; - MINTAUDIO_frequencies[p].gpio_bits = gpio_bits; - - MINTAUDIO_freqcount++; -} - -/* Search for the nearest frequency */ -int SDL_MintAudio_SearchFrequency(_THIS, int desired_freq) -{ - int i; - - /* Only 1 freq ? */ - if (MINTAUDIO_freqcount==1) { - return 0; - } - - /* Check the array */ - for (i=0; i= ((MINTAUDIO_frequencies[i].frequency+ - MINTAUDIO_frequencies[i+1].frequency)>>1)) { - return i; - } - } - - /* Not in the array, give the latest */ - return MINTAUDIO_freqcount-1; -} - -/* Check if FPU is present */ -void SDL_MintAudio_CheckFpu(void) -{ - unsigned long cookie_fpu; - - SDL_MintAudio_hasfpu = 0; - if (Getcookie(C__FPU, &cookie_fpu) != C_FOUND) { - return; - } - switch ((cookie_fpu>>16)&0xfffe) { - case 2: - case 4: - case 6: - case 8: - case 16: - SDL_MintAudio_hasfpu = 1; - break; - } -} - -/* The thread function, used under MiNT with xbios */ -int SDL_MintAudio_Thread(long param) -{ - SndBufPtr pointers; - SDL_bool buffers_filled[2] = {SDL_FALSE, SDL_FALSE}; - - SDL_MintAudio_thread_finished = SDL_FALSE; - while (!SDL_MintAudio_quit_thread) { - if (Buffptr(&pointers)!=0) - continue; - - if (( (unsigned long)pointers.play>=(unsigned long)SDL_MintAudio_audiobuf[0]) - && ( (unsigned long)pointers.play<=(unsigned long)SDL_MintAudio_audiobuf[1])) - { - /* DMA is reading buffer #0, setup buffer #1 if not already done */ - if (!buffers_filled[1]) { - SDL_MintAudio_numbuf = 1; - SDL_MintAudio_Callback(); - Setbuffer(0, SDL_MintAudio_audiobuf[1], SDL_MintAudio_audiobuf[1] + SDL_MintAudio_audiosize); - buffers_filled[1]=SDL_TRUE; - buffers_filled[0]=SDL_FALSE; - } - } else { - /* DMA is reading buffer #1, setup buffer #0 if not already done */ - if (!buffers_filled[0]) { - SDL_MintAudio_numbuf = 0; - SDL_MintAudio_Callback(); - Setbuffer(0, SDL_MintAudio_audiobuf[0], SDL_MintAudio_audiobuf[0] + SDL_MintAudio_audiosize); - buffers_filled[0]=SDL_TRUE; - buffers_filled[1]=SDL_FALSE; - } - } - - usleep(100); - } - SDL_MintAudio_thread_finished = SDL_TRUE; - return 0; -} - -void SDL_MintAudio_WaitThread(void) -{ - if (!SDL_MintAudio_mint_present) - return; - - if (SDL_MintAudio_thread_finished) - return; - - SDL_MintAudio_quit_thread = SDL_TRUE; - while (!SDL_MintAudio_thread_finished) { - Syield(); - } -} diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.h b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.h deleted file mode 100644 index 9a02580..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio.h +++ /dev/null @@ -1,153 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - - Patrice Mandin -*/ - -#ifndef _SDL_mintaudio_h -#define _SDL_mintaudio_h - -#include "../SDL_sysaudio.h" -#include "SDL_mintaudio_stfa.h" - -/* Hidden "this" pointer for the audio functions */ -#define _THIS SDL_AudioDevice *this - -/* 16 predivisors with 3 clocks max. */ -#define MINTAUDIO_maxfreqs (16*3) - -typedef struct { - Uint32 frequency; - Uint32 masterclock; - Uint32 predivisor; - int gpio_bits; /* in case of external clock */ -} mint_frequency_t; - -struct SDL_PrivateAudioData { - mint_frequency_t frequencies[MINTAUDIO_maxfreqs]; - int freq_count; /* Number of frequencies in the array */ - int numfreq; /* Number of selected frequency */ -}; - -/* Old variable names */ - -#define MINTAUDIO_frequencies (this->hidden->frequencies) -#define MINTAUDIO_freqcount (this->hidden->freq_count) -#define MINTAUDIO_numfreq (this->hidden->numfreq) - -/* _MCH cookie (values>>16) */ -enum { - MCH_ST=0, - MCH_STE, - MCH_TT, - MCH_F30, - MCH_CLONE, - MCH_ARANYM -}; - -/* Master clocks for replay frequencies */ -#define MASTERCLOCK_STE 8010666 /* Not sure of this one */ -#define MASTERCLOCK_TT 16107953 /* Not sure of this one */ -#define MASTERCLOCK_FALCON1 25175000 -#define MASTERCLOCK_FALCON2 32000000 /* Only usable for DSP56K */ -#define MASTERCLOCK_FALCONEXT -1 /* Clock on DSP56K port, unknown */ -#define MASTERCLOCK_44K 22579200 /* Standard clock for 44.1 Khz */ -#define MASTERCLOCK_48K 24576000 /* Standard clock for 48 Khz */ - -/* Master clock predivisors */ -#define MASTERPREDIV_STE 160 -#define MASTERPREDIV_TT 320 -#define MASTERPREDIV_FALCON 256 -#define MASTERPREDIV_MILAN 256 - -/* MFP 68901 interrupt sources */ -enum { - MFP_PARALLEL=0, - MFP_DCD, - MFP_CTS, - MFP_BITBLT, - MFP_TIMERD, - MFP_BAUDRATE=MFP_TIMERD, - MFP_TIMERC, - MFP_200HZ=MFP_TIMERC, - MFP_ACIA, - MFP_DISK, - MFP_TIMERB, - MFP_HBLANK=MFP_TIMERB, - MFP_TERR, - MFP_TBE, - MFP_RERR, - MFP_RBF, - MFP_TIMERA, - MFP_DMASOUND=MFP_TIMERA, - MFP_RING, - MFP_MONODETECT -}; - -/* Xbtimer() timers */ -enum { - XB_TIMERA=0, - XB_TIMERB, - XB_TIMERC, - XB_TIMERD -}; - -/* Variables */ -extern SDL_AudioDevice *SDL_MintAudio_device; -extern Uint8 *SDL_MintAudio_audiobuf[2]; /* Pointers to buffers */ -extern unsigned long SDL_MintAudio_audiosize; /* Length of audio buffer=spec->size */ -extern volatile unsigned short SDL_MintAudio_numbuf; /* Buffer to play */ -extern volatile unsigned short SDL_MintAudio_mutex; -extern cookie_stfa_t *SDL_MintAudio_stfa; -extern volatile unsigned long SDL_MintAudio_clocktics; -extern unsigned short SDL_MintAudio_hasfpu; /* To preserve fpu registers if needed */ - -/* MiNT thread variables */ -extern SDL_bool SDL_MintAudio_mint_present; -extern SDL_bool SDL_MintAudio_quit_thread; -extern SDL_bool SDL_MintAudio_thread_finished; -extern long SDL_MintAudio_thread_pid; - -/* Functions */ -void SDL_MintAudio_Callback(void); -void SDL_MintAudio_AddFrequency(_THIS, Uint32 frequency, Uint32 clock, - Uint32 prediv, int gpio_bits); -int SDL_MintAudio_SearchFrequency(_THIS, int desired_freq); -void SDL_MintAudio_CheckFpu(void); - -/* MiNT thread functions */ -int SDL_MintAudio_Thread(long param); -void SDL_MintAudio_WaitThread(void); - -/* ASM interrupt functions */ -void SDL_MintAudio_GsxbInterrupt(void); -void SDL_MintAudio_EmptyGsxbInterrupt(void); -void SDL_MintAudio_XbiosInterruptMeasureClock(void); -void SDL_MintAudio_XbiosInterrupt(void); -void SDL_MintAudio_Dma8Interrupt(void); -void SDL_MintAudio_StfaInterrupt(void); - -#endif /* _SDL_mintaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.c deleted file mode 100644 index d4c43cf..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.c +++ /dev/null @@ -1,361 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - using DMA 8bits (hardware access) - - Patrice Mandin -*/ - -/* Mint includes */ -#include -#include -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" - -#include "../../video/ataricommon/SDL_atarimxalloc_c.h" - -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_dma8.h" - -/*--- Defines ---*/ - -#define MINT_AUDIO_DRIVER_NAME "mint_dma8" - -/* Debug print info */ -#define DEBUG_NAME "audio:dma8: " -#if 0 -#define DEBUG_PRINT(what) \ - { \ - printf what; \ - } -#else -#define DEBUG_PRINT(what) -#endif - -/*--- Static variables ---*/ - -static unsigned long cookie_snd, cookie_mch; - -/*--- Audio driver functions ---*/ - -static void Mint_CloseAudio(_THIS); -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_LockAudio(_THIS); -static void Mint_UnlockAudio(_THIS); - -/* To check/init hardware audio */ -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec); - -/*--- Audio driver bootstrap functions ---*/ - -static int Audio_Available(void) -{ - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - - /* Check if user asked a different audio driver */ - if ((envr) && (SDL_strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) { - DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n")); - return 0; - } - - /* Cookie _MCH present ? if not, assume ST machine */ - if (Getcookie(C__MCH, &cookie_mch) == C_NOTFOUND) { - cookie_mch = MCH_ST; - } - - /* Cookie _SND present ? if not, assume ST machine */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - cookie_snd = SND_PSG; - } - - /* Check if we have 8 bits audio */ - if ((cookie_snd & SND_8BIT)==0) { - DEBUG_PRINT((DEBUG_NAME "no 8 bits sound\n")); - return(0); - } - - /* Check if audio is lockable */ - if (cookie_snd & SND_16BIT) { - if (Locksnd()!=1) { - DEBUG_PRINT((DEBUG_NAME "audio locked by other application\n")); - return(0); - } - - Unlocksnd(); - } - - DEBUG_PRINT((DEBUG_NAME "8 bits audio available!\n")); - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mint_OpenAudio; - this->CloseAudio = Mint_CloseAudio; - this->LockAudio = Mint_LockAudio; - this->UnlockAudio = Mint_UnlockAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MINTAUDIO_DMA8_bootstrap = { - MINT_AUDIO_DRIVER_NAME, "MiNT DMA 8 bits audio driver", - Audio_Available, Audio_CreateDevice -}; - -static void Mint_LockAudio(_THIS) -{ - void *oldpile; - - /* Stop replay */ - oldpile=(void *)Super(0); - DMAAUDIO_IO.control=0; - Super(oldpile); -} - -static void Mint_UnlockAudio(_THIS) -{ - void *oldpile; - - /* Restart replay */ - oldpile=(void *)Super(0); - DMAAUDIO_IO.control=3; - Super(oldpile); -} - -static void Mint_CloseAudio(_THIS) -{ - void *oldpile; - - /* Stop replay */ - oldpile=(void *)Super(0); - DMAAUDIO_IO.control=0; - Super(oldpile); - - DEBUG_PRINT((DEBUG_NAME "closeaudio: replay stopped\n")); - - /* Disable interrupt */ - Jdisint(MFP_DMASOUND); - - DEBUG_PRINT((DEBUG_NAME "closeaudio: interrupt disabled\n")); - - /* Wait if currently playing sound */ - while (SDL_MintAudio_mutex != 0) { - } - - DEBUG_PRINT((DEBUG_NAME "closeaudio: no more interrupt running\n")); - - /* Clear buffers */ - if (SDL_MintAudio_audiobuf[0]) { - Mfree(SDL_MintAudio_audiobuf[0]); - SDL_MintAudio_audiobuf[0] = SDL_MintAudio_audiobuf[1] = NULL; - } - - DEBUG_PRINT((DEBUG_NAME "closeaudio: buffers freed\n")); -} - -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec) -{ - int i, masterprediv, sfreq; - unsigned long masterclock; - - DEBUG_PRINT((DEBUG_NAME "asked: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - if (spec->channels > 2) - spec->channels = 2; - - /* Check formats available */ - spec->format = AUDIO_S8; - - /* Calculate and select the closest frequency */ - sfreq=0; - masterclock=MASTERCLOCK_STE; - masterprediv=MASTERPREDIV_STE; - switch(cookie_mch>>16) { -/* - case MCH_STE: - masterclock=MASTERCLOCK_STE; - masterprediv=MASTERPREDIV_STE; - break; -*/ - case MCH_TT: - masterclock=MASTERCLOCK_TT; - masterprediv=MASTERPREDIV_TT; - break; - case MCH_F30: - case MCH_ARANYM: - masterclock=MASTERCLOCK_FALCON1; - masterprediv=MASTERPREDIV_FALCON; - sfreq=1; - break; - } - - MINTAUDIO_freqcount=0; - for (i=sfreq;i<4;i++) { - SDL_MintAudio_AddFrequency(this, masterclock/(masterprediv*(1<freq); - spec->freq=MINTAUDIO_frequencies[MINTAUDIO_numfreq].frequency; - - DEBUG_PRINT((DEBUG_NAME "obtained: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - return 0; -} - -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec) -{ - void *oldpile; - unsigned long buffer; - unsigned char mode; - - /* Set replay tracks */ - if (cookie_snd & SND_16BIT) { - Settracks(0,0); - Setmontracks(0); - } - - oldpile=(void *)Super(0); - - /* Stop currently playing sound */ - DMAAUDIO_IO.control=0; - - /* Set buffer */ - buffer = (unsigned long) SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - DMAAUDIO_IO.start_high = (buffer>>16) & 255; - DMAAUDIO_IO.start_mid = (buffer>>8) & 255; - DMAAUDIO_IO.start_low = buffer & 255; - - buffer += SDL_MintAudio_audiosize; - DMAAUDIO_IO.end_high = (buffer>>16) & 255; - DMAAUDIO_IO.end_mid = (buffer>>8) & 255; - DMAAUDIO_IO.end_low = buffer & 255; - - mode = 3-MINTAUDIO_frequencies[MINTAUDIO_numfreq].predivisor; - if (spec->channels==1) { - mode |= 1<<7; - } - DMAAUDIO_IO.sound_ctrl = mode; - - /* Set interrupt */ - Jdisint(MFP_DMASOUND); - Xbtimer(XB_TIMERA, 8, 1, SDL_MintAudio_Dma8Interrupt); - Jenabint(MFP_DMASOUND); - - if (cookie_snd & SND_16BIT) { - if (Setinterrupt(SI_TIMERA, SI_PLAY)<0) { - DEBUG_PRINT((DEBUG_NAME "Setinterrupt() failed\n")); - } - } - - /* Go */ - DMAAUDIO_IO.control = 3; /* playback + repeat */ - - Super(oldpile); -} - -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - SDL_MintAudio_device = this; - - /* Check audio capabilities */ - if (Mint_CheckAudio(this, spec)==-1) { - return -1; - } - - SDL_CalculateAudioSpec(spec); - - /* Allocate memory for audio buffers in DMA-able RAM */ - DEBUG_PRINT((DEBUG_NAME "buffer size=%d\n", spec->size)); - - SDL_MintAudio_audiobuf[0] = Atari_SysMalloc(spec->size *2, MX_STRAM); - if (SDL_MintAudio_audiobuf[0]==NULL) { - SDL_SetError("MINT_OpenAudio: Not enough memory for audio buffer"); - return (-1); - } - SDL_MintAudio_audiobuf[1] = SDL_MintAudio_audiobuf[0] + spec->size ; - SDL_MintAudio_numbuf=0; - SDL_memset(SDL_MintAudio_audiobuf[0], spec->silence, spec->size *2); - SDL_MintAudio_audiosize = spec->size; - SDL_MintAudio_mutex = 0; - - DEBUG_PRINT((DEBUG_NAME "buffer 0 at 0x%08x\n", SDL_MintAudio_audiobuf[0])); - DEBUG_PRINT((DEBUG_NAME "buffer 1 at 0x%08x\n", SDL_MintAudio_audiobuf[1])); - - SDL_MintAudio_CheckFpu(); - - /* Setup audio hardware */ - Mint_InitAudio(this, spec); - - return(1); /* We don't use threaded audio */ -} diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.h b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.h deleted file mode 100644 index 698fed4..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_dma8.h +++ /dev/null @@ -1,85 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - DMA 8bits and Falcon Codec audio definitions - - Patrice Mandin, Didier Méquignon -*/ - -#ifndef _SDL_mintaudio_dma8_h -#define _SDL_mintaudio_dma8_h - -#define DMAAUDIO_IO_BASE (0xffff8900) -struct DMAAUDIO_IO_S { - unsigned char int_ctrl; - unsigned char control; - - unsigned char dummy1; - unsigned char start_high; - unsigned char dummy2; - unsigned char start_mid; - unsigned char dummy3; - unsigned char start_low; - - unsigned char dummy4; - unsigned char cur_high; - unsigned char dummy5; - unsigned char cur_mid; - unsigned char dummy6; - unsigned char cur_low; - - unsigned char dummy7; - unsigned char end_high; - unsigned char dummy8; - unsigned char end_mid; - unsigned char dummy9; - unsigned char end_low; - - unsigned char dummy10[12]; - - unsigned char track_ctrl; /* CODEC only */ - unsigned char sound_ctrl; - unsigned short sound_data; - unsigned short sound_mask; - - unsigned char dummy11[10]; - - unsigned short dev_ctrl; - unsigned short dest_ctrl; - unsigned short sync_div; - unsigned char track_rec; - unsigned char adderin_input; - unsigned char channel_input; - unsigned char channel_amplification; - unsigned char channel_reduction; - - unsigned char dummy12[6]; - - unsigned char data_direction; - unsigned char dummy13; - unsigned char dev_data; -}; -#define DMAAUDIO_IO ((*(volatile struct DMAAUDIO_IO_S *)DMAAUDIO_IO_BASE)) - -#endif /* _SDL_mintaudio_dma8_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.c deleted file mode 100644 index 41f78c9..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.c +++ /dev/null @@ -1,436 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - using XBIOS functions (GSXB compatible driver) - - Patrice Mandin -*/ - -/* Mint includes */ -#include -#include -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" - -#include "../../video/ataricommon/SDL_atarimxalloc_c.h" - -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_gsxb.h" - -/*--- Defines ---*/ - -#define MINT_AUDIO_DRIVER_NAME "mint_gsxb" - -/* Debug print info */ -#define DEBUG_NAME "audio:gsxb: " -#if 0 -#define DEBUG_PRINT(what) \ - { \ - printf what; \ - } -#else -#define DEBUG_PRINT(what) -#endif - -/*--- Static variables ---*/ - -static unsigned long cookie_snd, cookie_gsxb; - -/*--- Audio driver functions ---*/ - -static void Mint_CloseAudio(_THIS); -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_LockAudio(_THIS); -static void Mint_UnlockAudio(_THIS); - -/* To check/init hardware audio */ -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec); - -/* GSXB callbacks */ -static void Mint_GsxbInterrupt(void); -static void Mint_GsxbNullInterrupt(void); - -/*--- Audio driver bootstrap functions ---*/ - -static int Audio_Available(void) -{ - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - - /* Check if user asked a different audio driver */ - if ((envr) && (SDL_strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) { - DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n")); - return(0); - } - - /* Cookie _SND present ? if not, assume ST machine */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - cookie_snd = SND_PSG; - } - - /* Check if we have 16 bits audio */ - if ((cookie_snd & SND_16BIT)==0) { - DEBUG_PRINT((DEBUG_NAME "no 16 bits sound\n")); - return(0); - } - - /* Cookie GSXB present ? */ - cookie_gsxb = (Getcookie(C_GSXB, &cookie_gsxb) == C_FOUND); - - /* Is it GSXB ? */ - if (((cookie_snd & SND_GSXB)==0) || (cookie_gsxb==0)) { - DEBUG_PRINT((DEBUG_NAME "no GSXB audio\n")); - return(0); - } - - /* Check if audio is lockable */ - if (Locksnd()!=1) { - DEBUG_PRINT((DEBUG_NAME "audio locked by other application\n")); - return(0); - } - - Unlocksnd(); - - DEBUG_PRINT((DEBUG_NAME "GSXB audio available!\n")); - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mint_OpenAudio; - this->CloseAudio = Mint_CloseAudio; - this->LockAudio = Mint_LockAudio; - this->UnlockAudio = Mint_UnlockAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MINTAUDIO_GSXB_bootstrap = { - MINT_AUDIO_DRIVER_NAME, "MiNT GSXB audio driver", - Audio_Available, Audio_CreateDevice -}; - -static void Mint_LockAudio(_THIS) -{ - /* Stop replay */ - Buffoper(0); -} - -static void Mint_UnlockAudio(_THIS) -{ - /* Restart replay */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); -} - -static void Mint_CloseAudio(_THIS) -{ - /* Stop replay */ - Buffoper(0); - - /* Uninstall interrupt */ - if (NSetinterrupt(2, SI_NONE, Mint_GsxbNullInterrupt)<0) { - DEBUG_PRINT((DEBUG_NAME "NSetinterrupt() failed in close\n")); - } - - /* Wait if currently playing sound */ - while (SDL_MintAudio_mutex != 0) { - } - - /* Clear buffers */ - if (SDL_MintAudio_audiobuf[0]) { - Mfree(SDL_MintAudio_audiobuf[0]); - SDL_MintAudio_audiobuf[0] = SDL_MintAudio_audiobuf[1] = NULL; - } - - /* Unlock sound system */ - Unlocksnd(); -} - -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec) -{ - long snd_format; - int i, resolution, format_signed, format_bigendian; - Uint16 test_format = SDL_FirstAudioFormat(spec->format); - int valid_datatype = 0; - - resolution = spec->format & 0x00ff; - format_signed = ((spec->format & 0x8000)!=0); - format_bigendian = ((spec->format & 0x1000)!=0); - - DEBUG_PRINT((DEBUG_NAME "asked: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - if (spec->channels > 2) { - spec->channels = 2; /* no more than stereo! */ - } - - while ((!valid_datatype) && (test_format)) { - /* Check formats available */ - snd_format = Sndstatus(SND_QUERYFORMATS); - spec->format = test_format; - resolution = spec->format & 0xff; - format_signed = (spec->format & (1<<15)); - format_bigendian = (spec->format & (1<<12)); - switch (test_format) { - case AUDIO_U8: - case AUDIO_S8: - if (snd_format & SND_FORMAT8) { - valid_datatype = 1; - snd_format = Sndstatus(SND_QUERY8BIT); - } - break; - - case AUDIO_U16LSB: - case AUDIO_S16LSB: - case AUDIO_U16MSB: - case AUDIO_S16MSB: - if (snd_format & SND_FORMAT16) { - valid_datatype = 1; - snd_format = Sndstatus(SND_QUERY16BIT); - } - break; - - default: - test_format = SDL_NextAudioFormat(); - break; - } - } - - if (!valid_datatype) { - SDL_SetError("Unsupported audio format"); - return (-1); - } - - /* Check signed/unsigned format */ - if (format_signed) { - if (snd_format & SND_FORMATSIGNED) { - /* Ok */ - } else if (snd_format & SND_FORMATUNSIGNED) { - /* Give unsigned format */ - spec->format = spec->format & (~0x8000); - } - } else { - if (snd_format & SND_FORMATUNSIGNED) { - /* Ok */ - } else if (snd_format & SND_FORMATSIGNED) { - /* Give signed format */ - spec->format |= 0x8000; - } - } - - if (format_bigendian) { - if (snd_format & SND_FORMATBIGENDIAN) { - /* Ok */ - } else if (snd_format & SND_FORMATLITTLEENDIAN) { - /* Give little endian format */ - spec->format = spec->format & (~0x1000); - } - } else { - if (snd_format & SND_FORMATLITTLEENDIAN) { - /* Ok */ - } else if (snd_format & SND_FORMATBIGENDIAN) { - /* Give big endian format */ - spec->format |= 0x1000; - } - } - - /* Calculate and select the closest frequency */ - MINTAUDIO_freqcount=0; - for (i=1;i<4;i++) { - SDL_MintAudio_AddFrequency(this, - MASTERCLOCK_44K/(MASTERPREDIV_MILAN*(1<freq); - spec->freq=MINTAUDIO_frequencies[MINTAUDIO_numfreq].frequency; - - DEBUG_PRINT((DEBUG_NAME "obtained: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - return 0; -} - -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec) -{ - int channels_mode, prediv; - void *buffer; - - /* Stop currently playing sound */ - Buffoper(0); - - /* Set replay tracks */ - Settracks(0,0); - Setmontracks(0); - - /* Select replay format */ - switch (spec->format & 0xff) { - case 8: - if (spec->channels==2) { - channels_mode=STEREO8; - } else { - channels_mode=MONO8; - } - break; - case 16: - if (spec->channels==2) { - channels_mode=STEREO16; - } else { - channels_mode=MONO16; - } - break; - default: - channels_mode=STEREO16; - break; - } - if (Setmode(channels_mode)<0) { - DEBUG_PRINT((DEBUG_NAME "Setmode() failed\n")); - } - - prediv = MINTAUDIO_frequencies[MINTAUDIO_numfreq].predivisor; - Devconnect(DMAPLAY, DAC, CLKEXT, prediv, 1); - - /* Set buffer */ - buffer = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - if (Setbuffer(0, buffer, buffer + spec->size)<0) { - DEBUG_PRINT((DEBUG_NAME "Setbuffer() failed\n")); - } - - /* Install interrupt */ - if (NSetinterrupt(2, SI_PLAY, Mint_GsxbInterrupt)<0) { - DEBUG_PRINT((DEBUG_NAME "NSetinterrupt() failed\n")); - } - - /* Go */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); - DEBUG_PRINT((DEBUG_NAME "hardware initialized\n")); -} - -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - /* Lock sound system */ - if (Locksnd()!=1) { - SDL_SetError("Mint_OpenAudio: Audio system already in use"); - return(-1); - } - - SDL_MintAudio_device = this; - - /* Check audio capabilities */ - if (Mint_CheckAudio(this, spec)==-1) { - return -1; - } - - SDL_CalculateAudioSpec(spec); - - /* Allocate memory for audio buffers in DMA-able RAM */ - DEBUG_PRINT((DEBUG_NAME "buffer size=%d\n", spec->size)); - - SDL_MintAudio_audiobuf[0] = Atari_SysMalloc(spec->size *2, MX_STRAM); - if (SDL_MintAudio_audiobuf[0]==NULL) { - SDL_SetError("MINT_OpenAudio: Not enough memory for audio buffer"); - return (-1); - } - SDL_MintAudio_audiobuf[1] = SDL_MintAudio_audiobuf[0] + spec->size ; - SDL_MintAudio_numbuf=0; - SDL_memset(SDL_MintAudio_audiobuf[0], spec->silence, spec->size *2); - SDL_MintAudio_audiosize = spec->size; - SDL_MintAudio_mutex = 0; - - DEBUG_PRINT((DEBUG_NAME "buffer 0 at 0x%08x\n", SDL_MintAudio_audiobuf[0])); - DEBUG_PRINT((DEBUG_NAME "buffer 1 at 0x%08x\n", SDL_MintAudio_audiobuf[1])); - - SDL_MintAudio_CheckFpu(); - - /* Setup audio hardware */ - Mint_InitAudio(this, spec); - - return(1); /* We don't use threaded audio */ -} - -static void Mint_GsxbInterrupt(void) -{ - Uint8 *newbuf; - - if (SDL_MintAudio_mutex) - return; - - SDL_MintAudio_mutex=1; - - SDL_MintAudio_numbuf ^= 1; - SDL_MintAudio_Callback(); - newbuf = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - Setbuffer(0, newbuf, newbuf + SDL_MintAudio_audiosize); - - SDL_MintAudio_mutex=0; -} - -static void Mint_GsxbNullInterrupt(void) -{ -} diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.h b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.h deleted file mode 100644 index 595e313..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_gsxb.h +++ /dev/null @@ -1,108 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - * GSXB audio definitions - * - * Patrice Mandin - */ - -#ifndef _SDL_mintaudio_gsxb_h -#define _SDL_mintaudio_gsxb_h - -#include /* for trap_14_xxx macros */ - -/* GSXB Cookie */ - -#define C_GSXB 0x47535842L - -/* Bit 5 in cookie _SND */ - -#define SND_GSXB (1<<5) - -/* NSoundcmd modes */ - -#define SETRATE 7 /* Set sample rate */ -#define SET8BITFORMAT 8 /* 8 bits format */ -#define SET16BITFORMAT 9 /* 16 bits format */ -#define SET24BITFORMAT 10 /* 24 bits format */ -#define SET32BITFORMAT 11 /* 32 bits format */ -#define LTATTEN_MASTER 12 /* Attenuation */ -#define RTATTEN_MASTER 13 -#define LTATTEN_MICIN 14 -#define RTATTEN_MICIN 15 -#define LTATTEN_FMGEN 16 -#define RTATTEN_FMGEN 17 -#define LTATTEN_LINEIN 18 -#define RTATTEN_LINEIN 19 -#define LTATTEN_CDIN 20 -#define RTATTEN_CDIN 21 -#define LTATTEN_VIDIN 22 -#define RTATTEN_VIDIN 23 -#define LTATTEN_AUXIN 24 -#define RTATTEN_AUXIN 25 - -/* Setmode modes */ - -#define MONO16 3 -#define STEREO24 4 -#define STEREO32 5 -#define MONO24 6 -#define MONO32 7 - -/* Sndstatus modes */ - -#define SND_QUERYFORMATS 2 -#define SND_QUERYMIXERS 3 -#define SND_QUERYSOURCES 4 -#define SND_QUERYDUPLEX 5 -#define SND_QUERY8BIT 8 -#define SND_QUERY16BIT 9 -#define SND_QUERY24BIT 10 -#define SND_QUERY32BIT 11 - -#define SND_FORMAT8 (1<<0) -#define SND_FORMAT16 (1<<1) -#define SND_FORMAT24 (1<<2) -#define SND_FORMAT32 (1<<3) - -#define SND_FORMATSIGNED (1<<0) -#define SND_FORMATUNSIGNED (1<<1) -#define SND_FORMATBIGENDIAN (1<<2) -#define SND_FORMATLITTLEENDIAN (1<<3) - -/* Devconnect prescalers */ - -#define CLK_44K 1 -#define CLK_22K 3 -#define CLK_11K 7 - -/* Extra xbios functions */ - -#define NSoundcmd(mode,data,data2) \ - (long)trap_14_wwl((short)130,(short)(mode),(short)(data),(long)(data2)) -#define NSetinterrupt(src_inter,cause,inth_addr) \ - (long)trap_14_wwwl((short)135,(short)(src_inter),(short)(cause), \ - (long)(inth_addr)) - -#endif /* _SDL_mintaudio_gsxb_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_it.S b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_it.S deleted file mode 100644 index c751a59..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_it.S +++ /dev/null @@ -1,281 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ - -/* - Audio interrupts - - Patrice Mandin, Didier Méquignon - */ - - .text - - .globl _SDL_MintAudio_Callback - - .globl _SDL_MintAudio_XbiosInterrupt - .globl _SDL_MintAudio_XbiosInterruptMeasureClock - .globl _SDL_MintAudio_Dma8Interrupt - .globl _SDL_MintAudio_StfaInterrupt - - .globl _SDL_MintAudio_mutex - .globl _SDL_MintAudio_audiobuf - .globl _SDL_MintAudio_numbuf - .globl _SDL_MintAudio_audiosize - .globl _SDL_MintAudio_clocktics - .globl _SDL_MintAudio_hasfpu - - .globl _SDL_MintAudio_stfa - -/* - How it works: - - Audio is playing buffer #0 (resp. #1) - - We must calculate a sample in buffer #1 (resp. #0) - so we first call the callback to do it - - Then we swap the buffers -*/ - -#define savptr 0x4a2 -#define savamt 0x46 - -/*--- Xbios interrupt vector to measure Falcon external clock ---*/ - -_SDL_MintAudio_XbiosInterruptMeasureClock: /* 1 mS */ - - btst #0,0xFFFF8901:w /* state DMA sound */ - beqs SDL_MintAudio_EndIntMeasure - addql #1,_SDL_MintAudio_clocktics -SDL_MintAudio_EndIntMeasure: - bclr #5,0xFFFFFA0F:w /* Clear service bit */ - rte - -/*--- Xbios interrupt vector ---*/ - -_SDL_MintAudio_XbiosInterrupt: - - /* Reenable interrupts, so other interrupts can work */ - movew #0x2300,sr - - /* Clear service bit, so other MFP interrupts can work */ - bclr #5,0xfffffa0f:w - - /* Check if we are not already running */ - tstw _SDL_MintAudio_mutex - bne SDL_MintAudio_XbiosEnd - notw _SDL_MintAudio_mutex - - /* Swap buffers */ - eorw #1,_SDL_MintAudio_numbuf - - moveml d0-d7/a0-a6,sp@- - - /* Save FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Xbios_nofpu1 - .chip 68060 - fsave sp@- - fmoveml fpcr/fpsr/fpiar,sp@- - fmovemx fp0-fp7,sp@- - .chip 68000 -SDL_MintAudio_Xbios_nofpu1: - - /* Callback */ - jsr _SDL_MintAudio_Callback - - /* Restore FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Xbios_nofpu2 - .chip 68060 - fmovemx sp@+,fp0-fp7 - fmoveml sp@+,fpcr/fpsr/fpiar - frestore sp@+ - .chip 68000 -SDL_MintAudio_Xbios_nofpu2: - - /* Reserve space for registers */ - subl #savamt,savptr - - /* Set new buffer */ - - moveq #0,d0 - movel _SDL_MintAudio_audiosize,d1 - - movew _SDL_MintAudio_numbuf,d0 - lsll #2,d0 - lea _SDL_MintAudio_audiobuf,a0 - movel a0@(d0:l),a1 - - lea a1@(d1:l),a2 - - movel a2,sp@- - movel a1,sp@- - clrw sp@- - movew #131,sp@- - trap #14 - lea sp@(12),sp - - /* Restore registers space */ - addl #savamt,savptr - - moveml sp@+,d0-d7/a0-a6 - - clrw _SDL_MintAudio_mutex -SDL_MintAudio_XbiosEnd: - rte - -/*--- DMA 8 bits interrupt vector ---*/ - -_SDL_MintAudio_Dma8Interrupt: - - /* Reenable interrupts, so other interrupts can work */ - movew #0x2300,sr - - /* Clear service bit, so other MFP interrupts can work */ - bclr #5,0xfffffa0f:w - - /* Check if we are not already running */ - tstw _SDL_MintAudio_mutex - bne SDL_MintAudio_Dma8End - notw _SDL_MintAudio_mutex - - /* Swap buffers */ - eorw #1,_SDL_MintAudio_numbuf - - moveml d0-d1/a0-a1,sp@- - - /* Save FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Dma8_nofpu1 - .chip 68060 - fsave sp@- - fmoveml fpcr/fpsr/fpiar,sp@- - fmovemx fp0-fp7,sp@- - .chip 68000 -SDL_MintAudio_Dma8_nofpu1: - - /* Callback */ - jsr _SDL_MintAudio_Callback - - /* Restore FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Dma8_nofpu2 - .chip 68060 - fmovemx sp@+,fp0-fp7 - fmoveml sp@+,fpcr/fpsr/fpiar - frestore sp@+ - .chip 68000 -SDL_MintAudio_Dma8_nofpu2: - - /* Set new buffer */ - - moveq #0,d0 - - movew _SDL_MintAudio_numbuf,d0 - lslw #2,d0 - lea _SDL_MintAudio_audiobuf,a0 - movel a0@(d0:w),d1 - - /* Modify DMA addresses */ - lea 0xffff8900:w,a0 - - moveb d1,a0@(0x07) /* Start address */ - rorl #8,d1 - moveb d1,a0@(0x05) - rorl #8,d1 - moveb d1,a0@(0x03) - swap d1 - - addl _SDL_MintAudio_audiosize,d1 - - moveb d1,a0@(0x13) /* End address */ - rorl #8,d1 - moveb d1,a0@(0x11) - rorl #8,d1 - moveb d1,a0@(0x0f) - - moveml sp@+,d0-d1/a0-a1 - - clrw _SDL_MintAudio_mutex -SDL_MintAudio_Dma8End: - rte - -/*--- STFA interrupt vector ---*/ - -STFA_SOUND_START = 6 -STFA_SOUND_END = STFA_SOUND_START+8 - -_SDL_MintAudio_StfaInterrupt: - - /* Reenable interrupts, so other interrupts can work */ - movew #0x2300,sr - - /* Check if we are not already running */ - tstw _SDL_MintAudio_mutex - bnes SDL_MintAudio_StfaEnd - notw _SDL_MintAudio_mutex - - /* Swap buffers */ - eorw #1,_SDL_MintAudio_numbuf - - moveml d0-d7/a0-a6,sp@- - - /* Save FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Stfa_nofpu1 - .chip 68060 - fsave sp@- - fmoveml fpcr/fpsr/fpiar,sp@- - fmovemx fp0-fp7,sp@- - .chip 68000 -SDL_MintAudio_Stfa_nofpu1: - - /* Callback */ - jsr _SDL_MintAudio_Callback - - /* Restore FPU if needed */ - tstw _SDL_MintAudio_hasfpu - beqs SDL_MintAudio_Stfa_nofpu2 - .chip 68060 - fmovemx sp@+,fp0-fp7 - fmoveml sp@+,fpcr/fpsr/fpiar - frestore sp@+ - .chip 68000 -SDL_MintAudio_Stfa_nofpu2: - - /* Set new buffer */ - - moveq #0,d0 - movel _SDL_MintAudio_stfa,a1 - - movew _SDL_MintAudio_numbuf,d0 - lslw #2,d0 - lea _SDL_MintAudio_audiobuf,a0 - movel a0@(d0:w),d1 - - /* Modify STFA replay buffers */ - movel d1,a1@(STFA_SOUND_START) - addl _SDL_MintAudio_audiosize,d1 - movel d1,a1@(STFA_SOUND_END) - - moveml sp@+,d0-d7/a0-a6 - - clrw _SDL_MintAudio_mutex -SDL_MintAudio_StfaEnd: - rte diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.c deleted file mode 100644 index a464184..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.c +++ /dev/null @@ -1,404 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - using XBIOS functions (MacSound compatible driver) - - Patrice Mandin -*/ - -#include - -/* Mint includes */ -#include -#include -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" - -#include "../../video/ataricommon/SDL_atarimxalloc_c.h" - -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_mcsn.h" - -/*--- Defines ---*/ - -#define MINT_AUDIO_DRIVER_NAME "mint_mcsn" - -/* Debug print info */ -#define DEBUG_NAME "audio:mcsn: " -#if 0 -#define DEBUG_PRINT(what) \ - { \ - printf what; \ - } -#else -#define DEBUG_PRINT(what) -#endif - -/*--- Static variables ---*/ - -static unsigned long cookie_snd, cookie_mch; -static cookie_mcsn_t *cookie_mcsn; - -/*--- Audio driver functions ---*/ - -static void Mint_CloseAudio(_THIS); -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_LockAudio(_THIS); -static void Mint_UnlockAudio(_THIS); - -/* To check/init hardware audio */ -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec); - -/*--- Audio driver bootstrap functions ---*/ - -static int Audio_Available(void) -{ - unsigned long dummy; - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - - SDL_MintAudio_mint_present = (Getcookie(C_MiNT, &dummy) == C_FOUND); - - /* We can't use XBIOS in interrupt with Magic, don't know about thread */ - if (Getcookie(C_MagX, &dummy) == C_FOUND) { - return(0); - } - - /* Check if user asked a different audio driver */ - if ((envr) && (SDL_strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) { - DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n")); - return(0); - } - - /* Cookie _MCH present ? if not, assume ST machine */ - if (Getcookie(C__MCH, &cookie_mch) == C_NOTFOUND) { - cookie_mch = MCH_ST; - } - - /* Cookie _SND present ? if not, assume ST machine */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - cookie_snd = SND_PSG; - } - - /* Check if we have 16 bits audio */ - if ((cookie_snd & SND_16BIT)==0) { - DEBUG_PRINT((DEBUG_NAME "no 16 bits sound\n")); - return(0); - } - - /* Cookie MCSN present ? */ - if (Getcookie(C_McSn, (long *) &cookie_mcsn) != C_FOUND) { - DEBUG_PRINT((DEBUG_NAME "no MCSN audio\n")); - return(0); - } - - /* Check if interrupt at end of replay */ - if (cookie_mcsn->pint == 0) { - DEBUG_PRINT((DEBUG_NAME "no interrupt at end of replay\n")); - return(0); - } - - /* Check if audio is lockable */ - if (Locksnd()!=1) { - DEBUG_PRINT((DEBUG_NAME "audio locked by other application\n")); - return(0); - } - - Unlocksnd(); - - DEBUG_PRINT((DEBUG_NAME "MCSN audio available!\n")); - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mint_OpenAudio; - this->CloseAudio = Mint_CloseAudio; - this->LockAudio = Mint_LockAudio; - this->UnlockAudio = Mint_UnlockAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MINTAUDIO_MCSN_bootstrap = { - MINT_AUDIO_DRIVER_NAME, "MiNT MCSN audio driver", - Audio_Available, Audio_CreateDevice -}; - -static void Mint_LockAudio(_THIS) -{ - /* Stop replay */ - Buffoper(0); -} - -static void Mint_UnlockAudio(_THIS) -{ - /* Restart replay */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); -} - -static void Mint_CloseAudio(_THIS) -{ - /* Stop replay */ - SDL_MintAudio_WaitThread(); - Buffoper(0); - - if (!SDL_MintAudio_mint_present) { - /* Uninstall interrupt */ - Jdisint(MFP_DMASOUND); - } - - /* Wait if currently playing sound */ - while (SDL_MintAudio_mutex != 0) { - } - - /* Clear buffers */ - if (SDL_MintAudio_audiobuf[0]) { - Mfree(SDL_MintAudio_audiobuf[0]); - SDL_MintAudio_audiobuf[0] = SDL_MintAudio_audiobuf[1] = NULL; - } - - /* Unlock sound system */ - Unlocksnd(); -} - -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec) -{ - int i; - unsigned long masterclock, masterprediv; - - DEBUG_PRINT((DEBUG_NAME "asked: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - if (spec->channels > 2) { - spec->channels = 2; /* no more than stereo! */ - } - - /* Check formats available */ - MINTAUDIO_freqcount=0; - switch(cookie_mcsn->play) { - case MCSN_ST: - spec->channels=1; - spec->format=8; /* FIXME: is it signed or unsigned ? */ - SDL_MintAudio_AddFrequency(this, 12500, 0, 0, -1); - break; - case MCSN_TT: /* Also STE, Mega STE */ - spec->format=AUDIO_S8; - masterclock=MASTERCLOCK_STE; - masterprediv=MASTERPREDIV_STE; - if ((cookie_mch>>16)==MCH_TT) { - masterclock=MASTERCLOCK_TT; - masterprediv=MASTERPREDIV_TT; - } - for (i=0; i<4; i++) { - SDL_MintAudio_AddFrequency(this, masterclock/(masterprediv*(1<res1 != 0) { - for (i=1; i<4; i++) { - SDL_MintAudio_AddFrequency(this, (cookie_mcsn->res1)/(MASTERPREDIV_FALCON*(1<format |= 0x8000; /* Audio is always signed */ - if ((spec->format & 0x00ff)==16) { - spec->format |= 0x1000; /* Audio is always big endian */ - spec->channels=2; /* 16 bits always stereo */ - } - break; - } - -#if 1 - for (i=0; ifreq); - spec->freq=MINTAUDIO_frequencies[MINTAUDIO_numfreq].frequency; - - DEBUG_PRINT((DEBUG_NAME "obtained: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - return 0; -} - -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec) -{ - int channels_mode, prediv, dmaclock; - void *buffer; - - /* Stop currently playing sound */ - SDL_MintAudio_quit_thread = SDL_FALSE; - SDL_MintAudio_thread_finished = SDL_TRUE; - SDL_MintAudio_WaitThread(); - Buffoper(0); - - /* Set replay tracks */ - Settracks(0,0); - Setmontracks(0); - - /* Select replay format */ - channels_mode=STEREO16; - switch (spec->format & 0xff) { - case 8: - if (spec->channels==2) { - channels_mode=STEREO8; - } else { - channels_mode=MONO8; - } - break; - } - if (Setmode(channels_mode)<0) { - DEBUG_PRINT((DEBUG_NAME "Setmode() failed\n")); - } - - dmaclock = MINTAUDIO_frequencies[MINTAUDIO_numfreq].masterclock; - prediv = MINTAUDIO_frequencies[MINTAUDIO_numfreq].predivisor; - switch(cookie_mcsn->play) { - case MCSN_TT: - Devconnect(DMAPLAY, DAC, CLK25M, CLKOLD, 1); - Soundcmd(SETPRESCALE, prediv); - DEBUG_PRINT((DEBUG_NAME "STE/TT prescaler selected\n")); - break; - case MCSN_FALCON: - Devconnect(DMAPLAY, DAC, dmaclock, prediv, 1); - DEBUG_PRINT((DEBUG_NAME "Falcon prescaler selected\n")); - break; - } - - /* Set buffer */ - buffer = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - if (Setbuffer(0, buffer, buffer + spec->size)<0) { - DEBUG_PRINT((DEBUG_NAME "Setbuffer() failed\n")); - } - - if (SDL_MintAudio_mint_present) { - SDL_MintAudio_thread_pid = tfork(SDL_MintAudio_Thread, 0); - } else { - /* Install interrupt */ - Jdisint(MFP_DMASOUND); - Xbtimer(XB_TIMERA, 8, 1, SDL_MintAudio_XbiosInterrupt); - Jenabint(MFP_DMASOUND); - - if (Setinterrupt(SI_TIMERA, SI_PLAY)<0) { - DEBUG_PRINT((DEBUG_NAME "Setinterrupt() failed\n")); - } - } - - /* Go */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); - DEBUG_PRINT((DEBUG_NAME "hardware initialized\n")); -} - -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - /* Lock sound system */ - if (Locksnd()!=1) { - SDL_SetError("Mint_OpenAudio: Audio system already in use"); - return(-1); - } - - SDL_MintAudio_device = this; - - /* Check audio capabilities */ - if (Mint_CheckAudio(this, spec)==-1) { - return -1; - } - - SDL_CalculateAudioSpec(spec); - - /* Allocate memory for audio buffers in DMA-able RAM */ - DEBUG_PRINT((DEBUG_NAME "buffer size=%d\n", spec->size)); - - SDL_MintAudio_audiobuf[0] = Atari_SysMalloc(spec->size *2, MX_STRAM); - if (SDL_MintAudio_audiobuf[0]==NULL) { - SDL_SetError("MINT_OpenAudio: Not enough memory for audio buffer"); - return (-1); - } - SDL_MintAudio_audiobuf[1] = SDL_MintAudio_audiobuf[0] + spec->size ; - SDL_MintAudio_numbuf=0; - SDL_memset(SDL_MintAudio_audiobuf[0], spec->silence, spec->size *2); - SDL_MintAudio_audiosize = spec->size; - SDL_MintAudio_mutex = 0; - - DEBUG_PRINT((DEBUG_NAME "buffer 0 at 0x%08x\n", SDL_MintAudio_audiobuf[0])); - DEBUG_PRINT((DEBUG_NAME "buffer 1 at 0x%08x\n", SDL_MintAudio_audiobuf[1])); - - SDL_MintAudio_CheckFpu(); - - /* Setup audio hardware */ - Mint_InitAudio(this, spec); - - return(1); /* We don't use SDL threaded audio */ -} diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.h b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.h deleted file mode 100644 index f253ddd..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_mcsn.h +++ /dev/null @@ -1,59 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MCSN control structure - - Patrice Mandin -*/ - -#ifndef _SDL_mintaudio_mcsh_h -#define _SDL_mintaudio_mcsh_h - -typedef struct { - unsigned short version; /* Version */ - unsigned short size; /* Size of structure */ - - unsigned short play; /* Replay capability */ - unsigned short record; /* Record capability */ - unsigned short dsp; /* DSP56K present */ - unsigned short pint; /* Interrupt at end of replay */ - unsigned short rint; /* Interrupt at end of record */ - - unsigned long res1; /* Frequency of external clock */ - unsigned long res2; - unsigned long res3; - unsigned long res4; -} cookie_mcsn_t __attribute__((packed)); - -enum { - MCSN_ST=0, - MCSN_TT, - MCSN_STE=MCSN_TT, - MCSN_FALCON, - MCSN_MAC=MCSN_FALCON -}; - -#define SETSMPFREQ 7 /* Set sample frequency */ - -#endif /* _SDL_mintaudio_mcsh_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.c deleted file mode 100644 index 4ad1fdd..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.c +++ /dev/null @@ -1,323 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - using XBIOS functions (STFA driver) - - Patrice Mandin -*/ - -/* Mint includes */ -#include -#include -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" - -#include "../../video/ataricommon/SDL_atarimxalloc_c.h" - -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_stfa.h" - -/*--- Defines ---*/ - -#define MINT_AUDIO_DRIVER_NAME "mint_stfa" - -/* Debug print info */ -#define DEBUG_NAME "audio:stfa: " -#if 0 -#define DEBUG_PRINT(what) \ - { \ - printf what; \ - } -#else -#define DEBUG_PRINT(what) -#endif - -/*--- Static variables ---*/ - -static unsigned long cookie_snd, cookie_mch; -static cookie_stfa_t *cookie_stfa; - -static const int freqs[16]={ - 4995, 6269, 7493, 8192, - 9830, 10971, 12538, 14985, - 16384, 19819, 21943, 24576, - 30720, 32336, 43885, 49152 -}; - -/*--- Audio driver functions ---*/ - -static void Mint_CloseAudio(_THIS); -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_LockAudio(_THIS); -static void Mint_UnlockAudio(_THIS); - -/* To check/init hardware audio */ -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec); - -/*--- Audio driver bootstrap functions ---*/ - -static int Audio_Available(void) -{ - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - - /* Check if user asked a different audio driver */ - if ((envr) && (SDL_strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) { - DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n")); - return(0); - } - - /* Cookie _MCH present ? if not, assume ST machine */ - if (Getcookie(C__MCH, &cookie_mch) == C_NOTFOUND) { - cookie_mch = MCH_ST; - } - - /* Cookie _SND present ? if not, assume ST machine */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - cookie_snd = SND_PSG; - } - - /* Cookie STFA present ? */ - if (Getcookie(C_STFA, (long *) &cookie_stfa) != C_FOUND) { - DEBUG_PRINT((DEBUG_NAME "no STFA audio\n")); - return(0); - } - - SDL_MintAudio_stfa = cookie_stfa; - - DEBUG_PRINT((DEBUG_NAME "STFA audio available!\n")); - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mint_OpenAudio; - this->CloseAudio = Mint_CloseAudio; - this->LockAudio = Mint_LockAudio; - this->UnlockAudio = Mint_UnlockAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MINTAUDIO_STFA_bootstrap = { - MINT_AUDIO_DRIVER_NAME, "MiNT STFA audio driver", - Audio_Available, Audio_CreateDevice -}; - -static void Mint_LockAudio(_THIS) -{ - void *oldpile; - - /* Stop replay */ - oldpile=(void *)Super(0); - cookie_stfa->sound_enable=STFA_PLAY_DISABLE; - Super(oldpile); -} - -static void Mint_UnlockAudio(_THIS) -{ - void *oldpile; - - /* Restart replay */ - oldpile=(void *)Super(0); - cookie_stfa->sound_enable=STFA_PLAY_ENABLE|STFA_PLAY_REPEAT; - Super(oldpile); -} - -static void Mint_CloseAudio(_THIS) -{ - void *oldpile; - - /* Stop replay */ - oldpile=(void *)Super(0); - cookie_stfa->sound_enable=STFA_PLAY_DISABLE; - Super(oldpile); - - /* Wait if currently playing sound */ - while (SDL_MintAudio_mutex != 0) { - } - - /* Clear buffers */ - if (SDL_MintAudio_audiobuf[0]) { - Mfree(SDL_MintAudio_audiobuf[0]); - SDL_MintAudio_audiobuf[0] = SDL_MintAudio_audiobuf[1] = NULL; - } -} - -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec) -{ - int i; - - DEBUG_PRINT((DEBUG_NAME "asked: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - if (spec->channels > 2) { - spec->channels = 2; /* no more than stereo! */ - } - - /* Check formats available */ - MINTAUDIO_freqcount=0; - for (i=0;i<16;i++) { - SDL_MintAudio_AddFrequency(this, freqs[i], 0, i, -1); - } - -#if 1 - for (i=0; ifreq); - spec->freq=MINTAUDIO_frequencies[MINTAUDIO_numfreq].frequency; - - DEBUG_PRINT((DEBUG_NAME "obtained: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - return 0; -} - -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec) -{ - void *buffer; - void *oldpile; - - buffer = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - - oldpile=(void *)Super(0); - - /* Stop replay */ - cookie_stfa->sound_enable=STFA_PLAY_DISABLE; - - /* Select replay format */ - cookie_stfa->sound_control = MINTAUDIO_frequencies[MINTAUDIO_numfreq].predivisor; - if ((spec->format & 0xff)==8) { - cookie_stfa->sound_control |= STFA_FORMAT_8BIT; - } else { - cookie_stfa->sound_control |= STFA_FORMAT_16BIT; - } - if (spec->channels==2) { - cookie_stfa->sound_control |= STFA_FORMAT_STEREO; - } else { - cookie_stfa->sound_control |= STFA_FORMAT_MONO; - } - if ((spec->format & 0x8000)!=0) { - cookie_stfa->sound_control |= STFA_FORMAT_SIGNED; - } else { - cookie_stfa->sound_control |= STFA_FORMAT_UNSIGNED; - } - if ((spec->format & 0x1000)!=0) { - cookie_stfa->sound_control |= STFA_FORMAT_BIGENDIAN; - } else { - cookie_stfa->sound_control |= STFA_FORMAT_LITENDIAN; - } - - /* Set buffer */ - cookie_stfa->sound_start = (unsigned long) buffer; - cookie_stfa->sound_end = (unsigned long) (buffer + spec->size); - - /* Set interrupt */ - cookie_stfa->stfa_it = SDL_MintAudio_StfaInterrupt; - - /* Restart replay */ - cookie_stfa->sound_enable=STFA_PLAY_ENABLE|STFA_PLAY_REPEAT; - - Super(oldpile); - - DEBUG_PRINT((DEBUG_NAME "hardware initialized\n")); -} - -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - SDL_MintAudio_device = this; - - /* Check audio capabilities */ - if (Mint_CheckAudio(this, spec)==-1) { - return -1; - } - - SDL_CalculateAudioSpec(spec); - - /* Allocate memory for audio buffers in DMA-able RAM */ - DEBUG_PRINT((DEBUG_NAME "buffer size=%d\n", spec->size)); - - SDL_MintAudio_audiobuf[0] = Atari_SysMalloc(spec->size *2, MX_STRAM); - if (SDL_MintAudio_audiobuf[0]==NULL) { - SDL_SetError("MINT_OpenAudio: Not enough memory for audio buffer"); - return (-1); - } - SDL_MintAudio_audiobuf[1] = SDL_MintAudio_audiobuf[0] + spec->size ; - SDL_MintAudio_numbuf=0; - SDL_memset(SDL_MintAudio_audiobuf[0], spec->silence, spec->size *2); - SDL_MintAudio_audiosize = spec->size; - SDL_MintAudio_mutex = 0; - - DEBUG_PRINT((DEBUG_NAME "buffer 0 at 0x%08x\n", SDL_MintAudio_audiobuf[0])); - DEBUG_PRINT((DEBUG_NAME "buffer 1 at 0x%08x\n", SDL_MintAudio_audiobuf[1])); - - SDL_MintAudio_CheckFpu(); - - /* Setup audio hardware */ - Mint_InitAudio(this, spec); - - return(1); /* We don't use threaded audio */ -} diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.h b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.h deleted file mode 100644 index d4bf2d6..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_stfa.h +++ /dev/null @@ -1,100 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - STFA control structure - - Patrice Mandin -*/ - -#ifndef _SDL_mintaudio_stfa_h -#define _SDL_mintaudio_stfa_h - -/*--- Defines ---*/ - -#define C_STFA 0x53544641L /* Sound treiber für atari (seb/The removers) */ - -#define STFA_PLAY_ENABLE (1<<0) -#define STFA_PLAY_DISABLE (0<<0) -#define STFA_PLAY_REPEAT (1<<1) -#define STFA_PLAY_SINGLE (0<<1) - -#define STFA_FORMAT_SIGNED (1<<15) -#define STFA_FORMAT_UNSIGNED (0<<15) -#define STFA_FORMAT_STEREO (1<<14) -#define STFA_FORMAT_MONO (0<<14) -#define STFA_FORMAT_16BIT (1<<13) -#define STFA_FORMAT_8BIT (0<<13) -#define STFA_FORMAT_LITENDIAN (1<<9) -#define STFA_FORMAT_BIGENDIAN (0<<9) -#define STFA_FORMAT_FREQ_MASK 0x0f -enum { - STFA_FORMAT_F4995=0, - STFA_FORMAT_F6269, - STFA_FORMAT_F7493, - STFA_FORMAT_F8192, - - STFA_FORMAT_F9830, - STFA_FORMAT_F10971, - STFA_FORMAT_F12538, - STFA_FORMAT_F14985, - - STFA_FORMAT_F16384, - STFA_FORMAT_F19819, - STFA_FORMAT_F21943, - STFA_FORMAT_F24576, - - STFA_FORMAT_F30720, - STFA_FORMAT_F32336, - STFA_FORMAT_F43885, - STFA_FORMAT_F49152 -}; - -/*--- Types ---*/ - -typedef struct { - unsigned short sound_enable; - unsigned short sound_control; - unsigned short sound_output; - unsigned long sound_start; - unsigned long sound_current; - unsigned long sound_end; - unsigned short version; - void *old_vbl; - void *old_timera; - unsigned long old_mfp_status; - void *new_vbl; - void *drivers_list; - void *play_stop; - unsigned short frequency; - void *set_frequency; - - unsigned short frequency_threshold; - unsigned short *custom_freq_table; - unsigned short stfa_on_off; - void *new_drivers_list; - unsigned long old_bit_2_of_cookie_snd; - void (*stfa_it)(void); -} cookie_stfa_t __attribute__((packed)); - -#endif /* _SDL_mintaudio_stfa_h */ diff --git a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_xbios.c b/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_xbios.c deleted file mode 100644 index 4a1af3f..0000000 --- a/distrib/sdl-1.2.12/src/audio/mint/SDL_mintaudio_xbios.c +++ /dev/null @@ -1,495 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* - MiNT audio driver - using XBIOS functions (Falcon) - - Patrice Mandin, Didier Méquignon -*/ - -#include -#include - -/* Mint includes */ -#include -#include -#include - -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "../SDL_sysaudio.h" - -#include "../../video/ataricommon/SDL_atarimxalloc_c.h" - -#include "SDL_mintaudio.h" -#include "SDL_mintaudio_dma8.h" - -/*--- Defines ---*/ - -#define MINT_AUDIO_DRIVER_NAME "mint_xbios" - -/* Debug print info */ -#define DEBUG_NAME "audio:xbios: " -#if 0 -#define DEBUG_PRINT(what) \ - { \ - printf what; \ - } -#else -#define DEBUG_PRINT(what) -#endif - -/*--- Static variables ---*/ - -static unsigned long cookie_snd; - -/*--- Audio driver functions ---*/ - -static void Mint_CloseAudio(_THIS); -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_LockAudio(_THIS); -static void Mint_UnlockAudio(_THIS); - -/* To check/init hardware audio */ -static int Mint_CheckAudio(_THIS, SDL_AudioSpec *spec); -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec); - -/*--- Audio driver bootstrap functions ---*/ - -static int Audio_Available(void) -{ - unsigned long dummy; - const char *envr = SDL_getenv("SDL_AUDIODRIVER"); - - /*SDL_MintAudio_mint_present = (Getcookie(C_MiNT, &dummy) == C_FOUND);*/ - SDL_MintAudio_mint_present = SDL_FALSE; - - /* We can't use XBIOS in interrupt with Magic, don't know about thread */ - if (Getcookie(C_MagX, &dummy) == C_FOUND) { - return(0); - } - - /* Check if user asked a different audio driver */ - if ((envr) && (SDL_strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) { - DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n")); - return(0); - } - - /* Cookie _SND present ? if not, assume ST machine */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - cookie_snd = SND_PSG; - } - - /* Check if we have 16 bits audio */ - if ((cookie_snd & SND_16BIT)==0) { - DEBUG_PRINT((DEBUG_NAME "no 16 bits sound\n")); - return(0); - } - - /* Check if audio is lockable */ - if (Locksnd()!=1) { - DEBUG_PRINT((DEBUG_NAME "audio locked by other application\n")); - return(0); - } - - Unlocksnd(); - - DEBUG_PRINT((DEBUG_NAME "XBIOS audio available!\n")); - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = Mint_OpenAudio; - this->CloseAudio = Mint_CloseAudio; - this->LockAudio = Mint_LockAudio; - this->UnlockAudio = Mint_UnlockAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MINTAUDIO_XBIOS_bootstrap = { - MINT_AUDIO_DRIVER_NAME, "MiNT XBIOS audio driver", - Audio_Available, Audio_CreateDevice -}; - -static void Mint_LockAudio(_THIS) -{ - /* Stop replay */ - Buffoper(0); -} - -static void Mint_UnlockAudio(_THIS) -{ - /* Restart replay */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); -} - -static void Mint_CloseAudio(_THIS) -{ - /* Stop replay */ - SDL_MintAudio_WaitThread(); - Buffoper(0); - - if (!SDL_MintAudio_mint_present) { - /* Uninstall interrupt */ - Jdisint(MFP_DMASOUND); - } - - /* Wait if currently playing sound */ - while (SDL_MintAudio_mutex != 0) { - } - - /* Clear buffers */ - if (SDL_MintAudio_audiobuf[0]) { - Mfree(SDL_MintAudio_audiobuf[0]); - SDL_MintAudio_audiobuf[0] = SDL_MintAudio_audiobuf[1] = NULL; - } - - /* Unlock sound system */ - Unlocksnd(); -} - -/* Falcon XBIOS implementation of Devconnect() is buggy with external clock */ -static void Devconnect2(int src, int dst, int sclk, int pre) -{ - static const unsigned short MASK1[3] = { 0, 0x6000, 0 }; - static const unsigned short MASK2[4] = { 0xFFF0, 0xFF8F, 0xF0FF, 0x0FFF }; - static const unsigned short INDEX1[4] = { 1, 3, 5, 7 }; - static const unsigned short INDEX2[4] = { 0, 2, 4, 6 }; - unsigned short sync_div,dev_ctrl,dest_ctrl; - void *oldstack; - - if (dst==0) { - return; - } - - oldstack=(void *)Super(0); - - dev_ctrl = DMAAUDIO_IO.dev_ctrl; - dest_ctrl = DMAAUDIO_IO.dest_ctrl; - dev_ctrl &= MASK2[src]; - - if (src==ADC) { - dev_ctrl |= MASK1[sclk]; - } else { - dev_ctrl |= (INDEX1[sclk] << (src<<4)); - } - - if (dst & DMAREC) { - dest_ctrl &= 0xFFF0; - dest_ctrl |= INDEX1[src]; - } - - if (dst & DSPRECV) { - dest_ctrl &= 0xFF8F; - dest_ctrl |= (INDEX1[src]<<4); - } - - if (dst & EXTOUT) { - dest_ctrl &= 0xF0FF; - dest_ctrl |= (INDEX1[src]<<8); - } - - if (dst & DAC) { - dev_ctrl &= 0x0FFF; - dev_ctrl |= MASK1[sclk]; - dest_ctrl &= 0x0FFF; - dest_ctrl |= (INDEX2[src]<<12); - } - - sync_div = DMAAUDIO_IO.sync_div; - if (sclk==CLKEXT) { - pre<<=8; - sync_div &= 0xF0FF; - } else { - sync_div &= 0xFFF0; - } - sync_div |= pre; - - DMAAUDIO_IO.dev_ctrl = dev_ctrl; - DMAAUDIO_IO.dest_ctrl = dest_ctrl; - DMAAUDIO_IO.sync_div = sync_div; - - Super(oldstack); -} - -static void Mint_CheckExternalClock(_THIS) -{ -#define SIZE_BUF_CLOCK_MEASURE (44100/10) - - unsigned long cookie_snd; - char *buffer; - int i, j; - - /* DSP present with its GPIO port ? */ - if (Getcookie(C__SND, &cookie_snd) == C_NOTFOUND) { - return; - } - if ((cookie_snd & SND_DSP)==0) { - return; - } - - buffer = Atari_SysMalloc(SIZE_BUF_CLOCK_MEASURE, MX_STRAM); - if (buffer==NULL) { - DEBUG_PRINT((DEBUG_NAME "Not enough memory for the measure\n")); - return; - } - SDL_memset(buffer, 0, SIZE_BUF_CLOCK_MEASURE); - - Buffoper(0); - Settracks(0,0); - Setmontracks(0); - Setmode(MONO8); - Jdisint(MFP_TIMERA); - - for (i=0; i<2; i++) { - Gpio(GPIO_SET,7); /* DSP port gpio outputs */ - Gpio(GPIO_WRITE,2+i); /* 22.5792/24.576 MHz for 44.1/48KHz */ - Devconnect2(DMAPLAY, DAC, CLKEXT, CLK50K); /* Matrix and clock source */ - Setbuffer(0, buffer, buffer + SIZE_BUF_CLOCK_MEASURE); /* Set buffer */ - Xbtimer(XB_TIMERA, 5, 38, SDL_MintAudio_XbiosInterruptMeasureClock); /* delay mode timer A, prediv /64, 1KHz */ - Jenabint(MFP_TIMERA); - SDL_MintAudio_clocktics = 0; - Buffoper(SB_PLA_ENA); - usleep(110000); - - if((Buffoper(-1) & 1)==0) { - if (SDL_MintAudio_clocktics) { - unsigned long khz; - - khz = ((SIZE_BUF_CLOCK_MEASURE/SDL_MintAudio_clocktics) +1) & 0xFFFFFFFE; - DEBUG_PRINT((DEBUG_NAME "measure %d: freq=%lu KHz\n", i+1, khz)); - - if(khz==44) { - for (j=1; j<4; j++) { - SDL_MintAudio_AddFrequency(this, MASTERCLOCK_44K/(MASTERPREDIV_FALCON*(1<format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - if (spec->channels > 2) { - spec->channels = 2; /* no more than stereo! */ - } - - spec->format |= 0x8000; /* Audio is always signed */ - if ((spec->format & 0x00ff)==16) { - spec->format |= 0x1000; /* Audio is always big endian */ - spec->channels=2; /* 16 bits always stereo */ - } - - MINTAUDIO_freqcount=0; - - /* Add external clocks if present */ - Mint_CheckExternalClock(this); - - /* Standard clocks */ - for (i=1;i<12;i++) { - /* Remove unusable Falcon codec predivisors */ - if ((i==6) || (i==8) || (i==10)) { - continue; - } - SDL_MintAudio_AddFrequency(this, MASTERCLOCK_FALCON1/(MASTERPREDIV_FALCON*(i+1)), MASTERCLOCK_FALCON1, i, -1); - } - -#if 1 - for (i=0; ifreq); - spec->freq=MINTAUDIO_frequencies[MINTAUDIO_numfreq].frequency; - - DEBUG_PRINT((DEBUG_NAME "obtained: %d bits, ",spec->format & 0x00ff)); - DEBUG_PRINT(("signed=%d, ", ((spec->format & 0x8000)!=0))); - DEBUG_PRINT(("big endian=%d, ", ((spec->format & 0x1000)!=0))); - DEBUG_PRINT(("channels=%d, ", spec->channels)); - DEBUG_PRINT(("freq=%d\n", spec->freq)); - - return 0; -} - -static void Mint_InitAudio(_THIS, SDL_AudioSpec *spec) -{ - int channels_mode, dmaclock, prediv; - void *buffer; - - /* Stop currently playing sound */ - SDL_MintAudio_quit_thread = SDL_FALSE; - SDL_MintAudio_thread_finished = SDL_TRUE; - SDL_MintAudio_WaitThread(); - Buffoper(0); - - /* Set replay tracks */ - Settracks(0,0); - Setmontracks(0); - - /* Select replay format */ - channels_mode=STEREO16; - switch (spec->format & 0xff) { - case 8: - if (spec->channels==2) { - channels_mode=STEREO8; - } else { - channels_mode=MONO8; - } - break; - } - if (Setmode(channels_mode)<0) { - DEBUG_PRINT((DEBUG_NAME "Setmode() failed\n")); - } - - dmaclock = MINTAUDIO_frequencies[MINTAUDIO_numfreq].masterclock; - prediv = MINTAUDIO_frequencies[MINTAUDIO_numfreq].predivisor; - if (MINTAUDIO_frequencies[MINTAUDIO_numfreq].gpio_bits != -1) { - Gpio(GPIO_SET,7); /* DSP port gpio outputs */ - Gpio(GPIO_WRITE, MINTAUDIO_frequencies[MINTAUDIO_numfreq].gpio_bits); - Devconnect2(DMAPLAY, DAC|EXTOUT, CLKEXT, prediv); - } else { - Devconnect2(DMAPLAY, DAC, CLK25M, prediv); - } - - /* Set buffer */ - buffer = SDL_MintAudio_audiobuf[SDL_MintAudio_numbuf]; - if (Setbuffer(0, buffer, buffer + spec->size)<0) { - DEBUG_PRINT((DEBUG_NAME "Setbuffer() failed\n")); - } - - if (SDL_MintAudio_mint_present) { - SDL_MintAudio_thread_pid = tfork(SDL_MintAudio_Thread, 0); - } else { - /* Install interrupt */ - Jdisint(MFP_DMASOUND); - /*Xbtimer(XB_TIMERA, 8, 1, SDL_MintAudio_XbiosInterrupt);*/ - Xbtimer(XB_TIMERA, 8, 1, SDL_MintAudio_Dma8Interrupt); - Jenabint(MFP_DMASOUND); - - if (Setinterrupt(SI_TIMERA, SI_PLAY)<0) { - DEBUG_PRINT((DEBUG_NAME "Setinterrupt() failed\n")); - } - } - - /* Go */ - Buffoper(SB_PLA_ENA|SB_PLA_RPT); - DEBUG_PRINT((DEBUG_NAME "hardware initialized\n")); -} - -static int Mint_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - /* Lock sound system */ - if (Locksnd()!=1) { - SDL_SetError("Mint_OpenAudio: Audio system already in use"); - return(-1); - } - - SDL_MintAudio_device = this; - - /* Check audio capabilities */ - if (Mint_CheckAudio(this, spec)==-1) { - return -1; - } - - SDL_CalculateAudioSpec(spec); - - /* Allocate memory for audio buffers in DMA-able RAM */ - DEBUG_PRINT((DEBUG_NAME "buffer size=%d\n", spec->size)); - - SDL_MintAudio_audiobuf[0] = Atari_SysMalloc(spec->size *2, MX_STRAM); - if (SDL_MintAudio_audiobuf[0]==NULL) { - SDL_SetError("MINT_OpenAudio: Not enough memory for audio buffer"); - return (-1); - } - SDL_MintAudio_audiobuf[1] = SDL_MintAudio_audiobuf[0] + spec->size ; - SDL_MintAudio_numbuf=0; - SDL_memset(SDL_MintAudio_audiobuf[0], spec->silence, spec->size *2); - SDL_MintAudio_audiosize = spec->size; - SDL_MintAudio_mutex = 0; - - DEBUG_PRINT((DEBUG_NAME "buffer 0 at 0x%08x\n", SDL_MintAudio_audiobuf[0])); - DEBUG_PRINT((DEBUG_NAME "buffer 1 at 0x%08x\n", SDL_MintAudio_audiobuf[1])); - - SDL_MintAudio_CheckFpu(); - - /* Setup audio hardware */ - Mint_InitAudio(this, spec); - - return(1); /* We don't use SDL threaded audio */ -} diff --git a/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.c b/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.c deleted file mode 100644 index cb4d2be..0000000 --- a/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.c +++ /dev/null @@ -1,264 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Tru64 UNIX MME support */ -#include - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audio_c.h" -#include "SDL_mmeaudio.h" - -static BOOL inUse[NUM_BUFFERS]; - -/* Audio driver functions */ -static int MME_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void MME_WaitAudio(_THIS); -static Uint8 *MME_GetAudioBuf(_THIS); -static void MME_PlayAudio(_THIS); -static void MME_WaitDone(_THIS); -static void MME_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ -static int Audio_Available(void) -{ - return(1); -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - if ( device ) { - if ( device->hidden ) { - SDL_free(device->hidden); - device->hidden = NULL; - } - SDL_free(device); - device = NULL; - } -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - -/* Initialize all variables that we clean on shutdown */ - this = SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - /* Set the function pointers */ - this->OpenAudio = MME_OpenAudio; - this->WaitAudio = MME_WaitAudio; - this->PlayAudio = MME_PlayAudio; - this->GetAudioBuf = MME_GetAudioBuf; - this->WaitDone = MME_WaitDone; - this->CloseAudio = MME_CloseAudio; - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap MMEAUDIO_bootstrap = { - "waveout", "Tru64 MME WaveOut", - Audio_Available, Audio_CreateDevice -}; - -static void SetMMerror(char *function, MMRESULT code) -{ - int len; - char errbuf[MAXERRORLENGTH]; - - SDL_snprintf(errbuf, SDL_arraysize(errbuf), "%s: ", function); - len = SDL_strlen(errbuf); - waveOutGetErrorText(code, errbuf+len, MAXERRORLENGTH-len); - SDL_SetError("%s",errbuf); -} - -static void CALLBACK MME_CALLBACK(HWAVEOUT hwo, - UINT uMsg, - DWORD dwInstance, - LPARAM dwParam1, - LPARAM dwParam2) -{ - WAVEHDR *wp = (WAVEHDR *) dwParam1; - - if ( uMsg == WOM_DONE ) - inUse[wp->dwUser] = FALSE; -} - -static int MME_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - MMRESULT result; - int i; - - mixbuf = NULL; - - /* Set basic WAVE format parameters */ - shm = mmeAllocMem(sizeof(*shm)); - if ( shm == NULL ) { - SDL_SetError("Out of memory: shm"); - return(-1); - } - shm->sound = 0; - shm->wFmt.wf.wFormatTag = WAVE_FORMAT_PCM; - - /* Determine the audio parameters from the AudioSpec */ - switch ( spec->format & 0xFF ) { - case 8: - /* Unsigned 8 bit audio data */ - spec->format = AUDIO_U8; - shm->wFmt.wBitsPerSample = 8; - break; - case 16: - /* Signed 16 bit audio data */ - spec->format = AUDIO_S16; - shm->wFmt.wBitsPerSample = 16; - break; - default: - SDL_SetError("Unsupported audio format"); - return(-1); - } - - shm->wFmt.wf.nChannels = spec->channels; - shm->wFmt.wf.nSamplesPerSec = spec->freq; - shm->wFmt.wf.nBlockAlign = - shm->wFmt.wf.nChannels * shm->wFmt.wBitsPerSample / 8; - shm->wFmt.wf.nAvgBytesPerSec = - shm->wFmt.wf.nSamplesPerSec * shm->wFmt.wf.nBlockAlign; - - /* Check the buffer size -- minimum of 1/4 second (word aligned) */ - if ( spec->samples < (spec->freq/4) ) - spec->samples = ((spec->freq/4)+3)&~3; - - /* Update the fragment size as size in bytes */ - SDL_CalculateAudioSpec(spec); - - /* Open the audio device */ - result = waveOutOpen(&(shm->sound), - WAVE_MAPPER, - &(shm->wFmt.wf), - MME_CALLBACK, - NULL, - (CALLBACK_FUNCTION|WAVE_OPEN_SHAREABLE)); - if ( result != MMSYSERR_NOERROR ) { - SetMMerror("waveOutOpen()", result); - return(-1); - } - - /* Create the sound buffers */ - mixbuf = (Uint8 *)mmeAllocBuffer(NUM_BUFFERS * (spec->size)); - if ( mixbuf == NULL ) { - SDL_SetError("Out of memory: mixbuf"); - return(-1); - } - - for (i = 0; i < NUM_BUFFERS; i++) { - shm->wHdr[i].lpData = &mixbuf[i * (spec->size)]; - shm->wHdr[i].dwBufferLength = spec->size; - shm->wHdr[i].dwFlags = 0; - shm->wHdr[i].dwUser = i; - shm->wHdr[i].dwLoops = 0; /* loop control counter */ - shm->wHdr[i].lpNext = NULL; /* reserved for driver */ - shm->wHdr[i].reserved = 0; - inUse[i] = FALSE; - } - next_buffer = 0; - return 0; -} - -static void MME_WaitAudio(_THIS) -{ - while ( inUse[next_buffer] ) { - mmeWaitForCallbacks(); - mmeProcessCallbacks(); - } -} - -static Uint8 *MME_GetAudioBuf(_THIS) -{ - Uint8 *retval; - - inUse[next_buffer] = TRUE; - retval = (Uint8 *)(shm->wHdr[next_buffer].lpData); - return retval; -} - -static void MME_PlayAudio(_THIS) -{ - /* Queue it up */ - waveOutWrite(shm->sound, &(shm->wHdr[next_buffer]), sizeof(WAVEHDR)); - next_buffer = (next_buffer+1)%NUM_BUFFERS; -} - -static void MME_WaitDone(_THIS) -{ - MMRESULT result; - int i; - - if ( shm->sound ) { - for (i = 0; i < NUM_BUFFERS; i++) - while ( inUse[i] ) { - mmeWaitForCallbacks(); - mmeProcessCallbacks(); - } - result = waveOutReset(shm->sound); - if ( result != MMSYSERR_NOERROR ) - SetMMerror("waveOutReset()", result); - mmeProcessCallbacks(); - } -} - -static void MME_CloseAudio(_THIS) -{ - MMRESULT result; - - if ( mixbuf ) { - result = mmeFreeBuffer(mixbuf); - if (result != MMSYSERR_NOERROR ) - SetMMerror("mmeFreeBuffer", result); - mixbuf = NULL; - } - - if ( shm ) { - if ( shm->sound ) { - result = waveOutClose(shm->sound); - if (result != MMSYSERR_NOERROR ) - SetMMerror("waveOutClose()", result); - mmeProcessCallbacks(); - } - result = mmeFreeMem(shm); - if (result != MMSYSERR_NOERROR ) - SetMMerror("mmeFreeMem()", result); - shm = NULL; - } -} - diff --git a/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.h b/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.h deleted file mode 100644 index 06d9d83..0000000 --- a/distrib/sdl-1.2.12/src/audio/mme/SDL_mmeaudio.h +++ /dev/null @@ -1,51 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2004 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#ifndef _SDL_lowaudio_h -#define _SDL_lowaudio_h - -#include "../SDL_sysaudio.h" - -/* Hidden "this" pointer for the video functions */ -#define _THIS SDL_AudioDevice *this -#define NUM_BUFFERS 2 - -struct SharedMem { - HWAVEOUT sound; - WAVEHDR wHdr[NUM_BUFFERS]; - PCMWAVEFORMAT wFmt; -}; - -struct SDL_PrivateAudioData { - Uint8 *mixbuf; /* The raw allocated mixing buffer */ - struct SharedMem *shm; - int next_buffer; -}; - -#define shm (this->hidden->shm) -#define mixbuf (this->hidden->mixbuf) -#define next_buffer (this->hidden->next_buffer) -/* Old variable names */ -#endif /* _SDL_lowaudio_h */ diff --git a/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.c b/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.c deleted file mode 100644 index b5d2a3b..0000000 --- a/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.c +++ /dev/null @@ -1,299 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - - This driver was written by: - Erik Inge Bolsø - knan@mo.himolde.no -*/ -#include "SDL_config.h" - -/* Allow access to a raw mixing buffer */ - -#include -#include - -#include "SDL_timer.h" -#include "SDL_audio.h" -#include "../SDL_audiomem.h" -#include "../SDL_audio_c.h" -#include "../SDL_audiodev_c.h" -#include "SDL_nasaudio.h" - -/* The tag name used by artsc audio */ -#define NAS_DRIVER_NAME "nas" - -static struct SDL_PrivateAudioData *this2 = NULL; - -/* Audio driver functions */ -static int NAS_OpenAudio(_THIS, SDL_AudioSpec *spec); -static void NAS_WaitAudio(_THIS); -static void NAS_PlayAudio(_THIS); -static Uint8 *NAS_GetAudioBuf(_THIS); -static void NAS_CloseAudio(_THIS); - -/* Audio driver bootstrap functions */ - -static int Audio_Available(void) -{ - AuServer *aud = AuOpenServer("", 0, NULL, 0, NULL, NULL); - if (!aud) return 0; - - AuCloseServer(aud); - return 1; -} - -static void Audio_DeleteDevice(SDL_AudioDevice *device) -{ - SDL_free(device->hidden); - SDL_free(device); -} - -static SDL_AudioDevice *Audio_CreateDevice(int devindex) -{ - SDL_AudioDevice *this; - - /* Initialize all variables that we clean on shutdown */ - this = (SDL_AudioDevice *)SDL_malloc(sizeof(SDL_AudioDevice)); - if ( this ) { - SDL_memset(this, 0, (sizeof *this)); - this->hidden = (struct SDL_PrivateAudioData *) - SDL_malloc((sizeof *this->hidden)); - } - if ( (this == NULL) || (this->hidden == NULL) ) { - SDL_OutOfMemory(); - if ( this ) { - SDL_free(this); - } - return(0); - } - SDL_memset(this->hidden, 0, (sizeof *this->hidden)); - - /* Set the function pointers */ - this->OpenAudio = NAS_OpenAudio; - this->WaitAudio = NAS_WaitAudio; - this->PlayAudio = NAS_PlayAudio; - this->GetAudioBuf = NAS_GetAudioBuf; - this->CloseAudio = NAS_CloseAudio; - - this->free = Audio_DeleteDevice; - - return this; -} - -AudioBootStrap NAS_bootstrap = { - NAS_DRIVER_NAME, "Network Audio System", - Audio_Available, Audio_CreateDevice -}; - -/* This function waits until it is possible to write a full sound buffer */ -static void NAS_WaitAudio(_THIS) -{ - while ( this->hidden->buf_free < this->hidden->mixlen ) { - AuEvent ev; - AuNextEvent(this->hidden->aud, AuTrue, &ev); - AuDispatchEvent(this->hidden->aud, &ev); - } -} - -static void NAS_PlayAudio(_THIS) -{ - while (this->hidden->mixlen > this->hidden->buf_free) { /* We think the buffer is full? Yikes! Ask the server for events, - in the hope that some of them is LowWater events telling us more - of the buffer is free now than what we think. */ - AuEvent ev; - AuNextEvent(this->hidden->aud, AuTrue, &ev); - AuDispatchEvent(this->hidden->aud, &ev); - } - this->hidden->buf_free -= this->hidden->mixlen; - - /* Write the audio data */ - AuWriteElement(this->hidden->aud, this->hidden->flow, 0, this->hidden->mixlen, this->hidden->mixbuf, AuFalse, NULL); - - this->hidden->written += this->hidden->mixlen; - -#ifdef DEBUG_AUDIO - fprintf(stderr, "Wrote %d bytes of audio data\n", this->hidden->mixlen); -#endif -} - -static Uint8 *NAS_GetAudioBuf(_THIS) -{ - return(this->hidden->mixbuf); -} - -static void NAS_CloseAudio(_THIS) -{ - if ( this->hidden->mixbuf != NULL ) { - SDL_FreeAudioMem(this->hidden->mixbuf); - this->hidden->mixbuf = NULL; - } - if ( this->hidden->aud ) { - AuCloseServer(this->hidden->aud); - this->hidden->aud = 0; - } -} - -static unsigned char sdlformat_to_auformat(unsigned int fmt) -{ - switch (fmt) - { - case AUDIO_U8: - return AuFormatLinearUnsigned8; - case AUDIO_S8: - return AuFormatLinearSigned8; - case AUDIO_U16LSB: - return AuFormatLinearUnsigned16LSB; - case AUDIO_U16MSB: - return AuFormatLinearUnsigned16MSB; - case AUDIO_S16LSB: - return AuFormatLinearSigned16LSB; - case AUDIO_S16MSB: - return AuFormatLinearSigned16MSB; - } - return AuNone; -} - -static AuBool -event_handler(AuServer* aud, AuEvent* ev, AuEventHandlerRec* hnd) -{ - switch (ev->type) { - case AuEventTypeElementNotify: { - AuElementNotifyEvent* event = (AuElementNotifyEvent *)ev; - - switch (event->kind) { - case AuElementNotifyKindLowWater: - if (this2->buf_free >= 0) { - this2->really += event->num_bytes; - gettimeofday(&this2->last_tv, 0); - this2->buf_free += event->num_bytes; - } else { - this2->buf_free = event->num_bytes; - } - break; - case AuElementNotifyKindState: - switch (event->cur_state) { - case AuStatePause: - if (event->reason != AuReasonUser) { - if (this2->buf_free >= 0) { - this2->really += event->num_bytes; - gettimeofday(&this2->last_tv, 0); - this2->buf_free += event->num_bytes; - } else { - this2->buf_free = event->num_bytes; - } - } - break; - } - } - } - } - return AuTrue; -} - -static AuDeviceID -find_device(_THIS, int nch) -{ - int i; - for (i = 0; i < AuServerNumDevices(this->hidden->aud); i++) { - if ((AuDeviceKind(AuServerDevice(this->hidden->aud, i)) == - AuComponentKindPhysicalOutput) && - AuDeviceNumTracks(AuServerDevice(this->hidden->aud, i)) == nch) { - return AuDeviceIdentifier(AuServerDevice(this->hidden->aud, i)); - } - } - return AuNone; -} - -static int NAS_OpenAudio(_THIS, SDL_AudioSpec *spec) -{ - AuElement elms[3]; - int buffer_size; - Uint16 test_format, format; - - this->hidden->mixbuf = NULL; - - /* Try for a closest match on audio format */ - format = 0; - for ( test_format = SDL_FirstAudioFormat(spec->format); - ! format && test_format; ) { - format = sdlformat_to_auformat(test_format); - - if (format == AuNone) { - test_format = SDL_NextAudioFormat(); - } - } - if ( format == 0 ) { - SDL_SetError("Couldn't find any hardware audio formats"); - return(-1); - } - spec->format = test_format; - - this->hidden->aud = AuOpenServer("", 0, NULL, 0, NULL, NULL); - if (this->hidden->aud == 0) - { - SDL_SetError("Couldn't open connection to NAS server"); - return (-1); - } - - this->hidden->dev = find_device(this, spec->channels); - if ((this->hidden->dev == AuNone) || (!(this->hidden->flow = AuCreateFlow(this->hidden->aud, NULL)))) { - AuCloseServer(this->hidden->aud); - this->hidden->aud = 0; - SDL_SetError("Couldn't find a fitting playback device on NAS server"); - return (-1); - } - - buffer_size = spec->freq; - if (buffer_size < 4096) - buffer_size = 4096; - - if (buffer_size > 32768) - buffer_size = 32768; /* So that the buffer won't get unmanageably big. */ - - /* Calculate the final parameters for this audio specification */ - SDL_CalculateAudioSpec(spec); - - this2 = this->hidden; - - AuMakeElementImportClient(elms, spec->freq, format, spec->channels, AuTrue, - buffer_size, buffer_size / 4, 0, NULL); - AuMakeElementExportDevice(elms+1, 0, this->hidden->dev, spec->freq, - AuUnlimitedSamples, 0, NULL); - AuSetElements(this->hidden->aud, this->hidden->flow, AuTrue, 2, elms, NULL); - AuRegisterEventHandler(this->hidden->aud, AuEventHandlerIDMask, 0, this->hidden->flow, - event_handler, (AuPointer) NULL); - - AuStartFlow(this->hidden->aud, this->hidden->flow, NULL); - - /* Allocate mixing buffer */ - this->hidden->mixlen = spec->size; - this->hidden->mixbuf = (Uint8 *)SDL_AllocAudioMem(this->hidden->mixlen); - if ( this->hidden->mixbuf == NULL ) { - return(-1); - } - SDL_memset(this->hidden->mixbuf, spec->silence, spec->size); - - /* Get the parent process id (we're the parent of the audio thread) */ - this->hidden->parent = getpid(); - - /* We're ready to rock and roll. :-) */ - return(0); -} diff --git a/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.h b/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.h deleted file mode 100644 index 390d669..0000000 --- a/distrib/sdl-1.2.12/src/audio/nas/SDL_nasaudio.h +++ /dev/null @@ -1,62 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2006 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org - - This driver was written by: - Erik Inge Bolsø - knan@mo.himolde.no -*/ -#include "SDL_config.h" - -#ifndef _SDL_nasaudio_h -#define _SDL_nasaudio_h - -#ifdef __sgi -#include -#else -#include