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

Unified Diff: ui/accelerated_widget_mac/display_link_mac.cc

Issue 1280033004: Revert of Mac Overlays: Add GPU back-pressure (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « ui/accelerated_widget_mac/display_link_mac.h ('k') | ui/gl/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/accelerated_widget_mac/display_link_mac.cc
diff --git a/ui/accelerated_widget_mac/display_link_mac.cc b/ui/accelerated_widget_mac/display_link_mac.cc
index 3013efb58e9469864717da37468c9117d2854ded..c9a30699a06fff31a5b8117c2cfb7f5d7b64e0c6 100644
--- a/ui/accelerated_widget_mac/display_link_mac.cc
+++ b/ui/accelerated_widget_mac/display_link_mac.cc
@@ -27,9 +27,6 @@
// static
scoped_refptr<DisplayLinkMac> DisplayLinkMac::GetForDisplay(
CGDirectDisplayID display_id) {
- if (!display_id)
- return nullptr;
-
// Return the existing display link for this display, if it exists.
DisplayMap::iterator found = display_map_.Get().find(display_id);
if (found != display_map_.Get().end()) {
@@ -108,22 +105,6 @@
return true;
}
-base::TimeTicks DisplayLinkMac::GetNextVSyncTimeAfter(
- const base::TimeTicks& from, double interval_fraction) {
- if (!timebase_and_interval_valid_) {
- StartOrContinueDisplayLink();
- return from;
- }
-
- // Compute the previous vsync time.
- base::TimeTicks previous_vsync =
- interval_ * ((from - timebase_remainder_) / interval_) +
- timebase_remainder_;
-
- // Return |interval_fraction| through the next vsync.
- return previous_vsync + (1 + interval_fraction) * interval_;
-}
-
void DisplayLinkMac::Tick(const CVTimeStamp& cv_time) {
TRACE_EVENT0("ui", "DisplayLinkMac::Tick");
@@ -142,9 +123,6 @@
cv_time.hostTime / 1000);
interval_ = base::TimeDelta::FromMicroseconds(
1000000 * static_cast<int64>(numerator) / denominator);
- // Compute |timebase_remainder_| to be the first vsync after time zero.
- timebase_remainder_ =
- timebase_ - interval_ * ((timebase_ - base::TimeTicks()) / interval_);
timebase_and_interval_valid_ = true;
StopDisplayLink();
« no previous file with comments | « ui/accelerated_widget_mac/display_link_mac.h ('k') | ui/gl/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698