| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <functional> | 8 #include <functional> |
| 9 #include <map> | 9 #include <map> |
| 10 | 10 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 | 23 |
| 24 namespace gpu { | 24 namespace gpu { |
| 25 namespace gles2 { | 25 namespace gles2 { |
| 26 | 26 |
| 27 class TextureDefinition; | 27 class TextureDefinition; |
| 28 class TextureManager; | 28 class TextureManager; |
| 29 | 29 |
| 30 // Identifies a mailbox where a texture definition can be stored for | 30 // Identifies a mailbox where a texture definition can be stored for |
| 31 // transferring textures between contexts that are not in the same context | 31 // transferring textures between contexts that are not in the same context |
| 32 // group. It is a random key signed with a hash of a private key. | 32 // group. It is a random key signed with a hash of a private key. |
| 33 struct GPU_EXPORT MailboxName { | 33 struct MailboxName { |
| 34 MailboxName(); | |
| 35 GLbyte key[GL_MAILBOX_SIZE_CHROMIUM / 2]; | 34 GLbyte key[GL_MAILBOX_SIZE_CHROMIUM / 2]; |
| 36 GLbyte signature[GL_MAILBOX_SIZE_CHROMIUM / 2]; | 35 GLbyte signature[GL_MAILBOX_SIZE_CHROMIUM / 2]; |
| 37 }; | 36 }; |
| 38 | 37 |
| 39 // Manages resources scoped beyond the context or context group level. | 38 // Manages resources scoped beyond the context or context group level. |
| 40 class GPU_EXPORT MailboxManager : public base::RefCounted<MailboxManager> { | 39 class GPU_EXPORT MailboxManager : public base::RefCounted<MailboxManager> { |
| 41 public: | 40 public: |
| 42 MailboxManager(); | 41 MailboxManager(); |
| 43 | 42 |
| 44 // Generate a unique mailbox name signed with the manager's private key. | 43 // Generate a unique mailbox name signed with the manager's private key. |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 TextureDefinitionMap textures_; | 95 TextureDefinitionMap textures_; |
| 97 | 96 |
| 98 DISALLOW_COPY_AND_ASSIGN(MailboxManager); | 97 DISALLOW_COPY_AND_ASSIGN(MailboxManager); |
| 99 }; | 98 }; |
| 100 } // namespage gles2 | 99 } // namespage gles2 |
| 101 } // namespace gpu | 100 } // namespace gpu |
| 102 | 101 |
| 103 #endif // GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ | 102 #endif // GPU_COMMAND_BUFFER_SERVICE_MAILBOX_MANAGER_H_ |
| 104 | 103 |
| 105 | 104 |
| OLD | NEW |