diff options
Diffstat (limited to 'core/java/android/app/ActivityManager.java')
-rw-r--r-- | core/java/android/app/ActivityManager.java | 38 |
1 files changed, 21 insertions, 17 deletions
diff --git a/core/java/android/app/ActivityManager.java b/core/java/android/app/ActivityManager.java index e4e0d8e..e5c0e87 100644 --- a/core/java/android/app/ActivityManager.java +++ b/core/java/android/app/ActivityManager.java @@ -381,25 +381,29 @@ public class ActivityManager { * @hide */ static public boolean isHighEndGfx() { - MemInfoReader reader = new MemInfoReader(); - reader.readMemInfo(); - if (reader.getTotalSize() >= (512*1024*1024)) { - // If the device has at least 512MB RAM available to the kernel, - // we can afford the overhead of graphics acceleration. - return true; - } + if (SystemProperties.get("ro.softwaregl").equals("true")) { + return false; + } else { + MemInfoReader reader = new MemInfoReader(); + reader.readMemInfo(); + if (reader.getTotalSize() >= (512*1024*1024)) { + // If the device has at least 512MB RAM available to the kernel, + // we can afford the overhead of graphics acceleration. + return true; + } - Display display = DisplayManagerGlobal.getInstance().getRealDisplay( - Display.DEFAULT_DISPLAY); - Point p = new Point(); - display.getRealSize(p); - int pixels = p.x * p.y; - if (pixels >= (1024*600)) { - // If this is a sufficiently large screen, then there are enough - // pixels on it that we'd really like to use hw drawing. - return true; + Display display = DisplayManagerGlobal.getInstance().getRealDisplay( + Display.DEFAULT_DISPLAY); + Point p = new Point(); + display.getRealSize(p); + int pixels = p.x * p.y; + if (pixels >= (1024*600)) { + // If this is a sufficiently large screen, then there are enough + // pixels on it that we'd really like to use hw drawing. + return true; + } + return false; } - return false; } /** |