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

Commit f31b4bc6 authored by Leon Scroggins III's avatar Leon Scroggins III
Browse files

Revert "RenderEngine: don't blur when using protected content"

This reverts commit 247b2418.

We've fixed the issue in other CLs, so now we no longer need the
workaround.

Bug: 244398863
Bug: 213116783
Fixes: 270314344
Fixes: 205516620
Fixes: 242266174
Test: manual (ExoPlayer)
Change-Id: I6a7033360840b5caf0b84b56df25a44d9c789988
parent ade5478f
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -709,9 +709,7 @@ void SkiaRenderEngine::drawLayersInternal(
    SkCanvas* canvas = dstCanvas;
    SkiaCapture::OffscreenState offscreenCaptureState;
    const LayerSettings* blurCompositionLayer = nullptr;

    // TODO (b/270314344): Enable blurs in protected context.
    if (mBlurFilter && !mInProtectedContext) {
    if (mBlurFilter) {
        bool requiresCompositionLayer = false;
        for (const auto& layer : layers) {
            // if the layer doesn't have blur or it is not visible then continue
@@ -805,8 +803,7 @@ void SkiaRenderEngine::drawLayersInternal(
        const auto [bounds, roundRectClip] =
                getBoundsAndClip(layer.geometry.boundaries, layer.geometry.roundedCornersCrop,
                                 layer.geometry.roundedCornersRadius);
        // TODO (b/270314344): Enable blurs in protected context.
        if (mBlurFilter && layerHasBlur(layer, ctModifiesAlpha) && !mInProtectedContext) {
        if (mBlurFilter && layerHasBlur(layer, ctModifiesAlpha)) {
            std::unordered_map<uint32_t, sk_sp<SkImage>> cachedBlurs;

            // if multiple layers have blur, then we need to take a snapshot now because