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 GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ | 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ |
6 #define GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ | 6 #define GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ |
7 | 7 |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "gpu/command_buffer/common/mailbox.h" | 9 #include "gpu/command_buffer/common/mailbox.h" |
10 #include "gpu/gpu_export.h" | 10 #include "gpu/gpu_export.h" |
11 | 11 |
12 namespace gpu { | 12 namespace gpu { |
13 | |
14 struct SyncToken; | |
15 | |
16 namespace gles2 { | 13 namespace gles2 { |
17 | 14 |
18 class Texture; | 15 class Texture; |
| 16 struct SyncToken; |
19 | 17 |
20 // Manages resources scoped beyond the context or context group level. | 18 // Manages resources scoped beyond the context or context group level. |
21 class GPU_EXPORT MailboxManager : public base::RefCounted<MailboxManager> { | 19 class GPU_EXPORT MailboxManager : public base::RefCounted<MailboxManager> { |
22 public: | 20 public: |
23 static scoped_refptr<MailboxManager> Create(); | 21 static scoped_refptr<MailboxManager> Create(); |
24 | 22 |
25 // Look up the texture definition from the named mailbox. | 23 // Look up the texture definition from the named mailbox. |
26 virtual Texture* ConsumeTexture(const Mailbox& mailbox) = 0; | 24 virtual Texture* ConsumeTexture(const Mailbox& mailbox) = 0; |
27 | 25 |
28 // Put the texture into the named mailbox. | 26 // Put the texture into the named mailbox. |
(...skipping 17 matching lines...) Expand all Loading... |
46 friend class base::RefCounted<MailboxManager>; | 44 friend class base::RefCounted<MailboxManager>; |
47 | 45 |
48 DISALLOW_COPY_AND_ASSIGN(MailboxManager); | 46 DISALLOW_COPY_AND_ASSIGN(MailboxManager); |
49 }; | 47 }; |
50 | 48 |
51 } // namespage gles2 | 49 } // namespage gles2 |
52 } // namespace gpu | 50 } // namespace gpu |
53 | 51 |
54 #endif // GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ | 52 #endif // GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ |
55 | 53 |
OLD | NEW |