summaryrefslogtreecommitdiffstats
path: root/tests/HwAccelerationTest/src
diff options
context:
space:
mode:
authorRomain Guy <romainguy@google.com>2012-07-24 16:24:56 -0700
committerRomain Guy <romainguy@google.com>2012-07-24 16:41:21 -0700
commit786fc93d71b833ab6b02b0c7ea5e30f25cceeedf (patch)
tree7a33afdfc52077e9f9665acc6d6072cb23e3d9d2 /tests/HwAccelerationTest/src
parentd8031f0e8c0977ff04aeb2164afacb2434dc0775 (diff)
downloadframeworks_base-786fc93d71b833ab6b02b0c7ea5e30f25cceeedf.zip
frameworks_base-786fc93d71b833ab6b02b0c7ea5e30f25cceeedf.tar.gz
frameworks_base-786fc93d71b833ab6b02b0c7ea5e30f25cceeedf.tar.bz2
Make HardwareRenderer able to target generic Surface objects
Change-Id: I4b7199a1eb30e0df354ae12c4819adc69db5df40
Diffstat (limited to 'tests/HwAccelerationTest/src')
-rw-r--r--tests/HwAccelerationTest/src/com/android/test/hwui/GLTextureViewActivity.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/HwAccelerationTest/src/com/android/test/hwui/GLTextureViewActivity.java b/tests/HwAccelerationTest/src/com/android/test/hwui/GLTextureViewActivity.java
index 0e75b80..733e44f 100644
--- a/tests/HwAccelerationTest/src/com/android/test/hwui/GLTextureViewActivity.java
+++ b/tests/HwAccelerationTest/src/com/android/test/hwui/GLTextureViewActivity.java
@@ -22,7 +22,6 @@ import android.app.Activity;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
-import android.graphics.Matrix;
import android.graphics.SurfaceTexture;
import android.opengl.GLUtils;
import android.os.Bundle;
@@ -278,7 +277,7 @@ public class GLTextureViewActivity extends Activity implements TextureView.Surfa
return texture;
}
- private int buildProgram(String vertex, String fragment) {
+ private static int buildProgram(String vertex, String fragment) {
int vertexShader = buildShader(vertex, GL_VERTEX_SHADER);
if (vertexShader == 0) return 0;
@@ -309,7 +308,7 @@ public class GLTextureViewActivity extends Activity implements TextureView.Surfa
return program;
}
- private int buildShader(String source, int type) {
+ private static int buildShader(String source, int type) {
int shader = glCreateShader(type);
glShaderSource(shader, source);
@@ -337,7 +336,7 @@ public class GLTextureViewActivity extends Activity implements TextureView.Surfa
}
}
- private void checkGlError() {
+ private static void checkGlError() {
int error = glGetError();
if (error != GL_NO_ERROR) {
Log.w(LOG_TAG, "GL error = 0x" + Integer.toHexString(error));
@@ -420,7 +419,7 @@ public class GLTextureViewActivity extends Activity implements TextureView.Surfa
return null;
}
- private int[] getConfig() {
+ private static int[] getConfig() {
return new int[] {
EGL10.EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT,
EGL10.EGL_RED_SIZE, 8,