| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ | 5 #ifndef CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ |
| 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ | 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| 11 #include <memory> | 11 #include <memory> |
| 12 #include <utility> | 12 #include <utility> |
| 13 | 13 |
| 14 #include "base/callback.h" | 14 #include "base/callback.h" |
| 15 #include "base/containers/hash_tables.h" | 15 #include "base/containers/hash_tables.h" |
| 16 #include "base/hash.h" | 16 #include "base/hash.h" |
| 17 #include "base/macros.h" | 17 #include "base/macros.h" |
| 18 #include "base/trace_event/memory_dump_provider.h" | 18 #include "base/trace_event/memory_dump_provider.h" |
| 19 #include "content/common/content_export.h" | 19 #include "content/common/content_export.h" |
| 20 #include "gpu/command_buffer/client/gpu_memory_buffer_manager.h" | 20 #include "gpu/command_buffer/client/gpu_memory_buffer_manager.h" |
| 21 #include "gpu/ipc/common/gpu_memory_buffer_support.h" |
| 21 #include "gpu/ipc/common/surface_handle.h" | 22 #include "gpu/ipc/common/surface_handle.h" |
| 22 #include "gpu/ipc/host/gpu_memory_buffer_support.h" | |
| 23 | 23 |
| 24 namespace content { | 24 namespace content { |
| 25 class GpuProcessHost; | 25 class GpuProcessHost; |
| 26 | 26 |
| 27 class CONTENT_EXPORT BrowserGpuMemoryBufferManager | 27 class CONTENT_EXPORT BrowserGpuMemoryBufferManager |
| 28 : public gpu::GpuMemoryBufferManager, | 28 : public gpu::GpuMemoryBufferManager, |
| 29 public base::trace_event::MemoryDumpProvider { | 29 public base::trace_event::MemoryDumpProvider { |
| 30 public: | 30 public: |
| 31 using CreateCallback = | 31 using CreateCallback = |
| 32 base::Callback<void(const gfx::GpuMemoryBufferHandle& handle)>; | 32 base::Callback<void(const gfx::GpuMemoryBufferHandle& handle)>; |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 using BufferMap = base::hash_map<gfx::GpuMemoryBufferId, BufferInfo>; | 141 using BufferMap = base::hash_map<gfx::GpuMemoryBufferId, BufferInfo>; |
| 142 using ClientMap = base::hash_map<int, BufferMap>; | 142 using ClientMap = base::hash_map<int, BufferMap>; |
| 143 ClientMap clients_; | 143 ClientMap clients_; |
| 144 | 144 |
| 145 DISALLOW_COPY_AND_ASSIGN(BrowserGpuMemoryBufferManager); | 145 DISALLOW_COPY_AND_ASSIGN(BrowserGpuMemoryBufferManager); |
| 146 }; | 146 }; |
| 147 | 147 |
| 148 } // namespace content | 148 } // namespace content |
| 149 | 149 |
| 150 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ | 150 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ |
| OLD | NEW |