Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 |
| 11 #ifndef WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ | 11 #ifndef WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ |
| 12 #define WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ | 12 #define WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ |
| 13 | 13 |
| 14 #include <memory> | 14 #include <memory> |
| 15 | 15 |
| 16 #include "webrtc/api/audio/audio_mixer.h" | 16 #include "webrtc/api/audio/audio_mixer.h" |
| 17 #include "webrtc/api/call/audio_receive_stream.h" | 17 #include "webrtc/api/call/audio_receive_stream.h" |
| 18 #include "webrtc/api/call/audio_state.h" | 18 #include "webrtc/api/call/audio_state.h" |
| 19 #include "webrtc/audio/audio_state.h" | |
| 19 #include "webrtc/base/constructormagic.h" | 20 #include "webrtc/base/constructormagic.h" |
| 20 #include "webrtc/base/thread_checker.h" | 21 #include "webrtc/base/thread_checker.h" |
| 21 #include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h" | 22 #include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h" |
| 22 | 23 |
| 23 namespace webrtc { | 24 namespace webrtc { |
| 24 class CongestionController; | 25 class CongestionController; |
| 25 class RemoteBitrateEstimator; | 26 class RemoteBitrateEstimator; |
| 26 class RtcEventLog; | 27 class RtcEventLog; |
| 27 | 28 |
| 28 namespace voe { | 29 namespace voe { |
| (...skipping 28 matching lines...) Expand all Loading... | |
| 57 const webrtc::AudioReceiveStream::Config& config() const; | 58 const webrtc::AudioReceiveStream::Config& config() const; |
| 58 | 59 |
| 59 // AudioMixer::Source | 60 // AudioMixer::Source |
| 60 AudioFrameInfo GetAudioFrameWithInfo(int sample_rate_hz, | 61 AudioFrameInfo GetAudioFrameWithInfo(int sample_rate_hz, |
| 61 AudioFrame* audio_frame) override; | 62 AudioFrame* audio_frame) override; |
| 62 int PreferredSampleRate() const override; | 63 int PreferredSampleRate() const override; |
| 63 int Ssrc() const override; | 64 int Ssrc() const override; |
| 64 | 65 |
| 65 private: | 66 private: |
| 66 VoiceEngine* voice_engine() const; | 67 VoiceEngine* voice_engine() const; |
| 68 AudioState* audio_state() const; | |
| 69 int SetVoiceEnginePlayout(bool playout); | |
|
aleloi
2016/11/17 18:12:26
Added method for VoE->StartPlayout() / StopPlayout
| |
| 67 | 70 |
| 68 rtc::ThreadChecker thread_checker_; | 71 rtc::ThreadChecker thread_checker_; |
| 69 RemoteBitrateEstimator* remote_bitrate_estimator_ = nullptr; | 72 RemoteBitrateEstimator* remote_bitrate_estimator_ = nullptr; |
| 70 const webrtc::AudioReceiveStream::Config config_; | 73 const webrtc::AudioReceiveStream::Config config_; |
| 71 rtc::scoped_refptr<webrtc::AudioState> audio_state_; | 74 rtc::scoped_refptr<webrtc::AudioState> audio_state_; |
| 72 std::unique_ptr<RtpHeaderParser> rtp_header_parser_; | 75 std::unique_ptr<RtpHeaderParser> rtp_header_parser_; |
| 73 std::unique_ptr<voe::ChannelProxy> channel_proxy_; | 76 std::unique_ptr<voe::ChannelProxy> channel_proxy_; |
| 74 | 77 |
| 78 bool playing_ ACCESS_ON(thread_checker_) = false; | |
| 79 | |
| 75 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioReceiveStream); | 80 RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(AudioReceiveStream); |
| 76 }; | 81 }; |
| 77 } // namespace internal | 82 } // namespace internal |
| 78 } // namespace webrtc | 83 } // namespace webrtc |
| 79 | 84 |
| 80 #endif // WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ | 85 #endif // WEBRTC_AUDIO_AUDIO_RECEIVE_STREAM_H_ |
| OLD | NEW |