Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4206 in orxonox.OLD for orxonox/branches/openAL/src


Ignore:
Timestamp:
May 17, 2005, 2:30:10 AM (20 years ago)
Author:
bensch
Message:

orxonox/branches/openAL: doxygen-Tags

Location:
orxonox/branches/openAL/src/lib/sound
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • orxonox/branches/openAL/src/lib/sound/sound_engine.cc

    r4205 r4206  
    2121#include "sound_engine.h"
    2222
     23//#include <AL/alc.h> // maybe later
     24
    2325#include "p_node.h"
    2426#include "list.h"
    25 #include "AL/alc.h"
    2627#include "resource_manager.h"
    2728using namespace std;
     
    104105
    105106
     107/**
     108   \brief Plays back a SoundSource
     109*/
    106110void SoundSource::play()
    107111{
    108112  alSourcePlay(this->sourceID);
    109113}
     114
     115/**
     116   \brief Stops playback of a SoundSource
     117*/
    110118void SoundSource::stop()
    111119{
    112120  alSourceStop(this->sourceID);
    113121}
     122
     123/**
     124   \brief Pauses Playback of a SoundSource
     125*/
    114126void SoundSource::pause()
    115127{
     
    117129}
    118130
     131/**
     132   \brief Rewinds Playback of a SoundSource
     133*/
     134void SoundSource::rewind()
     135{
     136  alSourceRewind(this->sourceID);
     137}
     138
     139/**
     140   \brief sets the RolloffFactor of the Sound emitted from the SoundSource
     141   \param rolloffFactor The Factor described
     142
     143   this tells openAL how fast the Sounds decay outward from the Source
     144*/
    119145void SoundSource::setRolloffFactor(ALfloat rolloffFactor)
    120146{
     
    187213   \brief creates a new SoundSource.
    188214   \param fileName The Name to load the SoundBuffer from
    189    \param The sourceNode to bind this SoundSource to.
     215   \param sourceNode The sourceNode to bind this SoundSource to.
    190216   \returns The newly created SoundSource
    191217
     
    206232}
    207233
    208 
     234/**
     235   \brief adds a SoundBuffer to the bufferList of the SoundEngine
     236   \param buffer The buffer to add to the bufferList
     237*/
    209238void SoundEngine::addBuffer(SoundBuffer* buffer)
    210239{
     
    212241}
    213242
     243/**
     244   \brief removes a SoundBuffer from the bufferList of the SoundEngine
     245   \param buffer The buffer to delete from the SoundEngine
     246*/
    214247void SoundEngine::removeBuffer(SoundBuffer* buffer)
    215248{
     
    217250}
    218251
     252/**
     253   \brief adds a SoundSource to the sourceList of the SoundEngine
     254   \param source The source to add to the sourceList
     255*/
    219256void SoundEngine::addSource(SoundSource* source)
    220257{
    221258  this->sourceList->add(source);
    222259}
     260
     261/**
     262   \brief removes a SoundSource from the sourceList of the SoundEngine
     263   \param source The source to delete from the SoundEngine
     264*/
    223265void SoundEngine::removeSource(SoundSource* source)
    224266{
     
    284326}
    285327
     328/**
     329   \brief Transforms AL-errors into something readable
     330   \param err The error found
     331*/
    286332void SoundEngine::PrintALErrorString(ALenum err)
    287333{
     
    314360}
    315361
    316 
     362/*
    317363void SoundEngine::PrintALCErrorString(ALenum err)
    318364{
     
    344390    };
    345391}
     392*/
  • orxonox/branches/openAL/src/lib/sound/sound_engine.h

    r4205 r4206  
    1212
    1313
    14 #define SOUND_DOPPLER_FACTOR     0.01
    15 #define SOUND_DOPPLER_VELOCITY   500000000
     14#define SOUND_DOPPLER_FACTOR     0.01          //!< A factor for the audible doppler effect
     15#define SOUND_DOPPLER_VELOCITY   500000000     //!< A factor for the TravelSpeed of sound
    1616
    1717// FORWARD DEFINITION
     
    2727  ~SoundBuffer(void);
    2828
     29  /** \returns the ID of the buffer */
    2930  inline ALuint getID(void) { return this->bufferID; }
    3031
     
    4748  void stop();
    4849  void pause();
     50  void rewind();
    4951
    5052  // development functions
    51   /** \retruns The ID of the Source */
     53  /** \returns The ID of the Source */
    5254  inline ALuint getID(void) { return this->sourceID; }
    5355  /** \returns the SourceNode of this Source */
     
    8688  // error handling:
    8789  static void PrintALErrorString(ALenum err);
    88   static void PrintALCErrorString(ALenum err);
     90  //  static void PrintALCErrorString(ALenum err);
    8991
    9092 private:
Note: See TracChangeset for help on using the changeset viewer.