Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 06993503 authored by Dave Burke's avatar Dave Burke Committed by Android (Google) Code Review
Browse files

Merge "only clear FB when asked for the opaque layer" into klp-dev

parents 93573e91 ac68302e
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1597,9 +1597,10 @@ void SurfaceFlinger::doComposeSurfaces(const sp<const DisplayDevice>& hw, const
            if (!clip.isEmpty()) {
                switch (cur->getCompositionType()) {
                    case HWC_OVERLAY: {
                        const Layer::State& state(layer->getDrawingState());
                        if ((cur->getHints() & HWC_HINT_CLEAR_FB)
                                && i
                                && layer->isOpaque()
                                && layer->isOpaque() && (state.alpha == 0xFF)
                                && hasGlesComposition) {
                            // never clear the very first layer since we're
                            // guaranteed the FB is already cleared