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

Side by Side Diff: webkit/support/webkit_support.cc

Issue 12908004: Lazy initialize WGC3DInProcessCommandBufferImpl (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: explicit constructor Created 7 years, 8 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
« no previous file with comments | « webkit/support/webkit_support.h ('k') | no next file » | 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 "webkit/support/webkit_support.h" 5 #include "webkit/support/webkit_support.h"
6 6
7 #include "base/at_exit.h" 7 #include "base/at_exit.h"
8 #include "base/base64.h" 8 #include "base/base64.h"
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 gfx::GLSurface::InitializeOneOff(); 452 gfx::GLSurface::InitializeOneOff();
453 break; 453 break;
454 case GL_BINDING_SOFTWARE_RENDERER: 454 case GL_BINDING_SOFTWARE_RENDERER:
455 gfx::InitializeGLBindings(gfx::kGLImplementationOSMesaGL); 455 gfx::InitializeGLBindings(gfx::kGLImplementationOSMesaGL);
456 break; 456 break;
457 default: 457 default:
458 NOTREACHED(); 458 NOTREACHED();
459 } 459 }
460 } 460 }
461 461
462 WebKit::WebGraphicsContext3D* CreateGraphicsContext3D(
463 const WebKit::WebGraphicsContext3D::Attributes& attributes,
464 WebKit::WebView* web_view) {
465 scoped_ptr<WebGraphicsContext3DInProcessCommandBufferImpl> context(
466 new WebGraphicsContext3DInProcessCommandBufferImpl());
467 if (!context->Initialize(attributes, NULL))
468 return NULL;
469 return context.release();
470 }
471
472 WebKit::WebLayerTreeView* CreateLayerTreeView( 462 WebKit::WebLayerTreeView* CreateLayerTreeView(
473 LayerTreeViewType type, 463 LayerTreeViewType type,
474 DRTLayerTreeViewClient* client, 464 DRTLayerTreeViewClient* client,
475 WebKit::WebThread* thread) { 465 WebKit::WebThread* thread) {
476 scoped_ptr<cc::Thread> compositor_thread; 466 scoped_ptr<cc::Thread> compositor_thread;
477 if (thread) 467 if (thread)
478 compositor_thread = cc::ThreadImpl::CreateForDifferentThread( 468 compositor_thread = cc::ThreadImpl::CreateForDifferentThread(
479 static_cast<webkit_glue::WebThreadImpl*>(thread)-> 469 static_cast<webkit_glue::WebThreadImpl*>(thread)->
480 message_loop()->message_loop_proxy()); 470 message_loop()->message_loop_proxy());
481 471
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
859 // Logging 849 // Logging
860 void EnableWebCoreLogChannels(const std::string& channels) { 850 void EnableWebCoreLogChannels(const std::string& channels) {
861 webkit_glue::EnableWebCoreLogChannels(channels); 851 webkit_glue::EnableWebCoreLogChannels(channels);
862 } 852 }
863 853
864 void SetGamepadData(const WebKit::WebGamepads& pads) { 854 void SetGamepadData(const WebKit::WebGamepads& pads) {
865 test_environment->webkit_platform_support()->setGamepadData(pads); 855 test_environment->webkit_platform_support()->setGamepadData(pads);
866 } 856 }
867 857
868 } // namespace webkit_support 858 } // namespace webkit_support
OLDNEW
« no previous file with comments | « webkit/support/webkit_support.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698