1 // AudioInput.h: Audio input base class
3 // Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
5 // This program is free software; you can redistribute it and/or modify
6 // it under the terms of the GNU General Public License as published by
7 // the Free Software Foundation; either version 3 of the License, or
8 // (at your option) any later version.
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software
17 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 #ifndef GNASH_AUDIOINPUT_H
20 #define GNASH_AUDIOINPUT_H
22 #include <boost/cstdint.hpp> // for C99 int types
24 #include "dsodefs.h" //DSOEXPORT
29 /// A class representing a single AudioInput device.
31 /// This interface has almost everything needed for control of the input
32 /// device, but currently no data-fetching functions. These should be
33 /// implemented only when the requirements of AS have been investigated!
39 DSOEXPORT
AudioInput() {}
41 virtual ~AudioInput() {}
43 virtual void setActivityLevel(double a
) = 0;
45 virtual double activityLevel() const = 0;
47 virtual void setGain(double g
) = 0;
49 virtual double gain() const = 0;
51 virtual void setIndex(int i
) = 0;
53 virtual int index() const = 0;
55 virtual bool muted() = 0;
57 virtual void setName(std::string name
) = 0;
59 virtual const std::string
& name() const = 0;
61 virtual void setRate(int r
) = 0;
63 virtual int rate() const = 0;
65 virtual void setSilenceLevel(double s
) = 0;
67 virtual double silenceLevel() const = 0;
69 virtual void setSilenceTimeout(int s
) = 0;
71 virtual int silenceTimeout() const = 0;
73 virtual void setUseEchoSuppression(bool e
) = 0;
75 virtual bool useEchoSuppression() const = 0;
80 } // gnash.media namespace