Move ownership of voe::Channel into Audio[Receive|Send]Stream.
* VoEBase contains only stub methods (until downstream code is
updated).
* voe::Channel and ChannelProxy classes remain, but are now created
internally to the streams. As a result,
internal::Audio[Receive|Send]Stream can have a ChannelProxy injected
for testing.
* Stream classes share Call::module_process_thread_ for their RtpRtcp
modules, rather than using a separate thread shared only among audio
streams.
* voe::Channel instances use Call::worker_queue_ for encoding packets,
rather than having a separate queue for audio (send) streams.
Bug: webrtc:4690
Change-Id: I8059ef224ad13aa0a6ded2cafc52599c7f64d68d
Reviewed-on: https://webrtc-review.googlesource.com/34640
Commit-Queue: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21578}diff --git a/call/audio_receive_stream.h b/call/audio_receive_stream.h
index 505fd08..f8d787c 100644
--- a/call/audio_receive_stream.h
+++ b/call/audio_receive_stream.h
@@ -29,11 +29,6 @@
namespace webrtc {
class AudioSinkInterface;
-// WORK IN PROGRESS
-// This class is under development and is not yet intended for for use outside
-// of WebRtc/Libjingle. Please use the VoiceEngine API instead.
-// See: https://bugs.chromium.org/p/webrtc/issues/detail?id=4690
-
class AudioReceiveStream {
public:
struct Stats {
@@ -103,12 +98,13 @@
Transport* rtcp_send_transport = nullptr;
- // Underlying VoiceEngine handle, used to map AudioReceiveStream to lower-
- // level components.
- // TODO(solenberg): Remove when VoiceEngine channels are created outside
- // of Call.
+ // TODO(solenberg): Remove once clients don't use it anymore.
int voe_channel_id = -1;
+ // NetEq settings.
+ size_t jitter_buffer_max_packets = 50;
+ bool jitter_buffer_fast_accelerate = false;
+
// Identifier for an A/V synchronization group. Empty string to disable.
// TODO(pbos): Synchronize streams in a sync group, not just one video
// stream to one audio stream. Tracked by issue webrtc:4762.
@@ -135,14 +131,13 @@
virtual int GetOutputLevel() const = 0;
// Sets an audio sink that receives unmixed audio from the receive stream.
- // Ownership of the sink is passed to the stream and can be used by the
- // caller to do lifetime management (i.e. when the sink's dtor is called).
+ // Ownership of the sink is managed by the caller.
// Only one sink can be set and passing a null sink clears an existing one.
// NOTE: Audio must still somehow be pulled through AudioTransport for audio
// to stream through this sink. In practice, this happens if mixed audio
// is being pulled+rendered and/or if audio is being pulled for the purposes
// of feeding to the AEC.
- virtual void SetSink(std::unique_ptr<AudioSinkInterface> sink) = 0;
+ virtual void SetSink(AudioSinkInterface* sink) = 0;
// Sets playback gain of the stream, applied when mixing, and thus after it
// is potentially forwarded to any attached AudioSinkInterface implementation.