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

Side by Side Diff: content/common/gpu/image_transport_surface_mac.cc

Issue 12383042: Switch all contexts in a share group to be on the same screen as the window they present to. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 9 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 unified diff | Download patch
« no previous file with comments | « content/common/gpu/gpu_messages.h ('k') | ui/gl/gl_context_cgl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/common/gpu/image_transport_surface.h" 5 #include "content/common/gpu/image_transport_surface.h"
6 6
7 #include "base/mac/scoped_cftyperef.h" 7 #include "base/mac/scoped_cftyperef.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "content/common/gpu/gpu_messages.h" 9 #include "content/common/gpu/gpu_messages.h"
10 #include "content/common/gpu/texture_image_transport_surface.h" 10 #include "content/common/gpu/texture_image_transport_surface.h"
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 extensions += "GL_CHROMIUM_front_buffer_cached "; 263 extensions += "GL_CHROMIUM_front_buffer_cached ";
264 extensions += "GL_CHROMIUM_post_sub_buffer"; 264 extensions += "GL_CHROMIUM_post_sub_buffer";
265 return extensions; 265 return extensions;
266 } 266 }
267 267
268 gfx::Size IOSurfaceImageTransportSurface::GetSize() { 268 gfx::Size IOSurfaceImageTransportSurface::GetSize() {
269 return size_; 269 return size_;
270 } 270 }
271 271
272 void IOSurfaceImageTransportSurface::OnBufferPresented( 272 void IOSurfaceImageTransportSurface::OnBufferPresented(
273 const AcceleratedSurfaceMsg_BufferPresented_Params& /* params */) { 273 const AcceleratedSurfaceMsg_BufferPresented_Params& params) {
274 DCHECK(is_swap_buffers_pending_); 274 DCHECK(is_swap_buffers_pending_);
275
276 context_->share_group()->SetRendererID(params.renderer_id);
275 is_swap_buffers_pending_ = false; 277 is_swap_buffers_pending_ = false;
276 if (did_unschedule_) { 278 if (did_unschedule_) {
277 did_unschedule_ = false; 279 did_unschedule_ = false;
278 helper_->SetScheduled(true); 280 helper_->SetScheduled(true);
279 } 281 }
280 } 282 }
281 283
282 void IOSurfaceImageTransportSurface::OnResizeViewACK() { 284 void IOSurfaceImageTransportSurface::OnResizeViewACK() {
283 NOTREACHED(); 285 NOTREACHED();
284 } 286 }
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
474 else 476 else
475 return NULL; 477 return NULL;
476 } 478 }
477 479
478 // static 480 // static
479 void ImageTransportSurface::SetAllowOSMesaForTesting(bool allow) { 481 void ImageTransportSurface::SetAllowOSMesaForTesting(bool allow) {
480 g_allow_os_mesa = allow; 482 g_allow_os_mesa = allow;
481 } 483 }
482 484
483 } // namespace content 485 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_messages.h ('k') | ui/gl/gl_context_cgl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698