title: Drop shadow blur effect on a FrameLayout / Layout in Android
body: <p>I'm trying to make a drop shadow blur effect WITH COLOR on a rectangular layout view. I've tried to use this code but to no avail.</p>
  
  <pre><code>    int glowRadius = 14;
  
      int glowColor = Color.parseColor("#acc5fe");
  
      Paint paint = new Paint();
      paint.setColor(glowColor);
  
      paint.setMaskFilter(new BlurMaskFilter(glowRadius, BlurMaskFilter.Blur.OUTER));
      RectF rectF = new RectF(mRootView.getHeight(), mRootView.getWidth(),
              mRootView.getHeight(), mRootView.getWidth());
      Canvas canvas = new Canvas();
      canvas.drawRect(rectF, paint);
      mRootView.draw(canvas);
  </code></pre>
  
  <p>It doesn't seem to do anything though.
  I also tried to use shadowDx and shadowDy etc. but that does nothing.</p>
  
  <p><a href="https://stackoverflow.com/questions/47674828/how-to-add-a-blurred-drop-shadow-to-a-button">How to add a blurred drop shadow to a button?</a> is a very similar question but I don't think the 9-patch is a viable solution since it's a layout and not an image.</p>
  
  <p><strong>How do you create a drop outer shadow blur effect on Android?</strong></p>
  
  <p><strong>Update</strong></p>
  
  <p>Still haven't found a successful answer. I want something like</p>
  
  <p><a href="https://i.stack.imgur.com/48HtY.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/48HtY.png" alt="example blur"></a></p>
  
  <p>where the shadow effect is on the email edittext with a different color than black.</p>