Ensure that blurRegions take into account the buffers rotation.

Some tranformations are applied to content rendered into a buffer that
are unknown to the UI (e.g. Android View) that drew it. That is the case
for blurRegions so we must provide a matrix that translates the contents
of the blurRegion into the same coordinate space used by the other
geometry in RenderEngine's LayerSettings.

Bug: 185228719
Test: atest librenderengine_test and SilkFX demo
Change-Id: I4e3144bac678ffff2f29f3270d589e9f3fe94634
diff --git a/services/surfaceflinger/Layer.cpp b/services/surfaceflinger/Layer.cpp
index 4461420..7707aaf 100644
--- a/services/surfaceflinger/Layer.cpp
+++ b/services/surfaceflinger/Layer.cpp
@@ -632,6 +632,8 @@
     if (!targetSettings.disableBlurs) {
         layerSettings.backgroundBlurRadius = getBackgroundBlurRadius();
         layerSettings.blurRegions = getBlurRegions();
+        layerSettings.blurRegionTransform =
+                getActiveTransform(getDrawingState()).inverse().asMatrix4();
     }
     layerSettings.stretchEffect = getDrawingState().stretchEffect;
     // Record the name of the layer for debugging further down the stack.