Allow disabling layer rotation during screenshots
Add the ability to ignore layers' transformation matrices during
screenshot capture, which will allow the window manager to capture
unrotated images for recents during the device rotation animation.
Bug: 11805195
Change-Id: I854d87bc84ca06ef9a054a454af1c080ee66fbb8
diff --git a/include/gui/SurfaceComposerClient.h b/include/gui/SurfaceComposerClient.h
index e982bcd..350b987 100644
--- a/include/gui/SurfaceComposerClient.h
+++ b/include/gui/SurfaceComposerClient.h
@@ -164,7 +164,8 @@
const sp<IBinder>& display,
const sp<IGraphicBufferProducer>& producer,
uint32_t reqWidth, uint32_t reqHeight,
- uint32_t minLayerZ, uint32_t maxLayerZ);
+ uint32_t minLayerZ, uint32_t maxLayerZ,
+ bool useIdentityTransform);
private:
mutable sp<CpuConsumer> mCpuConsumer;
@@ -177,12 +178,14 @@
~ScreenshotClient();
// frees the previous screenshot and capture a new one
- status_t update(const sp<IBinder>& display);
- status_t update(const sp<IBinder>& display,
- uint32_t reqWidth, uint32_t reqHeight);
+ status_t update(const sp<IBinder>& display, bool useIdentityTransform);
status_t update(const sp<IBinder>& display,
uint32_t reqWidth, uint32_t reqHeight,
- uint32_t minLayerZ, uint32_t maxLayerZ);
+ bool useIdentityTransform);
+ status_t update(const sp<IBinder>& display,
+ uint32_t reqWidth, uint32_t reqHeight,
+ uint32_t minLayerZ, uint32_t maxLayerZ,
+ bool useIdentityTransform);
sp<CpuConsumer> getCpuConsumer() const;