Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(527)

Unified Diff: remoting/protocol/webrtc_video_stream.cc

Issue 1510343002: Add WebrtcConnectionToClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@webrtc_thread
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/protocol/webrtc_video_stream.h ('k') | remoting/remoting_srcs.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/webrtc_video_stream.cc
diff --git a/remoting/protocol/webrtc_video_stream.cc b/remoting/protocol/webrtc_video_stream.cc
new file mode 100644
index 0000000000000000000000000000000000000000..50c6ddd2e4d2521ee05b540951739604949c27e6
--- /dev/null
+++ b/remoting/protocol/webrtc_video_stream.cc
@@ -0,0 +1,49 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "remoting/protocol/webrtc_video_stream.h"
+
+#include "base/logging.h"
+#include "third_party/libjingle/source/talk/app/webrtc/mediastreaminterface.h"
+#include "third_party/libjingle/source/talk/app/webrtc/peerconnectioninterface.h"
+#include "third_party/libjingle/source/talk/app/webrtc/videosourceinterface.h"
+
+namespace remoting {
+namespace protocol {
+
+WebrtcVideoStream::WebrtcVideoStream(
+ rtc::scoped_refptr<webrtc::PeerConnectionInterface> connection,
+ rtc::scoped_refptr<webrtc::MediaStreamInterface> stream)
+ : connection_(connection), stream_(stream) {}
+
+WebrtcVideoStream::~WebrtcVideoStream() {
+ for (const auto& track : stream_->GetVideoTracks()) {
+ track->GetSource()->Stop();
+ stream_->RemoveTrack(track.get());
+ }
+ connection_->RemoveStream(stream_.get());
+}
+
+void WebrtcVideoStream::Pause(bool pause) {
+ NOTIMPLEMENTED();
+}
+
+void WebrtcVideoStream::OnInputEventReceived(int64_t event_timestamp) {
+ NOTIMPLEMENTED();
+}
+
+void WebrtcVideoStream::SetLosslessEncode(bool want_lossless) {
+ NOTIMPLEMENTED();
+}
+
+void WebrtcVideoStream::SetLosslessColor(bool want_lossless) {
+ NOTIMPLEMENTED();
+}
+
+void WebrtcVideoStream::SetSizeCallback(const SizeCallback& size_callback) {
+ NOTIMPLEMENTED();
+}
+
+} // namespace protocol
+} // namespace remoting
« no previous file with comments | « remoting/protocol/webrtc_video_stream.h ('k') | remoting/remoting_srcs.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698