Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: modules/audio_device/dummy/file_audio_device.cc

Issue 3020493002: Remove AudioDeviceObserver and make ADM not inherit from the Module interface.
Patch Set: linux build error Created 3 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
391 enabled = true; 391 enabled = true;
392 return 0; 392 return 0;
393 } 393 }
394 394
395 int32_t FileAudioDevice::PlayoutDelay(uint16_t& delayMS) const { 395 int32_t FileAudioDevice::PlayoutDelay(uint16_t& delayMS) const {
396 return 0; 396 return 0;
397 } 397 }
398 398
399 int32_t FileAudioDevice::RecordingDelay(uint16_t& delayMS) const { return -1; } 399 int32_t FileAudioDevice::RecordingDelay(uint16_t& delayMS) const { return -1; }
400 400
401 bool FileAudioDevice::PlayoutWarning() const { return false; }
402
403 bool FileAudioDevice::PlayoutError() const { return false; }
404
405 bool FileAudioDevice::RecordingWarning() const { return false; }
406
407 bool FileAudioDevice::RecordingError() const { return false; }
408
409 void FileAudioDevice::ClearPlayoutWarning() {}
410
411 void FileAudioDevice::ClearPlayoutError() {}
412
413 void FileAudioDevice::ClearRecordingWarning() {}
414
415 void FileAudioDevice::ClearRecordingError() {}
416
417 void FileAudioDevice::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer) { 401 void FileAudioDevice::AttachAudioBuffer(AudioDeviceBuffer* audioBuffer) {
418 rtc::CritScope lock(&_critSect); 402 rtc::CritScope lock(&_critSect);
419 403
420 _ptrAudioBuffer = audioBuffer; 404 _ptrAudioBuffer = audioBuffer;
421 405
422 // Inform the AudioBuffer about default settings for this implementation. 406 // Inform the AudioBuffer about default settings for this implementation.
423 // Set all values to zero here since the actual settings will be done by 407 // Set all values to zero here since the actual settings will be done by
424 // InitPlayout and InitRecording later. 408 // InitPlayout and InitRecording later.
425 _ptrAudioBuffer->SetRecordingSampleRate(0); 409 _ptrAudioBuffer->SetRecordingSampleRate(0);
426 _ptrAudioBuffer->SetPlayoutSampleRate(0); 410 _ptrAudioBuffer->SetPlayoutSampleRate(0);
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
499 483
500 int64_t deltaTimeMillis = rtc::TimeMillis() - currentTime; 484 int64_t deltaTimeMillis = rtc::TimeMillis() - currentTime;
501 if (deltaTimeMillis < 10) { 485 if (deltaTimeMillis < 10) {
502 SleepMs(10 - deltaTimeMillis); 486 SleepMs(10 - deltaTimeMillis);
503 } 487 }
504 488
505 return true; 489 return true;
506 } 490 }
507 491
508 } // namespace webrtc 492 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698