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

Unified Diff: content/browser/compositor/software_output_device_mac.mm

Issue 2018793002: Mac: Move remote layer use to GpuOutputSurfaceMac (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clean_up_mac
Patch Set: Review feedback Created 4 years, 7 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
Index: content/browser/compositor/software_output_device_mac.mm
diff --git a/content/browser/compositor/software_output_device_mac.mm b/content/browser/compositor/software_output_device_mac.mm
index da190699d0374d36f7a01a6d3c1ba4f62162c8d5..36a6e541e4d26ace69cabd0cf3b23edd8ee015e3 100644
--- a/content/browser/compositor/software_output_device_mac.mm
+++ b/content/browser/compositor/software_output_device_mac.mm
@@ -140,15 +140,19 @@
if (io_result)
DLOG(ERROR) << "Failed to unlock IOSurface " << io_result;
}
-
canvas_.reset();
- base::TimeTicks vsync_timebase;
- base::TimeDelta vsync_interval;
- ui::AcceleratedWidgetMacGotFrame(
- compositor_->widget(), 0, false, 0, io_surfaces_[current_index_],
- pixel_size_, scale_factor_, &vsync_timebase, &vsync_interval);
- if (!update_vsync_callback_.is_null())
- update_vsync_callback_.Run(vsync_timebase, vsync_interval);
+
+ ui::AcceleratedWidgetMac* widget =
+ ui::AcceleratedWidgetMac::Get(compositor_->widget());
+ if (widget) {
+ widget->GotIOSurfaceFrame(io_surfaces_[current_index_], pixel_size_,
+ scale_factor_);
+ base::TimeTicks vsync_timebase;
+ base::TimeDelta vsync_interval;
+ widget->GetVSyncParameters(&vsync_timebase, &vsync_interval);
+ if (!update_vsync_callback_.is_null())
+ update_vsync_callback_.Run(vsync_timebase, vsync_interval);
+ }
current_index_ = !current_index_;
}
« no previous file with comments | « content/browser/compositor/gpu_output_surface_mac.mm ('k') | content/browser/renderer_host/browser_compositor_view_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698