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

Side by Side Diff: webkit/compositor_bindings/web_layer_tree_view_impl.cc

Issue 12212007: cc: Route offscreen context creation for compositor to the browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 "web_layer_tree_view_impl.h" 5 #include "web_layer_tree_view_impl.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/string_number_conversions.h" 8 #include "base/string_number_conversions.h"
9 #include "cc/font_atlas.h" 9 #include "cc/font_atlas.h"
10 #include "cc/input_handler.h" 10 #include "cc/input_handler.h"
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 { 271 {
272 WebKit::WebCompositorOutputSurface* web = m_client->createOutputSurface(); 272 WebKit::WebCompositorOutputSurface* web = m_client->createOutputSurface();
273 return make_scoped_ptr(static_cast<cc::OutputSurface*>(web)); 273 return make_scoped_ptr(static_cast<cc::OutputSurface*>(web));
274 } 274 }
275 275
276 void WebLayerTreeViewImpl::didRecreateOutputSurface(bool success) 276 void WebLayerTreeViewImpl::didRecreateOutputSurface(bool success)
277 { 277 {
278 m_client->didRecreateOutputSurface(success); 278 m_client->didRecreateOutputSurface(success);
279 } 279 }
280 280
281 WebKit::WebGraphicsContext3D* WebLayerTreeViewImpl::createOrGetOffscreenContext3 dForMainThread()
282 {
283 return m_client->createOrGetOffscreenContext3dForMainThread();
284 }
285
286 WebKit::WebGraphicsContext3D* WebLayerTreeViewImpl::createOrGetOffscreenContext3 dForCompositorThread()
287 {
288 return m_client->createOrGetOffscreenContext3dForCompositorThread();
289 }
290
291 GrContext* WebLayerTreeViewImpl::createOrGetOffscreenGrContextForMainThread()
292 {
293 return m_client->createOrGetOffscreenGrContextForMainThread();
294 }
295
296 GrContext* WebLayerTreeViewImpl::createOrGetOffscreenGrContextForCompositorThrea d()
297 {
298 return m_client->createOrGetOffscreenGrContextForCompositorThread();
299 }
300
281 scoped_ptr<InputHandler> WebLayerTreeViewImpl::createInputHandler() 301 scoped_ptr<InputHandler> WebLayerTreeViewImpl::createInputHandler()
282 { 302 {
283 scoped_ptr<InputHandler> ret; 303 scoped_ptr<InputHandler> ret;
284 scoped_ptr<WebInputHandler> handler(m_client->createInputHandler()); 304 scoped_ptr<WebInputHandler> handler(m_client->createInputHandler());
285 if (handler) 305 if (handler)
286 ret = WebToCCInputHandlerAdapter::create(handler.Pass()); 306 ret = WebToCCInputHandlerAdapter::create(handler.Pass());
287 return ret.Pass(); 307 return ret.Pass();
288 } 308 }
289 309
290 void WebLayerTreeViewImpl::willCommit() 310 void WebLayerTreeViewImpl::willCommit()
(...skipping 15 matching lines...) Expand all
306 { 326 {
307 m_client->didCompleteSwapBuffers(); 327 m_client->didCompleteSwapBuffers();
308 } 328 }
309 329
310 void WebLayerTreeViewImpl::scheduleComposite() 330 void WebLayerTreeViewImpl::scheduleComposite()
311 { 331 {
312 m_client->scheduleComposite(); 332 m_client->scheduleComposite();
313 } 333 }
314 334
315 } // namespace WebKit 335 } // namespace WebKit
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698