| Index: cc/resources/resource_pool.cc
|
| diff --git a/cc/resources/resource_pool.cc b/cc/resources/resource_pool.cc
|
| index 75f7d1e45b22f8e37ac36f761a1b85a911c1b87d..f58bcc6f21e3242bbc41014f65e40af263f31868 100644
|
| --- a/cc/resources/resource_pool.cc
|
| +++ b/cc/resources/resource_pool.cc
|
| @@ -10,14 +10,17 @@ namespace cc {
|
|
|
| ResourcePool::Resource::Resource(cc::ResourceProvider* resource_provider,
|
| gfx::Size size,
|
| - GLenum format)
|
| + GLenum format,
|
| + cc::ResourceProvider::TextureType type)
|
| : cc::Resource(resource_provider->CreateManagedResource(
|
| size,
|
| format,
|
| GL_CLAMP_TO_EDGE,
|
| - ResourceProvider::TextureUsageAny),
|
| + ResourceProvider::TextureUsageAny,
|
| + type),
|
| size,
|
| - format),
|
| + format,
|
| + type),
|
| resource_provider_(resource_provider) {
|
| DCHECK(id());
|
| }
|
| @@ -43,7 +46,7 @@ ResourcePool::~ResourcePool() {
|
| }
|
|
|
| scoped_ptr<ResourcePool::Resource> ResourcePool::AcquireResource(
|
| - gfx::Size size, GLenum format) {
|
| + gfx::Size size, GLenum format, ResourceProvider::TextureType type) {
|
| for (ResourceList::iterator it = unused_resources_.begin();
|
| it != unused_resources_.end(); ++it) {
|
| Resource* resource = *it;
|
| @@ -61,7 +64,8 @@ scoped_ptr<ResourcePool::Resource> ResourcePool::AcquireResource(
|
| }
|
|
|
| // Create new resource.
|
| - Resource* resource = new Resource(resource_provider_, size, format);
|
| + Resource* resource = new Resource(
|
| + resource_provider_, size, format, type);
|
|
|
| // Extend all read locks on all resources until the resource is
|
| // finished being used, such that we know when resources are
|
|
|