|
|
// ########################################################################## // #### #### // #### RTP Audio Server Project #### // #### ============================ #### // #### #### // #### Audio Mixer #### // #### #### // #### Version 1.00 -- February 23, 2001 #### // #### #### // #### Copyright (C) 1999 Thomas Dreibholz #### // #### 2000 Universität Bonn, Abt. IV #### // #### 2001 EMail: Dreibholz@bigfoot.com #### // #### WWW: http://www.bigfoot.com/~dreibholz #### // #### #### // ########################################################################## #ifndef AUDIOMIXER_H #define AUDIOMIXER_H #include "system.h" #include <sys/soundcard.h> namespace Coral { /** * This class is an interface to an audio mixer. * * @short Audio Mixer * @author Thomas Dreibholz (Dreibholz@bigfoot.com) * @version 1.0 */ class AudioMixer { // ====== Constructor/Destructor ========================================= public: /** * Constructor. * * @param mixerChannel Mixer channel (e.g. SOUND_MIXER_PCM). * @param name Mixer device name (e.g. "/dev/mixer"). */ AudioMixer(int mixerChannel = SOUND_MIXER_PCM, const char* name = "/dev/mixer"); /** * Destructor. */ ~AudioMixer(); // ====== Mixer functions ================================================ /** * Check, if mixer is ready. * * @return true, if mixer is ready; false otherwise. */ inline bool ready() const; /** * Get volume. * * @param left Volume of left channel. * @param right Volume of right channel. * @return true, if volume has been written into variables; false otherwise. */ bool getVolume(card8& left, card8& right); /** * Set volume. * * @param left Volume of left channel. * @param right Volume of right channel. * @return true, if volume has been set; false otherwise. */ bool setVolume(const card8 left, const card8 right); // ====== Private data =================================================== private: int Device; int Channel; }; } #include "audiomixer.icc" #endif
Generated by: viper@odin on Fri Feb 23 12:41:26 2001, using kdoc 2.0a36. |