Changeset 2899 for code/branches
- Timestamp:
- Apr 6, 2009, 3:08:09 PM (16 years ago)
- Location:
- code/branches/sound/src/sound
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/sound/src/sound/SoundBase.h
r2866 r2899 28 28 29 29 #include <al.h> 30 #include <string> 30 31 31 32 class Ogre::SceneNode; … … 34 35 namespace orxonox 35 36 { 36 37 /** 38 * The SoudBase class is the base class for all sound file loader classes. 39 * It server as main interface to the OpenAL library. 40 * 41 */ 37 42 class SoundBase 38 43 { … … 49 54 bool isPlaying(); 50 55 56 virtual void loadFile(std::string filename) = 0; 57 51 58 private: 52 59 ALuint source_; -
code/branches/sound/src/sound/SoundManager.h
r2866 r2899 29 29 #include <alc.h> 30 30 31 #include <Tickable.h> 32 31 33 class SoundBase; 32 34 33 35 namespace Orxonox 34 36 { 37 /** 38 * The SoundManager class manages the OpenAL device, context and listener 39 * position. It has a list of all SoundBase objects and calls their update 40 * function every tick. It is a singleton. 41 * 42 */ 35 43 class SoundManager : public Tickable 36 44 { 37 45 public: 38 SoundManager();46 static SoundManager* instance(); 39 47 40 48 void addSound(SoundBase* sound); 41 49 void removeSound(SoundBase* sound); 42 50 43 51 void tick(float dt); 44 52 45 53 private: 54 SoundManager(); // private constructor -> singleton 55 static SoundManager* singleton_; 56 46 57 ALCcontext* context_; 47 58 ALCdevice* device_;
Note: See TracChangeset
for help on using the changeset viewer.