diff options
author | Jason Sams <rjsams@android.com> | 2010-12-15 02:11:37 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2010-12-15 02:11:37 -0800 |
commit | 6e6b7d89e26dea883777a39ca32b84e97354c814 (patch) | |
tree | 04ae0f13e44c4bbb4cd0e2ae855d3ed9c0cca983 | |
parent | 92c671bb7fcc492c62256a477729fca8faf30f6b (diff) | |
parent | 1316636ac28004152cffcb1c8795997c7a33765d (diff) | |
download | android_packages_wallpapers_MagicSmoke-6e6b7d89e26dea883777a39ca32b84e97354c814.tar.gz android_packages_wallpapers_MagicSmoke-6e6b7d89e26dea883777a39ca32b84e97354c814.tar.bz2 android_packages_wallpapers_MagicSmoke-6e6b7d89e26dea883777a39ca32b84e97354c814.zip |
Merge "Update for Allocation changes"
-rw-r--r-- | src/com/android/magicsmoke/MagicSmokeRS.java | 9 | ||||
-rw-r--r-- | src/com/android/magicsmoke/clouds.rs | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/src/com/android/magicsmoke/MagicSmokeRS.java b/src/com/android/magicsmoke/MagicSmokeRS.java index eb06855..268771f 100644 --- a/src/com/android/magicsmoke/MagicSmokeRS.java +++ b/src/com/android/magicsmoke/MagicSmokeRS.java @@ -262,8 +262,13 @@ class MagicSmokeRS extends RenderScriptScene implements OnSharedPreferenceChange int pixels[] = new int[65536]; in.getPixels(pixels, 0, 256, 0, 0, 256, 256); - mRealTextures[index] = Allocation.createTyped(mRS, mTextureType); - mSourceTextures[index] = Allocation.createTyped(mRS, mTextureType); + mRealTextures[index] = Allocation.createTyped(mRS, mTextureType, + Allocation.MipmapControl.MIPMAP_NONE, + Allocation.USAGE_SCRIPT | + Allocation.USAGE_GRAPHICS_TEXTURE); + mSourceTextures[index] = Allocation.createTyped(mRS, mTextureType, + Allocation.MipmapControl.MIPMAP_NONE, + Allocation.USAGE_SCRIPT); mSourceTextures[index].copyFrom(pixels); in.recycle(); } diff --git a/src/com/android/magicsmoke/clouds.rs b/src/com/android/magicsmoke/clouds.rs index a22e5c7..cc81e57 100644 --- a/src/com/android/magicsmoke/clouds.rs +++ b/src/com/android/magicsmoke/clouds.rs @@ -337,7 +337,7 @@ static void makeTexture(int *src, int *dst, rs_allocation rsid) { } } - rsgUploadToTexture(rsid, 0); + rsgAllocationSyncAll(rsid); } static void makeTextures() { |