| OLD | NEW |
| 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 #ifndef CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ | 5 #ifndef CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ |
| 6 #define CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ | 6 #define CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 using WebKit::WGC3Dintptr; | 45 using WebKit::WGC3Dintptr; |
| 46 using WebKit::WGC3Dsizeiptr; | 46 using WebKit::WGC3Dsizeiptr; |
| 47 using WebKit::WebGraphicsManagedMemoryStats; | 47 using WebKit::WebGraphicsManagedMemoryStats; |
| 48 using WebKit::WebGraphicsMemoryAllocation; | 48 using WebKit::WebGraphicsMemoryAllocation; |
| 49 | 49 |
| 50 namespace content { | 50 namespace content { |
| 51 class GpuChannelHost; | 51 class GpuChannelHost; |
| 52 class GpuChannelHostFactory; | 52 class GpuChannelHostFactory; |
| 53 struct GpuMemoryAllocationForRenderer; | 53 struct GpuMemoryAllocationForRenderer; |
| 54 | 54 |
| 55 const size_t kDefaultCommandBufferSize = 1024 * 1024; |
| 56 const size_t kDefaultStartTransferBufferSize = 1 * 1024 * 1024; |
| 57 const size_t kDefaultMinTransferBufferSize = 1 * 256 * 1024; |
| 58 const size_t kDefaultMaxTransferBufferSize = 16 * 1024 * 1024; |
| 59 |
| 55 // TODO(piman): move this logic to the compositor and remove it from the | 60 // TODO(piman): move this logic to the compositor and remove it from the |
| 56 // context... | 61 // context... |
| 57 class WebGraphicsContext3DSwapBuffersClient { | 62 class WebGraphicsContext3DSwapBuffersClient { |
| 58 public: | 63 public: |
| 59 virtual void OnViewContextSwapBuffersPosted() = 0; | 64 virtual void OnViewContextSwapBuffersPosted() = 0; |
| 60 virtual void OnViewContextSwapBuffersComplete() = 0; | 65 virtual void OnViewContextSwapBuffersComplete() = 0; |
| 61 virtual void OnViewContextSwapBuffersAborted() = 0; | 66 virtual void OnViewContextSwapBuffersAborted() = 0; |
| 62 | 67 |
| 63 protected: | 68 protected: |
| 64 virtual ~WebGraphicsContext3DSwapBuffersClient() {} | 69 virtual ~WebGraphicsContext3DSwapBuffersClient() {} |
| (...skipping 686 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 751 bool use_echo_for_swap_ack_; | 756 bool use_echo_for_swap_ack_; |
| 752 size_t command_buffer_size_; | 757 size_t command_buffer_size_; |
| 753 size_t start_transfer_buffer_size_; | 758 size_t start_transfer_buffer_size_; |
| 754 size_t min_transfer_buffer_size_; | 759 size_t min_transfer_buffer_size_; |
| 755 size_t max_transfer_buffer_size_; | 760 size_t max_transfer_buffer_size_; |
| 756 }; | 761 }; |
| 757 | 762 |
| 758 } // namespace content | 763 } // namespace content |
| 759 | 764 |
| 760 #endif // CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ | 765 #endif // CONTENT_COMMON_GPU_CLIENT_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ |
| OLD | NEW |