1 // ****************************************************************************
5 // Include file for EchoGals generic driver line level state machine.
7 // Class for setting and getting mixer values for input and output busses.
9 // Implemented as a base class with 3 derived classes, one for
12 // ----------------------------------------------------------------------------
14 // ----------------------------------------------------------------------------
16 // This file is part of Echo Digital Audio's generic driver library.
17 // Copyright Echo Digital Audio Corporation (c) 1998 - 2005
18 // All rights reserved
21 // This library is free software; you can redistribute it and/or
22 // modify it under the terms of the GNU Lesser General Public
23 // License as published by the Free Software Foundation; either
24 // version 2.1 of the License, or (at your option) any later version.
26 // This library is distributed in the hope that it will be useful,
27 // but WITHOUT ANY WARRANTY; without even the implied warranty of
28 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
29 // Lesser General Public License for more details.
31 // You should have received a copy of the GNU Lesser General Public
32 // License along with this library; if not, write to the Free Software
33 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
35 // ****************************************************************************
44 /****************************************************************************
46 CLineLevel - Base class
48 ****************************************************************************/
54 INT32 m_iGain
; // Current gain in dB X 256
56 CEchoGals
* m_pEchoGals
; // Ptr to our creator object
57 WORD m_wChannelIndex
; // pipe index for this line
62 // Construction/destruction
65 virtual ~CLineLevel();
68 // Initialization function for initializing arrays of this class
72 WORD wChannelIndex
, // Which channel we represent
73 CEchoGals
* pEchoGals
, // For setting line levels
74 INT32 iGain
= 0 // Initial gain setting
80 virtual ECHOSTATUS
SetMute( BOOL bOn
);
81 BOOL
IsMuteOn() { return m_fMuted
; }
87 INT32
GetGain() { return( m_iGain
); }
88 virtual ECHOSTATUS
SetGain(
90 BOOL fImmediate
= TRUE
93 }; // class CLineLevel
95 typedef CLineLevel
* PCLineLevel
;
99 /****************************************************************************
101 CBusInLineLevel - Derived class for managing input bus gains
103 ****************************************************************************/
105 class CBusInLineLevel
: public CLineLevel
112 // Construction/destruction
115 virtual ~CBusInLineLevel();
120 virtual ECHOSTATUS
SetMute( BOOL bOn
);
125 virtual ECHOSTATUS SetGain
128 BOOL fImmediate
= TRUE
132 }; // class CBusInLineLevel
134 typedef CBusInLineLevel
* PCBusInLineLevel
;
139 /****************************************************************************
141 CBusOutLineLevel - Derived class for managing output bus gains
143 ****************************************************************************/
145 class CBusOutLineLevel
: public CLineLevel
152 // Construction/destruction
155 virtual ~CBusOutLineLevel();
160 virtual ECHOSTATUS
SetMute( BOOL bOn
);
165 virtual ECHOSTATUS SetGain
168 BOOL fImmediate
= TRUE
172 }; // class CBusOutLineLevel
174 typedef CBusOutLineLevel
* PCBusOutLineLevel
;
178 // **** CLineLevel.h ****