summaryrefslogtreecommitdiff
path: root/include/gui/Surface.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/gui/Surface.h')
-rw-r--r--include/gui/Surface.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/include/gui/Surface.h b/include/gui/Surface.h
index 451bd68f66..43b8d965d2 100644
--- a/include/gui/Surface.h
+++ b/include/gui/Surface.h
@@ -33,6 +33,8 @@ struct ANativeWindow_Buffer;
namespace android {
+class ISurfaceComposer;
+
/*
* An implementation of ANativeWindow that feeds graphics buffers into a
* BufferQueue.
@@ -66,7 +68,8 @@ public:
* the controlledByApp flag indicates that this Surface (producer) is
* controlled by the application. This flag is used at connect time.
*/
- explicit Surface(const sp<IGraphicBufferProducer>& bufferProducer, bool controlledByApp = false);
+ explicit Surface(const sp<IGraphicBufferProducer>& bufferProducer,
+ bool controlledByApp = false);
/* getIGraphicBufferProducer() returns the IGraphicBufferProducer this
* Surface was created with. Usually it's an error to use the
@@ -152,6 +155,9 @@ public:
protected:
virtual ~Surface();
+ // Virtual for testing.
+ virtual sp<ISurfaceComposer> composerService() const;
+
private:
// can't be copied
Surface& operator = (const Surface& rhs);
@@ -245,7 +251,6 @@ protected:
enum { NUM_BUFFER_SLOTS = BufferQueue::NUM_BUFFER_SLOTS };
enum { DEFAULT_FORMAT = PIXEL_FORMAT_RGBA_8888 };
-private:
void querySupportedTimestampsLocked() const;
void freeAllBuffers();
@@ -399,7 +404,7 @@ private:
// A cached copy of the FrameEventHistory maintained by the consumer.
bool mEnableFrameTimestamps = false;
- ProducerFrameEventHistory mFrameEventHistory;
+ std::unique_ptr<ProducerFrameEventHistory> mFrameEventHistory;
};
namespace view {