OpenClonk
C4SoundIncludes.h
Go to the documentation of this file.
1 /*
2  * OpenClonk, http://www.openclonk.org
3  *
4  * Copyright (c) 2014-2016, The OpenClonk Team and contributors
5  *
6  * Distributed under the terms of the ISC license; see accompanying file
7  * "COPYING" for details.
8  *
9  * "Clonk" is a registered trademark of Matthes Bender, used with permission.
10  * See accompanying file "TRADEMARK" for details.
11  *
12  * To redistribute this file separately, substitute the full license texts
13  * for the above references.
14  */
15 
16 // Put all the terrible walls of includes for sound toolkits here
17 
18 #ifndef INC_C4SoundIncludes
19 #define INC_C4SoundIncludes
20 
21 #if AUDIO_TK == AUDIO_TK_SDL_MIXER
22 # define USE_RWOPS
23 # include <SDL_mixer.h>
24 # undef USE_RWOPS
25  typedef struct Mix_Chunk* C4SoundHandle;
26 # include <SDL.h>
27 #elif AUDIO_TK == AUDIO_TK_OPENAL
28 # include <al.h>
29 # include <alc.h>
30 # ifdef HAVE_ALEXT
31 # include <alext.h>
32 # endif
33  typedef ALuint C4SoundHandle;
34 # ifdef _WIN32
35  // This is an ugly hack to make FreeALUT not dllimport everything.
36 # define _XBOX
37 # endif
38 # include <AL/alut.h>
39 # undef _XBOX
40 # if defined(__APPLE__)
41 # import <CoreFoundation/CoreFoundation.h>
42 # import <AudioToolbox/AudioToolbox.h>
43 # endif
44 # include <vorbis/codec.h>
45 # include <vorbis/vorbisfile.h>
46 # include <ogg/os_types.h>
47 #else
48  typedef void* C4SoundHandle;
49 #endif
50 
51 #endif
struct Mix_Chunk * C4SoundHandle