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

Unified Diff: remoting/client/chromoting_client.cc

Issue 6736009: Measure bandwidth for chromoting video channel (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: done Created 9 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/client/chromoting_client.h ('k') | remoting/client/chromoting_stats.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/client/chromoting_client.cc
diff --git a/remoting/client/chromoting_client.cc b/remoting/client/chromoting_client.cc
index aee6df4c3638fe8b94b691e9e24b60bf0066acd9..bf1ad39a99ed105441041783205820727ea86edf 100644
--- a/remoting/client/chromoting_client.cc
+++ b/remoting/client/chromoting_client.cc
@@ -92,6 +92,10 @@ void ChromotingClient::ClientDone() {
}
}
+ChromotingStats* ChromotingClient::GetStats() {
+ return &stats_;
+}
+
void ChromotingClient::Repaint() {
if (message_loop() != MessageLoop::current()) {
message_loop()->PostTask(
@@ -125,6 +129,9 @@ void ChromotingClient::ProcessVideoPacket(const VideoPacket* packet,
return;
}
+ // Record size of the packet for statistics.
+ stats_.video_bandwidth()->Record(packet->data().size());
+
received_packets_.push_back(QueuedVideoPacket(packet, done));
if (!packet_being_processed_)
DispatchPacket();
« no previous file with comments | « remoting/client/chromoting_client.h ('k') | remoting/client/chromoting_stats.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698