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

Unified Diff: content/common/gpu/image_transport_surface_fbo_mac.cc

Issue 347653005: Make cross-process CALayers work on Mac (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@image_transport_1
Patch Set: Incorporate review feedback Created 6 years, 6 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/common/gpu/image_transport_surface_fbo_mac.cc
diff --git a/content/common/gpu/image_transport_surface_fbo_mac.cc b/content/common/gpu/image_transport_surface_fbo_mac.cc
index 79ec8db8dd1dd0dea1eba5ef0b32150a47f46130..3e86a484fe9d0ce87b4168c1fbdc9356c2e3c681 100644
--- a/content/common/gpu/image_transport_surface_fbo_mac.cc
+++ b/content/common/gpu/image_transport_surface_fbo_mac.cc
@@ -135,6 +135,8 @@ bool ImageTransportSurfaceFBO::SwapBuffers() {
DCHECK(!is_swap_buffers_pending_);
is_swap_buffers_pending_ = true;
+
+ storage_provider_->WillSwapBuffers();
return true;
}
@@ -158,6 +160,8 @@ bool ImageTransportSurfaceFBO::PostSubBuffer(
DCHECK(!is_swap_buffers_pending_);
is_swap_buffers_pending_ = true;
+
+ storage_provider_->WillSwapBuffers();
return true;
}
@@ -321,8 +325,8 @@ void ImageTransportSurfaceFBO::CreateFramebuffer() {
}
bool allocated_color_buffer = storage_provider_->AllocateColorBufferStorage(
- static_cast<CGLContextObj>(context_->GetHandle()),
- rounded_size_);
+ static_cast<CGLContextObj>(context_->GetHandle()), texture_id_,
+ rounded_size_, scale_factor_);
if (!allocated_color_buffer) {
DLOG(ERROR) << "Failed to allocate color buffer storage.";
DestroyFramebuffer();

Powered by Google App Engine
This is Rietveld 408576698