diff options
| author | 2009-11-03 15:20:53 -0800 | |
|---|---|---|
| committer | 2009-11-03 15:20:53 -0800 | |
| commit | 03fa848afd16ee678e2d04ec824794893f199804 (patch) | |
| tree | 5051b3c8f957864af13f2680e00158dfedb8f310 /libs/rs/rsAllocation.cpp | |
| parent | 11335d98fd28c6c10967055afb1862e6e44e8e80 (diff) | |
| parent | ebca5eec1c1e0a0cfc4ad25d1aacb1a3e30e44ef (diff) | |
am ebca5eec: am 83665194: Merge change I9d5e03db into eclair
Merge commit 'ebca5eec1c1e0a0cfc4ad25d1aacb1a3e30e44ef' into eclair-mr2-plus-aosp
* commit 'ebca5eec1c1e0a0cfc4ad25d1aacb1a3e30e44ef':
Fix RS bugs. We were holding a pointer to the script text from the java vm. Move freeing of objects to before context teardown to allow allocations to clean up their data.
Diffstat (limited to 'libs/rs/rsAllocation.cpp')
| -rw-r--r-- | libs/rs/rsAllocation.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/libs/rs/rsAllocation.cpp b/libs/rs/rsAllocation.cpp index 2cbfe17d40a9..38cec64e3753 100644 --- a/libs/rs/rsAllocation.cpp +++ b/libs/rs/rsAllocation.cpp @@ -54,6 +54,17 @@ Allocation::~Allocation() { free(mPtr); mPtr = NULL; + + if (mBufferID) { + // Causes a SW crash.... + //LOGV(" mBufferID %i", mBufferID); + //glDeleteBuffers(1, &mBufferID); + //mBufferID = 0; + } + if (mTextureID) { + glDeleteTextures(1, &mTextureID); + mTextureID = 0; + } } void Allocation::setCpuWritable(bool) |