TDME2  1.9.200
AudioBufferManager.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <string>
4 #include <unordered_map>
5 
6 #include <tdme/tdme.h>
7 #include <tdme/audio/fwd-tdme.h>
8 
9 using std::string;
10 using std::unordered_map;
11 
13 
14 /**
15  * Audio buffer manager
16  * @author Andreas Drewke
17  */
19 {
21  friend class Audio;
22  friend class Sound;
23 
24 private:
25  unordered_map<string, AudioBufferManager_AudioBufferManaged*> audioBuffers;
26 
27  // forbid class copy
29 
30  /**
31  * Private constructor
32  */
33  inline AudioBufferManager() {}
34 
35  /**
36  * Adds a audio buffer to manager / open al stack
37  * @param id id
38  * @return audio buffer managed
39  */
41 
42  /**
43  * Removes a texture from manager / open gl stack
44  * @param id id
45  * @return true if caller has to remove the audio buffer from open AL
46  */
47  bool removeAudioBuffer(const string& id);
48 
49 };
bool removeAudioBuffer(const string &id)
Removes a texture from manager / open gl stack.
unordered_map< string, AudioBufferManager_AudioBufferManaged * > audioBuffers
AudioBufferManager_AudioBufferManaged * addAudioBuffer(const string &id)
Adds a audio buffer to manager / open al stack.
Interface to audio module.
Definition: Audio.h:29
Sound audio entity implementation.
Definition: Sound.h:19
#define FORBID_CLASS_COPY(CLASS)
Definition: tdme.h:6