Krig Game Engine
Loading...
Searching...
No Matches
SoundFX.h
Go to the documentation of this file.
1
7#ifndef _SOUNDFX_H_
8#define _SOUNDFX_H_
9
10#include <AL/al.h>
11#include <vorbis/vorbisfile.h>
12#include <string>
13#include <map>
14#include <dirent.h>
15#include "constants.h"
16
17#define BUFFER_SIZE 65536
18
19class SoundFX {
20 public:
21 SoundFX();
22 ~SoundFX();
23
24 void PlaySFX(const std::string&);
25 void SetSFX(
26 const std::string&,
27 const ALfloat&, const ALfloat&, const ALfloat&,
28 const ALfloat&, const ALfloat&, const ALfloat&,
29 const ALboolean&
30 );
31
32 void SetSFXListener(
33 const ALfloat&, const ALfloat&, const ALfloat&,
34 const ALfloat&, const ALfloat&, const ALfloat&
35 );
36
37 void load();
38 void unload();
39
40 private:
41 ALuint *Sources; // Data for loading in the sound effects
42 ALuint *Buffers;
43
44 int Num_of_SFX;
45 std::map <std::string, int> File_Hash;
46};
47
48#endif
GameObject load()