Chromium Code Reviews| Index: content/renderer/media/webrtc_audio_device_impl.cc |
| diff --git a/content/renderer/media/webrtc_audio_device_impl.cc b/content/renderer/media/webrtc_audio_device_impl.cc |
| index 240ea8974dc811378b494939b588ac78fb4823b8..78674a2907fa7facb5a3014b5e5b559f0f508307 100644 |
| --- a/content/renderer/media/webrtc_audio_device_impl.cc |
| +++ b/content/renderer/media/webrtc_audio_device_impl.cc |
| @@ -173,11 +173,11 @@ void WebRtcAudioDeviceImpl::Capture( |
| } |
| } |
| -void WebRtcAudioDeviceImpl::OnDeviceStarted(int device_index) { |
| - VLOG(1) << "OnDeviceStarted (device_index=" << device_index << ")"; |
| - // -1 is an invalid device index. Do nothing if a valid device has |
| +void WebRtcAudioDeviceImpl::OnDeviceStarted(const std::string& device_uid) { |
| + VLOG(1) << "OnDeviceStarted (device_uid=" << device_uid << ")"; |
| + // Empty string is an invalid device id. Do nothing if a valid device has |
| // been started. Otherwise update the |recording_| state to false. |
| - if (device_index != -1) |
| + if (!device_uid.empty()) |
| return; |
| base::AutoLock auto_lock(lock_); |
| @@ -366,12 +366,12 @@ int32_t WebRtcAudioDeviceImpl::Init() { |
| input_buffer_size = 440; |
| output_buffer_size = 440; |
| } |
| -#elif defined(OS_LINUX) || defined(OS_OPENBSD) |
| +#elif defined(OS_LINUX) |
| if (output_sample_rate != 48000) { |
| DLOG(ERROR) << "Only 48kHz sample rate is supported on Linux."; |
| return -1; |
| } |
| - input_channels = 1; |
| + input_channels = 2; |
|
scherkus (not reviewing)
2011/11/16 01:20:40
was this change intentional?
henrika (OOO until Aug 14)
2011/11/16 13:24:02
Same question.
no longer working on chromium
2011/11/16 17:45:48
Yes. The testing shows that stereo is more widely
no longer working on chromium
2011/11/16 17:45:48
See comment above.
|
| output_channels = 1; |
| // Based on tests using the current ALSA implementation in Chrome, we have |