Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1288)

Unified Diff: cc/resource_pool.h

Issue 12471007: Part 8 of cc/ directory shuffles: resources (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/resource.cc ('k') | cc/resource_pool.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resource_pool.h
diff --git a/cc/resource_pool.h b/cc/resource_pool.h
deleted file mode 100644
index b477aa61ea4f8759dc3af79676503fa63ccfa16c..0000000000000000000000000000000000000000
--- a/cc/resource_pool.h
+++ /dev/null
@@ -1,63 +0,0 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CC_RESOURCE_POOL_H_
-#define CC_RESOURCE_POOL_H_
-
-#include <list>
-
-#include "base/memory/scoped_ptr.h"
-#include "cc/base/cc_export.h"
-#include "cc/output/renderer.h"
-#include "cc/resource.h"
-
-namespace cc {
-class ResourceProvider;
-
-class CC_EXPORT ResourcePool {
- public:
- class CC_EXPORT Resource : public cc::Resource {
- public:
- Resource(ResourceProvider* resource_provider,
- const gfx::Size& size,
- GLenum format);
- ~Resource();
-
- private:
- ResourceProvider* resource_provider_;
-
- DISALLOW_COPY_AND_ASSIGN(Resource);
- };
-
- static scoped_ptr<ResourcePool> Create(ResourceProvider* resource_provider) {
- return make_scoped_ptr(new ResourcePool(resource_provider));
- }
-
- virtual ~ResourcePool();
-
- ResourceProvider* resource_provider() { return resource_provider_; };
-
- scoped_ptr<ResourcePool::Resource> AcquireResource(
- const gfx::Size&, GLenum format);
- void ReleaseResource(scoped_ptr<ResourcePool::Resource>);
-
- void SetMaxMemoryUsageBytes(size_t max_memory_usage_bytes);
-
- protected:
- ResourcePool(ResourceProvider* resource_provider);
-
- private:
- ResourceProvider* resource_provider_;
- size_t max_memory_usage_bytes_;
- size_t memory_usage_bytes_;
-
- typedef std::list<Resource*> ResourceList;
- ResourceList resources_;
-
- DISALLOW_COPY_AND_ASSIGN(ResourcePool);
-};
-
-} // namespace cc
-
-#endif // CC_RESOURCE_POOL_H_
« no previous file with comments | « cc/resource.cc ('k') | cc/resource_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698