SF: Start restructuring display creation
Create the compositionengine::Display first thing, outside of
DisplayDevice, and pass it in as part of creating the DisplayDevice,
rather than creating it internal to DisplayDevice.
Also to start, move the logic to allocate a DisplayId for a HWC backed
virtual display into the CompositionEngine class.
This is a first step to moving the internal setup of the display to
CompositionEngine, and eventually eliminating DisplayDevice entirely, as
it is but a thin wrapper around the other class.
DisplayTransactionTest is adjusted so the dummy created DisplayDevices
have an appropriate compositionengine::Display.
Test: atest libsurfaceflinger_unittest libcompositionengine_test
Bug: 142831417
Change-Id: I8417682f4ead7b550a8973d4716c627e31b07b6e
Merged-In: I8417682f4ead7b550a8973d4716c627e31b07b6e
(cherry picked from commit 9370a480fc0a99575a57500b03c9c45d9e52bc1d)
diff --git a/services/surfaceflinger/SurfaceFlingerFactory.h b/services/surfaceflinger/SurfaceFlingerFactory.h
index 209bd0c..6f4fcc6 100644
--- a/services/surfaceflinger/SurfaceFlingerFactory.h
+++ b/services/surfaceflinger/SurfaceFlingerFactory.h
@@ -83,7 +83,7 @@
virtual sp<StartPropertySetThread> createStartPropertySetThread(
bool timestampPropertyValue) = 0;
- virtual sp<DisplayDevice> createDisplayDevice(DisplayDeviceCreationArgs&&) = 0;
+ virtual sp<DisplayDevice> createDisplayDevice(DisplayDeviceCreationArgs&) = 0;
virtual sp<GraphicBuffer> createGraphicBuffer(uint32_t width, uint32_t height,
PixelFormat format, uint32_t layerCount,
uint64_t usage, std::string requestorName) = 0;