Loading services/surfaceflinger/BufferLayer.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -167,7 +167,7 @@ std::optional<renderengine::LayerSettings> BufferLayer::prepareClientComposition } return std::nullopt; } bool blackOutLayer = (isProtected() && !targetSettings.supportProtectedContent) || bool blackOutLayer = (isProtected() && !targetSettings.supportsProtectedContent) || (isSecure() && !targetSettings.isSecure); const State& s(getDrawingState()); auto& layer = *result; Loading services/surfaceflinger/CompositionEngine/Android.bp +1 −0 Original line number Diff line number Diff line Loading @@ -94,6 +94,7 @@ cc_test { "tests/LayerTest.cpp", "tests/MockHWC2.cpp", "tests/MockHWComposer.cpp", "tests/MockPowerAdvisor.cpp", "tests/OutputTest.cpp", "tests/OutputLayerTest.cpp", "tests/RenderSurfaceTest.cpp", Loading services/surfaceflinger/CompositionEngine/include/compositionengine/DisplayCreationArgs.h +9 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ #include <optional> #include "DisplayHardware/DisplayIdentification.h" #include "DisplayHardware/PowerAdvisor.h" namespace android::compositionengine { Loading @@ -37,6 +38,10 @@ struct DisplayCreationArgs { // Identifies the display to the HWC, if composition is supported by it std::optional<DisplayId> displayId; // Optional pointer to the power advisor interface, if one is needed for // this display. Hwc2::PowerAdvisor* powerAdvisor = nullptr; }; /** Loading Loading @@ -68,6 +73,10 @@ public: mArgs.displayId = displayId; return *this; } DisplayCreationArgsBuilder& setPowerAdvisor(Hwc2::PowerAdvisor* powerAdvisor) { mArgs.powerAdvisor = powerAdvisor; return *this; } private: DisplayCreationArgs mArgs; Loading services/surfaceflinger/CompositionEngine/include/compositionengine/LayerFE.h +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ public: const bool isSecure; // If set to true, the target buffer has protected content support. const bool supportProtectedContent; const bool supportsProtectedContent; // Modified by each call to prepareClientComposition to indicate the // region of the target buffer that should be cleared. Loading services/surfaceflinger/CompositionEngine/include/compositionengine/LayerFECompositionState.h +6 −0 Original line number Diff line number Diff line Loading @@ -116,6 +116,12 @@ struct LayerFECompositionState { // The color transform mat4 colorTransform; bool colorTransformIsIdentity{true}; // True if the layer is completely opaque bool isOpaque{true}; // True if the layer has protected content bool hasProtectedContent{false}; }; } // namespace android::compositionengine Loading
services/surfaceflinger/BufferLayer.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -167,7 +167,7 @@ std::optional<renderengine::LayerSettings> BufferLayer::prepareClientComposition } return std::nullopt; } bool blackOutLayer = (isProtected() && !targetSettings.supportProtectedContent) || bool blackOutLayer = (isProtected() && !targetSettings.supportsProtectedContent) || (isSecure() && !targetSettings.isSecure); const State& s(getDrawingState()); auto& layer = *result; Loading
services/surfaceflinger/CompositionEngine/Android.bp +1 −0 Original line number Diff line number Diff line Loading @@ -94,6 +94,7 @@ cc_test { "tests/LayerTest.cpp", "tests/MockHWC2.cpp", "tests/MockHWComposer.cpp", "tests/MockPowerAdvisor.cpp", "tests/OutputTest.cpp", "tests/OutputLayerTest.cpp", "tests/RenderSurfaceTest.cpp", Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/DisplayCreationArgs.h +9 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ #include <optional> #include "DisplayHardware/DisplayIdentification.h" #include "DisplayHardware/PowerAdvisor.h" namespace android::compositionengine { Loading @@ -37,6 +38,10 @@ struct DisplayCreationArgs { // Identifies the display to the HWC, if composition is supported by it std::optional<DisplayId> displayId; // Optional pointer to the power advisor interface, if one is needed for // this display. Hwc2::PowerAdvisor* powerAdvisor = nullptr; }; /** Loading Loading @@ -68,6 +73,10 @@ public: mArgs.displayId = displayId; return *this; } DisplayCreationArgsBuilder& setPowerAdvisor(Hwc2::PowerAdvisor* powerAdvisor) { mArgs.powerAdvisor = powerAdvisor; return *this; } private: DisplayCreationArgs mArgs; Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/LayerFE.h +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ public: const bool isSecure; // If set to true, the target buffer has protected content support. const bool supportProtectedContent; const bool supportsProtectedContent; // Modified by each call to prepareClientComposition to indicate the // region of the target buffer that should be cleared. Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/LayerFECompositionState.h +6 −0 Original line number Diff line number Diff line Loading @@ -116,6 +116,12 @@ struct LayerFECompositionState { // The color transform mat4 colorTransform; bool colorTransformIsIdentity{true}; // True if the layer is completely opaque bool isOpaque{true}; // True if the layer has protected content bool hasProtectedContent{false}; }; } // namespace android::compositionengine