diff options
author | Paul Kocialkowski <contact@paulk.fr> | 2013-10-28 20:12:01 +0100 |
---|---|---|
committer | Paul Kocialkowski <contact@paulk.fr> | 2013-10-28 20:12:01 +0100 |
commit | a5ed31ba3bdfb8cd761e87f3de86198c6233c3cc (patch) | |
tree | e2f014f9f005d31095cc8844f60963b47b26ff0b /services | |
parent | be09772e71a516759b5ce7fb9d2bab0d7227f291 (diff) | |
download | frameworks_base-a5ed31ba3bdfb8cd761e87f3de86198c6233c3cc.zip frameworks_base-a5ed31ba3bdfb8cd761e87f3de86198c6233c3cc.tar.gz frameworks_base-a5ed31ba3bdfb8cd761e87f3de86198c6233c3cc.tar.bz2 |
Adapt hardware renderer and screen rotation animation for SoftwareGL
Change-Id: I0d7809e7ae408c4762982599576be9a78d54a2dc
Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
Diffstat (limited to 'services')
-rw-r--r-- | services/java/com/android/server/wm/ScreenRotationAnimation.java | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/services/java/com/android/server/wm/ScreenRotationAnimation.java b/services/java/com/android/server/wm/ScreenRotationAnimation.java index 338d706..732a32d 100644 --- a/services/java/com/android/server/wm/ScreenRotationAnimation.java +++ b/services/java/com/android/server/wm/ScreenRotationAnimation.java @@ -230,14 +230,20 @@ class ScreenRotationAnimation { try { try { - if (WindowManagerService.DEBUG_SURFACE_TRACE) { - mSurface = new SurfaceTrace(session, "FreezeSurface", - mWidth, mHeight, - PixelFormat.OPAQUE, Surface.FX_SURFACE_SCREENSHOT | Surface.HIDDEN); - } else { + if (android.os.SystemProperties.get("ro.softwaregl").equals("true")) { mSurface = new Surface(session, "FreezeSurface", mWidth, mHeight, - PixelFormat.OPAQUE, Surface.FX_SURFACE_SCREENSHOT | Surface.HIDDEN); + PixelFormat.OPAQUE, Surface.FX_SURFACE_DIM | Surface.HIDDEN); + } else { + if (WindowManagerService.DEBUG_SURFACE_TRACE) { + mSurface = new SurfaceTrace(session, "FreezeSurface", + mWidth, mHeight, + PixelFormat.OPAQUE, Surface.FX_SURFACE_SCREENSHOT | Surface.HIDDEN); + } else { + mSurface = new Surface(session, "FreezeSurface", + mWidth, mHeight, + PixelFormat.OPAQUE, Surface.FX_SURFACE_SCREENSHOT | Surface.HIDDEN); + } } if (!mSurface.isValid()) { // Screenshot failed, punt. |