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

Unified Diff: remoting/codec/video_encoder_vpx.cc

Issue 1365663003: Add UMA histograms for more detailed latency tracking on the CRD host. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixed tests Created 5 years, 3 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/codec/video_encoder_verbatim.cc ('k') | remoting/host/client_session.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/codec/video_encoder_vpx.cc
diff --git a/remoting/codec/video_encoder_vpx.cc b/remoting/codec/video_encoder_vpx.cc
index 1fa19a487cdc7ea5edbf48030f7293640e670b16..0dcd456ac32980e86227ede4a2e90942ccfa2dc9 100644
--- a/remoting/codec/video_encoder_vpx.cc
+++ b/remoting/codec/video_encoder_vpx.cc
@@ -270,8 +270,6 @@ scoped_ptr<VideoPacket> VideoEncoderVpx::Encode(
if (frame.updated_region().is_empty() && !encode_unchanged_frame_)
return nullptr;
- base::TimeTicks encode_start_time = base::TimeTicks::Now();
-
// Create or reconfigure the codec to match the size of |frame|.
if (!codec_ ||
(image_ &&
@@ -296,7 +294,7 @@ scoped_ptr<VideoPacket> VideoEncoderVpx::Encode(
}
// Do the actual encoding.
- int timestamp = (encode_start_time - timestamp_base_).InMilliseconds();
+ int timestamp = (base::TimeTicks::Now() - timestamp_base_).InMilliseconds();
vpx_codec_err_t ret = vpx_codec_encode(
codec_.get(), image_.get(), timestamp, 1, 0, VPX_DL_REALTIME);
DCHECK_EQ(ret, VPX_CODEC_OK)
@@ -341,10 +339,6 @@ scoped_ptr<VideoPacket> VideoEncoderVpx::Encode(
}
}
- // Note the time taken to encode the pixel data.
- packet->set_encode_time_ms(
- (base::TimeTicks::Now() - encode_start_time).InMillisecondsRoundedUp());
-
return packet.Pass();
}
« no previous file with comments | « remoting/codec/video_encoder_verbatim.cc ('k') | remoting/host/client_session.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698