Index: talk/session/media/channel.h |
diff --git a/talk/session/media/channel.h b/talk/session/media/channel.h |
index 5f51c07a287cf79aad3c2c82ab4aaa8fafc76834..7fdbdfaff6eca00ca1088d99b9938b5123e5e9d1 100644 |
--- a/talk/session/media/channel.h |
+++ b/talk/session/media/channel.h |
@@ -105,7 +105,6 @@ class BaseChannel |
bool secure_required() const { return secure_required_; } |
bool writable() const { return writable_; } |
- bool IsStreamMuted(uint32 ssrc); |
// Activate RTCP mux, regardless of the state so far. Once |
// activated, it can not be deactivated, and if the remote |
@@ -127,9 +126,6 @@ class BaseChannel |
std::string* error_desc); |
bool Enable(bool enable); |
- // Mute sending media on the stream with SSRC |ssrc| |
- // If there is only one sending stream SSRC 0 can be used. |
- bool MuteStream(uint32 ssrc, bool mute); |
// Multiplexing |
bool AddRecvStream(const StreamParams& sp); |
@@ -163,9 +159,6 @@ class BaseChannel |
// Used for latency measurements. |
sigslot::signal1<BaseChannel*> SignalFirstPacketReceived; |
- // Used to alert UI when the muted status changes, perhaps autonomously. |
- sigslot::repeater2<BaseChannel*, bool> SignalAutoMuted; |
- |
// Made public for easier testing. |
void SetReadyToSend(TransportChannel* channel, bool ready); |
@@ -232,8 +225,6 @@ class BaseChannel |
void EnableMedia_w(); |
void DisableMedia_w(); |
- virtual bool MuteStream_w(uint32 ssrc, bool mute); |
- bool IsStreamMuted_w(uint32 ssrc); |
void ChannelWritable_w(); |
void ChannelNotWritable_w(); |
bool AddRecvStream_w(const StreamParams& sp); |
@@ -324,7 +315,6 @@ class BaseChannel |
bool was_ever_writable_; |
MediaContentDirection local_content_direction_; |
MediaContentDirection remote_content_direction_; |
- std::set<uint32> muted_streams_; |
bool has_received_packet_; |
bool dtls_keyed_; |
bool secure_required_; |
@@ -343,6 +333,11 @@ class VoiceChannel : public BaseChannel { |
bool SetRemoteRenderer(uint32 ssrc, AudioRenderer* renderer); |
bool SetLocalRenderer(uint32 ssrc, AudioRenderer* renderer); |
+ // Mute sending media on the stream with SSRC |ssrc| |
+ // If there is only one sending stream SSRC 0 can be used. |
+ bool MuteStream(uint32 ssrc, bool mute, const AudioOptions* options); |
+ bool IsStreamMuted(uint32 ssrc); |
+ |
// downcasts a MediaChannel |
virtual VoiceMediaChannel* media_channel() const { |
return static_cast<VoiceMediaChannel*>(BaseChannel::media_channel()); |
@@ -387,9 +382,6 @@ class VoiceChannel : public BaseChannel { |
void StopTypingMonitor(); |
bool IsTypingMonitorRunning() const; |
- // Overrides BaseChannel::MuteStream_w. |
- virtual bool MuteStream_w(uint32 ssrc, bool mute); |
- |
int GetInputLevel_w(); |
int GetOutputLevel_w(); |
void GetActiveStreams_w(AudioInfo::StreamList* actives); |
@@ -399,8 +391,8 @@ class VoiceChannel : public BaseChannel { |
sigslot::signal3<VoiceChannel*, uint32, VoiceMediaChannel::Error> |
SignalMediaError; |
- // Configuration and setting. |
- bool SetChannelOptions(const AudioOptions& options); |
+ // Used to alert UI when the muted status changes, perhaps autonomously. |
+ sigslot::repeater2<BaseChannel*, bool> SignalAutoMuted; |
private: |
// overrides from BaseChannel |
@@ -416,6 +408,8 @@ class VoiceChannel : public BaseChannel { |
virtual bool SetRemoteContent_w(const MediaContentDescription* content, |
ContentAction action, |
std::string* error_desc); |
+ bool MuteStream_w(uint32 ssrc, bool mute, const AudioOptions* options); |
+ bool IsStreamMuted_w(uint32 ssrc); |
bool SetRingbackTone_w(const void* buf, int len); |
bool PlayRingbackTone_w(uint32 ssrc, bool play, bool loop); |
void HandleEarlyMediaTimeout(); |
@@ -440,6 +434,7 @@ class VoiceChannel : public BaseChannel { |
rtc::scoped_ptr<VoiceMediaMonitor> media_monitor_; |
rtc::scoped_ptr<AudioMonitor> audio_monitor_; |
rtc::scoped_ptr<TypingMonitor> typing_monitor_; |
+ std::set<uint32> muted_streams_; |
// Last AudioSendParameters sent down to the media_channel() via |
// SetSendParameters. |
@@ -493,8 +488,9 @@ class VideoChannel : public BaseChannel { |
sigslot::signal3<VideoChannel*, uint32, VideoMediaChannel::Error> |
SignalMediaError; |
- // Configuration and setting. |
- bool SetChannelOptions(const VideoOptions& options); |
+ // Mute sending media on the stream with SSRC |ssrc| |
+ // If there is only one sending stream SSRC 0 can be used. |
+ bool MuteStream(uint32 ssrc, bool mute, const VideoOptions* options); |
private: |
typedef std::map<uint32, VideoCapturer*> ScreencastMap; |
@@ -531,6 +527,7 @@ class VideoChannel : public BaseChannel { |
void OnVideoChannelError(uint32 ssrc, VideoMediaChannel::Error error); |
void OnSrtpError(uint32 ssrc, SrtpFilter::Mode mode, SrtpFilter::Error error); |
+ bool MuteStream_w(uint32 ssrc, bool mute, const VideoOptions* options); |
VideoRenderer* renderer_; |
ScreencastMap screencast_capturers_; |