Enable effect layers with blur

Change-Id: Ia13f0b6d816aa918433297567735482dc5b3502e
Test: launch apps
Bug: 149792636
Fixes: 148804546
diff --git a/services/surfaceflinger/EffectLayer.cpp b/services/surfaceflinger/EffectLayer.cpp
index 9d45e33..44d4d75 100644
--- a/services/surfaceflinger/EffectLayer.cpp
+++ b/services/surfaceflinger/EffectLayer.cpp
@@ -69,6 +69,8 @@
         // Set color for color fill settings.
         layerSettings->source.solidColor = getColor().rgb;
         results.push_back(*layerSettings);
+    } else if (hasBlur()) {
+        results.push_back(*layerSettings);
     }
 
     return results;
@@ -148,6 +150,10 @@
             mDrawingState.color.b >= 0.0_hf;
 }
 
+bool EffectLayer::hasBlur() const {
+    return getBackgroundBlurRadius() > 0;
+}
+
 } // namespace android
 
 // TODO(b/129481165): remove the #pragma below and fix conversion issues
diff --git a/services/surfaceflinger/EffectLayer.h b/services/surfaceflinger/EffectLayer.h
index 33758b6..1dcb633 100644
--- a/services/surfaceflinger/EffectLayer.h
+++ b/services/surfaceflinger/EffectLayer.h
@@ -62,7 +62,9 @@
 private:
     // Returns true if there is a valid color to fill.
     bool fillsColor() const;
-    bool hasSomethingToDraw() const { return fillsColor() || drawShadows(); }
+    // Returns true if this layer has a blur value.
+    bool hasBlur() const;
+    bool hasSomethingToDraw() const { return fillsColor() || drawShadows() || hasBlur(); }
 };
 
 } // namespace android