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

Side by Side Diff: webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc

Issue 11348231: Move gl_bindings_skia_cmd_buffer into webkit_gpu and make the latter a component (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: missing dep Created 8 years 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 (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/gpu/webgraphicscontext3d_in_process_command_buffer_impl.h" 5 #include "webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.h"
6 6
7 #include <GLES2/gl2.h> 7 #include <GLES2/gl2.h>
8 #ifndef GL_GLEXT_PROTOTYPES 8 #ifndef GL_GLEXT_PROTOTYPES
9 #define GL_GLEXT_PROTOTYPES 1 9 #define GL_GLEXT_PROTOTYPES 1
10 #endif 10 #endif
(...skipping 15 matching lines...) Expand all
26 #include "base/string_tokenizer.h" 26 #include "base/string_tokenizer.h"
27 #include "base/synchronization/lock.h" 27 #include "base/synchronization/lock.h"
28 #include "gpu/command_buffer/client/gles2_implementation.h" 28 #include "gpu/command_buffer/client/gles2_implementation.h"
29 #include "gpu/command_buffer/client/gles2_lib.h" 29 #include "gpu/command_buffer/client/gles2_lib.h"
30 #include "gpu/command_buffer/client/transfer_buffer.h" 30 #include "gpu/command_buffer/client/transfer_buffer.h"
31 #include "gpu/command_buffer/common/constants.h" 31 #include "gpu/command_buffer/common/constants.h"
32 #include "gpu/command_buffer/service/command_buffer_service.h" 32 #include "gpu/command_buffer/service/command_buffer_service.h"
33 #include "gpu/command_buffer/service/context_group.h" 33 #include "gpu/command_buffer/service/context_group.h"
34 #include "gpu/command_buffer/service/transfer_buffer_manager.h" 34 #include "gpu/command_buffer/service/transfer_buffer_manager.h"
35 #include "gpu/command_buffer/service/gpu_scheduler.h" 35 #include "gpu/command_buffer/service/gpu_scheduler.h"
36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h"
37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h"
38 #include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
39 #include "ui/gl/gl_context.h" 36 #include "ui/gl/gl_context.h"
40 #include "ui/gl/gl_share_group.h" 37 #include "ui/gl/gl_share_group.h"
41 #include "ui/gl/gl_surface.h" 38 #include "ui/gl/gl_surface.h"
42 #include "webkit/glue/gl_bindings_skia_cmd_buffer.h" 39 #include "webkit/gpu/gl_bindings_skia_cmd_buffer.h"
43 40
44 using gpu::Buffer; 41 using gpu::Buffer;
45 using gpu::CommandBuffer; 42 using gpu::CommandBuffer;
46 using gpu::CommandBufferService; 43 using gpu::CommandBufferService;
47 using gpu::gles2::GLES2CmdHelper; 44 using gpu::gles2::GLES2CmdHelper;
48 using gpu::gles2::GLES2Implementation; 45 using gpu::gles2::GLES2Implementation;
49 using gpu::GpuScheduler; 46 using gpu::GpuScheduler;
50 using gpu::TransferBuffer; 47 using gpu::TransferBuffer;
51 using gpu::TransferBufferManager; 48 using gpu::TransferBufferManager;
52 using gpu::TransferBufferManagerInterface; 49 using gpu::TransferBufferManagerInterface;
(...skipping 1597 matching lines...) Expand 10 before | Expand all | Expand 10 after
1650 } 1647 }
1651 1648
1652 WGC3Dboolean WebGraphicsContext3DInProcessCommandBufferImpl:: 1649 WGC3Dboolean WebGraphicsContext3DInProcessCommandBufferImpl::
1653 unmapBufferCHROMIUM(WGC3Denum target) { 1650 unmapBufferCHROMIUM(WGC3Denum target) {
1654 ClearContext(); 1651 ClearContext();
1655 return gl_->UnmapBufferCHROMIUM(target); 1652 return gl_->UnmapBufferCHROMIUM(target);
1656 } 1653 }
1657 1654
1658 GrGLInterface* WebGraphicsContext3DInProcessCommandBufferImpl:: 1655 GrGLInterface* WebGraphicsContext3DInProcessCommandBufferImpl::
1659 onCreateGrGLInterface() { 1656 onCreateGrGLInterface() {
1660 return webkit_glue::CreateCommandBufferSkiaGLBinding(); 1657 return CreateCommandBufferSkiaGLBinding();
1661 } 1658 }
1662 1659
1663 void WebGraphicsContext3DInProcessCommandBufferImpl::OnContextLost() { 1660 void WebGraphicsContext3DInProcessCommandBufferImpl::OnContextLost() {
1664 // TODO(kbr): improve the precision here. 1661 // TODO(kbr): improve the precision here.
1665 context_lost_reason_ = GL_UNKNOWN_CONTEXT_RESET_ARB; 1662 context_lost_reason_ = GL_UNKNOWN_CONTEXT_RESET_ARB;
1666 if (context_lost_callback_) { 1663 if (context_lost_callback_) {
1667 context_lost_callback_->onContextLost(); 1664 context_lost_callback_->onContextLost();
1668 } 1665 }
1669 } 1666 }
1670 1667
1671 DELEGATE_TO_GL_3(bindUniformLocationCHROMIUM, BindUniformLocationCHROMIUM, 1668 DELEGATE_TO_GL_3(bindUniformLocationCHROMIUM, BindUniformLocationCHROMIUM,
1672 WebGLId, WGC3Dint, const WGC3Dchar*) 1669 WebGLId, WGC3Dint, const WGC3Dchar*)
1673 1670
1674 DELEGATE_TO_GL(shallowFlushCHROMIUM, ShallowFlushCHROMIUM) 1671 DELEGATE_TO_GL(shallowFlushCHROMIUM, ShallowFlushCHROMIUM)
1675 1672
1676 DELEGATE_TO_GL_1(genMailboxCHROMIUM, GenMailboxCHROMIUM, WGC3Dbyte*) 1673 DELEGATE_TO_GL_1(genMailboxCHROMIUM, GenMailboxCHROMIUM, WGC3Dbyte*)
1677 DELEGATE_TO_GL_2(produceTextureCHROMIUM, ProduceTextureCHROMIUM, 1674 DELEGATE_TO_GL_2(produceTextureCHROMIUM, ProduceTextureCHROMIUM,
1678 WGC3Denum, const WGC3Dbyte*) 1675 WGC3Denum, const WGC3Dbyte*)
1679 DELEGATE_TO_GL_2(consumeTextureCHROMIUM, ConsumeTextureCHROMIUM, 1676 DELEGATE_TO_GL_2(consumeTextureCHROMIUM, ConsumeTextureCHROMIUM,
1680 WGC3Denum, const WGC3Dbyte*) 1677 WGC3Denum, const WGC3Dbyte*)
1681 1678
1682 } // namespace gpu 1679 } // namespace gpu
1683 } // namespace webkit 1680 } // namespace webkit
OLDNEW
« no previous file with comments | « webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.h ('k') | webkit/gpu/webgraphicscontext3d_in_process_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698