summaryrefslogtreecommitdiffstats
path: root/opengl/java
diff options
context:
space:
mode:
authorJack Palevich <jackpal@google.com>2012-03-19 11:17:40 -0700
committerJack Palevich <jackpal@google.com>2012-03-19 11:17:40 -0700
commit8b854cd74bd29b6bb0b4c681490a3a97b1739289 (patch)
tree50be755ac4b7a61215892eea9ef0289fdbfb1180 /opengl/java
parent6c25ffb77069a9f39884b8e91e1810254c3e2f03 (diff)
downloadframeworks_base-8b854cd74bd29b6bb0b4c681490a3a97b1739289.zip
frameworks_base-8b854cd74bd29b6bb0b4c681490a3a97b1739289.tar.gz
frameworks_base-8b854cd74bd29b6bb0b4c681490a3a97b1739289.tar.bz2
Remove EGL context limit for Adreno GPUs.
This change allows Adreno GPUs to have multiple EGL contexts. We had to limit this in earlier versions of Android due to limitations in the Adreno GPU driver (only 8 EGL contexts allowed system wide.) That brand of GPU has improved its EGL drivers to support multiple EGL contexts in more recent versions of their drivers used on more recent versions of Android. Bug: 6142005 Change-Id: Id3030466be9a3d9fbe728f1785378c1f05da98fe
Diffstat (limited to 'opengl/java')
-rw-r--r--opengl/java/android/opengl/GLSurfaceView.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/opengl/java/android/opengl/GLSurfaceView.java b/opengl/java/android/opengl/GLSurfaceView.java
index 8e2294c..3c9fd1d 100644
--- a/opengl/java/android/opengl/GLSurfaceView.java
+++ b/opengl/java/android/opengl/GLSurfaceView.java
@@ -1841,7 +1841,7 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
! renderer.startsWith(kMSM7K_RENDERER_PREFIX);
notifyAll();
}
- mLimitedGLESContexts = !mMultipleGLESContextsAllowed || renderer.startsWith(kADRENO);
+ mLimitedGLESContexts = !mMultipleGLESContextsAllowed;
if (LOG_SURFACE) {
Log.w(TAG, "checkGLDriver renderer = \"" + renderer + "\" multipleContextsAllowed = "
+ mMultipleGLESContextsAllowed
@@ -1867,6 +1867,11 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
}
}
+ /**
+ * This check was required for some pre-Android-3.0 hardware. Android 3.0 provides
+ * support for hardware-accelerated views, therefore multiple EGL contexts are
+ * supported on all Android 3.0+ EGL drivers.
+ */
private boolean mGLESVersionCheckComplete;
private int mGLESVersion;
private boolean mGLESDriverCheckComplete;
@@ -1875,7 +1880,6 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
private static final int kGLES_20 = 0x20000;
private static final String kMSM7K_RENDERER_PREFIX =
"Q3Dimension MSM7500 ";
- private static final String kADRENO = "Adreno";
private GLThread mEglOwner;
}