OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 4176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4187 { | 4187 { |
4188 WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id, | 4188 WEBRTC_TRACE(kTraceError, kTraceAudioDevice, _id, |
4189 "Built-in AEC DMO was not initialized properly at create time"); | 4189 "Built-in AEC DMO was not initialized properly at create time"); |
4190 return -1; | 4190 return -1; |
4191 } | 4191 } |
4192 | 4192 |
4193 _builtInAecEnabled = enable; | 4193 _builtInAecEnabled = enable; |
4194 return 0; | 4194 return 0; |
4195 } | 4195 } |
4196 | 4196 |
4197 bool AudioDeviceWindowsCore::BuiltInAECIsEnabled() const | |
4198 { | |
4199 return _builtInAecEnabled; | |
4200 } | |
4201 | |
4202 int AudioDeviceWindowsCore::SetDMOProperties() | 4197 int AudioDeviceWindowsCore::SetDMOProperties() |
4203 { | 4198 { |
4204 HRESULT hr = S_OK; | 4199 HRESULT hr = S_OK; |
4205 assert(_dmo != NULL); | 4200 assert(_dmo != NULL); |
4206 | 4201 |
4207 rtc::scoped_refptr<IPropertyStore> ps; | 4202 rtc::scoped_refptr<IPropertyStore> ps; |
4208 { | 4203 { |
4209 IPropertyStore* ptrPS = NULL; | 4204 IPropertyStore* ptrPS = NULL; |
4210 hr = _dmo->QueryInterface(IID_IPropertyStore, | 4205 hr = _dmo->QueryInterface(IID_IPropertyStore, |
4211 reinterpret_cast<void**>(&ptrPS)); | 4206 reinterpret_cast<void**>(&ptrPS)); |
(...skipping 884 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5096 int key_down = 0; | 5091 int key_down = 0; |
5097 for (int key = VK_SPACE; key < VK_NUMLOCK; key++) { | 5092 for (int key = VK_SPACE; key < VK_NUMLOCK; key++) { |
5098 short res = GetAsyncKeyState(key); | 5093 short res = GetAsyncKeyState(key); |
5099 key_down |= res & 0x1; // Get the LSB | 5094 key_down |= res & 0x1; // Get the LSB |
5100 } | 5095 } |
5101 return (key_down > 0); | 5096 return (key_down > 0); |
5102 } | 5097 } |
5103 } // namespace webrtc | 5098 } // namespace webrtc |
5104 | 5099 |
5105 #endif // WEBRTC_WINDOWS_CORE_AUDIO_BUILD | 5100 #endif // WEBRTC_WINDOWS_CORE_AUDIO_BUILD |
OLD | NEW |