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

Unified Diff: remoting/protocol/webrtc_video_stream.cc

Issue 2767193007: [Chromoting] Send DesktopFrame::capturer_id() to client through WebrtcVideoStream (Closed)
Patch Set: Created 3 years, 9 months 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/frame_stats.cc ('k') | no next file » | 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
index 8c2478bf7b1fd0ce525d646143071d111bd8f423..60b2f01c7d8d2a90528b45b492355e04120bf6f1 100644
--- a/remoting/protocol/webrtc_video_stream.cc
+++ b/remoting/protocol/webrtc_video_stream.cc
@@ -41,6 +41,7 @@ struct WebrtcVideoStream::FrameTimestamps {
struct WebrtcVideoStream::EncodedFrameWithTimestamps {
std::unique_ptr<WebrtcVideoEncoder::EncodedFrame> frame;
std::unique_ptr<FrameTimestamps> timestamps;
+ uint32_t capturer_id;
Sergey Ulanov 2017/03/24 23:54:26 I think it's better to put this in WebrtcVideoStre
Hzj_jie 2017/03/25 02:15:49 I intended to do so, but it's a little bit complex
};
WebrtcVideoStream::WebrtcVideoStream()
@@ -203,6 +204,7 @@ WebrtcVideoStream::EncodedFrameWithTimestamps WebrtcVideoStream::EncodeFrame(
result.timestamps->encode_started_time = base::TimeTicks::Now();
result.frame = encoder->Encode(frame.get(), params);
result.timestamps->encode_ended_time = base::TimeTicks::Now();
+ result.capturer_id = frame->capturer_id();
return result;
}
@@ -250,6 +252,8 @@ void WebrtcVideoStream::OnFrameEncoded(EncodedFrameWithTimestamps frame) {
stats.encode_delay = frame.timestamps->encode_ended_time -
frame.timestamps->encode_started_time;
+ stats.capturer_id = frame.capturer_id;
+
video_stats_dispatcher_.OnVideoFrameStats(result.frame_id, stats);
}
}
« no previous file with comments | « remoting/protocol/frame_stats.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698