Changeset 3196 for code/trunk/src/orxonox/sound/SoundBase.cc
- Timestamp:
- Jun 20, 2009, 9:20:47 AM (15 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/pch (added) merged: 3114-3118,3124-3125,3127-3131,3133,3138-3194
- Property svn:mergeinfo changed
-
code/trunk/src/orxonox/sound/SoundBase.cc
r3108 r3196 26 26 * 27 27 */ 28 29 #include "SoundBase.h" 30 31 #include <string> 28 32 #include <vector> 29 33 #include <AL/alut.h> 30 34 #include <vorbis/vorbisfile.h> 31 35 36 #include "util/Math.h" 37 #include "core/Core.h" 32 38 #include "orxonox/objects/worldentities/WorldEntity.h" 33 #include "util/Math.h"34 #include "SoundBase.h"35 39 #include "SoundManager.h" 36 #include "core/Core.h"37 40 38 41 namespace orxonox 39 42 { 40 SoundManager* SoundBase::soundmanager_s = NULL;41 42 43 SoundBase::SoundBase(WorldEntity* entity) 43 44 { 44 if(SoundBase::soundmanager_s == NULL)45 {46 SoundBase::soundmanager_s = new SoundManager();47 }48 49 45 this->source_ = 0; 50 46 this->buffer_ = 0; 51 47 this->entity_ = entity; 52 48 53 Sound Base::soundmanager_s->addSound(this);49 SoundManager::getInstance().addSound(this); 54 50 } 55 51 … … 141 137 filename = Core::getMediaPathString() + "/audio/" + filename; 142 138 143 if(!Sound Base::soundmanager_s->isSoundAvailable())139 if(!SoundManager::getInstance().isSoundAvailable()) 144 140 { 145 141 COUT(3) << "Sound: not available, skipping " << filename << std::endl; … … 179 175 } 180 176 181 ALuint SoundBase::loadOggFile( std::stringfilename)177 ALuint SoundBase::loadOggFile(const std::string& filename) 182 178 { 183 179 char inbuffer[4096];
Note: See TracChangeset
for help on using the changeset viewer.