OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 CC_RESOURCES_RESOURCE_PROVIDER_H_ | 5 #ifndef CC_RESOURCES_RESOURCE_PROVIDER_H_ |
6 #define CC_RESOURCES_RESOURCE_PROVIDER_H_ | 6 #define CC_RESOURCES_RESOURCE_PROVIDER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 ResourceId CreateResource(const gfx::Size& size, | 133 ResourceId CreateResource(const gfx::Size& size, |
134 TextureHint hint, | 134 TextureHint hint, |
135 ResourceFormat format); | 135 ResourceFormat format); |
136 | 136 |
137 // Creates a resource for a particular texture target (the distinction between | 137 // Creates a resource for a particular texture target (the distinction between |
138 // texture targets has no effect in software mode). | 138 // texture targets has no effect in software mode). |
139 ResourceId CreateGpuMemoryBufferResource(const gfx::Size& size, | 139 ResourceId CreateGpuMemoryBufferResource(const gfx::Size& size, |
140 TextureHint hint, | 140 TextureHint hint, |
141 ResourceFormat format); | 141 ResourceFormat format); |
142 | 142 |
143 // Wraps an IOSurface into a GL resource. | |
144 ResourceId CreateResourceFromIOSurface(const gfx::Size& size, | |
145 unsigned io_surface_id); | |
146 | |
147 // Wraps an external texture mailbox into a GL resource. | 143 // Wraps an external texture mailbox into a GL resource. |
148 ResourceId CreateResourceFromTextureMailbox( | 144 ResourceId CreateResourceFromTextureMailbox( |
149 const TextureMailbox& mailbox, | 145 const TextureMailbox& mailbox, |
150 std::unique_ptr<SingleReleaseCallbackImpl> release_callback_impl); | 146 std::unique_ptr<SingleReleaseCallbackImpl> release_callback_impl); |
151 | 147 |
152 ResourceId CreateResourceFromTextureMailbox( | 148 ResourceId CreateResourceFromTextureMailbox( |
153 const TextureMailbox& mailbox, | 149 const TextureMailbox& mailbox, |
154 std::unique_ptr<SingleReleaseCallbackImpl> release_callback_impl, | 150 std::unique_ptr<SingleReleaseCallbackImpl> release_callback_impl, |
155 bool read_lock_fences_enabled); | 151 bool read_lock_fences_enabled); |
156 | 152 |
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
690 // A process-unique ID used for disambiguating memory dumps from different | 686 // A process-unique ID used for disambiguating memory dumps from different |
691 // resource providers. | 687 // resource providers. |
692 int tracing_id_; | 688 int tracing_id_; |
693 | 689 |
694 DISALLOW_COPY_AND_ASSIGN(ResourceProvider); | 690 DISALLOW_COPY_AND_ASSIGN(ResourceProvider); |
695 }; | 691 }; |
696 | 692 |
697 } // namespace cc | 693 } // namespace cc |
698 | 694 |
699 #endif // CC_RESOURCES_RESOURCE_PROVIDER_H_ | 695 #endif // CC_RESOURCES_RESOURCE_PROVIDER_H_ |
OLD | NEW |