2 * SiS 7018, Trident 4D Wave DX/NX, Acer Lab M5451 Sound Driver.
3 * Copyright (c) 2002, 2008-2011 S.Zharski <imker@gmx.li>
4 * Distributed under the terms of the MIT license.
7 #ifndef _SiS7018_MIXER_H_
8 #define _SiS7018_MIXER_H_
14 #include "hmulti_audio.h"
19 struct MIXControlInfo
;
29 status_t
GetMix(multi_mix_value_info
*Info
);
30 status_t
SetMix(multi_mix_value_info
*Info
);
31 status_t
ListMixControls(multi_mix_control_info
* Info
);
33 uint32
InputRates() { return fInputRates
; }
34 uint32
OutputRates() { return fOutputRates
; }
35 uint32
InputFormats() { return fInputFormats
; }
36 uint32
OutputFormats() { return fOutputFormats
; }
38 void SetOutputRate(uint32 rate
);
41 void _ReadSupportedFormats();
42 bool _WaitPortReady(uint8 reg
, uint32 mask
, uint32
* result
= NULL
);
43 bool _WaitSTimerReady();
44 uint16
_ReadAC97(uint8 reg
);
45 void _WriteAC97(uint8 reg
, uint16 date
);
46 static uint16
_ReadAC97(void* cookie
, uint8 reg
);
47 static void _WriteAC97(void* cookie
, uint8 reg
, uint16 data
);
48 bool _CheckRegFeatures(uint8 AC97Reg
, uint16
& mask
, uint16
& result
);
49 bool _CorrectMIXControlInfo(MIXControlInfo
& info
, GainInfo
& gainInfo
);
50 void _InitGainLimits(multi_mix_control
& Control
, GainInfo
& Info
);
51 int32
_CreateMIXControlGroup(multi_mix_control_info
* MultiInfo
,
52 int32
& index
, int32 parentIndex
, MIXControlInfo
& Info
);
66 uint32 fOutputFormats
;
70 #endif // _SiS7018_MIXER_H_