Changeset 4883 in orxonox.OLD for orxonox/branches/weaponSystem/src/lib/sound/sound_engine.h
- Timestamp:
- Jul 17, 2005, 4:02:36 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/weaponSystem/src/lib/sound/sound_engine.h
r4878 r4883 27 27 28 28 /** @returns the ID of the buffer used in this SoundBuffer */ 29 inline ALuint getID() { return this->bufferID; }29 inline ALuint getID() const { return this->bufferID; } 30 30 31 31 private: … … 37 37 38 38 //! A class that represents a SoundSource 39 /**40 * @todo ability to play back different SoundBuffers on the same SounSource41 */42 39 class SoundSource : public BaseObject 43 40 { 44 41 public: 45 SoundSource( SoundBuffer* buffer, PNode* sourceNode= NULL);42 SoundSource(const PNode* sourceNode = NULL, const SoundBuffer* buffer = NULL); 46 43 ~SoundSource(); 47 44 48 45 // user interaction 49 46 void play(); 47 void play(const SoundBuffer* buffer); 50 48 void stop(); 51 49 void pause(); … … 56 54 inline ALuint getID() const { return this->sourceID; } 57 55 /** @returns the SoundBuffer of this Source */ 58 inline SoundBuffer* getBuffer() const { return this->buffer; }56 inline const SoundBuffer* getBuffer() const { return this->buffer; } 59 57 /** @returns the SourceNode of this Source */ 60 inline PNode* getNode() const { return this->sourceNode;}58 inline const PNode* getNode() const { return this->sourceNode;} 61 59 62 60 void setRolloffFactor(ALfloat rolloffFactor); 63 61 64 62 private: 65 ALuint sourceID; //!< The ID of the Source66 SoundBuffer* buffer; //!< The buffer to play in this source.67 PNode* sourceNode; //!< The SourceNode represente the position/velocity... of this source.63 ALuint sourceID; //!< The ID of the Source 64 const SoundBuffer* buffer; //!< The buffer to play in this source. 65 const PNode* sourceNode; //!< The SourceNode represente the position/velocity... of this source. 68 66 }; 69 67
Note: See TracChangeset
for help on using the changeset viewer.