| 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 22 matching lines...) Expand all Loading... |
| 33 int32_t RegisterAudioCallback(AudioTransport* audioCallback); | 33 int32_t RegisterAudioCallback(AudioTransport* audioCallback); |
| 34 | 34 |
| 35 int32_t InitPlayout(); | 35 int32_t InitPlayout(); |
| 36 int32_t InitRecording(); | 36 int32_t InitRecording(); |
| 37 | 37 |
| 38 virtual int32_t SetRecordingSampleRate(uint32_t fsHz); | 38 virtual int32_t SetRecordingSampleRate(uint32_t fsHz); |
| 39 virtual int32_t SetPlayoutSampleRate(uint32_t fsHz); | 39 virtual int32_t SetPlayoutSampleRate(uint32_t fsHz); |
| 40 int32_t RecordingSampleRate() const; | 40 int32_t RecordingSampleRate() const; |
| 41 int32_t PlayoutSampleRate() const; | 41 int32_t PlayoutSampleRate() const; |
| 42 | 42 |
| 43 virtual int32_t SetRecordingChannels(uint8_t channels); | 43 virtual int32_t SetRecordingChannels(size_t channels); |
| 44 virtual int32_t SetPlayoutChannels(uint8_t channels); | 44 virtual int32_t SetPlayoutChannels(size_t channels); |
| 45 uint8_t RecordingChannels() const; | 45 size_t RecordingChannels() const; |
| 46 uint8_t PlayoutChannels() const; | 46 size_t PlayoutChannels() const; |
| 47 int32_t SetRecordingChannel( | 47 int32_t SetRecordingChannel( |
| 48 const AudioDeviceModule::ChannelType channel); | 48 const AudioDeviceModule::ChannelType channel); |
| 49 int32_t RecordingChannel( | 49 int32_t RecordingChannel( |
| 50 AudioDeviceModule::ChannelType& channel) const; | 50 AudioDeviceModule::ChannelType& channel) const; |
| 51 | 51 |
| 52 virtual int32_t SetRecordedBuffer(const void* audioBuffer, | 52 virtual int32_t SetRecordedBuffer(const void* audioBuffer, |
| 53 size_t nSamples); | 53 size_t nSamples); |
| 54 int32_t SetCurrentMicLevel(uint32_t level); | 54 int32_t SetCurrentMicLevel(uint32_t level); |
| 55 virtual void SetVQEData(int playDelayMS, | 55 virtual void SetVQEData(int playDelayMS, |
| 56 int recDelayMS, | 56 int recDelayMS, |
| (...skipping 16 matching lines...) Expand all Loading... |
| 73 private: | 73 private: |
| 74 int32_t _id; | 74 int32_t _id; |
| 75 CriticalSectionWrapper& _critSect; | 75 CriticalSectionWrapper& _critSect; |
| 76 CriticalSectionWrapper& _critSectCb; | 76 CriticalSectionWrapper& _critSectCb; |
| 77 | 77 |
| 78 AudioTransport* _ptrCbAudioTransport; | 78 AudioTransport* _ptrCbAudioTransport; |
| 79 | 79 |
| 80 uint32_t _recSampleRate; | 80 uint32_t _recSampleRate; |
| 81 uint32_t _playSampleRate; | 81 uint32_t _playSampleRate; |
| 82 | 82 |
| 83 uint8_t _recChannels; | 83 size_t _recChannels; |
| 84 uint8_t _playChannels; | 84 size_t _playChannels; |
| 85 | 85 |
| 86 // selected recording channel (left/right/both) | 86 // selected recording channel (left/right/both) |
| 87 AudioDeviceModule::ChannelType _recChannel; | 87 AudioDeviceModule::ChannelType _recChannel; |
| 88 | 88 |
| 89 // 2 or 4 depending on mono or stereo | 89 // 2 or 4 depending on mono or stereo |
| 90 size_t _recBytesPerSample; | 90 size_t _recBytesPerSample; |
| 91 size_t _playBytesPerSample; | 91 size_t _playBytesPerSample; |
| 92 | 92 |
| 93 // 10ms in stereo @ 96kHz | 93 // 10ms in stereo @ 96kHz |
| 94 int8_t _recBuffer[kMaxBufferSizeBytes]; | 94 int8_t _recBuffer[kMaxBufferSizeBytes]; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 114 | 114 |
| 115 int _playDelayMS; | 115 int _playDelayMS; |
| 116 int _recDelayMS; | 116 int _recDelayMS; |
| 117 int _clockDrift; | 117 int _clockDrift; |
| 118 int high_delay_counter_; | 118 int high_delay_counter_; |
| 119 }; | 119 }; |
| 120 | 120 |
| 121 } // namespace webrtc | 121 } // namespace webrtc |
| 122 | 122 |
| 123 #endif // WEBRTC_AUDIO_DEVICE_AUDIO_DEVICE_BUFFER_H | 123 #endif // WEBRTC_AUDIO_DEVICE_AUDIO_DEVICE_BUFFER_H |
| OLD | NEW |