|
1 /* |
|
2 * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Audio Stubs - |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "AudioEqualizerProxy.h" |
|
20 #include "BassBoostProxy.h" |
|
21 #include "DistanceAttenuationProxy.h" |
|
22 #include "EnvironmentalReverbProxy.h" |
|
23 #include "ListenerDopplerProxy.h" |
|
24 #include "ListenerLocationProxy.h" |
|
25 #include "ListenerOrientationProxy.h" |
|
26 #include "LoudnessProxy.h" |
|
27 #include "RoomLevelProxy.h" |
|
28 #include "SourceDopplerProxy.h" |
|
29 #include "SourceLocationProxy.h" |
|
30 #include "SourceOrientationProxy.h" |
|
31 #include "StereoWideningProxy.h" |
|
32 #include "AddedDevSoundControlCI.h" |
|
33 #include "AddedDevSoundControlProxy.h" |
|
34 #include "RestrictedAudioOutputProxy.h" |
|
35 #include "AudioInputProxy.h" |
|
36 #include "AudioOutputProxy.h" |
|
37 #include "AudioInputMessageTypes.h" |
|
38 #include "AudioOutputMessageTypes.h" |
|
39 #include "G711DecoderIntfcProxy.h" |
|
40 #include "G729DecoderIntfcProxy.h" |
|
41 #include "IlbcDecoderIntfcProxy.h" |
|
42 #include "G711EncoderIntfcProxy.h" |
|
43 #include "G729EncoderIntfcProxy.h" |
|
44 #include "IlbcEncoderIntfcProxy.h" |
|
45 #include "SpeechEncoderConfigProxy.h" |
|
46 #include "ErrorConcealmentIntfcProxy.h" |
|
47 #include "CustomInterfaceProxyFactory.h" |
|
48 |
|
49 |
|
50 EXPORT_C TAny* CCustomInterfaceProxyFactory::CreateProxy(TUid aInterfaceUid, |
|
51 TMMFMessageDestinationPckg aHandlePckg, |
|
52 MCustomCommand& aCustomCommand, |
|
53 CCustomInterfaceUtility* aCustomInterfaceUtility) |
|
54 { |
|
55 TAny* customInterface = NULL; |
|
56 |
|
57 if (aInterfaceUid == KUidAudioInput) |
|
58 { |
|
59 CAudioInputProxy* inputProxy = CAudioInputProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
60 customInterface = inputProxy; |
|
61 } |
|
62 else if(aInterfaceUid == KUidAudioOutput) |
|
63 { |
|
64 CAudioOutputProxy* outputProxy = CAudioOutputProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
65 customInterface = outputProxy; |
|
66 } |
|
67 else if (aInterfaceUid == KUidAudioEqualizerEffect) |
|
68 { |
|
69 CAudioEqualizerProxy* audioEqualizerProxy = CAudioEqualizerProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
70 customInterface = audioEqualizerProxy; |
|
71 } |
|
72 else if (aInterfaceUid == KUidBassBoostEffect) |
|
73 { |
|
74 CBassBoostProxy* bassBoostProxy = CBassBoostProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
75 customInterface = bassBoostProxy; |
|
76 } |
|
77 else if (aInterfaceUid == KUidDistanceAttenuationEffect) |
|
78 { |
|
79 CDistanceAttenuationProxy* distanceAttenuationProxy = CDistanceAttenuationProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
80 customInterface = distanceAttenuationProxy; |
|
81 } |
|
82 else if (aInterfaceUid == KUidEnvironmentalReverbEffect) |
|
83 { |
|
84 CEnvironmentalReverbProxy* environmentalReverbProxy = CEnvironmentalReverbProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
85 customInterface = environmentalReverbProxy; |
|
86 } |
|
87 else if (aInterfaceUid == KUidListenerDopplerEffect) |
|
88 { |
|
89 CListenerDopplerProxy* listenerDopplerProxy = CListenerDopplerProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
90 customInterface = listenerDopplerProxy; |
|
91 } |
|
92 else if (aInterfaceUid == KUidListenerLocationEffect) |
|
93 { |
|
94 CListenerLocationProxy* listenerLocationProxy = CListenerLocationProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
95 customInterface = listenerLocationProxy; |
|
96 } |
|
97 else if (aInterfaceUid == KUidListenerOrientationEffect) |
|
98 { |
|
99 CListenerOrientationProxy* listenerOrientationProxy = CListenerOrientationProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
100 customInterface = listenerOrientationProxy; |
|
101 } |
|
102 else if (aInterfaceUid == KUidLoudnessEffect) |
|
103 { |
|
104 CLoudnessProxy* loudnessProxy = CLoudnessProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
105 customInterface = loudnessProxy; |
|
106 } |
|
107 else if (aInterfaceUid == KUidRoomLevelEffect) |
|
108 { |
|
109 CRoomLevelProxy* roomLevelProxy = CRoomLevelProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
110 customInterface = roomLevelProxy; |
|
111 } |
|
112 else if (aInterfaceUid == KUidSourceDopplerEffect) |
|
113 { |
|
114 CSourceDopplerProxy* sourceDopplerProxy = CSourceDopplerProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
115 customInterface = sourceDopplerProxy; |
|
116 } |
|
117 else if (aInterfaceUid == KUidSourceLocationEffect) |
|
118 { |
|
119 CSourceLocationProxy* sourceLocationProxy = CSourceLocationProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
120 customInterface = sourceLocationProxy; |
|
121 } |
|
122 else if (aInterfaceUid == KUidSourceOrientationEffect) |
|
123 { |
|
124 CSourceOrientationProxy* sourceOrientationProxy = CSourceOrientationProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
125 customInterface = sourceOrientationProxy; |
|
126 } |
|
127 else if (aInterfaceUid == KUidStereoWideningEffect) |
|
128 { |
|
129 CStereoWideningProxy* stereoWideningProxy = CStereoWideningProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
130 customInterface = stereoWideningProxy; |
|
131 } |
|
132 else if(aInterfaceUid == KUidAddedDevSoundControlInterface) |
|
133 { |
|
134 CAddedDevSoundControlProxy* proxy = CAddedDevSoundControlProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
135 customInterface = proxy; |
|
136 } |
|
137 else if (aInterfaceUid == KUidG711DecoderIntfc) |
|
138 { |
|
139 CG711DecoderIntfcProxy* g711DecoderIntfcProxy = CG711DecoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
140 customInterface = g711DecoderIntfcProxy; |
|
141 } |
|
142 else if (aInterfaceUid == KUidG729DecoderIntfc) |
|
143 { |
|
144 CG729DecoderIntfcProxy* g729DecoderIntfcProxy = CG729DecoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
145 customInterface = g729DecoderIntfcProxy; |
|
146 } |
|
147 else if (aInterfaceUid == KUidIlbcDecoderIntfc) |
|
148 { |
|
149 CIlbcDecoderIntfcProxy* iIlbcDecoderIntfcProxy = CIlbcDecoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
150 customInterface = iIlbcDecoderIntfcProxy; |
|
151 } |
|
152 else if (aInterfaceUid == KUidG711EncoderIntfc) |
|
153 { |
|
154 CG711EncoderIntfcProxy* g711EncoderIntfcProxy = CG711EncoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
155 customInterface = g711EncoderIntfcProxy; |
|
156 } |
|
157 else if (aInterfaceUid == KUidG729EncoderIntfc) |
|
158 { |
|
159 CG729EncoderIntfcProxy* g729EncoderIntfcProxy = CG729EncoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
160 customInterface = g729EncoderIntfcProxy; |
|
161 } |
|
162 else if (aInterfaceUid == KUidIlbcEncoderIntfc) |
|
163 { |
|
164 CIlbcEncoderIntfcProxy* iIlbcEncoderIntfcProxy = CIlbcEncoderIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
165 customInterface = iIlbcEncoderIntfcProxy; |
|
166 } |
|
167 else if (aInterfaceUid == KUidSpeechEncoderConfig) |
|
168 { |
|
169 CSpeechEncoderConfigProxy* speechEncoderIntfcProxy = CSpeechEncoderConfigProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
170 customInterface = speechEncoderIntfcProxy; |
|
171 } |
|
172 else if (aInterfaceUid == KUidErrorConcealmentIntfc) |
|
173 { |
|
174 CErrorConcealmentIntfcProxy* errConcealmentIntfcProxy = CErrorConcealmentIntfcProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
175 customInterface = errConcealmentIntfcProxy; |
|
176 } |
|
177 else if(aInterfaceUid == KUidRestrictedAudioOutput) |
|
178 { |
|
179 CRestrictedAudioOutputProxy* proxy = CRestrictedAudioOutputProxy::NewL(aHandlePckg, aCustomCommand, aCustomInterfaceUtility); |
|
180 customInterface = proxy; |
|
181 } |
|
182 |
|
183 return customInterface; |
|
184 } |
|
185 |
|
186 |
|
187 // End of File |