From 86bdb2f918ffd238d6e0d1ae1f95af882f04d6cb Mon Sep 17 00:00:00 2001 From: Mathias Agopian Date: Wed, 8 Dec 2010 17:23:18 -0800 Subject: [PATCH] fix [3260137] Sometimes front-facing camera mirroring is wrong make sure to take the buffer's orientation into account. Change-Id: I9fef89e66368ad2dec1cb8c7b77ac2b3b4858efb --- services/surfaceflinger/Layer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp index fe4379dc5..85fd2c7f3 100644 --- a/services/surfaceflinger/Layer.cpp +++ b/services/surfaceflinger/Layer.cpp @@ -204,7 +204,8 @@ void Layer::setGeometry(hwc_layer_t* hwcl) return; } - hwcl->transform = mOrientation; + Transform tr(Transform(mOrientation) * Transform(mBufferTransform)); + hwcl->transform = tr.getOrientation(); if (needsBlending()) { hwcl->blending = mPremultipliedAlpha ?