| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "components/mus/gpu/mus_gpu_memory_buffer_manager.h" | 5 #include "services/ui/gpu/mus_gpu_memory_buffer_manager.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "components/mus/common/generic_shared_memory_id_generator.h" | |
| 9 #include "components/mus/gpu/gpu_service_mus.h" | |
| 10 #include "gpu/ipc/client/gpu_memory_buffer_impl.h" | 8 #include "gpu/ipc/client/gpu_memory_buffer_impl.h" |
| 11 #include "gpu/ipc/client/gpu_memory_buffer_impl_shared_memory.h" | 9 #include "gpu/ipc/client/gpu_memory_buffer_impl_shared_memory.h" |
| 12 #include "gpu/ipc/common/gpu_memory_buffer_support.h" | 10 #include "gpu/ipc/common/gpu_memory_buffer_support.h" |
| 13 #include "gpu/ipc/service/gpu_memory_buffer_factory.h" | 11 #include "gpu/ipc/service/gpu_memory_buffer_factory.h" |
| 12 #include "services/ui/common/generic_shared_memory_id_generator.h" |
| 13 #include "services/ui/gpu/gpu_service_mus.h" |
| 14 | 14 |
| 15 namespace mus { | 15 namespace mus { |
| 16 | 16 |
| 17 namespace { | 17 namespace { |
| 18 | 18 |
| 19 MusGpuMemoryBufferManager* g_gpu_memory_buffer_manager = nullptr; | 19 MusGpuMemoryBufferManager* g_gpu_memory_buffer_manager = nullptr; |
| 20 | 20 |
| 21 bool IsNativeGpuMemoryBufferFactoryConfigurationSupported( | 21 bool IsNativeGpuMemoryBufferFactoryConfigurationSupported( |
| 22 gfx::BufferFormat format, | 22 gfx::BufferFormat format, |
| 23 gfx::BufferUsage usage) { | 23 gfx::BufferUsage usage) { |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 int client_id, | 106 int client_id, |
| 107 bool is_native, | 107 bool is_native, |
| 108 const gpu::SyncToken& sync_token) { | 108 const gpu::SyncToken& sync_token) { |
| 109 if (is_native) { | 109 if (is_native) { |
| 110 gpu_service_->gpu_channel_manager()->DestroyGpuMemoryBuffer(id, client_id, | 110 gpu_service_->gpu_channel_manager()->DestroyGpuMemoryBuffer(id, client_id, |
| 111 sync_token); | 111 sync_token); |
| 112 } | 112 } |
| 113 } | 113 } |
| 114 | 114 |
| 115 } // namespace mus | 115 } // namespace mus |
| OLD | NEW |