Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright 2004 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2004 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 TALK_SESSION_MEDIA_CHANNEL_H_ | 11 #ifndef TALK_SESSION_MEDIA_CHANNEL_H_ |
| 12 #define TALK_SESSION_MEDIA_CHANNEL_H_ | 12 #define TALK_SESSION_MEDIA_CHANNEL_H_ |
| 13 | 13 |
| 14 #include <map> | 14 #include <map> |
| 15 #include <set> | 15 #include <set> |
| 16 #include <string> | 16 #include <string> |
| 17 #include <utility> | 17 #include <utility> |
| 18 #include <vector> | 18 #include <vector> |
| 19 | 19 |
| 20 #include "webrtc/audio_sink.h" | 20 #include "webrtc/audio_sink.h" |
| 21 #include "webrtc/base/asyncudpsocket.h" | 21 #include "webrtc/base/asyncudpsocket.h" |
| 22 #include "webrtc/base/criticalsection.h" | 22 #include "webrtc/base/criticalsection.h" |
| 23 #include "webrtc/base/network.h" | 23 #include "webrtc/base/network.h" |
| 24 #include "webrtc/base/sigslot.h" | 24 #include "webrtc/base/sigslot.h" |
| 25 #include "webrtc/base/window.h" | 25 #include "webrtc/base/window.h" |
| 26 #include "webrtc/media/base/mediachannel.h" | 26 #include "webrtc/media/base/mediachannel.h" |
| 27 #include "webrtc/media/base/mediaengine.h" | 27 #include "webrtc/media/base/mediaengine.h" |
| 28 #include "webrtc/media/base/streamparams.h" | 28 #include "webrtc/media/base/streamparams.h" |
| 29 #include "webrtc/media/base/videocapturer.h" | |
| 30 #include "webrtc/media/base/videosinkinterface.h" | 29 #include "webrtc/media/base/videosinkinterface.h" |
| 30 #include "webrtc/media/base/videosourceinterface.h" | |
| 31 #include "webrtc/p2p/base/transportcontroller.h" | 31 #include "webrtc/p2p/base/transportcontroller.h" |
| 32 #include "webrtc/p2p/client/socketmonitor.h" | 32 #include "webrtc/p2p/client/socketmonitor.h" |
| 33 #include "webrtc/pc/audiomonitor.h" | 33 #include "webrtc/pc/audiomonitor.h" |
| 34 #include "webrtc/pc/bundlefilter.h" | 34 #include "webrtc/pc/bundlefilter.h" |
| 35 #include "webrtc/pc/mediamonitor.h" | 35 #include "webrtc/pc/mediamonitor.h" |
| 36 #include "webrtc/pc/mediasession.h" | 36 #include "webrtc/pc/mediasession.h" |
| 37 #include "webrtc/pc/rtcpmuxfilter.h" | 37 #include "webrtc/pc/rtcpmuxfilter.h" |
| 38 #include "webrtc/pc/srtpfilter.h" | 38 #include "webrtc/pc/srtpfilter.h" |
| 39 | 39 |
| 40 namespace webrtc { | 40 namespace webrtc { |
| (...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 437 virtual VideoMediaChannel* media_channel() const { | 437 virtual VideoMediaChannel* media_channel() const { |
| 438 return static_cast<VideoMediaChannel*>(BaseChannel::media_channel()); | 438 return static_cast<VideoMediaChannel*>(BaseChannel::media_channel()); |
| 439 } | 439 } |
| 440 | 440 |
| 441 bool SetSink(uint32_t ssrc, rtc::VideoSinkInterface<VideoFrame>* sink); | 441 bool SetSink(uint32_t ssrc, rtc::VideoSinkInterface<VideoFrame>* sink); |
| 442 | 442 |
| 443 // TODO(pthatcher): Refactor to use a "capture id" instead of an | 443 // TODO(pthatcher): Refactor to use a "capture id" instead of an |
| 444 // ssrc here as the "key". | 444 // ssrc here as the "key". |
| 445 // Passes ownership of the capturer to the channel. | 445 // Passes ownership of the capturer to the channel. |
| 446 bool AddScreencast(uint32_t ssrc, VideoCapturer* capturer); | 446 bool AddScreencast(uint32_t ssrc, VideoCapturer* capturer); |
| 447 bool SetCapturer(uint32_t ssrc, VideoCapturer* capturer); | 447 // Register a source. The |ssrc| must correspond to a registered |
| 448 // send stream. | |
|
pthatcher1
2016/03/05 01:45:41
We should specify what happens if it isn't (ie not
nisse-webrtc
2016/03/15 16:28:00
The current implementation will always explode, ex
| |
| 449 void SetSource(uint32_t ssrc, | |
| 450 rtc::VideoSourceInterface<cricket::VideoFrame>* source); | |
| 448 bool RemoveScreencast(uint32_t ssrc); | 451 bool RemoveScreencast(uint32_t ssrc); |
| 449 // True if we've added a screencast. Doesn't matter if the capturer | 452 // True if we've added a screencast. Doesn't matter if the capturer |
| 450 // has been started or not. | 453 // has been started or not. |
| 451 bool IsScreencasting(); | 454 bool IsScreencasting(); |
| 452 // Get statistics about the current media session. | 455 // Get statistics about the current media session. |
| 453 bool GetStats(VideoMediaInfo* stats); | 456 bool GetStats(VideoMediaInfo* stats); |
| 454 | 457 |
| 455 sigslot::signal2<VideoChannel*, const std::vector<ConnectionInfo>&> | 458 sigslot::signal2<VideoChannel*, const std::vector<ConnectionInfo>&> |
| 456 SignalConnectionMonitor; | 459 SignalConnectionMonitor; |
| 457 | 460 |
| (...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 620 // SetSendParameters. | 623 // SetSendParameters. |
| 621 DataSendParameters last_send_params_; | 624 DataSendParameters last_send_params_; |
| 622 // Last DataRecvParameters sent down to the media_channel() via | 625 // Last DataRecvParameters sent down to the media_channel() via |
| 623 // SetRecvParameters. | 626 // SetRecvParameters. |
| 624 DataRecvParameters last_recv_params_; | 627 DataRecvParameters last_recv_params_; |
| 625 }; | 628 }; |
| 626 | 629 |
| 627 } // namespace cricket | 630 } // namespace cricket |
| 628 | 631 |
| 629 #endif // TALK_SESSION_MEDIA_CHANNEL_H_ | 632 #endif // TALK_SESSION_MEDIA_CHANNEL_H_ |
| OLD | NEW |