audiobase.h

Go to the documentation of this file.
00001 
00024 #ifndef AUDIOBASE_H_INCLUDED_C41996D8
00025 #define AUDIOBASE_H_INCLUDED_C41996D8
00026 
00027 #include "openalpp/export.h"
00028 #include <cstdlib>
00029 extern "C" {
00030 #include <AL/al.h>
00031 #include <AL/alut.h>
00032 #include <AL/alc.h>
00033 }
00034 #include "openalpp/windowsstuff.h"
00035 #include "openalpp/error.h"
00036 #include "openalpp/referenced.h"
00037 #include "openalpp/ref_ptr.h"
00056 namespace openalpp {
00057 
00061 typedef enum SampleFormat {Mono8,Stereo8,Mono16,Stereo16};
00062 
00067 class OPENALPP_API AudioBase : public Referenced{
00072   static int instances_;
00073 
00077   static ALCdevice *device_;
00078 
00082 #ifndef WIN32
00083 #if OPENAL_VERSION < 2007
00084   static void *context_;
00085 #else // OPENAL_VERSION < 2007
00086   static ALCcontext *context_;
00087 #endif // OPENAL_VERSION < 2007
00088 #else
00089   static struct ALCcontext_struct *context_;
00090 #endif
00091  protected:
00099    AudioBase(int frequency=-1,int refresh=-1,int synchronous=-1)
00100     throw (InitError);
00101 
00105   virtual  ~AudioBase();
00106 
00111   static bool reverbinitiated_;
00112 
00119   static void (*alReverbScale)(ALuint sid, ALfloat param);
00120 
00127   static void (*alReverbDelay)(ALuint sid, ALfloat param);
00128 };
00129 
00130 }
00131 
00132 #endif /* AUDIOBASE_H_INCLUDED_C41996D8 */

Generated on Sat Dec 30 13:31:01 2006 for openalpp by  doxygen 1.5.1