diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/camera/PhotoUI.java | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/com/android/camera/PhotoUI.java b/src/com/android/camera/PhotoUI.java index 3b4d04dc7..58751efbf 100644 --- a/src/com/android/camera/PhotoUI.java +++ b/src/com/android/camera/PhotoUI.java @@ -126,13 +126,6 @@ public class PhotoUI implements PieListener, int bottom, int oldLeft, int oldTop, int oldRight, int oldBottom) { int width = right - left; int height = bottom - top; - // Full-screen preview - int w = width; - int h = height; - if (CameraUtil.getDisplayRotation(mActivity) % 180 != 0) { - w = height; - h = width; - } if (mPreviewWidth != width || mPreviewHeight != height) { mPreviewWidth = width; mPreviewHeight = height; @@ -266,6 +259,11 @@ public class PhotoUI implements PieListener, Log.v(TAG, "SurfaceTexture ready."); mSurfaceTexture = surface; mController.onPreviewUIReady(); + // Workaround for b/11168275, see b/10981460 for more details + if (mPreviewWidth != 0 && mPreviewHeight != 0) { + // Re-apply transform matrix for new surface texture + setTransformMatrix(mPreviewWidth, mPreviewHeight); + } } @Override |