aboutsummaryrefslogtreecommitdiffstats
path: root/src/org/cyanogenmod/wallpapers/photophase
diff options
context:
space:
mode:
authorJorge Ruesga <jorge@ruesga.com>2013-08-20 17:25:53 +0200
committerJorge Ruesga <jorge@ruesga.com>2013-08-20 17:25:53 +0200
commit9f78861e1caf977a61570a225dd2ab56afa19a32 (patch)
tree2be5300c578e0f58226d85a39dc5ba9ede6df3df /src/org/cyanogenmod/wallpapers/photophase
parented09bbd4f29dc28dcfb98147143dfcdc3291f52d (diff)
downloadandroid_packages_wallpapers_PhotoPhase-9f78861e1caf977a61570a225dd2ab56afa19a32.tar.gz
android_packages_wallpapers_PhotoPhase-9f78861e1caf977a61570a225dd2ab56afa19a32.tar.bz2
android_packages_wallpapers_PhotoPhase-9f78861e1caf977a61570a225dd2ab56afa19a32.zip
Rename handle var name
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
Diffstat (limited to 'src/org/cyanogenmod/wallpapers/photophase')
-rw-r--r--src/org/cyanogenmod/wallpapers/photophase/utils/GLESUtil.java20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/org/cyanogenmod/wallpapers/photophase/utils/GLESUtil.java b/src/org/cyanogenmod/wallpapers/photophase/utils/GLESUtil.java
index a62afe7..4707431 100644
--- a/src/org/cyanogenmod/wallpapers/photophase/utils/GLESUtil.java
+++ b/src/org/cyanogenmod/wallpapers/photophase/utils/GLESUtil.java
@@ -412,16 +412,16 @@ public final class GLESUtil {
int num = effect == null ? 1 : 2;
- int[] textureNames = new int[num];
- GLES20.glGenTextures(num, textureNames, 0);
+ int[] textureHandles = new int[num];
+ GLES20.glGenTextures(num, textureHandles, 0);
GLESUtil.glesCheckError("glGenTextures");
- if (textureNames[0] <= 0 || (effect != null && textureNames[1] <= 0)) {
+ if (textureHandles[0] <= 0 || (effect != null && textureHandles[1] <= 0)) {
Log.e(TAG, "Failed to generate a valid texture");
return new GLESTextureInfo();
}
// Bind the texture to the name
- GLES20.glBindTexture(GLES20.GL_TEXTURE_2D, textureNames[0]);
+ GLES20.glBindTexture(GLES20.GL_TEXTURE_2D, textureHandles[0]);
GLESUtil.glesCheckError("glBindTexture");
// Set the texture properties
@@ -436,27 +436,27 @@ public final class GLESUtil {
// Load the texture
GLUtils.texImage2D(GLES20.GL_TEXTURE_2D, 0, bitmap, 0);
- if (!GLES20.glIsTexture(textureNames[0])) {
+ if (!GLES20.glIsTexture(textureHandles[0])) {
Log.e(TAG, "Failed to load a valid texture");
return new GLESTextureInfo();
}
// Has a effect?
- int handle = textureNames[0];
+ int handle = textureHandles[0];
if (effect != null) {
// Apply the effect (we need a thread-safe call here)
synchronized (sSync) {
// No more than 1024 (the minimum supported by all the gles20 devices)
int w = Math.min(dimen.width(), 1024);
int h = Math.min(dimen.width(), 1024);
- effect.apply(textureNames[0], w, h, textureNames[1]);
+ effect.apply(textureHandles[0], w, h, textureHandles[1]);
}
- handle = textureNames[1];
+ handle = textureHandles[1];
// Delete the unused texture
- int[] textures = {textureNames[0]};
+ int[] textures = {textureHandles[0]};
GLES20.glDeleteTextures(1, textures, 0);
- GLESUtil.glesCheckError("glTexParameteri");
+ GLESUtil.glesCheckError("glDeleteTextures");
}
// Return the texture handle identifier and the associated info