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

Unified Diff: cc/resource_provider.h

Issue 11358080: Separate TransferableResource into own header (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove unused accessor Created 8 years, 1 month 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
« cc/DEPS ('K') | « cc/cc.gyp ('k') | cc/resource_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resource_provider.h
diff --git a/cc/resource_provider.h b/cc/resource_provider.h
index 6262d316c1023c745ba097aee76f0645292cb501..f7db99c9a4fe1b820880d79a83fa90a3b1fc679a 100644
--- a/cc/resource_provider.h
+++ b/cc/resource_provider.h
@@ -11,6 +11,7 @@
#include "cc/cc_export.h"
#include "cc/graphics_context.h"
#include "cc/texture_copier.h"
+#include "cc/transferable_resource.h"
#include "third_party/khronos/GLES2/gl2.h"
#include "third_party/skia/include/core/SkBitmap.h"
#include "third_party/skia/include/core/SkCanvas.h"
@@ -43,23 +44,6 @@ public:
GLTexture = 1,
Bitmap,
};
- struct Mailbox {
- GLbyte name[64];
- };
- struct TransferableResource {
- unsigned id;
- GLenum format;
- gfx::Size size;
- Mailbox mailbox;
- };
- typedef std::vector<TransferableResource> TransferableResourceArray;
- struct CC_EXPORT TransferableResourceList {
- TransferableResourceList();
- ~TransferableResourceList();
-
- TransferableResourceArray resources;
- unsigned syncPoint;
- };
static scoped_ptr<ResourceProvider> create(GraphicsContext*);
@@ -122,16 +106,16 @@ public:
// Prepares resources to be transfered to the parent, moving them to
// mailboxes and serializing meta-data into TransferableResources.
- // Resources are not removed from the ResourceProvider, but are markes as
+ // Resources are not removed from the ResourceProvider, but are marked as
// "in use".
- TransferableResourceList prepareSendToParent(const ResourceIdArray&);
+ void prepareSendToParent(const ResourceIdArray&, TransferableResourceList*);
// Prepares resources to be transfered back to the child, moving them to
// mailboxes and serializing meta-data into TransferableResources.
// Resources are removed from the ResourceProvider. Note: the resource IDs
// passed are in the parent namespace and will be translated to the child
// namespace when returned.
- TransferableResourceList prepareSendToChild(int child, const ResourceIdArray&);
+ void prepareSendToChild(int child, const ResourceIdArray&, TransferableResourceList*);
// Receives resources from a child, moving them from mailboxes. Resource IDs
// passed are in the child namespace, and will be translated to the parent
« cc/DEPS ('K') | « cc/cc.gyp ('k') | cc/resource_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698