title: Android make bitmap opaque against background color
body: <p>Given a bitmap, I know how to make an ImageView more transparent by setting alpha.  But I want to also set a white background color (different from the view its sitting on), so it appears more opaque than transparent. </p>
  
  <p>Referring to the image below,</p>
  
  <blockquote>
    <p>I get the left pic using , ImageView.SetBitmapImage(bitmap).<br>
    Using ImageView.SetAlpha = 0.5, I get the middle pic<br>
    but how do I get the right pic.</p>
  </blockquote>
  
  <p><a href="https://i.stack.imgur.com/3G0Zh.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3G0Zh.png" alt="enter image description here"></a></p>
  
  <p>Also, in my axml, I have set the ImageView background color to white, but it still doesn't help...I still get the middle pic.</p>
  
  <pre><code>     &lt;ImageView
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:background="#FFFFFF" /&gt;
  </code></pre>