Changeset 7297 in orxonox.OLD for trunk/src/lib/sound
- Timestamp:
- Apr 15, 2006, 9:48:08 PM (19 years ago)
- Location:
- trunk/src/lib/sound
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/sound/ogg_player.cc
r7296 r7297 140 140 } 141 141 empty(); 142 SoundEngine::getInstance()->pushALSource(source); 142 alSourcei(this->source, AL_BUFFER, 0); 143 SoundEngine::getInstance()->pushALSource(this->source); 143 144 this->source = 0; 144 145 this->state &= !SourceAllocated; -
trunk/src/lib/sound/sound_source.cc
r7291 r7297 25 25 26 26 /** 27 * creates a SoundSource at position sourceNode with the SoundBuffer buffer27 * @brief creates a SoundSource at position sourceNode with the SoundBuffer buffer 28 28 */ 29 29 SoundSource::SoundSource(const PNode* sourceNode, const SoundBuffer* buffer) … … 42 42 43 43 /** 44 * deletes a SoundSource44 * @brief deletes a SoundSource 45 45 */ 46 46 SoundSource::~SoundSource() … … 50 50 51 51 /** 52 * Plays back a SoundSource52 * @brief Plays back a SoundSource 53 53 */ 54 54 void SoundSource::play() … … 92 92 93 93 /** 94 * Stops playback of a SoundSource94 * @brief Stops playback of a SoundSource 95 95 */ 96 96 void SoundSource::stop() … … 102 102 if (DEBUG >= 3) 103 103 SoundEngine::checkError("StopSource", __LINE__); 104 alSourcei(this->sourceID, AL_BUFFER, 0); 104 105 SoundEngine::getInstance()->pushALSource(this->sourceID); 105 106 this->sourceID = 0; … … 108 109 109 110 /** 110 * Pauses Playback of a SoundSource111 * @brief Pauses Playback of a SoundSource 111 112 */ 112 113 void SoundSource::pause() … … 118 119 119 120 /** 120 * Rewinds Playback of a SoundSource121 * @brief Rewinds Playback of a SoundSource 121 122 */ 122 123 void SoundSource::rewind() … … 129 130 130 131 /** 131 * sets the RolloffFactor of the Sound emitted from the SoundSource132 * @brief sets the RolloffFactor of the Sound emitted from the SoundSource 132 133 * @param rolloffFactor The Factor described 133 134 134 * 135 * this tells openAL how fast the Sounds decay outward from the Source 135 136 */ 136 137 void SoundSource::setRolloffFactor(ALfloat rolloffFactor)
Note: See TracChangeset
for help on using the changeset viewer.