summaryrefslogtreecommitdiffstats
path: root/libs/rs/rsAllocation.h
diff options
context:
space:
mode:
authorJason Sams <rjsams@android.com>2009-12-14 12:57:40 -0800
committerJason Sams <rjsams@android.com>2009-12-14 12:59:49 -0800
commit3b7d39bb51f851ddee441fa34884495217e477f9 (patch)
treeae1568c9e64155d2d164a5f80910145d603d772e /libs/rs/rsAllocation.h
parent97f2578e8cf154ba08f2f4219a8ff1cd97613192 (diff)
downloadframeworks_base-3b7d39bb51f851ddee441fa34884495217e477f9.zip
frameworks_base-3b7d39bb51f851ddee441fa34884495217e477f9.tar.gz
frameworks_base-3b7d39bb51f851ddee441fa34884495217e477f9.tar.bz2
Implement RS tracked defered texture and buffer object uploads.
Diffstat (limited to 'libs/rs/rsAllocation.h')
-rw-r--r--libs/rs/rsAllocation.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/libs/rs/rsAllocation.h b/libs/rs/rsAllocation.h
index 490abcf..f0b2122 100644
--- a/libs/rs/rsAllocation.h
+++ b/libs/rs/rsAllocation.h
@@ -46,10 +46,12 @@ public:
void * getPtr() const {return mPtr;}
const Type * getType() const {return mType.get();}
- void uploadToTexture(Context *rsc, uint32_t lodOffset = 0);
+ void deferedUploadToTexture(const Context *rsc, uint32_t lodOffset);
+ void uploadToTexture(const Context *rsc);
uint32_t getTextureID() const {return mTextureID;}
- void uploadToBufferObject();
+ void deferedUploadToBufferObject(const Context *rsc);
+ void uploadToBufferObject(const Context *rsc);
uint32_t getBufferObjectID() const {return mBufferID;}
@@ -70,6 +72,8 @@ public:
virtual void dumpLOGV(const char *prefix) const;
+ virtual void uploadCheck(const Context *rsc);
+
protected:
void sendDirty() const;
@@ -94,6 +98,7 @@ protected:
// Is this a legal structure to be used as a texture source.
// Initially this will require 1D or 2D and color data
bool mIsTexture;
+ uint32_t mTextureLOD;
uint32_t mTextureID;
// Is this a legal structure to be used as a vertex source.
@@ -101,6 +106,8 @@ protected:
// is allowed.
bool mIsVertexBuffer;
uint32_t mBufferID;
+
+ bool mUploadDefered;
};
}