| Index: cc/resources/resource_pool.cc
|
| diff --git a/cc/resources/resource_pool.cc b/cc/resources/resource_pool.cc
|
| index afcc114a96342b73fe27b49c4f4a3e5f4f5325f1..940a8b0ab92ef0aa69e4d094c3077a638228677e 100644
|
| --- a/cc/resources/resource_pool.cc
|
| +++ b/cc/resources/resource_pool.cc
|
| @@ -10,13 +10,15 @@ namespace cc {
|
|
|
| ResourcePool::Resource::Resource(cc::ResourceProvider* resource_provider,
|
| gfx::Size size,
|
| - GLenum format)
|
| + GLenum format,
|
| + bool use_16_bit_resource)
|
| : cc::Resource(resource_provider->CreateManagedResource(
|
| size,
|
| format,
|
| ResourceProvider::TextureUsageAny),
|
| size,
|
| - format),
|
| + format,
|
| + use_16_bit_resource),
|
| resource_provider_(resource_provider) {
|
| DCHECK(id());
|
| }
|
| @@ -42,7 +44,7 @@ ResourcePool::~ResourcePool() {
|
| }
|
|
|
| scoped_ptr<ResourcePool::Resource> ResourcePool::AcquireResource(
|
| - gfx::Size size, GLenum format) {
|
| + gfx::Size size, GLenum format, bool use_16_bit_resource) {
|
| for (ResourceList::iterator it = unused_resources_.begin();
|
| it != unused_resources_.end(); ++it) {
|
| Resource* resource = *it;
|
| @@ -60,7 +62,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, use_16_bit_resource);
|
|
|
| // Extend all read locks on all resources until the resource is
|
| // finished being used, such that we know when resources are
|
|
|