Skip to content

Commit 14fd41a

Browse files
committed
Don't skip blurring recently-decomposed cachedsets.
If we had found that a cachedset had a blur effect applied, then we tell the layer requesting the blur to skip blurring. This is so that we do not blur twice. But, this does not hold if we needed to update a cachedset, meaning that the blur effect was no longer applied. This was previously causing us to never render a blur. Bug: 390403736 Change-Id: I4389a8c73b20556abe392fe3b464408c6775fc34 Flag: EXEMPT bug fix Test: Notification shade + blurs
1 parent 5a2c613 commit 14fd41a

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

  • services/surfaceflinger/CompositionEngine/src/planner

services/surfaceflinger/CompositionEngine/src/planner/Flattener.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,7 @@ bool Flattener::mergeWithCachedSets(const std::vector<const LayerState*>& layers
325325
priorBlurLayer == (*incomingLayerIter)->getOutputLayer();
326326
OutputLayer::CompositionState& state =
327327
(*incomingLayerIter)->getOutputLayer()->editState();
328+
328329
state.overrideInfo = {
329330
.buffer = mNewCachedSet->getBuffer(),
330331
.acquireFence = mNewCachedSet->getDrawFence(),
@@ -378,6 +379,7 @@ bool Flattener::mergeWithCachedSets(const std::vector<const LayerState*>& layers
378379
};
379380
++incomingLayerIter;
380381
}
382+
priorBlurLayer = currentLayerIter->getBlurLayer();
381383
} else if (currentLayerIter->getLayerCount() > 1) {
382384
// Break the current layer into its constituent layers
383385
++mInvalidatedCachedSetAges[currentLayerIter->getAge()];
@@ -400,8 +402,8 @@ bool Flattener::mergeWithCachedSets(const std::vector<const LayerState*>& layers
400402
currentLayerIter->updateAge(now);
401403
merged.emplace_back(*currentLayerIter);
402404
++incomingLayerIter;
405+
priorBlurLayer = currentLayerIter->getBlurLayer();
403406
}
404-
priorBlurLayer = currentLayerIter->getBlurLayer();
405407
++currentLayerIter;
406408
}
407409

0 commit comments

Comments
 (0)