title: How to replicate iOS 7 Blur View in Android
body: <p>I like the style iOS 7 has used for their <strong>Notification</strong> and <strong>Music</strong> popover like below.</p>
  
  <p><img src="https://i.stack.imgur.com/MIYZa.jpg" alt="enter image description here"></p>
  
  <p>So, I try to implement this thing in Android. After doing some search, I achieved how to do that. What I have tried is following.</p>
  
  <p><strong>1) First I take a root reference of the View and take a snap of it using <code>getDrawingCache()</code> function of View.</strong></p>
  
  <pre><code>linearLayout.buildDrawingCache();
  SoftReference&lt;Bitmap&gt; bitmap = new SoftReference&lt;Bitmap&gt;(
              Bitmap.createBitmap(linearLayout.getDrawingCache()));
  linearLayout.destroyDrawingCache();
  </code></pre>
  
  <p><strong>2) I take the position relative to its parent and cut the image as per requirement.</strong></p>
  
  <pre><code>SoftReference&lt;Bitmap&gt; temp = new SoftReference&lt;Bitmap&gt;(
              Bitmap.createBitmap(bitmap.get(), 0,
                      (parentHeight - childHeight), childWidth, childHeight));
  </code></pre>
  
  <p><strong>3) I make that bitmap image blur with some algorithm. ( I use <a href="https://stackoverflow.com/questions/2067955/fast-bitmap-blur-for-android-sdk">Fast Bitmap Blur For Android SDK</a> <em>fastBlur</em> effect )</strong></p>
  
  <p><strong>4) set it in the overlay view.</strong></p>
  
  <pre><code>imageView1.setImageBitmap(Utils.fastblur(temp.get(), 8));
  </code></pre>
  
  <p>But my problem is it takes time to take a snap then giving blur effect and cutting image and then i got final result. While iOS has very fast blurring process like when drawer is coming from bottom, it immediately blur the screen which is behind it.</p>
  
  <p>Is there any other way to achieve that? Because using my scenario, i can't take every second snap of screen and do all process 1 to 4 every second on every move of drawer. </p>