Expose IGBP getter
Useful for comparing a SurfaceControl to an existing Surface,
but without calling getSurface which may cause the allocation of
an as of yet unexisting Surface wrapper.
Bug: 122588130
Test: None
Change-Id: I5742bf6af06bd48013a2418b583de8eeeecba2df
diff --git a/libs/gui/SurfaceControl.cpp b/libs/gui/SurfaceControl.cpp
index 8e500a4..008f520 100644
--- a/libs/gui/SurfaceControl.cpp
+++ b/libs/gui/SurfaceControl.cpp
@@ -177,6 +177,12 @@
return mHandle;
}
+sp<IGraphicBufferProducer> SurfaceControl::getIGraphicBufferProducer() const
+{
+ Mutex::Autolock _l(mLock);
+ return mGraphicBufferProducer;
+}
+
sp<SurfaceComposerClient> SurfaceControl::getClient() const
{
return mClient;