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

Side by Side Diff: components/mus/gpu/mus_gpu_memory_buffer_manager.h

Issue 2087673002: Remove CreateGpuMemoryBufferFromClientId and plumbing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 6 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
OLDNEW
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 #ifndef COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_ 5 #ifndef COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_
6 #define COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_ 6 #define COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 16 matching lines...) Expand all
27 // Overridden from gpu::GpuMemoryBufferManager: 27 // Overridden from gpu::GpuMemoryBufferManager:
28 std::unique_ptr<gfx::GpuMemoryBuffer> AllocateGpuMemoryBuffer( 28 std::unique_ptr<gfx::GpuMemoryBuffer> AllocateGpuMemoryBuffer(
29 const gfx::Size& size, 29 const gfx::Size& size,
30 gfx::BufferFormat format, 30 gfx::BufferFormat format,
31 gfx::BufferUsage usage, 31 gfx::BufferUsage usage,
32 gpu::SurfaceHandle surface_handle) override; 32 gpu::SurfaceHandle surface_handle) override;
33 std::unique_ptr<gfx::GpuMemoryBuffer> CreateGpuMemoryBufferFromHandle( 33 std::unique_ptr<gfx::GpuMemoryBuffer> CreateGpuMemoryBufferFromHandle(
34 const gfx::GpuMemoryBufferHandle& handle, 34 const gfx::GpuMemoryBufferHandle& handle,
35 const gfx::Size& size, 35 const gfx::Size& size,
36 gfx::BufferFormat format) override; 36 gfx::BufferFormat format) override;
37 std::unique_ptr<gfx::GpuMemoryBuffer> CreateGpuMemoryBufferFromClientId(
38 int client_id,
39 const gfx::GpuMemoryBufferId& gpu_memory_buffer_id) override;
40 gfx::GpuMemoryBuffer* GpuMemoryBufferFromClientBuffer( 37 gfx::GpuMemoryBuffer* GpuMemoryBufferFromClientBuffer(
41 ClientBuffer buffer) override; 38 ClientBuffer buffer) override;
42 void SetDestructionSyncToken(gfx::GpuMemoryBuffer* buffer, 39 void SetDestructionSyncToken(gfx::GpuMemoryBuffer* buffer,
43 const gpu::SyncToken& sync_token) override; 40 const gpu::SyncToken& sync_token) override;
44 41
45 private: 42 private:
46 DISALLOW_COPY_AND_ASSIGN(MusGpuMemoryBufferManager); 43 DISALLOW_COPY_AND_ASSIGN(MusGpuMemoryBufferManager);
47 44
48 void DestroyGpuMemoryBuffer(gfx::GpuMemoryBufferId id, 45 void DestroyGpuMemoryBuffer(gfx::GpuMemoryBufferId id,
49 int client_id, 46 int client_id,
50 bool is_native, 47 bool is_native,
51 const gpu::SyncToken& sync_token); 48 const gpu::SyncToken& sync_token);
52 49
53 GpuServiceMus* gpu_service_; 50 GpuServiceMus* gpu_service_;
54 const int client_id_; 51 const int client_id_;
55 base::WeakPtrFactory<MusGpuMemoryBufferManager> weak_factory_; 52 base::WeakPtrFactory<MusGpuMemoryBufferManager> weak_factory_;
56 }; 53 };
57 54
58 } // namespace mus 55 } // namespace mus
59 56
60 #endif // COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_ 57 #endif // COMPONENTS_MUS_GPU_MUS_GPU_MEMORY_BUFFER_MANAGER_H_
OLDNEW
« no previous file with comments | « components/mus/common/mojo_gpu_memory_buffer_manager.cc ('k') | components/mus/gpu/mus_gpu_memory_buffer_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698