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

Unified Diff: remoting/test/scroll_frame_generator.cc

Issue 2420183002: Don't use barcodes in ProtocolPerfTests (Closed)
Patch Set: Update ChromotingHost::OnSessionAuthenticated() to fix test crash Created 4 years, 2 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/test/scroll_frame_generator.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/test/scroll_frame_generator.cc
diff --git a/remoting/test/scroll_frame_generator.cc b/remoting/test/scroll_frame_generator.cc
index 1a6a1ec0b6834d89306d5a3dffc81980f8141410..01e0af239da995088c13a81b431462598aaa8c7d 100644
--- a/remoting/test/scroll_frame_generator.cc
+++ b/remoting/test/scroll_frame_generator.cc
@@ -41,19 +41,12 @@ std::unique_ptr<webrtc::DesktopFrame> ScrollFrameGenerator::GenerateFrame(
result->mutable_updated_region()->SetRect(
webrtc::DesktopRect::MakeSize(result->size()));
- ++last_frame_id_;
- frame_timestamp_[last_frame_id_] = now;
- DrawBarcode(last_frame_id_, true, result.get());
-
return result;
}
-base::TimeDelta ScrollFrameGenerator::GetFrameLatency(
- const webrtc::DesktopFrame& frame) {
- int frame_id = ReadBarcode(frame);
- if (!frame_timestamp_.count(frame_id))
- LOG(FATAL) << "Unknown frame_id.";
- return base::TimeTicks::Now() - frame_timestamp_[frame_id];
+protocol::InputEventTimestamps ScrollFrameGenerator::TakeLastEventTimestamps() {
+ base::TimeTicks now = base::TimeTicks::Now();
+ return protocol::InputEventTimestamps{now, now};
}
} // namespace test
« no previous file with comments | « remoting/test/scroll_frame_generator.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698