summaryrefslogtreecommitdiffstats
path: root/services/surfaceflinger/Layer.cpp
diff options
context:
space:
mode:
authorMathias Agopian <mathias@google.com>2010-12-07 21:00:25 -0800
committerMathias Agopian <mathias@google.com>2010-12-07 21:16:14 -0800
commite24cc7a38dce071267156a9345e9ec3f27890daf (patch)
treec6394c3f08a6538160e7ae0747e374bf20d03df5 /services/surfaceflinger/Layer.cpp
parentdb13e364f967113c27383ed9bd5f2a10f46f05c9 (diff)
downloadframeworks_native-e24cc7a38dce071267156a9345e9ec3f27890daf.zip
frameworks_native-e24cc7a38dce071267156a9345e9ec3f27890daf.tar.gz
frameworks_native-e24cc7a38dce071267156a9345e9ec3f27890daf.tar.bz2
[317580] fix issue where the screen wouldn't be rotated properly in bypass mode
In some situations, the screen transformation would not be applied while in bypass mode. Change-Id: I3d6dd52e4c12b11aae97b54bf8e2322536eee37f
Diffstat (limited to 'services/surfaceflinger/Layer.cpp')
-rw-r--r--services/surfaceflinger/Layer.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index a18f473..3a8690e 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -466,6 +466,18 @@ bool Layer::setBypass(bool enable)
return true;
}
+void Layer::updateBuffersOrientation()
+{
+ sp<GraphicBuffer> buffer(getBypassBuffer());
+ if (buffer != NULL && mOrientation != buffer->transform) {
+ ClientRef::Access sharedClient(mUserClientRef);
+ SharedBufferServer* lcblk(sharedClient.get());
+ if (lcblk) { // all buffers need reallocation
+ lcblk->reallocateAll();
+ }
+ }
+}
+
uint32_t Layer::doTransaction(uint32_t flags)
{
const Layer::State& front(drawingState());