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

Side by Side Diff: content/browser/gpu/browser_gpu_memory_buffer_manager.h

Issue 654223006: Cleanup GpuMemoryBuffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: style nits Created 6 years, 1 month 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 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 "base/callback.h" 8 #include "base/callback.h"
9 #include "content/common/content_export.h" 9 #include "content/common/content_export.h"
10 #include "gpu/command_buffer/client/gpu_memory_buffer_manager.h" 10 #include "gpu/command_buffer/client/gpu_memory_buffer_manager.h"
(...skipping 12 matching lines...) Expand all
23 23
24 static BrowserGpuMemoryBufferManager* current(); 24 static BrowserGpuMemoryBufferManager* current();
25 25
26 // Overridden from gpu::GpuMemoryBufferManager: 26 // Overridden from gpu::GpuMemoryBufferManager:
27 scoped_ptr<gfx::GpuMemoryBuffer> AllocateGpuMemoryBuffer( 27 scoped_ptr<gfx::GpuMemoryBuffer> AllocateGpuMemoryBuffer(
28 const gfx::Size& size, 28 const gfx::Size& size,
29 gfx::GpuMemoryBuffer::Format format, 29 gfx::GpuMemoryBuffer::Format format,
30 gfx::GpuMemoryBuffer::Usage usage) override; 30 gfx::GpuMemoryBuffer::Usage usage) override;
31 gfx::GpuMemoryBuffer* GpuMemoryBufferFromClientBuffer( 31 gfx::GpuMemoryBuffer* GpuMemoryBufferFromClientBuffer(
32 ClientBuffer buffer) override; 32 ClientBuffer buffer) override;
33 void SetDestructionSyncPoint(gfx::GpuMemoryBuffer* buffer,
34 uint32 sync_point) override;
33 35
34 void AllocateGpuMemoryBufferForChildProcess( 36 void AllocateGpuMemoryBufferForChildProcess(
35 const gfx::Size& size, 37 const gfx::Size& size,
36 gfx::GpuMemoryBuffer::Format format, 38 gfx::GpuMemoryBuffer::Format format,
37 gfx::GpuMemoryBuffer::Usage usage, 39 gfx::GpuMemoryBuffer::Usage usage,
38 base::ProcessHandle child_process_handle, 40 base::ProcessHandle child_process_handle,
39 int child_client_id, 41 int child_client_id,
40 const AllocationCallback& callback); 42 const AllocationCallback& callback);
41 void ChildProcessDeletedGpuMemoryBuffer( 43 void ChildProcessDeletedGpuMemoryBuffer(
42 gfx::GpuMemoryBufferType type, 44 gfx::GpuMemoryBufferType type,
43 const gfx::GpuMemoryBufferId& id, 45 const gfx::GpuMemoryBufferId& id,
44 base::ProcessHandle child_process_handle); 46 base::ProcessHandle child_process_handle,
47 int child_client_id,
48 uint32 sync_point);
45 void ProcessRemoved(base::ProcessHandle process_handle); 49 void ProcessRemoved(base::ProcessHandle process_handle);
46 50
47 private: 51 private:
48 struct AllocateGpuMemoryBufferRequest; 52 struct AllocateGpuMemoryBufferRequest;
49 53
50 static void AllocateGpuMemoryBufferOnIO( 54 static void AllocateGpuMemoryBufferOnIO(
51 AllocateGpuMemoryBufferRequest* request); 55 AllocateGpuMemoryBufferRequest* request);
52 static void GpuMemoryBufferCreatedOnIO( 56 static void GpuMemoryBufferCreatedOnIO(
53 AllocateGpuMemoryBufferRequest* request, 57 AllocateGpuMemoryBufferRequest* request,
54 scoped_ptr<GpuMemoryBufferImpl> buffer); 58 scoped_ptr<GpuMemoryBufferImpl> buffer);
55 59
56 int gpu_client_id_; 60 int gpu_client_id_;
57 }; 61 };
58 62
59 } // namespace content 63 } // namespace content
60 64
61 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_ 65 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_MEMORY_BUFFER_MANAGER_H_
OLDNEW
« no previous file with comments | « cc/test/test_gpu_memory_buffer_manager.cc ('k') | content/browser/gpu/browser_gpu_memory_buffer_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698