Loading services/surfaceflinger/CompositionEngine/include/compositionengine/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -74,7 +74,7 @@ public: // Recalculates the state of the output layer from the output-independent // Recalculates the state of the output layer from the output-independent // layer. If includeGeometry is false, the geometry state can be skipped. // layer. If includeGeometry is false, the geometry state can be skipped. virtual void updateCompositionState(bool includeGeometry) = 0; virtual void updateCompositionState(bool includeGeometry, bool forceClientComposition) = 0; // Writes the geometry state to the HWC, or does nothing if this layer does // Writes the geometry state to the HWC, or does nothing if this layer does // not use the HWC. If includeGeometry is false, the geometry state can be // not use the HWC. If includeGeometry is false, the geometry state can be Loading services/surfaceflinger/CompositionEngine/include/compositionengine/impl/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,7 @@ public: void setHwcLayer(std::shared_ptr<HWC2::Layer>) override; void setHwcLayer(std::shared_ptr<HWC2::Layer>) override; void updateCompositionState(bool) override; void updateCompositionState(bool includeGeometry, bool forceClientComposition) override; void writeStateToHWC(bool) override; void writeStateToHWC(bool) override; void writeCursorPositionToHWC() const override; void writeCursorPositionToHWC() const override; Loading services/surfaceflinger/CompositionEngine/include/compositionengine/mock/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -40,7 +40,7 @@ public: MOCK_CONST_METHOD0(getState, const impl::OutputLayerCompositionState&()); MOCK_CONST_METHOD0(getState, const impl::OutputLayerCompositionState&()); MOCK_METHOD0(editState, impl::OutputLayerCompositionState&()); MOCK_METHOD0(editState, impl::OutputLayerCompositionState&()); MOCK_METHOD1(updateCompositionState, void(bool)); MOCK_METHOD2(updateCompositionState, void(bool, bool)); MOCK_METHOD1(writeStateToHWC, void(bool)); MOCK_METHOD1(writeStateToHWC, void(bool)); MOCK_CONST_METHOD0(writeCursorPositionToHWC, void()); MOCK_CONST_METHOD0(writeCursorPositionToHWC, void()); Loading services/surfaceflinger/CompositionEngine/src/Output.cpp +2 −5 Original line number Original line Diff line number Diff line Loading @@ -552,11 +552,8 @@ void Output::updateAndWriteCompositionState( ALOGV(__FUNCTION__); ALOGV(__FUNCTION__); for (auto* layer : getOutputLayersOrderedByZ()) { for (auto* layer : getOutputLayersOrderedByZ()) { if (refreshArgs.devOptForceClientComposition) { layer->updateCompositionState(refreshArgs.updatingGeometryThisFrame, layer->editState().forceClientComposition = true; refreshArgs.devOptForceClientComposition); } layer->updateCompositionState(refreshArgs.updatingGeometryThisFrame); // Send the updated state to the HWC, if appropriate. // Send the updated state to the HWC, if appropriate. layer->writeStateToHWC(refreshArgs.updatingGeometryThisFrame); layer->writeStateToHWC(refreshArgs.updatingGeometryThisFrame); Loading services/surfaceflinger/CompositionEngine/src/OutputLayer.cpp +3 −2 Original line number Original line Diff line number Diff line Loading @@ -259,7 +259,7 @@ uint32_t OutputLayer::calculateOutputRelativeBufferTransform() const { return transform.getOrientation(); return transform.getOrientation(); } // namespace impl } // namespace impl void OutputLayer::updateCompositionState(bool includeGeometry) { void OutputLayer::updateCompositionState(bool includeGeometry, bool forceClientComposition) { const auto& layerFEState = getLayer().getFEState(); const auto& layerFEState = getLayer().getFEState(); const auto& outputState = getOutput().getState(); const auto& outputState = getOutput().getState(); const auto& profile = *getOutput().getDisplayColorProfile(); const auto& profile = *getOutput().getDisplayColorProfile(); Loading Loading @@ -294,7 +294,8 @@ void OutputLayer::updateCompositionState(bool includeGeometry) { // These are evaluated every frame as they can potentially change at any // These are evaluated every frame as they can potentially change at any // time. // time. if (layerFEState.forceClientComposition || !profile.isDataspaceSupported(state.dataspace)) { if (layerFEState.forceClientComposition || !profile.isDataspaceSupported(state.dataspace) || forceClientComposition) { state.forceClientComposition = true; state.forceClientComposition = true; } } } } Loading Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -74,7 +74,7 @@ public: // Recalculates the state of the output layer from the output-independent // Recalculates the state of the output layer from the output-independent // layer. If includeGeometry is false, the geometry state can be skipped. // layer. If includeGeometry is false, the geometry state can be skipped. virtual void updateCompositionState(bool includeGeometry) = 0; virtual void updateCompositionState(bool includeGeometry, bool forceClientComposition) = 0; // Writes the geometry state to the HWC, or does nothing if this layer does // Writes the geometry state to the HWC, or does nothing if this layer does // not use the HWC. If includeGeometry is false, the geometry state can be // not use the HWC. If includeGeometry is false, the geometry state can be Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/impl/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -39,7 +39,7 @@ public: void setHwcLayer(std::shared_ptr<HWC2::Layer>) override; void setHwcLayer(std::shared_ptr<HWC2::Layer>) override; void updateCompositionState(bool) override; void updateCompositionState(bool includeGeometry, bool forceClientComposition) override; void writeStateToHWC(bool) override; void writeStateToHWC(bool) override; void writeCursorPositionToHWC() const override; void writeCursorPositionToHWC() const override; Loading
services/surfaceflinger/CompositionEngine/include/compositionengine/mock/OutputLayer.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -40,7 +40,7 @@ public: MOCK_CONST_METHOD0(getState, const impl::OutputLayerCompositionState&()); MOCK_CONST_METHOD0(getState, const impl::OutputLayerCompositionState&()); MOCK_METHOD0(editState, impl::OutputLayerCompositionState&()); MOCK_METHOD0(editState, impl::OutputLayerCompositionState&()); MOCK_METHOD1(updateCompositionState, void(bool)); MOCK_METHOD2(updateCompositionState, void(bool, bool)); MOCK_METHOD1(writeStateToHWC, void(bool)); MOCK_METHOD1(writeStateToHWC, void(bool)); MOCK_CONST_METHOD0(writeCursorPositionToHWC, void()); MOCK_CONST_METHOD0(writeCursorPositionToHWC, void()); Loading
services/surfaceflinger/CompositionEngine/src/Output.cpp +2 −5 Original line number Original line Diff line number Diff line Loading @@ -552,11 +552,8 @@ void Output::updateAndWriteCompositionState( ALOGV(__FUNCTION__); ALOGV(__FUNCTION__); for (auto* layer : getOutputLayersOrderedByZ()) { for (auto* layer : getOutputLayersOrderedByZ()) { if (refreshArgs.devOptForceClientComposition) { layer->updateCompositionState(refreshArgs.updatingGeometryThisFrame, layer->editState().forceClientComposition = true; refreshArgs.devOptForceClientComposition); } layer->updateCompositionState(refreshArgs.updatingGeometryThisFrame); // Send the updated state to the HWC, if appropriate. // Send the updated state to the HWC, if appropriate. layer->writeStateToHWC(refreshArgs.updatingGeometryThisFrame); layer->writeStateToHWC(refreshArgs.updatingGeometryThisFrame); Loading
services/surfaceflinger/CompositionEngine/src/OutputLayer.cpp +3 −2 Original line number Original line Diff line number Diff line Loading @@ -259,7 +259,7 @@ uint32_t OutputLayer::calculateOutputRelativeBufferTransform() const { return transform.getOrientation(); return transform.getOrientation(); } // namespace impl } // namespace impl void OutputLayer::updateCompositionState(bool includeGeometry) { void OutputLayer::updateCompositionState(bool includeGeometry, bool forceClientComposition) { const auto& layerFEState = getLayer().getFEState(); const auto& layerFEState = getLayer().getFEState(); const auto& outputState = getOutput().getState(); const auto& outputState = getOutput().getState(); const auto& profile = *getOutput().getDisplayColorProfile(); const auto& profile = *getOutput().getDisplayColorProfile(); Loading Loading @@ -294,7 +294,8 @@ void OutputLayer::updateCompositionState(bool includeGeometry) { // These are evaluated every frame as they can potentially change at any // These are evaluated every frame as they can potentially change at any // time. // time. if (layerFEState.forceClientComposition || !profile.isDataspaceSupported(state.dataspace)) { if (layerFEState.forceClientComposition || !profile.isDataspaceSupported(state.dataspace) || forceClientComposition) { state.forceClientComposition = true; state.forceClientComposition = true; } } } } Loading